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

match_time_inds fails #750

Closed
daniel-klein opened this issue Nov 8, 2024 · 1 comment
Closed

match_time_inds fails #750

daniel-klein opened this issue Nov 8, 2024 · 1 comment
Milestone

Comments

@daniel-klein
Copy link
Contributor

    def match_time_inds(self, inds=None):
         """ Find the nearest matching sim time indices for the current module """
         if inds is None: inds = Ellipsis
         self_tvec = self.t.abstvec
         sim_tvec = self.sim.t.abstvec
         if len(self_tvec) == len(sim_tvec): # Shortcut to avoid doing matching
             return inds
         else:
             out = sc.findnearest(sim_tvec, [inds])
             return out

The function is called with inds=None, so inds will be set to Ellipsis. But sc.findnearest doesn't like Ellipsis, resulting in an exception.

@cliffckerr
Copy link
Contributor

Closed by #749

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

No branches or pull requests

2 participants