pzserver 0.2.1__tar.gz → 0.2.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (54) hide show
  1. pzserver-0.2.3/.devcontainer/Dockerfile +14 -0
  2. {pzserver-0.2.1 → pzserver-0.2.3}/.devcontainer/devcontainer.json +5 -6
  3. {pzserver-0.2.1 → pzserver-0.2.3}/.github/workflows/build-documentation.yml +3 -3
  4. {pzserver-0.2.1 → pzserver-0.2.3}/.github/workflows/linting.yml +3 -1
  5. {pzserver-0.2.1 → pzserver-0.2.3}/.github/workflows/publish-to-pypi.yml +2 -5
  6. {pzserver-0.2.1 → pzserver-0.2.3}/.github/workflows/smoke-test.yml +3 -2
  7. {pzserver-0.2.1 → pzserver-0.2.3}/.github/workflows/testing-and-coverage.yml +3 -2
  8. {pzserver-0.2.1 → pzserver-0.2.3}/.pre-commit-config.yaml +5 -4
  9. {pzserver-0.2.1 → pzserver-0.2.3}/PKG-INFO +42 -5
  10. {pzserver-0.2.1 → pzserver-0.2.3}/README.md +8 -2
  11. {pzserver-0.2.1 → pzserver-0.2.3}/docs/index.rst +1 -1
  12. {pzserver-0.2.1 → pzserver-0.2.3}/docs/notebooks/intro_notebook.ipynb +121 -56
  13. pzserver-0.2.3/docs/notebooks/public-specz-compilation.ipynb +687 -0
  14. pzserver-0.2.3/docs/notebooks/public-training-set-des-dr2.ipynb +715 -0
  15. pzserver-0.2.3/pyproject.toml +36 -0
  16. pzserver-0.2.3/requirements-dev.txt +14 -0
  17. pzserver-0.2.3/requirements.txt +11 -0
  18. pzserver-0.2.3/src/pzserver/_version.py +16 -0
  19. {pzserver-0.2.1 → pzserver-0.2.3}/src/pzserver.egg-info/PKG-INFO +42 -5
  20. {pzserver-0.2.1 → pzserver-0.2.3}/src/pzserver.egg-info/SOURCES.txt +5 -5
  21. {pzserver-0.2.1 → pzserver-0.2.3}/src/pzserver.egg-info/requires.txt +8 -7
  22. pzserver-0.2.1/.build-documentation.yml +0 -35
  23. pzserver-0.2.1/.devcontainer/Dockerfile +0 -15
  24. pzserver-0.2.1/docs/notebooks/README.md +0 -1
  25. pzserver-0.2.1/docs/notebooks/intro_notebook.html +0 -18713
  26. pzserver-0.2.1/docs/requirements.txt +0 -10
  27. pzserver-0.2.1/pyproject.toml +0 -60
  28. pzserver-0.2.1/src/pzserver/_version.py +0 -4
  29. {pzserver-0.2.1 → pzserver-0.2.3}/.copier-answers.yml +0 -0
  30. {pzserver-0.2.1 → pzserver-0.2.3}/.devcontainer/docker-compose.yml +0 -0
  31. {pzserver-0.2.1 → pzserver-0.2.3}/.gitignore +0 -0
  32. {pzserver-0.2.1 → pzserver-0.2.3}/.readthedocs.yml +0 -0
  33. {pzserver-0.2.1 → pzserver-0.2.3}/LICENSE +0 -0
  34. {pzserver-0.2.1 → pzserver-0.2.3}/__init__.py +0 -0
  35. {pzserver-0.2.1 → pzserver-0.2.3}/docs/Makefile +0 -0
  36. {pzserver-0.2.1 → pzserver-0.2.3}/docs/conf.py +0 -0
  37. {pzserver-0.2.1 → pzserver-0.2.3}/docs/installation.rst +0 -0
  38. {pzserver-0.2.1 → pzserver-0.2.3}/docs/make.bat +0 -0
  39. /pzserver-0.2.1/docs/notebooks.rst → /pzserver-0.2.3/docs/nbs.rst +0 -0
  40. {pzserver-0.2.1 → pzserver-0.2.3}/docs/notebooks/images/ScreenShotTokenGenerator.png +0 -0
  41. {pzserver-0.2.1 → pzserver-0.2.3}/docs/notebooks/images/ScreenShotTokenMenu.png +0 -0
  42. {pzserver-0.2.1 → pzserver-0.2.3}/docs/notebooks/images/linea.png +0 -0
  43. {pzserver-0.2.1 → pzserver-0.2.3}/docs/notebooks/images/rubin.png +0 -0
  44. {pzserver-0.2.1 → pzserver-0.2.3}/setup.cfg +0 -0
  45. {pzserver-0.2.1 → pzserver-0.2.3}/src/.pylintrc +0 -0
  46. {pzserver-0.2.1 → pzserver-0.2.3}/src/pzserver/__init__.py +0 -0
  47. {pzserver-0.2.1 → pzserver-0.2.3}/src/pzserver/catalog.py +0 -0
  48. {pzserver-0.2.1 → pzserver-0.2.3}/src/pzserver/communicate.py +0 -0
  49. {pzserver-0.2.1 → pzserver-0.2.3}/src/pzserver/core.py +0 -0
  50. {pzserver-0.2.1 → pzserver-0.2.3}/src/pzserver.egg-info/dependency_links.txt +0 -0
  51. {pzserver-0.2.1 → pzserver-0.2.3}/src/pzserver.egg-info/top_level.txt +0 -0
  52. {pzserver-0.2.1 → pzserver-0.2.3}/tests/.pylintrc +0 -0
  53. {pzserver-0.2.1 → pzserver-0.2.3}/tests/pzserver/conftest.py +0 -0
  54. {pzserver-0.2.1 → pzserver-0.2.3}/tests/pzserver/test_catalog.py +0 -0
