-
Notifications
You must be signed in to change notification settings - Fork 422
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Vitis accelerator #991
base: main
Are you sure you want to change the base?
Vitis accelerator #991
Conversation
e92a6be
to
86f75b5
Compare
Squashed commit of all the work done by Konstantinos Axiotis prior to merge with Alex Yang work.
c875785
to
64c8baa
Compare
- use backend specific target parameter - remove environnement checks that are also performed in the makefile
@@ -865,6 +865,14 @@ class TraceData(ctypes.Structure): | |||
else: | |||
return output, trace_output | |||
|
|||
def hardware_predict(self, x, **kwargs): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This method has been added to enable performing predictions directly on the FPGA from the Python code. It feels a bit intrusive to add this backend-specific code to the hls4ml core. Another approach could be to modify predict()
to allow backend-specific overloading. So, model.hardware_predict(x)
could become model.predict(x, target='hw')
, but this also requires some modification of the existing core code. Could an hls4ml dev provide advice on the best approach here? (@vloncar, @jmitrevs?). Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would be in favor of naming this somewhat different (predict_hw
for example) and moving the exception to backends (in FPGABackend
should be enough to cover those that don't/cannot support it).
Some longer term idea here would be that we would have 3 ways of doing preciction: predict_emu
(emulation, the current one), predict_sim
(simulation via pyverilator) and predict_hw
(real deal), with the predict
being predict_emu
by default with maybe a switch for user to control which one is called if it's just predict(x)
.
Description
The Vitis Accelerator Backend builds upon the foundation laid by the Vitis backend and streamlines the generation process for PCIe accelerators using the Vitis Accelerator Flow.
Features:
Type of change
For a new feature or function, please create an issue first to discuss it
with us before submitting a pull request.
Note: Please delete options that are not relevant.
Tests
The backend has been tested with the hls4ml getting started tutorial example.
Test Configuration:
The Vitis version used for the validation is 2022.2.
The functionality of the project was tested on a VCK5000 accelerator board.
Checklist
pre-commit
on the files I edited or added.