-
Notifications
You must be signed in to change notification settings - Fork 42
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
Reduce duplication 1 #1050
Merged
Merged
Reduce duplication 1 #1050
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
samuelbray32
requested changes
Aug 1, 2024
Co-authored-by: Samuel Bray <sam.bray@ucsf.edu>
samuelbray32
approved these changes
Aug 1, 2024
edeno
approved these changes
Aug 1, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This is a tidying PR that aims to (a) merge existing fully duplicated functions, and (b) increase similarity across functions that will be merged in future PRs. The latter is included as an initial step to make sure what I see as similar is intended as such. This includes cases where the newer version of something was improved without giving the same stylistic edits or additional functionality to the old version.
This partially addresses #977, per checklist in most recent comment.
common_ephys.py
, B: add spacing/line breaks to reflect updated versioncommon_position.py
, B: Add default value for unused variable.decoding/utils.py
, A: Common location for_get_peak_amplitude
. Updated V0 to pass the waveform extractor instead of waveformdecoding/v0/
discretize_and_trim
get_time_bins_from_interval
make_default_decoding_params
- required some additional control-flow for cpu/gpu and clusterless/spikes.get_X_data
decoding/v1/
clusterless
, B: addtrack_graph
andtime_slice
params/functionalityget_orientation_name
linearization/v1/main
, B: make table definition comments/spacing like V0 defposition/v1/dlc_utils
, A: import funcs fromcommon
ripple/v1/ripple
, A: import func from prev versionspikesorting_merge
, B: add smoothing sigma param with defaultspikesorting_curation
spikesorting/v1/curation
spikesorting/v1/recording
spikesorting/utils.py
, A: Extracting core logic ofset_group_by_shank
into a function that returns insert candidates for parent functions to run. Internal logic otherwise the samespikesorting/v0/curation_figurl
, B: Updated to reflect V1 version that uses comprehension over for loopsspikesorting/vX/artifact
, B: Reflow of docstring, migrate variable reassignment to withinChunkRecordingExecutor
call.Other changes:
decoding_merge
: removed unused importdecoding/v1/core
: remove reference to undefined variable in error messageget_networkx
methodsChecklist:
CITATION.cff
alter
snippet for release notes.CHANGELOG.md
with PR number and description.