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

Calling to_dict() early prevents to_python() late #32

Open
mccalluc opened this issue Mar 8, 2022 · 0 comments
Open

Calling to_dict() early prevents to_python() late #32

mccalluc opened this issue Mar 8, 2022 · 0 comments

Comments

@mccalluc
Copy link
Contributor

mccalluc commented Mar 8, 2022

in imaging_builders.py:

        vc = self._setup_view_config_raster(vc, dataset)
        conf = vc.to_dict()
        # Don't want to render all layers
        del conf["datasets"][0]["files"][0]["options"]["renderLayers"]
        return get_conf_cells(
            conf, f'TODO: Confirm that this notebook works! {type(self).__name__}')

The problem is that at this point, conf isn't really a Vitessce view config object: It's just a dict, so we can't call to_python on it to make a notebook.

  • Is there some way to build the conf so that it doesn't have the stuff we don't want?
  • If that's hard, how bad would it be if we left the view conf intact?

Chuck:

Do you know if there’s a way to construct the Vitessce conf so it doesn’t have the renderLayers to begin with? Maybe that would require a change in the vitessce-python?

If that’s not feasible, maybe we do just dump the JSON to the notebook, since to_python can’t be used on a regular dict. I don’t think that would be the end of the world.

Ilan:

I think that would require a change, but we may have added the feature and then never updated things here. I’d have to check.

So yes this would require a change to Vitessce python. It adds all the images right now and is hard coded to do so

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

1 participant