fastmachinelearning / hls4ml

Machine learning on FPGAs using HLS
https://fastmachinelearning.org/hls4ml
Apache License 2.0
1.24k stars 402 forks source link

Add option to configure IP version #851

Closed AdrianAlan closed 1 year ago

AdrianAlan commented 1 year ago

A small change of adding an option to specify the IP version, defaulting to 1.0.0.

Motivation: although it is a long time since the Y2K22 issue I hear people still run into it when running on systems where admins didn't install the patch. The same workaround was suggested in here. Issue mentioned in #633.

Type of change

Tests

Please suggest tests for this change.

Checklist

vloncar commented 1 year ago

Nice!

But how would one set a version using the public API? The only way to use it is to create the config manually and call the keras_to_hls() or set it after the ModelGraph was created but before the write() is called.

AdrianAlan commented 1 year ago

Now it should be possible to specify it through hls4ml.converters.create_config as well. Is there another way you thought about it?

PS Wouldn't you have the same concern about ClockUncertainty?

vloncar commented 1 year ago

Looks good. It failed for the accelerator backend, so I added support for it as well.