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

Some improvements to time handling #3546

Open
JoeZiminski opened this issue Nov 20, 2024 · 0 comments
Open

Some improvements to time handling #3546

JoeZiminski opened this issue Nov 20, 2024 · 0 comments
Labels
core Changes to core module

Comments

@JoeZiminski
Copy link
Collaborator

As discussed in #3509, some improvements to the time-handling could be made:

  1. get_times() returns a view to the segment time_vector if it exist. This means that changing the returned array will also change the one stored on the segment. This is different behaviour to if .t_start is used under the hood, as the array will be generated on the fly. I think everyone is agreed that get_times() should return a copy of the time_vector (if it exists).

  2. copy.deepcopy(recording) or I think recording.clone() does not copy the time_vector. This is discussed here. An fix could be:

What about times for clone()? This is not handled at the BaseExtractor level but the BaseRecording could override it or add an clone_extra_stuff() in base class and the BaseRecording could just implement it
@alejoe91 alejoe91 added the core Changes to core module label Nov 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Changes to core module
Projects
None yet
Development

No branches or pull requests

2 participants