eyepiece 0.0.1__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.
- eyepiece-0.0.1/.gitignore +221 -0
- eyepiece-0.0.1/.pre-commit-config.yaml +28 -0
- eyepiece-0.0.1/.readthedocs.yaml +20 -0
- eyepiece-0.0.1/CHANGELOG.md +33 -0
- eyepiece-0.0.1/LICENSE +21 -0
- eyepiece-0.0.1/PKG-INFO +107 -0
- eyepiece-0.0.1/README.md +52 -0
- eyepiece-0.0.1/pyproject.toml +56 -0
- eyepiece-0.0.1/src/eyepiece/__init__.py +70 -0
- eyepiece-0.0.1/src/eyepiece/_result.py +104 -0
- eyepiece-0.0.1/src/eyepiece/_style.py +82 -0
- eyepiece-0.0.1/src/eyepiece/_version.py +24 -0
- eyepiece-0.0.1/src/eyepiece/anim.py +406 -0
- eyepiece-0.0.1/src/eyepiece/images.py +462 -0
- eyepiece-0.0.1/src/eyepiece/layout.py +251 -0
- eyepiece-0.0.1/src/eyepiece/output.py +69 -0
- eyepiece-0.0.1/src/eyepiece/scene.py +293 -0
- eyepiece-0.0.1/src/eyepiece/schematic.py +149 -0
- eyepiece-0.0.1/src/eyepiece/stats.py +287 -0
- eyepiece-0.0.1/tools/check_internal_refs.py +80 -0
|
@@ -0,0 +1,221 @@
|
|
|
1
|
+
# Byte-compiled / optimized / DLL files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[codz]
|
|
4
|
+
*$py.class
|
|
5
|
+
|
|
6
|
+
# C extensions
|
|
7
|
+
*.so
|
|
8
|
+
|
|
9
|
+
# Distribution / packaging
|
|
10
|
+
.Python
|
|
11
|
+
build/
|
|
12
|
+
develop-eggs/
|
|
13
|
+
dist/
|
|
14
|
+
downloads/
|
|
15
|
+
eggs/
|
|
16
|
+
.eggs/
|
|
17
|
+
lib/
|
|
18
|
+
lib64/
|
|
19
|
+
parts/
|
|
20
|
+
sdist/
|
|
21
|
+
var/
|
|
22
|
+
wheels/
|
|
23
|
+
share/python-wheels/
|
|
24
|
+
*.egg-info/
|
|
25
|
+
.installed.cfg
|
|
26
|
+
*.egg
|
|
27
|
+
MANIFEST
|
|
28
|
+
|
|
29
|
+
# PyInstaller
|
|
30
|
+
# Usually these files are written by a python script from a template
|
|
31
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
32
|
+
*.manifest
|
|
33
|
+
*.spec
|
|
34
|
+
|
|
35
|
+
# Installer logs
|
|
36
|
+
pip-log.txt
|
|
37
|
+
pip-delete-this-directory.txt
|
|
38
|
+
|
|
39
|
+
# Unit test / coverage reports
|
|
40
|
+
htmlcov/
|
|
41
|
+
.tox/
|
|
42
|
+
.nox/
|
|
43
|
+
.coverage
|
|
44
|
+
.coverage.*
|
|
45
|
+
.cache
|
|
46
|
+
nosetests.xml
|
|
47
|
+
coverage.xml
|
|
48
|
+
*.cover
|
|
49
|
+
*.py.cover
|
|
50
|
+
.hypothesis/
|
|
51
|
+
.pytest_cache/
|
|
52
|
+
cover/
|
|
53
|
+
|
|
54
|
+
# Translations
|
|
55
|
+
*.mo
|
|
56
|
+
*.pot
|
|
57
|
+
|
|
58
|
+
# Django stuff:
|
|
59
|
+
*.log
|
|
60
|
+
local_settings.py
|
|
61
|
+
db.sqlite3
|
|
62
|
+
db.sqlite3-journal
|
|
63
|
+
|
|
64
|
+
# Flask stuff:
|
|
65
|
+
instance/
|
|
66
|
+
.webassets-cache
|
|
67
|
+
|
|
68
|
+
# Scrapy stuff:
|
|
69
|
+
.scrapy
|
|
70
|
+
|
|
71
|
+
# Sphinx documentation
|
|
72
|
+
docs/_build/
|
|
73
|
+
|
|
74
|
+
# PyBuilder
|
|
75
|
+
.pybuilder/
|
|
76
|
+
target/
|
|
77
|
+
|
|
78
|
+
# Jupyter Notebook
|
|
79
|
+
.ipynb_checkpoints
|
|
80
|
+
|
|
81
|
+
# IPython
|
|
82
|
+
profile_default/
|
|
83
|
+
ipython_config.py
|
|
84
|
+
|
|
85
|
+
# pyenv
|
|
86
|
+
# For a library or package, you might want to ignore these files since the code is
|
|
87
|
+
# intended to run in multiple environments; otherwise, check them in:
|
|
88
|
+
# .python-version
|
|
89
|
+
|
|
90
|
+
# pipenv
|
|
91
|
+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
|
92
|
+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
93
|
+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
94
|
+
# install all needed dependencies.
|
|
95
|
+
# Pipfile.lock
|
|
96
|
+
|
|
97
|
+
# UV
|
|
98
|
+
# Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
|
|
99
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
100
|
+
# commonly ignored for libraries.
|
|
101
|
+
# uv.lock
|
|
102
|
+
|
|
103
|
+
# poetry
|
|
104
|
+
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
|
105
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
106
|
+
# commonly ignored for libraries.
|
|
107
|
+
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
|
108
|
+
# poetry.lock
|
|
109
|
+
# poetry.toml
|
|
110
|
+
|
|
111
|
+
# pdm
|
|
112
|
+
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
|
113
|
+
# pdm recommends including project-wide configuration in pdm.toml, but excluding .pdm-python.
|
|
114
|
+
# https://pdm-project.org/en/latest/usage/project/#working-with-version-control
|
|
115
|
+
# pdm.lock
|
|
116
|
+
# pdm.toml
|
|
117
|
+
.pdm-python
|
|
118
|
+
.pdm-build/
|
|
119
|
+
|
|
120
|
+
# pixi
|
|
121
|
+
# Similar to Pipfile.lock, it is generally recommended to include pixi.lock in version control.
|
|
122
|
+
# pixi.lock
|
|
123
|
+
# Pixi creates a virtual environment in the .pixi directory, just like venv module creates one
|
|
124
|
+
# in the .venv directory. It is recommended not to include this directory in version control.
|
|
125
|
+
.pixi
|
|
126
|
+
|
|
127
|
+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
|
128
|
+
__pypackages__/
|
|
129
|
+
|
|
130
|
+
# Celery stuff
|
|
131
|
+
celerybeat-schedule
|
|
132
|
+
celerybeat.pid
|
|
133
|
+
|
|
134
|
+
# Redis
|
|
135
|
+
*.rdb
|
|
136
|
+
*.aof
|
|
137
|
+
*.pid
|
|
138
|
+
|
|
139
|
+
# RabbitMQ
|
|
140
|
+
mnesia/
|
|
141
|
+
rabbitmq/
|
|
142
|
+
rabbitmq-data/
|
|
143
|
+
|
|
144
|
+
# ActiveMQ
|
|
145
|
+
activemq-data/
|
|
146
|
+
|
|
147
|
+
# SageMath parsed files
|
|
148
|
+
*.sage.py
|
|
149
|
+
|
|
150
|
+
# Environments
|
|
151
|
+
.env
|
|
152
|
+
.envrc
|
|
153
|
+
.venv
|
|
154
|
+
env/
|
|
155
|
+
venv/
|
|
156
|
+
ENV/
|
|
157
|
+
env.bak/
|
|
158
|
+
venv.bak/
|
|
159
|
+
|
|
160
|
+
# Spyder project settings
|
|
161
|
+
.spyderproject
|
|
162
|
+
.spyproject
|
|
163
|
+
|
|
164
|
+
# Rope project settings
|
|
165
|
+
.ropeproject
|
|
166
|
+
|
|
167
|
+
# mkdocs documentation
|
|
168
|
+
/site
|
|
169
|
+
|
|
170
|
+
# mypy
|
|
171
|
+
.mypy_cache/
|
|
172
|
+
.dmypy.json
|
|
173
|
+
dmypy.json
|
|
174
|
+
|
|
175
|
+
# Pyre type checker
|
|
176
|
+
.pyre/
|
|
177
|
+
|
|
178
|
+
# pytype static type analyzer
|
|
179
|
+
.pytype/
|
|
180
|
+
|
|
181
|
+
# Cython debug symbols
|
|
182
|
+
cython_debug/
|
|
183
|
+
|
|
184
|
+
# PyCharm
|
|
185
|
+
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
|
186
|
+
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
|
187
|
+
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
|
188
|
+
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
|
189
|
+
# .idea/
|
|
190
|
+
|
|
191
|
+
# Abstra
|
|
192
|
+
# Abstra is an AI-powered process automation framework.
|
|
193
|
+
# Ignore directories containing user credentials, local state, and settings.
|
|
194
|
+
# Learn more at https://abstra.io/docs
|
|
195
|
+
.abstra/
|
|
196
|
+
|
|
197
|
+
# Visual Studio Code
|
|
198
|
+
# Visual Studio Code specific template is maintained in a separate VisualStudioCode.gitignore
|
|
199
|
+
# that can be found at https://github.com/github/gitignore/blob/main/Global/VisualStudioCode.gitignore
|
|
200
|
+
# and can be added to the global gitignore or merged into this file. However, if you prefer,
|
|
201
|
+
# you could uncomment the following to ignore the entire vscode folder
|
|
202
|
+
# .vscode/
|
|
203
|
+
# Temporary file for partial code execution
|
|
204
|
+
tempCodeRunnerFile.py
|
|
205
|
+
|
|
206
|
+
# Ruff stuff:
|
|
207
|
+
.ruff_cache/
|
|
208
|
+
|
|
209
|
+
# PyPI configuration file
|
|
210
|
+
.pypirc
|
|
211
|
+
|
|
212
|
+
# Marimo
|
|
213
|
+
marimo/_static/
|
|
214
|
+
marimo/_lsp/
|
|
215
|
+
__marimo__/
|
|
216
|
+
|
|
217
|
+
# Streamlit
|
|
218
|
+
.streamlit/secrets.toml
|
|
219
|
+
|
|
220
|
+
# hatch-vcs generated version file
|
|
221
|
+
*_version.py
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
repos:
|
|
2
|
+
- repo: local
|
|
3
|
+
hooks:
|
|
4
|
+
- id: no-internal-refs
|
|
5
|
+
name: no internal research references
|
|
6
|
+
entry: python3 tools/check_internal_refs.py
|
|
7
|
+
language: system
|
|
8
|
+
types: [text]
|
|
9
|
+
exclude: ^(CHANGELOG\.md|tools/check_internal_refs\.py)$
|
|
10
|
+
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
11
|
+
rev: "v6.0.0"
|
|
12
|
+
hooks:
|
|
13
|
+
- id: trailing-whitespace
|
|
14
|
+
- id: name-tests-test
|
|
15
|
+
args: [--pytest-test-first]
|
|
16
|
+
- id: end-of-file-fixer
|
|
17
|
+
- repo: https://github.com/astral-sh/ruff-pre-commit
|
|
18
|
+
rev: v0.15.2
|
|
19
|
+
hooks:
|
|
20
|
+
- id: ruff-check
|
|
21
|
+
args: [--fix]
|
|
22
|
+
- id: ruff-format
|
|
23
|
+
- repo: https://github.com/compilerla/conventional-pre-commit
|
|
24
|
+
rev: v4.3.0
|
|
25
|
+
hooks:
|
|
26
|
+
- id: conventional-pre-commit
|
|
27
|
+
stages: [commit-msg]
|
|
28
|
+
args: []
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# Required
|
|
2
|
+
version: 2
|
|
3
|
+
|
|
4
|
+
# Set the OS, Python version and other tools you might need
|
|
5
|
+
build:
|
|
6
|
+
os: ubuntu-22.04
|
|
7
|
+
tools:
|
|
8
|
+
python: "3.12"
|
|
9
|
+
|
|
10
|
+
python:
|
|
11
|
+
install:
|
|
12
|
+
- method: pip
|
|
13
|
+
path: .
|
|
14
|
+
extra_requirements:
|
|
15
|
+
# Install with the [docs] flag for sphinx docs specific extensions
|
|
16
|
+
- docs
|
|
17
|
+
|
|
18
|
+
# Build documentation in the "docs/" directory with Sphinx
|
|
19
|
+
sphinx:
|
|
20
|
+
configuration: docs/conf.py
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## 0.0.1 (2026-08-11)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* call-time style resolution with zero-style light fallback ([7888620](https://github.com/CoreySpohn/eyepiece/commit/7888620d77f6f5ac93379f8eab2d9733fea55376))
|
|
9
|
+
* complex-field 2x2 show_field with SubFigure embedding ([4c92480](https://github.com/CoreySpohn/eyepiece/commit/4c924806f2b9e790aa7d1b4a8facd68901482deb))
|
|
10
|
+
* corner plots, hist-vs-pdf overlay, covariance ellipse ([72da7be](https://github.com/CoreySpohn/eyepiece/commit/72da7be3d67a1560d7ef44f76bc54b6369b3a780))
|
|
11
|
+
* flat public namespace and firewall guard tests ([7d7b0a2](https://github.com/CoreySpohn/eyepiece/commit/7d7b0a208ce1113c9f8efaeec58bf05cc00a5fea))
|
|
12
|
+
* imshow_log, imshow_diverging, and shared-norm compare_row ([223c945](https://github.com/CoreySpohn/eyepiece/commit/223c9455007f2806c52919ce9ef7f6a750400447))
|
|
13
|
+
* mode-aware save_fig with directory anchoring ([74118de](https://github.com/CoreySpohn/eyepiece/commit/74118de9115036858dcb00308187a67a6ef9f87b))
|
|
14
|
+
* multi-sink grab-frame record() and animate() facade ([c217283](https://github.com/CoreySpohn/eyepiece/commit/c21728317626305f8c94bbdbe0401e26813c7962))
|
|
15
|
+
* pixel-edge extent and axis-label helpers ([47a052a](https://github.com/CoreySpohn/eyepiece/commit/47a052a56169595c569bee1ca0f386b4fd303a6e))
|
|
16
|
+
* PlotResult/MosaicResult return contract and artist key vocabulary ([cf3f06c](https://github.com/CoreySpohn/eyepiece/commit/cf3f06cac4273dda8181119b926fabb78429fba5))
|
|
17
|
+
* scaffold eyepiece package ([b08f5cb](https://github.com/CoreySpohn/eyepiece/commit/b08f5cb5ab550380df7d8e4232b0fcf584a94dbf))
|
|
18
|
+
* SourceStyles, Frame, and docs skeleton ([ea20c94](https://github.com/CoreySpohn/eyepiece/commit/ea20c947b4aa30a4064cd9ce1873c7480cb13e8b))
|
|
19
|
+
* trajectory trail with depth cues, sky_fan, fading_track, schematic rail ([5aa3967](https://github.com/CoreySpohn/eyepiece/commit/5aa39679828f726562a616f35fa1f9f17028469f))
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
### Bug Fixes
|
|
23
|
+
|
|
24
|
+
* compare_row single-image squeeze, empty-list guard, update range docs ([f6aae74](https://github.com/CoreySpohn/eyepiece/commit/f6aae741c5b147623833fdda462f101bdc904c36))
|
|
25
|
+
* identity-based eq/hash on PlotResult and MosaicResult ([ce629a3](https://github.com/CoreySpohn/eyepiece/commit/ce629a31dcdf66fd1ccba4175cb9a567f61cc4d1))
|
|
26
|
+
* restore internal-ref guard coverage with hook-safe pattern forms ([c693619](https://github.com/CoreySpohn/eyepiece/commit/c693619b35c042f1de4f615d62dd023ec850fa48))
|
|
27
|
+
* sky_fan errorbar artist, schematic lines key and highlight guard ([ba0cec3](https://github.com/CoreySpohn/eyepiece/commit/ba0cec34374f76c8ec0b142ae2b5536ad3f50e5c))
|
|
28
|
+
* validate configured ffmpeg path and cover anim mechanics with tests ([6c1613b](https://github.com/CoreySpohn/eyepiece/commit/6c1613b3d9ee664f6b6c4ec08a9f4388406dbc25))
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
### Miscellaneous Chores
|
|
32
|
+
|
|
33
|
+
* release 0.0.1 ([8b60e62](https://github.com/CoreySpohn/eyepiece/commit/8b60e62610407673d4f2426243831bb0784de8fd))
|
eyepiece-0.0.1/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Corey Spohn
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
eyepiece-0.0.1/PKG-INFO
ADDED
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: eyepiece
|
|
3
|
+
Version: 0.0.1
|
|
4
|
+
Summary: Plotting and animation primitives for astronomical imaging simulations: ax-first stateless figure functions, a multi-sink animation recorder, and styled figure saving.
|
|
5
|
+
Project-URL: Homepage, https://github.com/CoreySpohn/eyepiece
|
|
6
|
+
Project-URL: Issues, https://github.com/CoreySpohn/eyepiece/issues
|
|
7
|
+
Author-email: Corey Spohn <corey.a.spohn@nasa.gov>
|
|
8
|
+
License: MIT License
|
|
9
|
+
|
|
10
|
+
Copyright (c) 2026 Corey Spohn
|
|
11
|
+
|
|
12
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
13
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
14
|
+
in the Software without restriction, including without limitation the rights
|
|
15
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
16
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
17
|
+
furnished to do so, subject to the following conditions:
|
|
18
|
+
|
|
19
|
+
The above copyright notice and this permission notice shall be included in all
|
|
20
|
+
copies or substantial portions of the Software.
|
|
21
|
+
|
|
22
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
23
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
24
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
25
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
26
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
27
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
28
|
+
SOFTWARE.
|
|
29
|
+
License-File: LICENSE
|
|
30
|
+
Classifier: Development Status :: 2 - Pre-Alpha
|
|
31
|
+
Classifier: Intended Audience :: Science/Research
|
|
32
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
33
|
+
Classifier: Programming Language :: Python :: 3
|
|
34
|
+
Classifier: Topic :: Scientific/Engineering :: Astronomy
|
|
35
|
+
Requires-Python: >=3.11
|
|
36
|
+
Requires-Dist: hwostyle>=1.3.0
|
|
37
|
+
Requires-Dist: matplotlib>=3.8
|
|
38
|
+
Requires-Dist: numpy
|
|
39
|
+
Provides-Extra: dev
|
|
40
|
+
Requires-Dist: pre-commit; extra == 'dev'
|
|
41
|
+
Provides-Extra: docs
|
|
42
|
+
Requires-Dist: imageio-ffmpeg; extra == 'docs'
|
|
43
|
+
Requires-Dist: ipython; extra == 'docs'
|
|
44
|
+
Requires-Dist: myst-nb; extra == 'docs'
|
|
45
|
+
Requires-Dist: sphinx; extra == 'docs'
|
|
46
|
+
Requires-Dist: sphinx-autoapi; extra == 'docs'
|
|
47
|
+
Requires-Dist: sphinx-autodoc-typehints; extra == 'docs'
|
|
48
|
+
Requires-Dist: sphinx-book-theme; extra == 'docs'
|
|
49
|
+
Provides-Extra: hwo
|
|
50
|
+
Requires-Dist: hwoutils; extra == 'hwo'
|
|
51
|
+
Provides-Extra: test
|
|
52
|
+
Requires-Dist: pytest; extra == 'test'
|
|
53
|
+
Requires-Dist: pytest-cov; extra == 'test'
|
|
54
|
+
Description-Content-Type: text/markdown
|
|
55
|
+
|
|
56
|
+
# eyepiece
|
|
57
|
+
|
|
58
|
+
Plotting and animation primitives for astronomical imaging simulations.
|
|
59
|
+
|
|
60
|
+
## What eyepiece is
|
|
61
|
+
|
|
62
|
+
`eyepiece` provides ax-first, stateless figure functions for the plots that
|
|
63
|
+
recur across direct-imaging work: log-scaled and diverging image displays,
|
|
64
|
+
complex-field panels, corner plots, orbit and sky-track scenes, optical-train
|
|
65
|
+
schematics, and a multi-sink animation recorder that grabs frames once and
|
|
66
|
+
writes them to any combination of gif, mp4, and html. Every primitive takes
|
|
67
|
+
plain arrays in and returns a small result object holding the axes and the
|
|
68
|
+
artists it drew, so callers can update or extend a figure without re-deriving
|
|
69
|
+
which line or image object came from where.
|
|
70
|
+
|
|
71
|
+
Figure style (color, colormaps, and mode) is resolved through
|
|
72
|
+
[hwostyle](https://github.com/HabitableWorldsObservatory/hwostyle) at call
|
|
73
|
+
time, not at import time. `import eyepiece` never activates a style or
|
|
74
|
+
touches matplotlib's rcParams. Without an active hwostyle mode, primitives
|
|
75
|
+
fall back to a fixed light-mode palette, so eyepiece also works as a
|
|
76
|
+
standalone plotting library.
|
|
77
|
+
|
|
78
|
+
## What eyepiece is not
|
|
79
|
+
|
|
80
|
+
- **Not a simulation library.** eyepiece takes arrays and returns figures; it
|
|
81
|
+
never imports a simulation, orbit, or optics package.
|
|
82
|
+
- **Not a style engine.** Color, colormap, and mode definitions live in
|
|
83
|
+
hwostyle; eyepiece only reads them at call time.
|
|
84
|
+
- **Not a data pipeline.** Aggregating or transforming simulation output
|
|
85
|
+
before plotting is the caller's job.
|
|
86
|
+
|
|
87
|
+
## Status
|
|
88
|
+
|
|
89
|
+
eyepiece is in early development. The package currently exposes only its
|
|
90
|
+
version; the plotting and animation API is under active construction.
|
|
91
|
+
|
|
92
|
+
## Installation
|
|
93
|
+
|
|
94
|
+
```bash
|
|
95
|
+
pip install eyepiece
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
Unit conversions used by a small number of layout helpers (arcsecond and AU
|
|
99
|
+
extents) are optional and pull in [hwoutils](https://github.com/CoreySpohn/hwoutils):
|
|
100
|
+
|
|
101
|
+
```bash
|
|
102
|
+
pip install eyepiece[hwo]
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
## License
|
|
106
|
+
|
|
107
|
+
MIT
|
eyepiece-0.0.1/README.md
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# eyepiece
|
|
2
|
+
|
|
3
|
+
Plotting and animation primitives for astronomical imaging simulations.
|
|
4
|
+
|
|
5
|
+
## What eyepiece is
|
|
6
|
+
|
|
7
|
+
`eyepiece` provides ax-first, stateless figure functions for the plots that
|
|
8
|
+
recur across direct-imaging work: log-scaled and diverging image displays,
|
|
9
|
+
complex-field panels, corner plots, orbit and sky-track scenes, optical-train
|
|
10
|
+
schematics, and a multi-sink animation recorder that grabs frames once and
|
|
11
|
+
writes them to any combination of gif, mp4, and html. Every primitive takes
|
|
12
|
+
plain arrays in and returns a small result object holding the axes and the
|
|
13
|
+
artists it drew, so callers can update or extend a figure without re-deriving
|
|
14
|
+
which line or image object came from where.
|
|
15
|
+
|
|
16
|
+
Figure style (color, colormaps, and mode) is resolved through
|
|
17
|
+
[hwostyle](https://github.com/HabitableWorldsObservatory/hwostyle) at call
|
|
18
|
+
time, not at import time. `import eyepiece` never activates a style or
|
|
19
|
+
touches matplotlib's rcParams. Without an active hwostyle mode, primitives
|
|
20
|
+
fall back to a fixed light-mode palette, so eyepiece also works as a
|
|
21
|
+
standalone plotting library.
|
|
22
|
+
|
|
23
|
+
## What eyepiece is not
|
|
24
|
+
|
|
25
|
+
- **Not a simulation library.** eyepiece takes arrays and returns figures; it
|
|
26
|
+
never imports a simulation, orbit, or optics package.
|
|
27
|
+
- **Not a style engine.** Color, colormap, and mode definitions live in
|
|
28
|
+
hwostyle; eyepiece only reads them at call time.
|
|
29
|
+
- **Not a data pipeline.** Aggregating or transforming simulation output
|
|
30
|
+
before plotting is the caller's job.
|
|
31
|
+
|
|
32
|
+
## Status
|
|
33
|
+
|
|
34
|
+
eyepiece is in early development. The package currently exposes only its
|
|
35
|
+
version; the plotting and animation API is under active construction.
|
|
36
|
+
|
|
37
|
+
## Installation
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
pip install eyepiece
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
Unit conversions used by a small number of layout helpers (arcsecond and AU
|
|
44
|
+
extents) are optional and pull in [hwoutils](https://github.com/CoreySpohn/hwoutils):
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
pip install eyepiece[hwo]
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
## License
|
|
51
|
+
|
|
52
|
+
MIT
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ['hatchling', "hatch-fancy-pypi-readme", "hatch-vcs"]
|
|
3
|
+
build-backend = "hatchling.build"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "eyepiece"
|
|
7
|
+
description = "Plotting and animation primitives for astronomical imaging simulations: ax-first stateless figure functions, a multi-sink animation recorder, and styled figure saving."
|
|
8
|
+
authors = [{ name = "Corey Spohn", email = "corey.a.spohn@nasa.gov" }]
|
|
9
|
+
dynamic = ['readme', 'version']
|
|
10
|
+
requires-python = ">=3.11"
|
|
11
|
+
license = { file = "LICENSE" }
|
|
12
|
+
classifiers = [
|
|
13
|
+
"Development Status :: 2 - Pre-Alpha",
|
|
14
|
+
"Intended Audience :: Science/Research",
|
|
15
|
+
"License :: OSI Approved :: MIT License",
|
|
16
|
+
"Programming Language :: Python :: 3",
|
|
17
|
+
"Topic :: Scientific/Engineering :: Astronomy",
|
|
18
|
+
]
|
|
19
|
+
dependencies = ["matplotlib>=3.8", "numpy", "hwostyle>=1.3.0"]
|
|
20
|
+
|
|
21
|
+
[project.optional-dependencies]
|
|
22
|
+
hwo = ["hwoutils"]
|
|
23
|
+
docs = ["sphinx", "myst-nb", "sphinx-book-theme", "sphinx-autoapi", "sphinx_autodoc_typehints", "ipython", "imageio-ffmpeg"]
|
|
24
|
+
test = ["pytest", "pytest-cov"]
|
|
25
|
+
dev = ["pre-commit"]
|
|
26
|
+
|
|
27
|
+
[project.urls]
|
|
28
|
+
Homepage = "https://github.com/CoreySpohn/eyepiece"
|
|
29
|
+
Issues = "https://github.com/CoreySpohn/eyepiece/issues"
|
|
30
|
+
|
|
31
|
+
[tool.hatch.version]
|
|
32
|
+
source = "vcs"
|
|
33
|
+
|
|
34
|
+
[tool.hatch.build.hooks.vcs]
|
|
35
|
+
version-file = "src/eyepiece/_version.py"
|
|
36
|
+
|
|
37
|
+
[tool.hatch.metadata.hooks.fancy-pypi-readme]
|
|
38
|
+
content-type = "text/markdown"
|
|
39
|
+
|
|
40
|
+
[[tool.hatch.metadata.hooks.fancy-pypi-readme.fragments]]
|
|
41
|
+
path = "README.md"
|
|
42
|
+
|
|
43
|
+
[tool.ruff.lint]
|
|
44
|
+
select = ["B", "D", "E", "F", "I", "UP", "RUF"]
|
|
45
|
+
|
|
46
|
+
[tool.ruff.lint.pydocstyle]
|
|
47
|
+
convention = "google"
|
|
48
|
+
|
|
49
|
+
[tool.ruff.lint.per-file-ignores]
|
|
50
|
+
"tests/**" = ["D"]
|
|
51
|
+
|
|
52
|
+
[tool.hatch.build.targets.wheel]
|
|
53
|
+
packages = ["src/eyepiece"]
|
|
54
|
+
|
|
55
|
+
[tool.hatch.build.targets.sdist]
|
|
56
|
+
exclude = ["/scripts", "/docs", "/tests", "/.github"]
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
"""Plotting and animation primitives for astronomical imaging simulations.
|
|
2
|
+
|
|
3
|
+
eyepiece provides a small set of pure functions for rendering, comparing,
|
|
4
|
+
and animating simulated images (point spread functions, coronagraph
|
|
5
|
+
detection maps, complex optical fields, and the like). Every public name
|
|
6
|
+
lives at the top level of this package; the submodules that implement them
|
|
7
|
+
(``images``, ``layout``, ``output``, ``anim``) are internal organization
|
|
8
|
+
and are not part of the public API.
|
|
9
|
+
|
|
10
|
+
Example::
|
|
11
|
+
|
|
12
|
+
import eyepiece as ep
|
|
13
|
+
|
|
14
|
+
result = ep.imshow_log(image)
|
|
15
|
+
ep.save_fig(result.fig, "psf")
|
|
16
|
+
|
|
17
|
+
The library never imports a simulation library and never mutates
|
|
18
|
+
matplotlib's global state at import time; style is applied explicitly by
|
|
19
|
+
the caller (see ``eyepiece._style``), not captured when this package loads.
|
|
20
|
+
"""
|
|
21
|
+
|
|
22
|
+
from eyepiece._result import MosaicResult, PlotResult
|
|
23
|
+
from eyepiece._version import __version__
|
|
24
|
+
from eyepiece.anim import animate, record
|
|
25
|
+
from eyepiece.images import compare_row, imshow_diverging, imshow_log, show_field
|
|
26
|
+
from eyepiece.layout import (
|
|
27
|
+
Frame,
|
|
28
|
+
SourceStyles,
|
|
29
|
+
extent_arcsec,
|
|
30
|
+
extent_au,
|
|
31
|
+
extent_lod,
|
|
32
|
+
extent_lod_from_pixels,
|
|
33
|
+
label_arcsec,
|
|
34
|
+
label_au,
|
|
35
|
+
label_lod,
|
|
36
|
+
)
|
|
37
|
+
from eyepiece.output import save_fig
|
|
38
|
+
from eyepiece.scene import fading_track, sky_fan, trail
|
|
39
|
+
from eyepiece.schematic import schematic
|
|
40
|
+
from eyepiece.stats import corner, corner_overlay, cov_ellipse, hist_vs_pdf
|
|
41
|
+
|
|
42
|
+
__all__ = [
|
|
43
|
+
"Frame",
|
|
44
|
+
"MosaicResult",
|
|
45
|
+
"PlotResult",
|
|
46
|
+
"SourceStyles",
|
|
47
|
+
"__version__",
|
|
48
|
+
"animate",
|
|
49
|
+
"compare_row",
|
|
50
|
+
"corner",
|
|
51
|
+
"corner_overlay",
|
|
52
|
+
"cov_ellipse",
|
|
53
|
+
"extent_arcsec",
|
|
54
|
+
"extent_au",
|
|
55
|
+
"extent_lod",
|
|
56
|
+
"extent_lod_from_pixels",
|
|
57
|
+
"fading_track",
|
|
58
|
+
"hist_vs_pdf",
|
|
59
|
+
"imshow_diverging",
|
|
60
|
+
"imshow_log",
|
|
61
|
+
"label_arcsec",
|
|
62
|
+
"label_au",
|
|
63
|
+
"label_lod",
|
|
64
|
+
"record",
|
|
65
|
+
"save_fig",
|
|
66
|
+
"schematic",
|
|
67
|
+
"show_field",
|
|
68
|
+
"sky_fan",
|
|
69
|
+
"trail",
|
|
70
|
+
]
|