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

Add ipytree support (Jupyter widget for tree-structured data) #2522

Closed
tylere opened this issue Dec 20, 2021 · 3 comments
Closed

Add ipytree support (Jupyter widget for tree-structured data) #2522

tylere opened this issue Dec 20, 2021 · 3 comments
Assignees
Labels

Comments

@tylere
Copy link

tylere commented Dec 20, 2021

Add support for the ipytree within Colab.

Screen Shot 2021-12-20 at 11 50 14 AM

Is your feature request related to a problem? Please describe.
When working with geospatial data, there is often a need to inspect layers of information (often nested) for a region of interest. With the addition of Colab support for ipyleaflet, there is a way to display and interact with spatial data, but there is a related need to display layer data.

Describe the solution you'd like
Provide a way to install and use the third-oarty jupyter widget ipytree. A good test case would be the ability to run the ipytree_ileaflet example.

Describe alternatives you've considered
I have considered manually building simple trees using the standard jupyter widgets, but that seems like reinventing the wheel...

Additional context
When trying to display an ipytree widget in Colab, Chrome developer tools reports a 404 error accessing the following:

manager.min.js:1654` GET https://cdn.jsdelivr.net/npm/[email protected]/dist/index.js 404

I confirmed that the file is not accessible from the CDN, however, there are other related CDN files for [email protected]
https://www.jsdelivr.com/package/npm/ipytree

@giswqs
Copy link

giswqs commented Dec 20, 2021

I second the support for ipytree @martinRenou. I have a Python package for geospatial analysis called whiteboxgui, which is used by geemap and leafmap. I implemented it using both ipywidgets and ipytree. Currently, only the ipywdigets version works in Google Colab. Here is a notebook example image image

Implemented using ipywidgets
image

Implemented using ipytree
image

Demo
tutorial

@blois blois self-assigned this Dec 20, 2021
@blois
Copy link
Contributor

blois commented Dec 20, 2021

The ipytree_ipyleaflet.ipynb example appears to work using ipytree==0.2.0:

https://colab.research.google.com/gist/blois/1af162473872445cbece540ffe6830c4/untitled1200.ipynb

The dist/ folder does not appear in the 0.2.1 release.

@tylere
Copy link
Author

tylere commented Dec 21, 2021

Closing since Colab support is working as intended... just need to get the CDN copy corrected.

@tylere tylere closed this as completed Dec 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants