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

Enable injecting Python generated Stimuli [vcs: #minor] #142

Merged
merged 30 commits into from
Mar 4, 2024
Merged

Conversation

anilbey
Copy link
Contributor

@anilbey anilbey commented Feb 26, 2024

Adds a layer to create stimuli in Python and combine them with + operator. It does not use NEURON and it is not dependent on the Cell module. The current trace of each generated stimuli can be retrieved consistently.

Changes

  • Add StimulusFactory enabling Python generated Stimulus creation
  • Stimulus creation through StimulusFactory is decoupled from the Cell object
  • Cell.add_step and Cell.add_ramp use StimulusFactory
  • Move stimuli module to stimulus/circuit_stimulus_definitions
  • [DOCS] Add list of stimuli page that describe, generate and plot the stimuli
  • Add jupyter notebook displaying how to inject the StimulusFactory Stimulus into Cell

@codecov-commenter
Copy link

codecov-commenter commented Feb 26, 2024

Codecov Report

Attention: Patch coverage is 96.61654% with 9 lines in your changes are missing coverage. Please review.

Project coverage is 89.23%. Comparing base (d7a5240) to head (e39fd4d).
Report is 11 commits behind head on main.

Files Patch % Lines
tests/test_stimulus/test_factory.py 94.89% 5 Missing ⚠️
bluecellulab/stimulus/factory.py 97.41% 3 Missing ⚠️
bluecellulab/cell/injector.py 95.65% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #142      +/-   ##
==========================================
+ Coverage   85.30%   89.23%   +3.92%     
==========================================
  Files          80       87       +7     
  Lines        5404     5387      -17     
==========================================
+ Hits         4610     4807     +197     
+ Misses        794      580     -214     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@anilbey anilbey marked this pull request as ready for review February 27, 2024 08:35
@anilbey anilbey closed this Feb 27, 2024
@anilbey anilbey reopened this Feb 27, 2024
@anilbey anilbey force-pushed the injector branch 11 times, most recently from eaa09d6 to 5c735bc Compare February 29, 2024 10:45
@anilbey anilbey changed the title make injector module's protocol signatures consistent Enable injecting Python generated Stimuli Mar 4, 2024
@anilbey anilbey changed the title Enable injecting Python generated Stimuli Enable injecting Python generated Stimuli [vcs: #minor] Mar 4, 2024
Copy link
Contributor

@darshanmandge darshanmandge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @anilbey! It's nice that you have added tests and example notebook for the new stimuli. It looks good to me. It is good to merge if it is fine for the GUI @stefanoantonel

@stefanoantonel
Copy link

Looks good to me!
If you can just put an example of how to reproduce at least the patterns that we see on the OpenBrainPlatform that would be helpful

@anilbey anilbey merged commit afded40 into main Mar 4, 2024
10 checks passed
@anilbey anilbey deleted the injector branch March 4, 2024 15:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants