lava-nc / lava-dl

Deep Learning library for Lava
https://lava-nc.org
BSD 3-Clause "New" or "Revised" License
149 stars 71 forks source link

Bug Fix - IO Binning Mode. Signed by pbonazzi #244

Closed pbonazzi closed 6 months ago

pbonazzi commented 11 months ago

Issue Number: #235

Objective of pull request: Fix the bug of Event.fill_tensor(binning_mode="SUM") which was not performing as expected.

Pull request checklist

Your PR fulfills the following requirements:

Pull request type

Please check your PR type:

What is the current behavior?

What is the new behavior?

Does this introduce a breaking change?

Supplemental information

The implementation uses np.add.at because torch introduced the function torch.index_add only in versions >= 2.0 and I didn't want to introduce versioning issues.

bamsumit commented 11 months ago

@pbonazzi looks like there are linting error, please fix them. Look at the errors here or run linting locally using flakeheaven lint src/lava tests