@@ -0,0 +1,14 @@
1
+ FROM mcr.microsoft.com/devcontainers/python:0-3.10
2
+
3
+ ENV PYTHONUNBUFFERED 1
4
+
5
+ # [Optional] If your requirements rarely change, uncomment this section to add them to the image.
6
+ COPY requirements-dev.txt /tmp/pip-tmp/
7
+ RUN pip3 --disable-pip-version-check --no-cache-dir install -r /tmp/pip-tmp/requirements-dev.txt \
8
+ && rm -rf /tmp/pip-tmp
9
+
10
+ RUN apt-get update && apt-get -y install pandoc
11
+
12
+
13
+
14
+
@@ -1,7 +1,7 @@
1
1
  // For format details, see https://aka.ms/devcontainer.json. For config options, see the
2
2
  // README at: https://github.com/devcontainers/templates/tree/main/src/postgres
3
3
  {
4
- "name": "Python 3 & PostgreSQL",
4
+ "name": "PZServer Library",
5
5
  "dockerComposeFile": "docker-compose.yml",
6
6
  "service": "app",
7
7
  "workspaceFolder": "/workspaces/${localWorkspaceFolderBasename}",
@@ -17,11 +17,11 @@
17
17
  // "features": {},
18
18
  // Use 'forwardPorts' to make a list of ports inside the container available locally.
19
19
  // This can be used to network with other containers or the host.
20
- "forwardPorts": [
21
- 8000
22
- ],
20
+ // "forwardPorts": [
21
+ // 8000
22
+ // ],
23
23
  // Use 'postCreateCommand' to run commands after the container is created.
24
- // "postCreateCommand": "pip install --user -r requirements.txt",
24
+ "postCreateCommand": "pip install -e . && pip install '.[dev]' && pre-commit install",
25
25
  // Configure tool-specific properties.
26
26
  "customizations": {
27
27
  "vscode": {
@@ -29,7 +29,6 @@
29
29
  "aaron-bond.better-comments",
30
30
  "PKief.material-icon-theme",
31
31
  "njpwerner.autodocstring",
32
- "TabNine.tabnine-vscode",
33
32
  "ms-azuretools.vscode-docker"
34
33
  ]
35
34
  }
@@ -8,7 +8,7 @@ on:
8
8
 
9
9
  jobs:
10
10
  build:
11
-
11
+ name: build_doc
12
12
  runs-on: ubuntu-latest
13
13
 
14
14
  steps:
@@ -24,13 +24,13 @@ jobs:
24
24
  pip install .
25
25
  pip install .[dev]
26
26
  if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
27
- if [ -f docs/requirements.txt ]; then pip install -r docs/requirements.txt; fi
27
+ if [ -f requirements-dev.txt ]; then pip install -r requirements-dev.txt; fi
28
28
  - name: Install notebook requirements
29
29
  run: |
30
30
  sudo apt-get install pandoc
31
31
  - name: Build docs
32
32
  run: |
33
- sphinx-build -T -E -b html -d docs/build/doctrees ./docs docs/build/html
33
+ sphinx-build -T -E -b html -d docs/build/doctrees ./docs docs/build/html -D exclude_patterns="notebooks/*"
34
34
  - name: Run ghp-import
35
35
  run: |
36
36
  ghp-import -n -p -f -x docs/ docs/build/html
@@ -11,10 +11,11 @@ on:
11
11
 
12
12
  jobs:
13
13
  build:
14
+ name: lint
14
15
  runs-on: ubuntu-latest
15
16
  strategy:
16
17
  matrix:
17
- python-version: ['3.8', '3.9', '3.10']
18
+ python-version: ['3.10', '3.11', '3.12']
18
19
 
19
20
  steps:
20
21
  - uses: actions/checkout@v3
@@ -29,6 +30,7 @@ jobs:
29
30
  pip install .
30
31
  pip install .[dev]
31
32
  if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
33
+ if [ -f requirements-dev.txt ]; then pip install -r requirements-dev.txt; fi
32
34
  - name: Analyze code with linter
33
35
 
34
36
  run: |
@@ -17,7 +17,7 @@ permissions:
17
17
 
18
18
  jobs:
19
19
  pypi-publish:
20
- name: Upload release to PyPI
20
+ name: pypi_publish
21
21
  runs-on: ubuntu-latest
22
22
  environment:
23
23
  name: pypi
@@ -37,7 +37,4 @@ jobs:
37
37
  - name: Build package
38
38
  run: python -m build
39
39
  - name: Publish package
40
- uses: pypa/gh-action-pypi-publish@release/v1
41
- # with:
42
- # user: __token__
43
- # password: ${{ secrets.PYPI_API_TOKEN }}
40
+ uses: pypa/gh-action-pypi-publish@release/v1
@@ -9,11 +9,11 @@ on:
9
9
 
10
10
  jobs:
11
11
  build:
12
-
12
+ name: smoke_test
13
13
  runs-on: ubuntu-latest
14
14
  strategy:
15
15
  matrix:
16
- python-version: ['3.8', '3.9', '3.10']
16
+ python-version: ['3.10', '3.11', '3.12']
17
17
 
18
18
  steps:
19
19
  - uses: actions/checkout@v3
@@ -28,6 +28,7 @@ jobs:
28
28
  pip install .
29
29
  pip install .[dev]
30
30
  if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
31
+ if [ -f requirements-dev.txt ]; then pip install -r requirements-dev.txt; fi
31
32
  - name: Run unit tests with pytest
32
33
  run: |
33
34
  python -m pytest tests
@@ -11,11 +11,11 @@ on:
11
11
 
12
12
  jobs:
13
13
  build:
14
-
14
+ name: test_and_coverage
15
15
  runs-on: ubuntu-latest
16
16
  strategy:
17
17
  matrix:
18
- python-version: ['3.8', '3.9', '3.10']
18
+ python-version: ['3.10', '3.11', '3.12']
19
19
 
20
20
  steps:
21
21
  - uses: actions/checkout@v3
@@ -30,6 +30,7 @@ jobs:
30
30
  pip install .
31
31
  pip install .[dev]
32
32
  if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
33
+ if [ -f requirements-dev.txt ]; then pip install -r requirements-dev.txt; fi
33
34
  - name: Run unit tests with pytest
34
35
  run: |
35
36
  python -m pytest tests --cov=pzserver --cov-report=xml
@@ -4,7 +4,7 @@ repos:
4
4
  # This hook should always pass. It will print a message if the local version
5
5
  # is out of date.
6
6
  - repo: https://github.com/lincc-frameworks/pre-commit-hooks
7
- rev: v0.1
7
+ rev: v0.1.2
8
8
  hooks:
9
9
  - id: check-lincc-frameworks-template-version
10
10
  name: Check template version
@@ -18,6 +18,7 @@ repos:
18
18
  name: Clear output from Jupyter notebooks
19
19
  description: Clear output from Jupyter notebooks.
20
20
  files: \.ipynb$
21
+ exclude: ^docs/notebooks/intro_notebook.ipynb$
21
22
  stages: [commit]
22
23
  language: system
23
24
  entry: jupyter nbconvert --clear-output
@@ -39,7 +40,7 @@ repos:
39
40
 
40
41
  # prevents committing directly branches named 'main' and 'master'.
41
42
  - repo: https://github.com/pre-commit/pre-commit-hooks
42
- rev: v4.4.0
43
+ rev: v4.6.0
43
44
  hooks:
44
45
  - id: no-commit-to-branch
45
46
  name: Prevent main branch commits
@@ -51,7 +52,7 @@ repos:
51
52
 
52
53
  # verify that pyproject.toml is well formed
53
54
  - repo: https://github.com/abravalheri/validate-pyproject
54
- rev: v0.12.1
55
+ rev: v0.16
55
56
  hooks:
56
57
  - id: validate-pyproject
57
58
  name: Validate pyproject.toml
@@ -59,7 +60,7 @@ repos:
59
60
 
60
61
  # Automatically sort the imports used in .py files
61
62
  - repo: https://github.com/pycqa/isort
62
- rev: 5.12.0
63
+ rev: 5.13.2
63
64
  hooks:
64
65
  - id: isort
65
66
  name: isort (python files in src/ and tests/)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: pzserver
3
- Version: 0.2.1
3
+ Version: 0.2.3
4
4
  Author-email: LIneA <itteam@linea.org.br>
5
5
  License: MIT License
6
6
 
@@ -28,16 +28,53 @@ Classifier: License :: OSI Approved :: MIT License
28
28
  Classifier: Intended Audience :: Developers
29
29
  Classifier: Intended Audience :: Science/Research
30
30
  Classifier: Operating System :: OS Independent
31
- Classifier: Programming Language :: Python
31
+ Classifier: Programming Language :: Python :: 3.7
32
+ Classifier: Programming Language :: Python :: 3.8
33
+ Classifier: Programming Language :: Python :: 3.9
34
+ Classifier: Programming Language :: Python :: 3.10
35
+ Classifier: Programming Language :: Python :: 3.11
36
+ Classifier: Programming Language :: Python :: 3.12
37
+ Requires-Python: <3.13,>=3.7
32
38
  Description-Content-Type: text/markdown
33
- Provides-Extra: dev
34
39
  License-File: LICENSE
40
+ Requires-Dist: deprecated
41
+ Requires-Dist: numpy>=1.23
42
+ Requires-Dist: pandas>=1.2.0
43
+ Requires-Dist: requests>=2.23.0
44
+ Requires-Dist: astropy>=5.0.0
45
+ Requires-Dist: matplotlib>=3.6.0
46
+ Requires-Dist: tables_io>=0.7.9
47
+ Requires-Dist: Jinja2>=3.1.2
48
+ Requires-Dist: ipython>=8.5.0
49
+ Requires-Dist: h5py>=3.8.0
50
+ Requires-Dist: pyarrow>=15.0.2
51
+ Provides-Extra: dev
52
+ Requires-Dist: pytest; extra == "dev"
53
+ Requires-Dist: pytest-cov; extra == "dev"
54
+ Requires-Dist: pre-commit; extra == "dev"
55
+ Requires-Dist: sphinx<8,>=7.0.0; extra == "dev"
56
+ Requires-Dist: sphinx_rtd_theme<2,>=1.2.0; extra == "dev"
57
+ Requires-Dist: sphinx-autoapi<4,>=3.0.0; extra == "dev"
58
+ Requires-Dist: pylint; extra == "dev"
59
+ Requires-Dist: ipykernel; extra == "dev"
60
+ Requires-Dist: nbconvert; extra == "dev"
61
+ Requires-Dist: nbsphinx; extra == "dev"
62
+ Requires-Dist: ipython; extra == "dev"
63
+ Requires-Dist: jupyterlab; extra == "dev"
64
+ Requires-Dist: matplotlib; extra == "dev"
65
+ Requires-Dist: ghp-import; extra == "dev"
35
66
 
36
67
  # Pz Server Library
37
68
 
69
+ ![PyPI](https://img.shields.io/pypi/v/pzserver?label=PyPI)
70
+ ![PyPI - Status](https://img.shields.io/pypi/status/pzserver)
71
+ ![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/linea-it/pzserver/build-documentation.yml?label=docs)
72
+ ![GitHub](https://img.shields.io/github/license/linea-it/pzserver)
73
+
38
74
  A Python library to access data from the [Photo-z Server](https://pz-server-dev.linea.org.br/).
39
75
 
40
- The Photo-z Server is an online service based on software developed and delivered as part of the in-kind contribution program BRA-LIN, from LIneA to the Rubin Observatory's LSST. The Photo-z Server is open source and the code is abailable on the Github repository [linea-it/pz-server](https://github.com/linea-it/pzserver_app).
76
+ The Photo-z Server is an online service based on software developed and delivered as part of the in-kind contribution program BRA-LIN, from LIneA to the Rubin Observatory's LSST. The Photo-z Server is open source, and the code is
77
+ available on the GitHub repository [linea-it/pzserver_app](https://github.com/linea-it/pzserver_app).
41
78
 
42
79
  An overview of this and other contributions is available [here](https://linea-it.github.io/pz-lsst-inkind-doc/).
43
- The API documentation is available [here](https://linea-it.github.io/pzserver/html/index.html).
80
+ The API documentation is available [here](https://linea-it.github.io/pzserver).
@@ -1,8 +1,14 @@
1
1
  # Pz Server Library
2
2
 
3
+ ![PyPI](https://img.shields.io/pypi/v/pzserver?label=PyPI)
4
+ ![PyPI - Status](https://img.shields.io/pypi/status/pzserver)
5
+ ![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/linea-it/pzserver/build-documentation.yml?label=docs)
6
+ ![GitHub](https://img.shields.io/github/license/linea-it/pzserver)
7
+
3
8
  A Python library to access data from the [Photo-z Server](https://pz-server-dev.linea.org.br/).
4
9
 
5
- The Photo-z Server is an online service based on software developed and delivered as part of the in-kind contribution program BRA-LIN, from LIneA to the Rubin Observatory's LSST. The Photo-z Server is open source and the code is abailable on the Github repository [linea-it/pz-server](https://github.com/linea-it/pzserver_app).
10
+ The Photo-z Server is an online service based on software developed and delivered as part of the in-kind contribution program BRA-LIN, from LIneA to the Rubin Observatory's LSST. The Photo-z Server is open source, and the code is
11
+ available on the GitHub repository [linea-it/pzserver_app](https://github.com/linea-it/pzserver_app).
6
12
 
7
13
  An overview of this and other contributions is available [here](https://linea-it.github.io/pz-lsst-inkind-doc/).
8
- The API documentation is available [here](https://linea-it.github.io/pzserver/html/index.html).
14
+ The API documentation is available [here](https://linea-it.github.io/pzserver).
@@ -15,7 +15,7 @@ The Photo-z Server Library is a Python package to support the Photo-z Server use
15
15
  Home page <self>
16
16
  Install <installation>
17
17
  API Reference <autoapi/index>
18
- Notebooks <notebooks>
18
+ Notebooks <nbs>
19
19
 
20
20
 
21
21
  Indices and tables
@@ -11,7 +11,7 @@
11
11
  "\n",
12
12
  "Contact author: [Julia Gschwend](mailto:julia@linea.org.br)\n",
13
13
  "\n",
14
- "Last verified run: 2023-May-05<br>"
14
+ "Last verified run: 2024-May-06<br>"
15
15
  ]
16
16
  },
17
17
  {
@@ -20,23 +20,25 @@
20
20
  "tags": []
21
21
  },
22
22
  "source": [
23
- "<a class=\"anchor\" id=\"contents\"></a>\n",
24
- "#### Notebook contents\n",
23
+ "<div id=\"notebook-contents\" />\n",
24
+ "\n",
25
+ "# Notebook contents\n",
26
+ "\n",
25
27
  "- PZ Server\n",
26
- " - [Introduction](#intro) \n",
27
- " - [How to upload a data product to the PZ Server](#upload)\n",
28
- " - [How to download a data product from the PZ Server](#download)\n",
28
+ " - [Introduction](#introduction) \n",
29
+ " - [How to upload a data product to the PZ Server](#how-to-upload-a-data-product-to-the-pz-server)\n",
30
+ " - [How to download a data product from the PZ Server](#how-to-download-a-data-product-from-the-pz-server)\n",
29
31
  "- PZ Server API (Python library pz-server-lib)\n",
30
- " - [How to get general info from PZ Server](#general)\n",
31
- " - [How to display the metadata of a data product](#metadata)\n",
32
- " - [How to download data products as .zip files](#download-zip) \n",
33
- " - [How to share data products with other RSP users](#share)\n",
34
- " - [How to retrieve contents of data products (work on memory)](#retrieve-contents)\n",
32
+ " - [How to get general info from PZ Server](#how-to-get-general-info-from-pz-server)\n",
33
+ " - [How to display the metadata of a data product](#how-to-display-the-metadata-of-a-data-product)\n",
34
+ " - [How to download data products as .zip files](#how-to-download-data-products-as-zip-files) \n",
35
+ " - [How to share data products with other RSP users](#how-to-share-data-products-with-other-rsp-users)\n",
36
+ " - [How to retrieve contents of data products (work on memory)](#how-to-retrieve-contents-of-data-products-work-on-memory)\n",
35
37
  "- Product types \n",
36
- " - [Spec-z Catalogs](#spec)\n",
37
- " - [Training Sets](#train)\n",
38
- " - [Photo-z Validation Results](#valid)\n",
39
- " - [Photo-z Tables](#pz_tables)"
38
+ " - [Spec-z Catalogs](#spec-z-catalog)\n",
39
+ " - [Training Sets](#training-sets)\n",
40
+ " - [Photo-z Validation Results](#photo-z-validation-results)\n",
41
+ " - [Photo-z Tables](#photo-z-tables)"
40
42
  ]
41
43
  },
42
44
  {
@@ -45,8 +47,10 @@
45
47
  "tags": []
46
48
  },
47
49
  "source": [
48
- "<a class=\"anchor\" id=\"intro\"></a>\n",
49
50
  "# The PZ Server\n",
51
+ "\n",
52
+ "<div id=\"introduction\"></div>\n",
53
+ "\n",
50
54
  "## Introduction \n"
51
55
  ]
52
56
  },
@@ -65,9 +69,13 @@
65
69
  "cell_type": "markdown",
66
70
  "metadata": {},
67
71
  "source": [
68
- "<a class=\"anchor\" id=\"upload\"></a>\n",
69
- "## How to upload a data product to the PZ Server\n",
70
- "<div style=\"text-align: right\"><a href=\"#contents\">back to the top</a></div> \n",
72
+ "<div style=\"text-align: right\" id=\"how-to-upload-a-data-product-to-the-pz-server\">\n",
73
+ "\n",
74
+ "[back to the top](#notebook-contents)\n",
75
+ "\n",
76
+ "</div>\n",
77
+ "\n",
78
+ "## How to upload a data product to the PZ Server \n",
71
79
  "\n",
72
80
  "To upload a data product, click on the button **NEW PRODUCT** on the top left of the **User-generated Data Products** page and fill in the Upload Form with relevant metadata.\n",
73
81
  "\n",
@@ -83,9 +91,13 @@
83
91
  "cell_type": "markdown",
84
92
  "metadata": {},
85
93
  "source": [
86
- "<a class=\"anchor\" id=\"download\"></a>\n",
94
+ "<div style=\"text-align: right\">\n",
95
+ "\n",
96
+ "[back to the top](#notebook-contents)\n",
97
+ "\n",
98
+ "</div>\n",
99
+ "\n",
87
100
  "## How to download a data product from the PZ Server\n",
88
- "<div style=\"text-align: right\"><a href=\"#contents\">back to the top</a></div> \n",
89
101
  "\n",
90
102
  "To download a data product available on the Photo-z Server, go to one of the two pages by clicking on the card \"LSST PZ Data Products\" (for official products released by LSST DM Team) or \"User-generated Data Products\" (for products uploaded by the members of LSST community. The download button is on the left side of each data product (each row of the list). "
91
103
  ]
@@ -94,8 +106,13 @@
94
106
  "cell_type": "markdown",
95
107
  "metadata": {},
96
108
  "source": [
97
- "# The PZ Server API (Python library pz-server-lib)\n",
98
- "<div style=\"text-align: right\"><a href=\"#contents\">back to the top</a></div> "
109
+ "<div style=\"text-align: right\" id=\"how-to-download-a-data-product-from-the-pz-server\">\n",
110
+ "\n",
111
+ "[back to the top](#notebook-contents)\n",
112
+ "\n",
113
+ "</div>\n",
114
+ "\n",
115
+ "# The PZ Server API (Python library pz-server-lib)"
99
116
  ]
100
117
  },
101
118
  {
@@ -106,7 +123,7 @@
106
123
  "\n",
107
124
  "**Using pip**\n",
108
125
  "\n",
109
- "The PZ Server API is avalialble on **pip** as `pz-server-lib`. To install the API and its dependencies, type, on the Terminal: \n",
126
+ "The PZ Server API is avalialble on **pip** as `pzserver`. To install the API and its dependencies, type, on the Terminal: \n",
110
127
  "\n",
111
128
  "```\n",
112
129
  "$ pip install pzserver \n",
@@ -128,7 +145,7 @@
128
145
  "```\n",
129
146
  "\n",
130
147
  "\n",
131
- "OBS: You might need to restart the kernel on the notebook to incorporate the new library. \n"
148
+ "OBS: You might need to restart the kernel on the notebook to incorporate the new library.\n"
132
149
  ]
133
150
  },
134
151
  {
@@ -141,7 +158,9 @@
141
158
  {
142
159
  "cell_type": "code",
143
160
  "execution_count": null,
144
- "metadata": {},
161
+ "metadata": {
162
+ "tags": []
163
+ },
145
164
  "outputs": [],
146
165
  "source": [
147
166
  "from pzserver import PzServer \n",
@@ -170,16 +189,20 @@
170
189
  "metadata": {},
171
190
  "outputs": [],
172
191
  "source": [
173
- "pz_server = PzServer(token=\"<paste your API Token here>\", host=\"pz-dev\") # \"pz-dev\" is the temporary host for test phase "
192
+ "pz_server = PzServer(token=\"<your token>\", host=\"pz-dev\") # \"pz-dev\" is the temporary host for test phase "
174
193
  ]
175
194
  },
176
195
  {
177
196
  "cell_type": "markdown",
178
197
  "metadata": {},
179
198
  "source": [
180
- "<a class=\"anchor\" id=\"general\"></a>\n",
181
- "## How to get general info from PZ Server\n",
182
- "<div style=\"text-align: right\"> <a href=\"#contents\">back to the top</a> </div> "
199
+ "<div style=\"text-align: right\" id=\"how-to-get-general-info-from-pz-server\">\n",
200
+ "\n",
201
+ "[back to the top](#notebook-contents)\n",
202
+ "\n",
203
+ "</div>\n",
204
+ "\n",
205
+ "## How to get general info from PZ Server"
183
206
  ]
184
207
  },
185
208
  {
@@ -326,9 +349,13 @@
326
349
  "cell_type": "markdown",
327
350
  "metadata": {},
328
351
  "source": [
329
- "<a class=\"anchor\" id=\"metadata\"></a>\n",
330
- "## How to display the metadata of a data product\n",
331
- "<div style=\"text-align: right\"> <a href=\"#contents\">back to the top</a> </div> "
352
+ "<div style=\"text-align: right\" id=\"how-to-display-the-metadata-of-a-data-product\">\n",
353
+ "\n",
354
+ "[back to the top](#notebook-contents)\n",
355
+ "\n",
356
+ "</div>\n",
357
+ "\n",
358
+ "## How to display the metadata of a data product "
332
359
  ]
333
360
  },
334
361
  {
@@ -363,9 +390,13 @@
363
390
  "cell_type": "markdown",
364
391
  "metadata": {},
365
392
  "source": [
366
- "<a class=\"anchor\" id=\"download-zip\"></a>\n",
367
- "## How to download data products as .zip files\n",
368
- "<div style=\"text-align: right\"> <a href=\"#contents\">back to the top</a> </div> "
393
+ "<div style=\"text-align: right\" id=\"how-to-download-data-products-as-zip-files\">\n",
394
+ "\n",
395
+ "[back to the top](#notebook-contents)\n",
396
+ "\n",
397
+ "</div>\n",
398
+ "\n",
399
+ "## How to download data products as .zip files "
369
400
  ]
370
401
  },
371
402
  {
@@ -388,9 +419,13 @@
388
419
  "cell_type": "markdown",
389
420
  "metadata": {},
390
421
  "source": [
391
- "<a class=\"anchor\" id=\"share\"></a>\n",
422
+ "<div style=\"text-align: right\" id=\"how-to-share-data-products-with-other-rsp-users\">\n",
423
+ "\n",
424
+ "[back to the top](#notebook-contents)\n",
425
+ "\n",
426
+ "</div>\n",
427
+ "\n",
392
428
  "## How to share data products with other RSP users\n",
393
- "<div style=\"text-align: right\"> <a href=\"#contents\">back to the top</a> </div> \n",
394
429
  "\n",
395
430
  "All data products uploaded to the PZ Server are imediately available and visible to all PZ Server users (people with RSP credentials) through the PZ Server website or via the API. Besides informing the product **id** or **internal_name** for programatic access, another way to share a data product is providing the product's URL, which leads to the product's download page. The URL is composed by the PZ Server website address + **/products/** + **internal_name**:\n",
396
431
  "\n",
@@ -412,9 +447,13 @@
412
447
  "cell_type": "markdown",
413
448
  "metadata": {},
414
449
  "source": [
415
- "<a class=\"anchor\" id=\"retrieve-contents\"></a>\n",
416
- "## How to retrieve contents of data products (work on memory)\n",
417
- "<div style=\"text-align: right\"> <a href=\"#contents\">back to the top</a> </div> "
450
+ "<div style=\"text-align: right\" id=\"how-to-retrieve-contents-of-data-products-work-on-memory\">\n",
451
+ "\n",
452
+ "[back to the top](#notebook-contents)\n",
453
+ "\n",
454
+ "</div>\n",
455
+ "\n",
456
+ "## How to retrieve contents of data products (work on memory)"
418
457
  ]
419
458
  },
420
459
  {
@@ -552,10 +591,13 @@
552
591
  "cell_type": "markdown",
553
592
  "metadata": {},
554
593
  "source": [
555
- "<div style=\"text-align: right\"> <a href=\"#contents\">back to the top</a> </div> \n",
556
- "<a class=\"anchor\" id=\"prod-types\"></a>\n",
594
+ "<div style=\"text-align: right\">\n",
595
+ "\n",
596
+ "[back to the top](#notebook-contents)\n",
557
597
  "\n",
558
- "# Product types \n"
598
+ "</div>\n",
599
+ "\n",
600
+ "# Product types "
559
601
  ]
560
602
  },
561
603
  {
@@ -580,9 +622,13 @@
580
622
  "tags": []
581
623
  },
582
624
  "source": [
583
- "<a class=\"anchor\" id=\"spec\"></a>\n",
584
- "## Spec-z Catalog \n",
585
- "<div style=\"text-align: right\"> <a href=\"#contents\">back to the top</a> </div> "
625
+ "<div style=\"text-align: right\" id=\"spec-z-catalog\">\n",
626
+ "\n",
627
+ "[back to the top](#notebook-contents)\n",
628
+ "\n",
629
+ "</div>\n",
630
+ "\n",
631
+ "## Spec-z Catalog "
586
632
  ]
587
633
  },
588
634
  {
@@ -682,9 +728,13 @@
682
728
  "cell_type": "markdown",
683
729
  "metadata": {},
684
730
  "source": [
685
- "<a class=\"anchor\" id=\"train\"></a>\n",
731
+ "<div style=\"text-align: right\" id=\"training-sets\">\n",
732
+ "\n",
733
+ "[back to the top](#notebook-contents)\n",
734
+ "\n",
735
+ "</div>\n",
736
+ "\n",
686
737
  "## Training Sets \n",
687
- "<div style=\"text-align: right\"> <a href=\"#contents\">back to the top</a> </div> \n",
688
738
  " \n",
689
739
  "In the context of the PZ Server, Training Sets are defined as the product of matching (spatially) a given Spec-z Catalog (single survey or compilation) to the photometric data, in this case, the LSST Objects Catalog. The PZ Server API offers a tool called _Training Set Maker_ for users to build customized Training Sets based on the Spec-z Catalogs available. Please see the companion Jupyter Notebook `pz_tsm_tutorial.ipynb` for details. \n",
690
740
  "\n",
@@ -767,9 +817,13 @@
767
817
  "cell_type": "markdown",
768
818
  "metadata": {},
769
819
  "source": [
770
- "<a class=\"anchor\" id=\"valid\"></a>\n",
820
+ "<div style=\"text-align: right\" id=\"photo-z-validation-results\">\n",
821
+ "\n",
822
+ "[back to the top](#notebook-contents)\n",
823
+ "\n",
824
+ "</div>\n",
825
+ "\n",
771
826
  "## Photo-z Validation Results\n",
772
- "<div style=\"text-align: right\"> <a href=\"#contents\">back to the top</a> </div> \n",
773
827
  " \n",
774
828
  "Validation Results are the outputs of any photo-z algorithm applied on a Validation Set. The format and number of files of this data product are strongly dependent on the algorithm used to create it, so there are no constraints on these two parameters. In the case of multiple files, for instance, if the user includes the results of training procedures (e.g., neural nets weights, decision trees files, or any machine learning by-product) or additional files (SED templates, filter transmission curves, theoretical magnitudes grid, Bayesian priors, etc.), it will be required to put all files together in a single compressed file (.zip or .tar, or .tar.gz) before uploading it to the Photo-z Server. \n",
775
829
  "\n",
@@ -825,9 +879,13 @@
825
879
  "tags": []
826
880
  },
827
881
  "source": [
828
- "<a class=\"anchor\" id=\"pz_tables\"></a>\n",
829
- "### Photo-z Tables \n",
830
- "<div style=\"text-align: right\"> <a href=\"#contents\">back to the top</a> </div> "
882
+ "<div style=\"text-align: right\" id=\"photo-z-tables\">\n",
883
+ "\n",
884
+ "[back to the top](#notebook-contents)\n",
885
+ "\n",
886
+ "</div>\n",
887
+ "\n",
888
+ "### Photo-z Tables "
831
889
  ]
832
890
  },
833
891
  {
@@ -856,8 +914,15 @@
856
914
  "\n",
857
915
  "### Users feedback \n",
858
916
  "\n",
859
- "Is something important missing? [Click here to open an issue in the PZ Server library repository on GitHub](https://github.com/linea-it/pz-server-lib/issues). "
917
+ "Is something important missing? [Click here to open an issue in the PZ Server library repository on GitHub](https://github.com/linea-it/pzserver/issues/new). "
860
918
  ]
919
+ },
920
+ {
921
+ "cell_type": "code",
922
+ "execution_count": null,
923
+ "metadata": {},
924
+ "outputs": [],
925
+ "source": []
861
926
  }
862
927
  ],
863
928
  "metadata": {
@@ -876,7 +941,7 @@
876
941
  "name": "python",
877
942
  "nbconvert_exporter": "python",
878
943
  "pygments_lexer": "ipython3",
879
- "version": "3.9.16"
944
+ "version": "3.10.11"
880
945
  },
881
946
  "nbsphinx": {
882
947
  "execute": "never"