Skip to content
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

Implement strategies for ReadGate/SolutionReadout #139

Open
2 tasks done
AlessandroPierro opened this issue Nov 28, 2022 · 2 comments
Open
2 tasks done

Implement strategies for ReadGate/SolutionReadout #139

AlessandroPierro opened this issue Nov 28, 2022 · 2 comments
Assignees
Labels
0-needs-review Has to be reviewed. 1-feature New feature or request 2-not-important/not-urgent

Comments

@AlessandroPierro
Copy link
Collaborator

Objective of issue: propose implementation of different reading strategies for ReadGate/SolutionReadout

lava-optimization version:

  • 0.2.2 (current version)

I'm submitting a ...

  • feature request

Current behavior:

  • ReadGate/SolutionReadout of OptimizationSolver store and communicate only the best found solution, along with the associated cost and time step, for performance reasons.

Expected behavior:

  • For profiling and research purposes, it would be useful to have the possibility to specify an alternative reading strategy, e.g. communicating the new solution each time the cost improves.
@GaboFGuerra
Copy link
Collaborator

GaboFGuerra commented Jan 12, 2023

We had the expected behavior in a previous release and it was removed in the last one in favor of the current behavior. We should bring back the previous version which I would have left as default and offered the most performant version as optional. The reason being that the cost in performance is relatively low and the user experience is much better if the user can track the evolution of the search.

Also, are we sure we are providing the best solution if target cost was not found? In a debug session one user was getting an all -1 vector when target_cost was not found. Maybe we need a test for this.

But @AlessandroPierro, how are you envisioning the strategy implementation? We can probably not support a fully generic strategy easily, because it requires changing the CostIntegrator (microcode) and ReadGate (C) processes. Thus, we would only allow the user to switch between streaming every better cost or only the best. Right?

@AlessandroPierro
Copy link
Collaborator Author

We had the expected behavior in a previous release and it was removed in the last one in favor of the current behavior. We should bring back the previous version which I would have left as default and offered the most performant version as optional. The reason being that the cost in performance is relatively low and the user experience is much better if the user can track the evolution of the search.

I agree for CPU backend, but on Loihi we observed 100x speedup. We can redesign this now using StateProbes. I would leave the most performant version for the ReadGate/SolutionReadout and delegate the finer tracking to a probe_cost flag as we discussed. What do you think? @GaboFGuerra

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0-needs-review Has to be reviewed. 1-feature New feature or request 2-not-important/not-urgent
Projects
None yet
Development

No branches or pull requests

4 participants