Skip to content

Fix Quantity merging across concatenation semantics - #1979

Open
emanueldellipaoli01-a11y wants to merge 1 commit into
NeuralEnsemble:masterfrom
emanueldellipaoli01-a11y:fix-1978-quantity-merge-compat
Open

emanueldellipaoli01-a11y wants to merge 1 commit into
NeuralEnsemble:masterfrom
emanueldellipaoli01-a11y:fix-1978-quantity-merge-compat

Conversation

@emanueldellipaoli01-a11y

Copy link
Copy Markdown

This PR fixes inconsistencies when merging Neo objects containing Quantity values, making the behavior more reliable across different versions of the quantities library.

The changes handle unit conversion explicitly before concatenation, avoiding unexpected behavior caused by differences in how quantities interacts with np.concatenate. They also address merging of UncertainQuantity annotations and SpikeTrainList objects, along with related cases in other Neo objects.

Regression tests have been added to cover the affected functionality, including relevant IO-related cases, and to ensure that compatible quantities expressed in different units are merged consistently.

This branch has not been deployed

No deployments
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.

1 participant