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

Rename and docs update rebase #91

Merged
merged 10 commits into from
Aug 15, 2024
2 changes: 1 addition & 1 deletion .binder/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
pan3d[viewer]
pan3d[all]
imageio
trame-jupyter-extension
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,6 @@ jobs:
pip install .
pip install -r tests/requirements.txt
pytest -s ./tests/test_builder.py
pip install .[viewer]
pip install .[geotrame]
pytest -s ./tests/test_viewer.py
working-directory: .
2 changes: 1 addition & 1 deletion .github/workflows/test_and_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ jobs:
pip install .
pip install -r tests/requirements.txt
pytest -s ./tests/test_builder.py
pip install .[viewer]
pip install .[geotrame]
pytest -s ./tests/test_viewer.py
working-directory: .

Expand Down
2 changes: 1 addition & 1 deletion docker/scripts/build_image.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
CURRENT_DIR=`dirname "$0"`

cd $CURRENT_DIR/../..
docker build -t pan3d-viewer . -f docker/Dockerfile
docker build -t geotrame . -f docker/Dockerfile
cd -
2 changes: 1 addition & 1 deletion docker/scripts/run_image.sh
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
#!/usr/bin/env bash
docker run -it --rm -p 8080:80 pan3d-viewer
docker run -it --rm -p 8080:80 geotrame
2 changes: 1 addition & 1 deletion docker/setup/apps.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
trame: # Default app under /index.html
app: pan3d-viewer
app: geotrame
41 changes: 22 additions & 19 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,22 @@

Pan3D aims to be an utility package for viewing and processing a wide variety of multidimensional datasets. Any dataset that can be interpreted with [xarray][xarray-link] can be explored and rendered with Pan3D.

GeoTrame is a Pan3D application focused on geospatial rendering use cases. This is a graphical user interface leveraging the Pan3D infrastructure to help geospatial scientists explore data.

![](images/0.png)

For an introduction to this project, check out our [blog post][blog-post-link].


## Installation

To install requirements for the DatasetBuilder class only:
To install requirements for the Pan3D DatasetBuilder class only:

pip install pan3d

To install requirements for the DatasetViewer user interface:
To install requirements for the GeoTrame user interface:

pip install "pan3d[viewer]"
pip install "pan3d[geotrame]"

**Optional**: to install requirements for Pangeo and ESGF catalogs, respectively:

Expand All @@ -37,44 +39,45 @@ To install requirements for the DatasetViewer user interface:

## Quick Start

`pan3d-viewer` is the main entrypoint for launching Pan3D locally. Below are some example usages.
`geotrame` is the main entrypoint for launching GeoTrame locally. Below are some example usages.

To launch Pan3D without a target dataset to browse XArray examples:
To launch GeoTrame without a target dataset to browse XArray examples:

pan3d-viewer
geotrame

To launch Pan3D with a local path to a target dataset:
To launch GeoTrame with a local path to a target dataset:

pan3d-viewer --dataset=/path/to/dataset.zarr
geotrame --dataset=/path/to/dataset.zarr

To launch Pan3D with a remote URL to a target dataset:
To launch GeoTrame with a remote URL to a target dataset:

pan3d-viewer --dataset=https://host.org/link/to/dataset.zarr
geotrame --dataset=https://host.org/link/to/dataset.zarr

To launch Pan3D with a compatible configuration file (see [examples][examples-link]):
To launch GeoTrame with a compatible configuration file (see [examples][examples-link]):

pan3d-viewer --config_path=/path/to/pan3d_state.json
geotrame --config_path=/path/to/pan3d_state.json

To launch Pan3D with the option to browse the Pangeo and ESGF Dataset Catalogs:
To launch GeoTrame with the option to browse the Pangeo and ESGF Dataset Catalogs (see [Catalogs Tutorial](tutorials/catalogs.md)):

pan3d-viewer --catalogs pangeo esgf
geotrame --catalogs pangeo esgf

Or you may specify only one catalog:

pan3d-viewer --catalogs pangeo
geotrame --catalogs pangeo

pan3d-viewer --catalogs esgf
geotrame --catalogs esgf


