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

Instead of using the smallest step size, search for a step size that works for all stimuli #345

Open
bparks13 opened this issue Oct 22, 2024 · 0 comments · May be fixed by #347
Open

Instead of using the smallest step size, search for a step size that works for all stimuli #345

bparks13 opened this issue Oct 22, 2024 · 0 comments · May be fixed by #347
Assignees
Labels
bug Something isn't working
Milestone

Comments

@bparks13
Copy link
Member

Currently, the logic is that the step size should remain the same as the current step size if possible, and if this is not possible, the new step size will be the smallest possible step size to accommodate the requested amplitude. This causes issues if the rest of the stimuli are too large to fit within the smallest step size.

Instead, we should evaluate the existing stimuli by taking their current amplitudes, and comparing them to the list of possible step sizes for the new amplitude. Search for a step size that works for all amplitudes (i.e., the steps are between 1 and 255). Choose the step size that accomplishes this.

If no such step size exists (the amplitudes are too far apart to be bridged by a common step size), give an error message immediately that the requested amplitude is outside of the bounds of the current step size. If the user continues forward, then allow them to set the new amplitude and override the existing step size, clearing the stimuli for channels that do not fit into the new step size, similar to how it is currently performed.

@bparks13 bparks13 added the bug Something isn't working label Oct 22, 2024
@bparks13 bparks13 added this to the 0.4.1 milestone Oct 22, 2024
@bparks13 bparks13 self-assigned this Oct 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant