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

[Fix] z score inplace #592

Merged

Conversation

Moritz-Alexander-Kern
Copy link
Member

This PR closes #591 .

Changes:

The check for the signal type when using z_score inplace was changed from:

 if inplace and not np.issubdtype(float, sig.dtype): 

to:

if inplace and not np.issubdtype(sig.dtype, np.floating):

Additionally a regression unittest was added.

This was originally discovered in the Elephant_Tutorial_-_LFP_analysis.ipynb notebook, see also https://tutorials.python-elephant.org .

@Moritz-Alexander-Kern Moritz-Alexander-Kern added the bugfix Fix for an indentified bug. label Aug 30, 2023
@coveralls
Copy link
Collaborator

Coverage Status

coverage: 86.64% (-0.3%) from 86.977% when pulling 31e6257 on INM-6:fix/z_score_inplace into 2bd871a on NeuralEnsemble:master.

@Moritz-Alexander-Kern Moritz-Alexander-Kern changed the title Fix/z score inplace [Fix] z score inplace Aug 30, 2023
@Moritz-Alexander-Kern Moritz-Alexander-Kern added this to the v0.14.0 milestone Sep 18, 2023
Copy link
Member Author

@Moritz-Alexander-Kern Moritz-Alexander-Kern left a comment

Choose a reason for hiding this comment

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

build wheels

@Moritz-Alexander-Kern Moritz-Alexander-Kern merged commit 0354d0e into NeuralEnsemble:master Oct 20, 2023
@Moritz-Alexander-Kern Moritz-Alexander-Kern deleted the fix/z_score_inplace branch November 6, 2023 14:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix Fix for an indentified bug.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug] signal_processing.zscore: Cannot perform inplace operation for np.float 32 and np.float64
3 participants