> The `pan3d-viewer` entrypoint will automatically launch your default browser to open `localhost:8080`.
> The `geotrame` entrypoint will automatically launch your default browser to open `localhost:8080`.
>
> To launch without opening your browser, add the `--server` argument to your command.


## Tutorials

- [How to use the Pan3D viewer](tutorials/dataset_viewer.md)
- [Pan3D command line](tutorials/local_server.md)
- [How to use GeoTrame](tutorials/dataset_viewer.md)
- [GeoTrame command line](tutorials/command_line.md)
- [Catalogs Tutorial](tutorials/catalogs.md)
- [How to use Pan3D in a Jupyter notebook](tutorials/jupyter_notebook.md)

## Examples
Expand Down
20 changes: 6 additions & 14 deletions docs/api/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Introduction

Pan3D uses JSON files to save an application state for reuse. The UI and the API include access to import and export functions which read and write these configuration files, respectively. This documentation provides guidelines for reading and writing these files manually.
Pan3D uses JSON files to save an application state for reuse. The GeoTrame UI and the Pan3D DatasetBuilder API include access to import and export functions which read and write these configuration files, respectively. This documentation provides guidelines for reading and writing these files manually.

There are five sections available in the configuration file format: `data_origin`, `data_array`, `data_slices`, `ui`, and `render`. The values in these sections will be passed to various attributes on the current `DatasetBuilder` instance and, if applicable, the corresponding `DatasetViewer` instance state.

Expand All @@ -19,16 +19,8 @@ There are five sections available in the configuration file format: `data_origin
"t_index": 5
},
"data_slices": {
"lat": [
-45,
45,
100
],
"lon": [
-90,
90,
100
]
"lon": [1000, 6000, 20],
"lat": [500, 3000, 20],
},
"ui": {
"main_drawer": false,
Expand Down Expand Up @@ -77,9 +69,9 @@ The value for this key should be a mapping of coordinate names (which are likely

Each slicing array should be a list of three values `[start, stop, step]`.

`start`: the coordinate value at which the sliced data should start (inclusive)
`start`: the index at which the sliced data should start (inclusive)

`stop`: the coordinate value at which the sliced data should stop (exclusive)
`stop`: the index at which the sliced data should stop (exclusive)

`step`: an integer > 0 which represents the number of items to skip when slicing the data (e.g. step=2 represents 0.5 resolution)

Expand All @@ -89,7 +81,7 @@ The value for this key should be a mapping of any number of UI state values. The

| Key | Required? | Type | Value Description |
|-----|-----------|------|-------------------|
|`main_drawer`|NO (default=True)|`bool`|If true, open the lefthand drawer for dataset and data array browsing/selection.|
|`main_drawer`|NO (default=False)|`bool`|If true, open the lefthand drawer for dataset and data array browsing/selection.|
|`axis_drawer`|NO (default=False)|`bool`|If true, open the righthand drawer for axis assignment/slicing. **Note:** By default, this becomes True when a data array is selected.|
|`unapplied_changes`|NO (default=False)|`bool`|If true, show "Apply and Render" button, which when clicked will apply any unapplied changes and rerender.|
|`error_message`|NO (default=None)|`str`|If not None, this string will show as the error message above the render area.|
Expand Down
4 changes: 2 additions & 2 deletions docs/images/0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/10.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/10a.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/11.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/12.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/13.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/14.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/15.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/16.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/17.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/18.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/19.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/20.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/21.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/22.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/23.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/24.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/25.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/26.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/27.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/28.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/29.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/images/3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/30.png
4 changes: 2 additions & 2 deletions docs/images/4.png
4 changes: 2 additions & 2 deletions docs/images/5.png
4 changes: 2 additions & 2 deletions docs/images/6.png
4 changes: 2 additions & 2 deletions docs/images/7.png
4 changes: 2 additions & 2 deletions docs/images/8.png
Binary file added docs/images/8a.png
Binary file added docs/images/8b.png
Binary file added docs/images/8c.png
Binary file added docs/images/8d.png
4 changes: 2 additions & 2 deletions docs/images/9.png
4 changes: 2 additions & 2 deletions docs/images/9b.png
Loading