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

Run.get_image has arguments with names that differ from labscript args #53

Open
philipstarkey opened this issue Aug 17, 2019 · 1 comment
Labels
bug Something isn't working trivial

Comments

@philipstarkey
Copy link
Member

Original report (archived issue) by Chris Billington (Bitbucket: cbillington, GitHub: chrisjbillington).


Lyse's Run.get_image accepts 'label' and 'image' kwargs to specify the two possible levels of the hierarchy we use to store images. However, Camera.expose, IMAXdxCamera.expose etc call these 'name' and 'frametype'.

The lyse args should be changed to match the labscript ones with backward compatibility, something like:

def get_image(self, orientation, name=None, frametype=None, **kwargs):
    name = kwargs.pop('image', name)
    frametype = kwargs.pop('label', frametype)
    if kwargs:
        # raise an error saying remaining kwargs not allowed
    if name is None or frametype is None:
        # raise an error about this too, they are non-optional.
        # Better yet, make 'frametype' optional with the default value
        # matching that of the expose() method: frametype='frame'.
        # name can't be optional though.
    # rest of function here with renamed variables
@philipstarkey
Copy link
Member Author

Original comment by Chris Billington (Bitbucket: cbillington, GitHub: chrisjbillington).


  • Edited issue description

@philipstarkey philipstarkey added trivial bug Something isn't working labels Apr 5, 2020
Loki27182 pushed a commit to Loki27182/lyse that referenced this issue Oct 9, 2023
Update for pandas deprecated functions.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working trivial
Projects
None yet
Development

No branches or pull requests

1 participant