MAAP-Project / stac_ipyleaflet

Apache License 2.0
29 stars 2 forks source link

Refactor Dependencies #128

Open wildintellect opened 9 months ago

wildintellect commented 9 months ago

Description

In order to make stac_ipyleaflet widely compatible with many containerized images, we need to be stricter about not pulling in large dependencies. https://github.com/MAAP-Project/stac_ipyleaflet/blob/main/requirements.txt needs to be revisited to clean up unused library imports.

Example: Xarray and rio_tiler appear to only be used for the commented out sections following https://github.com/MAAP-Project/stac_ipyleaflet/blob/35ded6cc4b49277a6709dd1b130ae3eb111d44f7/stac_ipyleaflet/core.py#L510 If we can avoid Xarray as a dependency that would be good.

An alternative would be to make optional dependencies. Features that are only available if dependencies are installed.

wildintellect commented 9 months ago

@anilnatha until this is solved looks like we should only use stac_ipyleaflet in pangeo based workspaces that already include Xarray.

emmalu commented 9 months ago

My initial thoughts on what can be removed:

anilnatha commented 9 months ago

I noticed the project has a requirements.txt file and dependencies are also listed in the setup.cfg file, if these could be consolidated to the setup.cfg it may make it easier to maintain the dependency list.