m4opt 0.1.0__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.
- m4opt-0.1.0/.github/dependabot.yml +6 -0
- m4opt-0.1.0/.github/workflows/ci_cron_weekly.yml +44 -0
- m4opt-0.1.0/.github/workflows/ci_tests.yml +110 -0
- m4opt-0.1.0/.github/workflows/codeql-analysis.yml +72 -0
- m4opt-0.1.0/.github/workflows/publish.yml +19 -0
- m4opt-0.1.0/.gitignore +70 -0
- m4opt-0.1.0/.pre-commit-config.yaml +44 -0
- m4opt-0.1.0/.readthedocs.yml +21 -0
- m4opt-0.1.0/CHANGES.rst +8 -0
- m4opt-0.1.0/MANIFEST.in +10 -0
- m4opt-0.1.0/PKG-INFO +148 -0
- m4opt-0.1.0/README.rst +98 -0
- m4opt-0.1.0/docs/Makefile +133 -0
- m4opt-0.1.0/docs/_static/css/risk_table.css +45 -0
- m4opt-0.1.0/docs/_static/example.ecsv +304 -0
- m4opt-0.1.0/docs/_static/example.gif +0 -0
- m4opt-0.1.0/docs/conf.py +266 -0
- m4opt-0.1.0/docs/design/index.rst +7 -0
- m4opt-0.1.0/docs/design/milp.rst +348 -0
- m4opt-0.1.0/docs/dev/changes.rst +8 -0
- m4opt-0.1.0/docs/dev/contributing.rst +2 -0
- m4opt-0.1.0/docs/dev/index.rst +12 -0
- m4opt-0.1.0/docs/dev/npr7150.rst +338 -0
- m4opt-0.1.0/docs/dev/related.rst +80 -0
- m4opt-0.1.0/docs/dev/testing.rst +2 -0
- m4opt-0.1.0/docs/guide/cli.rst +10 -0
- m4opt-0.1.0/docs/guide/constraints.rst +12 -0
- m4opt-0.1.0/docs/guide/dynamics.rst +5 -0
- m4opt-0.1.0/docs/guide/fov.rst +189 -0
- m4opt-0.1.0/docs/guide/index.rst +17 -0
- m4opt-0.1.0/docs/guide/milp.rst +7 -0
- m4opt-0.1.0/docs/guide/missions.rst +6 -0
- m4opt-0.1.0/docs/guide/orbit.rst +5 -0
- m4opt-0.1.0/docs/guide/skygrid.rst +81 -0
- m4opt-0.1.0/docs/guide/synphot.rst +40 -0
- m4opt-0.1.0/docs/guide/utils.rst +7 -0
- m4opt-0.1.0/docs/index.rst +55 -0
- m4opt-0.1.0/docs/install/cplex.rst +74 -0
- m4opt-0.1.0/docs/install/deploy.rst +73 -0
- m4opt-0.1.0/docs/install/gurobi.rst +49 -0
- m4opt-0.1.0/docs/install/index.rst +29 -0
- m4opt-0.1.0/docs/make.bat +172 -0
- m4opt-0.1.0/docs/scenarios/dorado.rst +151 -0
- m4opt-0.1.0/docs/scenarios/index.rst +14 -0
- m4opt-0.1.0/docs/scenarios/sedmachine.rst +4 -0
- m4opt-0.1.0/docs/scenarios/ztf.rst +113 -0
- m4opt-0.1.0/licenses/DORADO_LICENSE.txt +249 -0
- m4opt-0.1.0/licenses/LICENSE.rst +26 -0
- m4opt-0.1.0/licenses/README.rst +12 -0
- m4opt-0.1.0/licenses/TEMPLATE_LICENCE.rst +31 -0
- m4opt-0.1.0/m4opt/__init__.py +4 -0
- m4opt-0.1.0/m4opt/_cli/__init__.py +11 -0
- m4opt-0.1.0/m4opt/_cli/animate.py +391 -0
- m4opt-0.1.0/m4opt/_cli/core.py +74 -0
- m4opt-0.1.0/m4opt/_cli/prime.py +19 -0
- m4opt-0.1.0/m4opt/_cli/schedule.py +738 -0
- m4opt-0.1.0/m4opt/_cli/tests/__init__.py +0 -0
- m4opt-0.1.0/m4opt/_cli/tests/conftest.py +14 -0
- m4opt-0.1.0/m4opt/_cli/tests/data/800.fits +2185 -4
- m4opt-0.1.0/m4opt/_cli/tests/test_core.py +70 -0
- m4opt-0.1.0/m4opt/_cli/tests/test_end_to_end.py +86 -0
- m4opt-0.1.0/m4opt/_version.py +21 -0
- m4opt-0.1.0/m4opt/conftest.py +66 -0
- m4opt-0.1.0/m4opt/constraints/__init__.py +12 -0
- m4opt-0.1.0/m4opt/constraints/_body_separation.py +78 -0
- m4opt-0.1.0/m4opt/constraints/_core.py +16 -0
- m4opt-0.1.0/m4opt/constraints/_earth_limb.py +59 -0
- m4opt-0.1.0/m4opt/constraints/_galactic.py +23 -0
- m4opt-0.1.0/m4opt/constraints/tests/__init__.py +0 -0
- m4opt-0.1.0/m4opt/constraints/tests/test_body_separation.py +37 -0
- m4opt-0.1.0/m4opt/constraints/tests/test_earth_limb.py +50 -0
- m4opt-0.1.0/m4opt/constraints/tests/test_galactic.py +19 -0
- m4opt-0.1.0/m4opt/dynamics/__init__.py +12 -0
- m4opt-0.1.0/m4opt/dynamics/_roll.py +156 -0
- m4opt-0.1.0/m4opt/dynamics/_slew.py +175 -0
- m4opt-0.1.0/m4opt/dynamics/tests/__init__.py +0 -0
- m4opt-0.1.0/m4opt/dynamics/tests/test_roll.py +29 -0
- m4opt-0.1.0/m4opt/extern/__init__.py +5 -0
- m4opt-0.1.0/m4opt/fov/__init__.py +3 -0
- m4opt-0.1.0/m4opt/fov/_core.py +357 -0
- m4opt-0.1.0/m4opt/milp.py +324 -0
- m4opt-0.1.0/m4opt/missions/__init__.py +7 -0
- m4opt-0.1.0/m4opt/missions/_core.py +36 -0
- m4opt-0.1.0/m4opt/missions/_ultrasat.py +137 -0
- m4opt-0.1.0/m4opt/missions/_uvex.py +159 -0
- m4opt-0.1.0/m4opt/orbit/__init__.py +5 -0
- m4opt-0.1.0/m4opt/orbit/_core.py +29 -0
- m4opt-0.1.0/m4opt/orbit/_spice.py +69 -0
- m4opt-0.1.0/m4opt/orbit/_tle.py +115 -0
- m4opt-0.1.0/m4opt/py.typed +0 -0
- m4opt-0.1.0/m4opt/skygrid/__init__.py +6 -0
- m4opt-0.1.0/m4opt/skygrid/_geodesic.py +153 -0
- m4opt-0.1.0/m4opt/skygrid/_healpix.py +27 -0
- m4opt-0.1.0/m4opt/skygrid/_sinusoidal.py +45 -0
- m4opt-0.1.0/m4opt/skygrid/_spiral.py +34 -0
- m4opt-0.1.0/m4opt/skygrid/tests/__init__.py +0 -0
- m4opt-0.1.0/m4opt/skygrid/tests/test_skygrid.py +33 -0
- m4opt-0.1.0/m4opt/synphot/__init__.py +10 -0
- m4opt-0.1.0/m4opt/synphot/_detector.py +128 -0
- m4opt-0.1.0/m4opt/synphot/_extinction.py +115 -0
- m4opt-0.1.0/m4opt/synphot/_extrinsic.py +95 -0
- m4opt-0.1.0/m4opt/synphot/_math.py +144 -0
- m4opt-0.1.0/m4opt/synphot/background/__init__.py +16 -0
- m4opt-0.1.0/m4opt/synphot/background/_core.py +4 -0
- m4opt-0.1.0/m4opt/synphot/background/_galactic.py +188 -0
- m4opt-0.1.0/m4opt/synphot/background/_skybright/__init__.py +108 -0
- m4opt-0.1.0/m4opt/synphot/background/_skybright/data/10FebZen.txt +2493 -0
- m4opt-0.1.0/m4opt/synphot/background/_skybright/data/10JunZen.txt +2491 -0
- m4opt-0.1.0/m4opt/synphot/background/_skybright/data/10Nog.txt +2493 -0
- m4opt-0.1.0/m4opt/synphot/background/_skybright/data/10Nwh.txt +2499 -0
- m4opt-0.1.0/m4opt/synphot/background/_skybright/data/10Phx.txt +2493 -0
- m4opt-0.1.0/m4opt/synphot/background/_skybright/data/10Tuc.txt +2499 -0
- m4opt-0.1.0/m4opt/synphot/background/_skybright/data/10Zen.txt +2499 -0
- m4opt-0.1.0/m4opt/synphot/background/_skybright/data/README.rst +12 -0
- m4opt-0.1.0/m4opt/synphot/background/_skybright/data/__init__.py +0 -0
- m4opt-0.1.0/m4opt/synphot/background/_zodiacal/__init__.py +231 -0
- m4opt-0.1.0/m4opt/synphot/background/_zodiacal/data/__init__.py +0 -0
- m4opt-0.1.0/m4opt/synphot/background/_zodiacal/data/leinert_zodi.txt +22 -0
- m4opt-0.1.0/m4opt/synphot/background/_zodiacal/data/stis_zodi_high.ecsv +71 -0
- m4opt-0.1.0/m4opt/synphot/tests/__init__.py +0 -0
- m4opt-0.1.0/m4opt/synphot/tests/test_detector.py +95 -0
- m4opt-0.1.0/m4opt/synphot/tests/test_extinction.py +67 -0
- m4opt-0.1.0/m4opt/tests/__init__.py +0 -0
- m4opt-0.1.0/m4opt/tests/hypothesis.py +40 -0
- m4opt-0.1.0/m4opt/tests/plugins/__init__.py +0 -0
- m4opt-0.1.0/m4opt/tests/plugins/problem_size_limits.py +10 -0
- m4opt-0.1.0/m4opt/tests/test_milp.py +124 -0
- m4opt-0.1.0/m4opt/utils/__init__.py +0 -0
- m4opt-0.1.0/m4opt/utils/console.py +136 -0
- m4opt-0.1.0/m4opt/utils/numpy.py +102 -0
- m4opt-0.1.0/m4opt/utils/resource.py +37 -0
- m4opt-0.1.0/m4opt/utils/tests/__init__.py +0 -0
- m4opt-0.1.0/m4opt/utils/tests/test_console.py +11 -0
- m4opt-0.1.0/m4opt/utils/typing_extensions.py +9 -0
- m4opt-0.1.0/m4opt.egg-info/PKG-INFO +148 -0
- m4opt-0.1.0/m4opt.egg-info/SOURCES.txt +141 -0
- m4opt-0.1.0/m4opt.egg-info/dependency_links.txt +1 -0
- m4opt-0.1.0/m4opt.egg-info/entry_points.txt +2 -0
- m4opt-0.1.0/m4opt.egg-info/requires.txt +30 -0
- m4opt-0.1.0/m4opt.egg-info/top_level.txt +4 -0
- m4opt-0.1.0/pyproject.toml +134 -0
- m4opt-0.1.0/setup.cfg +4 -0
- m4opt-0.1.0/tox.ini +88 -0
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
# GitHub Actions workflow that runs on a cron schedule.
|
|
2
|
+
|
|
3
|
+
name: Cron Scheduled CI Tests
|
|
4
|
+
|
|
5
|
+
on:
|
|
6
|
+
schedule:
|
|
7
|
+
# run at 6am UTC on Mondays
|
|
8
|
+
- cron: '0 6 * * 1'
|
|
9
|
+
|
|
10
|
+
jobs:
|
|
11
|
+
# Testing links in documents is a good example of something to run on a schedule
|
|
12
|
+
# to catch links that stop working for some reason.
|
|
13
|
+
cron_tests:
|
|
14
|
+
name: ${{ matrix.name }}
|
|
15
|
+
runs-on: ubuntu-latest
|
|
16
|
+
strategy:
|
|
17
|
+
matrix:
|
|
18
|
+
include:
|
|
19
|
+
- name: Check links in docs using tox
|
|
20
|
+
python: '3.11'
|
|
21
|
+
toxenv: linkcheck
|
|
22
|
+
|
|
23
|
+
- name: Python 3.11 with latest dev versions of key dependencies
|
|
24
|
+
python: '3.11'
|
|
25
|
+
toxenv: py311-test-devdeps
|
|
26
|
+
|
|
27
|
+
steps:
|
|
28
|
+
- uses: actions/checkout@v4
|
|
29
|
+
- name: Cache Astropy data
|
|
30
|
+
uses: actions/cache@v4
|
|
31
|
+
with:
|
|
32
|
+
key: ${{ matrix.toxenv }}
|
|
33
|
+
path: ~/.astropy/cache
|
|
34
|
+
- name: Set up python ${{ matrix.python }}
|
|
35
|
+
uses: actions/setup-python@v5
|
|
36
|
+
with:
|
|
37
|
+
cache: pip
|
|
38
|
+
python-version: ${{ matrix.python }}
|
|
39
|
+
- name: Install base dependencies
|
|
40
|
+
run: |
|
|
41
|
+
python -m pip install --upgrade pip
|
|
42
|
+
python -m pip install tox
|
|
43
|
+
- name: Test with tox
|
|
44
|
+
run: tox -e ${{ matrix.toxenv }}
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
# GitHub Actions workflow for testing and continuous integration.
|
|
2
|
+
#
|
|
3
|
+
# This file performs testing using tox and tox.ini to define and configure the test environments.
|
|
4
|
+
|
|
5
|
+
name: CI Tests
|
|
6
|
+
|
|
7
|
+
on:
|
|
8
|
+
- push
|
|
9
|
+
- pull_request
|
|
10
|
+
|
|
11
|
+
jobs:
|
|
12
|
+
types:
|
|
13
|
+
name: Python type checking
|
|
14
|
+
runs-on: ubuntu-latest
|
|
15
|
+
steps:
|
|
16
|
+
- name: Checkout code
|
|
17
|
+
uses: actions/checkout@v4
|
|
18
|
+
with:
|
|
19
|
+
fetch-depth: 0
|
|
20
|
+
- name: Set up python
|
|
21
|
+
uses: actions/setup-python@v5
|
|
22
|
+
with:
|
|
23
|
+
cache: pip
|
|
24
|
+
python-version: "3.11"
|
|
25
|
+
- name: Run mypy
|
|
26
|
+
uses: python/mypy@v1.15.0
|
|
27
|
+
# Github Actions supports ubuntu, windows, and macos virtual environments:
|
|
28
|
+
# https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners
|
|
29
|
+
ci_tests:
|
|
30
|
+
name: ${{ matrix.name }}
|
|
31
|
+
runs-on: ${{ matrix.os }}
|
|
32
|
+
strategy:
|
|
33
|
+
matrix:
|
|
34
|
+
include:
|
|
35
|
+
- name: Python 3.11 with minimal dependencies and coverage checking
|
|
36
|
+
os: ubuntu-latest
|
|
37
|
+
python: '3.11'
|
|
38
|
+
toxenv: py311-test-cov
|
|
39
|
+
|
|
40
|
+
- name: Python 3.11 with all optional dependencies and coverage checking
|
|
41
|
+
os: ubuntu-latest
|
|
42
|
+
python: '3.11'
|
|
43
|
+
toxenv: py11-test-alldeps-cov
|
|
44
|
+
|
|
45
|
+
# - name: OS X - Python 3.11 with all optional dependencies
|
|
46
|
+
# os: macos-latest
|
|
47
|
+
# python: '3.11'
|
|
48
|
+
# toxenv: py311-test-alldeps
|
|
49
|
+
|
|
50
|
+
# - name: Windows - Python 3.11 with all optional dependencies
|
|
51
|
+
# os: windows-latest
|
|
52
|
+
# python: '3.11'
|
|
53
|
+
# toxenv: py311-test-alldeps
|
|
54
|
+
|
|
55
|
+
- name: Python 3.11 with oldest supported version of all dependencies
|
|
56
|
+
os: ubuntu-20.04
|
|
57
|
+
python: '3.11'
|
|
58
|
+
toxenv: py311-test-oldestdeps
|
|
59
|
+
|
|
60
|
+
# - name: Python 3.11 with latest dev versions of key dependencies
|
|
61
|
+
# os: ubuntu-latest
|
|
62
|
+
# python: '3.11'
|
|
63
|
+
# toxenv: py311-test-devdeps
|
|
64
|
+
|
|
65
|
+
# - name: Test building of Sphinx docs
|
|
66
|
+
# os: ubuntu-latest
|
|
67
|
+
# python: '3.11'
|
|
68
|
+
# toxenv: build_docs
|
|
69
|
+
|
|
70
|
+
steps:
|
|
71
|
+
- name: Checkout code
|
|
72
|
+
uses: actions/checkout@v4
|
|
73
|
+
with:
|
|
74
|
+
fetch-depth: 0
|
|
75
|
+
- name: Cache Astropy data
|
|
76
|
+
uses: actions/cache@v4
|
|
77
|
+
with:
|
|
78
|
+
key: ${{ matrix.toxenv }}
|
|
79
|
+
path: ~/.astropy/cache
|
|
80
|
+
- name: Set up python ${{ matrix.python }} on ${{ matrix.os }}
|
|
81
|
+
uses: actions/setup-python@v5
|
|
82
|
+
with:
|
|
83
|
+
cache: pip
|
|
84
|
+
python-version: ${{ matrix.python }}
|
|
85
|
+
- name: Install base dependencies
|
|
86
|
+
run: |
|
|
87
|
+
python -m pip install --upgrade pip
|
|
88
|
+
python -m pip install tox codecov
|
|
89
|
+
|
|
90
|
+
- name: Test with tox
|
|
91
|
+
env:
|
|
92
|
+
CPLEX_STUDIO_KEY: ${{ secrets.CPLEX_STUDIO_KEY }}
|
|
93
|
+
GRB_LICENSE_FILE_CONTENTS: ${{ secrets.GRB_LICENSE_FILE_CONTENTS }}
|
|
94
|
+
run: |
|
|
95
|
+
if [ -n "$GRB_LICENSE_FILE_CONTENTS" ]; then
|
|
96
|
+
printenv GRB_LICENSE_FILE_CONTENTS > $HOME/gurobi.lic
|
|
97
|
+
fi
|
|
98
|
+
tox -e ${{ matrix.toxenv }}
|
|
99
|
+
|
|
100
|
+
- name: Upload coverage to codecov
|
|
101
|
+
if: contains(matrix.toxenv, '-cov')
|
|
102
|
+
uses: codecov/codecov-action@v5
|
|
103
|
+
with:
|
|
104
|
+
token: ${{ secrets.CODECOV_TOKEN }}
|
|
105
|
+
|
|
106
|
+
- name: Upload test results to Codecov
|
|
107
|
+
if: contains(matrix.toxenv, '-cov')
|
|
108
|
+
uses: codecov/test-results-action@v1
|
|
109
|
+
with:
|
|
110
|
+
token: ${{ secrets.CODECOV_TOKEN }}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
# For most projects, this workflow file will not need changing; you simply need
|
|
2
|
+
# to commit it to your repository.
|
|
3
|
+
#
|
|
4
|
+
# You may wish to alter this file to override the set of languages analyzed,
|
|
5
|
+
# or to provide custom queries or build logic.
|
|
6
|
+
#
|
|
7
|
+
# ******** NOTE ********
|
|
8
|
+
# We have attempted to detect the languages in your repository. Please check
|
|
9
|
+
# the `language` matrix defined below to confirm you have the correct set of
|
|
10
|
+
# supported CodeQL languages.
|
|
11
|
+
#
|
|
12
|
+
name: "CodeQL"
|
|
13
|
+
|
|
14
|
+
on:
|
|
15
|
+
push:
|
|
16
|
+
branches: [ main ]
|
|
17
|
+
pull_request:
|
|
18
|
+
# The branches below must be a subset of the branches above
|
|
19
|
+
branches: [ main ]
|
|
20
|
+
schedule:
|
|
21
|
+
- cron: '38 10 * * 4'
|
|
22
|
+
|
|
23
|
+
jobs:
|
|
24
|
+
analyze:
|
|
25
|
+
name: Analyze
|
|
26
|
+
runs-on: ubuntu-latest
|
|
27
|
+
permissions:
|
|
28
|
+
actions: read
|
|
29
|
+
contents: read
|
|
30
|
+
security-events: write
|
|
31
|
+
|
|
32
|
+
strategy:
|
|
33
|
+
fail-fast: false
|
|
34
|
+
matrix:
|
|
35
|
+
language: [ 'python' ]
|
|
36
|
+
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
|
|
37
|
+
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support
|
|
38
|
+
|
|
39
|
+
steps:
|
|
40
|
+
- name: Checkout repository
|
|
41
|
+
uses: actions/checkout@v4
|
|
42
|
+
|
|
43
|
+
# Initializes the CodeQL tools for scanning.
|
|
44
|
+
- name: Initialize CodeQL
|
|
45
|
+
uses: github/codeql-action/init@v3
|
|
46
|
+
with:
|
|
47
|
+
languages: ${{ matrix.language }}
|
|
48
|
+
# If you wish to specify custom queries, you can do so here or in a config file.
|
|
49
|
+
# By default, queries listed here will override any specified in a config file.
|
|
50
|
+
# Prefix the list here with "+" to use these queries and those in the config file.
|
|
51
|
+
|
|
52
|
+
# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
|
|
53
|
+
# queries: security-extended,security-and-quality
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
|
|
57
|
+
# If this step fails, then you should remove it and run the build manually (see below)
|
|
58
|
+
- name: Autobuild
|
|
59
|
+
uses: github/codeql-action/autobuild@v3
|
|
60
|
+
|
|
61
|
+
# ℹ️ Command-line programs to run using the OS shell.
|
|
62
|
+
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
|
|
63
|
+
|
|
64
|
+
# If the Autobuild fails above, remove it and uncomment the following three lines.
|
|
65
|
+
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
|
|
66
|
+
|
|
67
|
+
# - run: |
|
|
68
|
+
# echo "Run, Build Application using script"
|
|
69
|
+
# ./location_of_script_within_repo/buildscript.sh
|
|
70
|
+
|
|
71
|
+
- name: Perform CodeQL Analysis
|
|
72
|
+
uses: github/codeql-action/analyze@v3
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
name: Publish
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
schedule:
|
|
5
|
+
# run every day at 4am UTC
|
|
6
|
+
- cron: '0 4 * * *'
|
|
7
|
+
workflow_dispatch:
|
|
8
|
+
pull_request:
|
|
9
|
+
push:
|
|
10
|
+
branches:
|
|
11
|
+
- main
|
|
12
|
+
tags:
|
|
13
|
+
- v*
|
|
14
|
+
|
|
15
|
+
jobs:
|
|
16
|
+
publish:
|
|
17
|
+
uses: OpenAstronomy/github-actions-workflows/.github/workflows/publish_pure_python.yml@8c0fde6f7e926df6ed7057255d29afa9c1ad5320 # v1.16.0
|
|
18
|
+
secrets:
|
|
19
|
+
pypi_token: ${{ secrets.pypi_token }}
|
m4opt-0.1.0/.gitignore
ADDED
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
# Compiled files
|
|
2
|
+
*.py[cod]
|
|
3
|
+
*.a
|
|
4
|
+
*.o
|
|
5
|
+
*.so
|
|
6
|
+
__pycache__
|
|
7
|
+
|
|
8
|
+
# Ignore .c files by default to avoid including generated code. If you want to
|
|
9
|
+
# add a non-generated .c extension, use `git add -f filename.c`.
|
|
10
|
+
*.c
|
|
11
|
+
|
|
12
|
+
# Other generated files
|
|
13
|
+
*/_version.py
|
|
14
|
+
*/cython_version.py
|
|
15
|
+
htmlcov
|
|
16
|
+
.coverage
|
|
17
|
+
.coverage.*
|
|
18
|
+
MANIFEST
|
|
19
|
+
.ipynb_checkpoints
|
|
20
|
+
.hypothesis
|
|
21
|
+
junit.xml
|
|
22
|
+
|
|
23
|
+
# Sphinx
|
|
24
|
+
docs/api
|
|
25
|
+
docs/_build
|
|
26
|
+
docs/guide/roman_wfi.ds9
|
|
27
|
+
|
|
28
|
+
# Eclipse editor project files
|
|
29
|
+
.project
|
|
30
|
+
.pydevproject
|
|
31
|
+
.settings
|
|
32
|
+
|
|
33
|
+
# Pycharm editor project files
|
|
34
|
+
.idea
|
|
35
|
+
|
|
36
|
+
# Floobits project files
|
|
37
|
+
.floo
|
|
38
|
+
.flooignore
|
|
39
|
+
|
|
40
|
+
# Visual Studio Code project files
|
|
41
|
+
.vscode
|
|
42
|
+
|
|
43
|
+
# Packages/installer info
|
|
44
|
+
*.egg
|
|
45
|
+
*.egg-info
|
|
46
|
+
dist
|
|
47
|
+
build
|
|
48
|
+
eggs
|
|
49
|
+
.eggs
|
|
50
|
+
parts
|
|
51
|
+
bin
|
|
52
|
+
var
|
|
53
|
+
sdist
|
|
54
|
+
develop-eggs
|
|
55
|
+
.installed.cfg
|
|
56
|
+
distribute-*.tar.gz
|
|
57
|
+
|
|
58
|
+
# Other
|
|
59
|
+
.cache
|
|
60
|
+
.tox
|
|
61
|
+
.*.sw[op]
|
|
62
|
+
*~
|
|
63
|
+
.project
|
|
64
|
+
.pydevproject
|
|
65
|
+
.settings
|
|
66
|
+
pip-wheel-metadata/
|
|
67
|
+
.tmp
|
|
68
|
+
|
|
69
|
+
# Mac OSX
|
|
70
|
+
.DS_Store
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
# See https://pre-commit.com for more information
|
|
2
|
+
# See https://pre-commit.com/hooks.html for more hooks
|
|
3
|
+
repos:
|
|
4
|
+
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
5
|
+
rev: v5.0.0
|
|
6
|
+
hooks:
|
|
7
|
+
- id: check-case-conflict
|
|
8
|
+
# Check for files with names that would conflict on a case-insensitive
|
|
9
|
+
# filesystem like MacOS HFS+ or Windows FAT.
|
|
10
|
+
- id: check-json
|
|
11
|
+
# Attempts to load all json files to verify syntax.
|
|
12
|
+
- id: check-merge-conflict
|
|
13
|
+
# Check for files that contain merge conflict strings.
|
|
14
|
+
- id: check-symlinks
|
|
15
|
+
# Checks for symlinks which do not point to anything.
|
|
16
|
+
- id: check-toml
|
|
17
|
+
# Attempts to load all TOML files to verify syntax.
|
|
18
|
+
- id: check-xml
|
|
19
|
+
# Attempts to load all xml files to verify syntax.
|
|
20
|
+
- id: check-yaml
|
|
21
|
+
# Attempts to load all yaml files to verify syntax.
|
|
22
|
+
- id: detect-private-key
|
|
23
|
+
# Checks for the existence of private keys.
|
|
24
|
+
- id: end-of-file-fixer
|
|
25
|
+
# Makes sure files end in a newline and only a newline.
|
|
26
|
+
- id: trailing-whitespace
|
|
27
|
+
# Trims trailing whitespace.
|
|
28
|
+
exclude_types: [python] # Covered by Ruff W291.
|
|
29
|
+
- repo: https://github.com/astral-sh/ruff-pre-commit
|
|
30
|
+
# Ruff version.
|
|
31
|
+
rev: v0.9.6
|
|
32
|
+
hooks:
|
|
33
|
+
# Run the linter.
|
|
34
|
+
- id: ruff
|
|
35
|
+
args: ["--extend-select", "I", "--fix"]
|
|
36
|
+
# Run the formatter.
|
|
37
|
+
- id: ruff-format
|
|
38
|
+
- repo: https://github.com/codespell-project/codespell
|
|
39
|
+
rev: v2.4.1
|
|
40
|
+
hooks:
|
|
41
|
+
- id: codespell
|
|
42
|
+
args: ["--write-changes"]
|
|
43
|
+
additional_dependencies:
|
|
44
|
+
- tomli
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
version: 2
|
|
2
|
+
|
|
3
|
+
build:
|
|
4
|
+
apt_packages:
|
|
5
|
+
- graphviz
|
|
6
|
+
os: ubuntu-24.04
|
|
7
|
+
tools:
|
|
8
|
+
python: '3.11'
|
|
9
|
+
|
|
10
|
+
python:
|
|
11
|
+
install:
|
|
12
|
+
- method: pip
|
|
13
|
+
path: .
|
|
14
|
+
extra_requirements:
|
|
15
|
+
- docs
|
|
16
|
+
- all
|
|
17
|
+
|
|
18
|
+
sphinx:
|
|
19
|
+
configuration: docs/conf.py
|
|
20
|
+
|
|
21
|
+
formats: []
|
m4opt-0.1.0/CHANGES.rst
ADDED
m4opt-0.1.0/MANIFEST.in
ADDED
m4opt-0.1.0/PKG-INFO
ADDED
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
Metadata-Version: 2.2
|
|
2
|
+
Name: m4opt
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Multi-Mission Multi-Messenger Observation Planning Toolkit
|
|
5
|
+
Author-email: M4OPT Developers <leo.singer@ligo.org>
|
|
6
|
+
License: BSD-3-Clause
|
|
7
|
+
Project-URL: homepage, https://m4opt.readthedocs.io/
|
|
8
|
+
Project-URL: Bug Tracker, https://github.com/m4opt/m4opt/issues
|
|
9
|
+
Project-URL: Change Log, https://m4opt.readthedocs.io/en/latest/changes.html
|
|
10
|
+
Project-URL: Documentation, https://m4opt.readthedocs.io/
|
|
11
|
+
Project-URL: GitHub, https://github.com/m4opt/m4opt
|
|
12
|
+
Project-URL: Source Code, https://github.com/m4opt/m4opt
|
|
13
|
+
Classifier: Development Status :: 3 - Alpha
|
|
14
|
+
Classifier: Environment :: Console
|
|
15
|
+
Classifier: Intended Audience :: Science/Research
|
|
16
|
+
Classifier: License :: OSI Approved :: BSD License
|
|
17
|
+
Classifier: Operating System :: MacOS
|
|
18
|
+
Classifier: Operating System :: POSIX :: Linux
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
20
|
+
Classifier: Topic :: Scientific/Engineering :: Astronomy
|
|
21
|
+
Classifier: Typing :: Typed
|
|
22
|
+
Requires-Python: >=3.11
|
|
23
|
+
Description-Content-Type: text/x-rst
|
|
24
|
+
Requires-Dist: antiprism-python
|
|
25
|
+
Requires-Dist: astropy>=7.0.0
|
|
26
|
+
Requires-Dist: astropy-healpix
|
|
27
|
+
Requires-Dist: cplex
|
|
28
|
+
Requires-Dist: docplex
|
|
29
|
+
Requires-Dist: dust-extinction
|
|
30
|
+
Requires-Dist: dustmaps
|
|
31
|
+
Requires-Dist: ligo.skymap>=2.2.0
|
|
32
|
+
Requires-Dist: numpy>=2.1.0
|
|
33
|
+
Requires-Dist: regions
|
|
34
|
+
Requires-Dist: satellitetle
|
|
35
|
+
Requires-Dist: scipy
|
|
36
|
+
Requires-Dist: sgp4
|
|
37
|
+
Requires-Dist: spiceypy
|
|
38
|
+
Requires-Dist: sympy
|
|
39
|
+
Requires-Dist: synphot
|
|
40
|
+
Requires-Dist: typer
|
|
41
|
+
Requires-Dist: typing_extensions; python_version < "3.12"
|
|
42
|
+
Requires-Dist: xdg-base-dirs
|
|
43
|
+
Provides-Extra: test
|
|
44
|
+
Requires-Dist: astroplan; extra == "test"
|
|
45
|
+
Requires-Dist: pytest-astropy; extra == "test"
|
|
46
|
+
Provides-Extra: docs
|
|
47
|
+
Requires-Dist: pysiaf; extra == "docs"
|
|
48
|
+
Requires-Dist: sphinx-astropy[confv2]; extra == "docs"
|
|
49
|
+
Requires-Dist: sphinxcontrib-typer; extra == "docs"
|
|
50
|
+
|
|
51
|
+
Multi-Mission Multi-Messenger Observation Planning Toolkit
|
|
52
|
+
----------------------------------------------------------
|
|
53
|
+
|
|
54
|
+
.. image:: http://img.shields.io/badge/powered%20by-AstroPy-orange.svg?style=flat
|
|
55
|
+
:target: http://www.astropy.org
|
|
56
|
+
:alt: Powered by Astropy Badge
|
|
57
|
+
.. image:: https://codecov.io/gh/m4opt/m4opt/branch/main/graph/badge.svg?token=L837JHNTUV
|
|
58
|
+
:target: https://codecov.io/gh/m4opt/m4opt
|
|
59
|
+
:alt: Code coverage status
|
|
60
|
+
.. image:: https://readthedocs.org/projects/m4opt/badge/?version=latest
|
|
61
|
+
:target: https://m4opt.readthedocs.io/en/latest/?badge=latest
|
|
62
|
+
:alt: Documentation Status
|
|
63
|
+
|
|
64
|
+
.. image:: docs/_static/example.gif
|
|
65
|
+
:alt: Visualization of an example observing plan for UVEX generated M4OPT
|
|
66
|
+
|
|
67
|
+
M4OPT is an open-source toolkit for multi-facility scheduling of astrophysics
|
|
68
|
+
observing campaigns. It focuses on extremely rapid follow-up of gravitational
|
|
69
|
+
wave (GW) and neutrino events with heterogeneous networks of space and
|
|
70
|
+
ground-based observatories.
|
|
71
|
+
|
|
72
|
+
M4OPT uses the versatile mathematical framework of `mixed integer
|
|
73
|
+
programming`__ to model and solve complex observation scheduling problems.
|
|
74
|
+
Although M4OPT is open source, for the largest problems it can leverage two
|
|
75
|
+
industrial-strength commercial MIP solvers: `CPLEX`__ or `Gurobi`__. Both
|
|
76
|
+
solvers are available for free for academic users.
|
|
77
|
+
|
|
78
|
+
__ https://en.wikipedia.org/wiki/Integer_programming
|
|
79
|
+
__ https://www.ibm.com/products/ilog-cplex-optimization-studio
|
|
80
|
+
__ https://www.gurobi.com
|
|
81
|
+
|
|
82
|
+
M4OPT is designed from the `Astropy affiliated package`__ template, and is
|
|
83
|
+
meant to follow those standards, including interoperability with the
|
|
84
|
+
`Astropy`__ ecosystem. It also complies with `NASA Procedural Requirements
|
|
85
|
+
(NPR) 7150`__ for `Class C software`__ and is suitable for non-safety-critical
|
|
86
|
+
ground software applications for `Class D NASA payloads`__.
|
|
87
|
+
|
|
88
|
+
__ https://www.astropy.org/affiliated/
|
|
89
|
+
__ https://www.astropy.org
|
|
90
|
+
__ https://nodis3.gsfc.nasa.gov/displayDir.cfm?t=NPR&c=7150&s=2C
|
|
91
|
+
__ https://nodis3.gsfc.nasa.gov/displayDir.cfm?Internal_ID=N_PR_7150_002C_&page_name=AppendixD
|
|
92
|
+
__ https://nodis3.gsfc.nasa.gov/displayDir.cfm?t=NPR&c=8705&s=4A
|
|
93
|
+
|
|
94
|
+
Features
|
|
95
|
+
--------
|
|
96
|
+
|
|
97
|
+
* **Global**: jointly and globally solves the problems of tiling (the set of
|
|
98
|
+
telescope boresight orientations and roll angles) and the scheduling (which
|
|
99
|
+
tile is observed at what time), rather than solving each sub-problem one at
|
|
100
|
+
a time
|
|
101
|
+
* **Optimal**: generally solves all the way to optimality, rather than
|
|
102
|
+
finding merely a "good enough" solution
|
|
103
|
+
* **Fast**: solve an entire orbit in about 5 minutes
|
|
104
|
+
* **General**: does not depend on heuristics of any kind
|
|
105
|
+
* **Flexible**: problem is formulated in the versatile framework of
|
|
106
|
+
`mixed integer programming <https://en.wikipedia.org/wiki/Integer_programming>`_
|
|
107
|
+
|
|
108
|
+
License
|
|
109
|
+
-------
|
|
110
|
+
|
|
111
|
+
This project is Copyright (c) M4OPT Developers and licensed under
|
|
112
|
+
the terms of the BSD 3-Clause license. This package is based upon
|
|
113
|
+
the `Astropy package template <https://github.com/astropy/package-template>`_
|
|
114
|
+
which is licensed under the BSD 3-clause license. See the licenses folder for
|
|
115
|
+
more information.
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
Contributing
|
|
119
|
+
------------
|
|
120
|
+
|
|
121
|
+
We love contributions! m4opt is open source,
|
|
122
|
+
built on open source, and we'd love to have you hang out in our community.
|
|
123
|
+
|
|
124
|
+
**Imposter syndrome disclaimer**: We want your help. No, really.
|
|
125
|
+
|
|
126
|
+
There may be a little voice inside your head that is telling you that you're not
|
|
127
|
+
ready to be an open source contributor; that your skills aren't nearly good
|
|
128
|
+
enough to contribute. What could you possibly offer a project like this one?
|
|
129
|
+
|
|
130
|
+
We assure you - the little voice in your head is wrong. If you can write code at
|
|
131
|
+
all, you can contribute code to open source. Contributing to open source
|
|
132
|
+
projects is a fantastic way to advance one's coding skills. Writing perfect code
|
|
133
|
+
isn't the measure of a good developer (that would disqualify all of us!); it's
|
|
134
|
+
trying to create something, making mistakes, and learning from those
|
|
135
|
+
mistakes. That's how we all improve, and we are happy to help others learn.
|
|
136
|
+
|
|
137
|
+
Being an open source contributor doesn't just mean writing code, either. You can
|
|
138
|
+
help out by writing documentation, tests, or even giving feedback about the
|
|
139
|
+
project (and yes - that includes giving feedback about the contribution
|
|
140
|
+
process). Some of these contributions may be the most valuable to the project as
|
|
141
|
+
a whole, because you're coming to the project with fresh eyes, so you can see
|
|
142
|
+
the errors and assumptions that seasoned contributors have glossed over.
|
|
143
|
+
|
|
144
|
+
Note: This disclaimer was originally written by
|
|
145
|
+
`Adrienne Lowe <https://github.com/adriennefriend>`_ for a
|
|
146
|
+
`PyCon talk <https://www.youtube.com/watch?v=6Uj746j9Heo>`_, and was adapted by
|
|
147
|
+
m4opt based on its use in the README file for the
|
|
148
|
+
`MetPy project <https://github.com/Unidata/MetPy>`_.
|
m4opt-0.1.0/README.rst
ADDED
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
Multi-Mission Multi-Messenger Observation Planning Toolkit
|
|
2
|
+
----------------------------------------------------------
|
|
3
|
+
|
|
4
|
+
.. image:: http://img.shields.io/badge/powered%20by-AstroPy-orange.svg?style=flat
|
|
5
|
+
:target: http://www.astropy.org
|
|
6
|
+
:alt: Powered by Astropy Badge
|
|
7
|
+
.. image:: https://codecov.io/gh/m4opt/m4opt/branch/main/graph/badge.svg?token=L837JHNTUV
|
|
8
|
+
:target: https://codecov.io/gh/m4opt/m4opt
|
|
9
|
+
:alt: Code coverage status
|
|
10
|
+
.. image:: https://readthedocs.org/projects/m4opt/badge/?version=latest
|
|
11
|
+
:target: https://m4opt.readthedocs.io/en/latest/?badge=latest
|
|
12
|
+
:alt: Documentation Status
|
|
13
|
+
|
|
14
|
+
.. image:: docs/_static/example.gif
|
|
15
|
+
:alt: Visualization of an example observing plan for UVEX generated M4OPT
|
|
16
|
+
|
|
17
|
+
M4OPT is an open-source toolkit for multi-facility scheduling of astrophysics
|
|
18
|
+
observing campaigns. It focuses on extremely rapid follow-up of gravitational
|
|
19
|
+
wave (GW) and neutrino events with heterogeneous networks of space and
|
|
20
|
+
ground-based observatories.
|
|
21
|
+
|
|
22
|
+
M4OPT uses the versatile mathematical framework of `mixed integer
|
|
23
|
+
programming`__ to model and solve complex observation scheduling problems.
|
|
24
|
+
Although M4OPT is open source, for the largest problems it can leverage two
|
|
25
|
+
industrial-strength commercial MIP solvers: `CPLEX`__ or `Gurobi`__. Both
|
|
26
|
+
solvers are available for free for academic users.
|
|
27
|
+
|
|
28
|
+
__ https://en.wikipedia.org/wiki/Integer_programming
|
|
29
|
+
__ https://www.ibm.com/products/ilog-cplex-optimization-studio
|
|
30
|
+
__ https://www.gurobi.com
|
|
31
|
+
|
|
32
|
+
M4OPT is designed from the `Astropy affiliated package`__ template, and is
|
|
33
|
+
meant to follow those standards, including interoperability with the
|
|
34
|
+
`Astropy`__ ecosystem. It also complies with `NASA Procedural Requirements
|
|
35
|
+
(NPR) 7150`__ for `Class C software`__ and is suitable for non-safety-critical
|
|
36
|
+
ground software applications for `Class D NASA payloads`__.
|
|
37
|
+
|
|
38
|
+
__ https://www.astropy.org/affiliated/
|
|
39
|
+
__ https://www.astropy.org
|
|
40
|
+
__ https://nodis3.gsfc.nasa.gov/displayDir.cfm?t=NPR&c=7150&s=2C
|
|
41
|
+
__ https://nodis3.gsfc.nasa.gov/displayDir.cfm?Internal_ID=N_PR_7150_002C_&page_name=AppendixD
|
|
42
|
+
__ https://nodis3.gsfc.nasa.gov/displayDir.cfm?t=NPR&c=8705&s=4A
|
|
43
|
+
|
|
44
|
+
Features
|
|
45
|
+
--------
|
|
46
|
+
|
|
47
|
+
* **Global**: jointly and globally solves the problems of tiling (the set of
|
|
48
|
+
telescope boresight orientations and roll angles) and the scheduling (which
|
|
49
|
+
tile is observed at what time), rather than solving each sub-problem one at
|
|
50
|
+
a time
|
|
51
|
+
* **Optimal**: generally solves all the way to optimality, rather than
|
|
52
|
+
finding merely a "good enough" solution
|
|
53
|
+
* **Fast**: solve an entire orbit in about 5 minutes
|
|
54
|
+
* **General**: does not depend on heuristics of any kind
|
|
55
|
+
* **Flexible**: problem is formulated in the versatile framework of
|
|
56
|
+
`mixed integer programming <https://en.wikipedia.org/wiki/Integer_programming>`_
|
|
57
|
+
|
|
58
|
+
License
|
|
59
|
+
-------
|
|
60
|
+
|
|
61
|
+
This project is Copyright (c) M4OPT Developers and licensed under
|
|
62
|
+
the terms of the BSD 3-Clause license. This package is based upon
|
|
63
|
+
the `Astropy package template <https://github.com/astropy/package-template>`_
|
|
64
|
+
which is licensed under the BSD 3-clause license. See the licenses folder for
|
|
65
|
+
more information.
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
Contributing
|
|
69
|
+
------------
|
|
70
|
+
|
|
71
|
+
We love contributions! m4opt is open source,
|
|
72
|
+
built on open source, and we'd love to have you hang out in our community.
|
|
73
|
+
|
|
74
|
+
**Imposter syndrome disclaimer**: We want your help. No, really.
|
|
75
|
+
|
|
76
|
+
There may be a little voice inside your head that is telling you that you're not
|
|
77
|
+
ready to be an open source contributor; that your skills aren't nearly good
|
|
78
|
+
enough to contribute. What could you possibly offer a project like this one?
|
|
79
|
+
|
|
80
|
+
We assure you - the little voice in your head is wrong. If you can write code at
|
|
81
|
+
all, you can contribute code to open source. Contributing to open source
|
|
82
|
+
projects is a fantastic way to advance one's coding skills. Writing perfect code
|
|
83
|
+
isn't the measure of a good developer (that would disqualify all of us!); it's
|
|
84
|
+
trying to create something, making mistakes, and learning from those
|
|
85
|
+
mistakes. That's how we all improve, and we are happy to help others learn.
|
|
86
|
+
|
|
87
|
+
Being an open source contributor doesn't just mean writing code, either. You can
|
|
88
|
+
help out by writing documentation, tests, or even giving feedback about the
|
|
89
|
+
project (and yes - that includes giving feedback about the contribution
|
|
90
|
+
process). Some of these contributions may be the most valuable to the project as
|
|
91
|
+
a whole, because you're coming to the project with fresh eyes, so you can see
|
|
92
|
+
the errors and assumptions that seasoned contributors have glossed over.
|
|
93
|
+
|
|
94
|
+
Note: This disclaimer was originally written by
|
|
95
|
+
`Adrienne Lowe <https://github.com/adriennefriend>`_ for a
|
|
96
|
+
`PyCon talk <https://www.youtube.com/watch?v=6Uj746j9Heo>`_, and was adapted by
|
|
97
|
+
m4opt based on its use in the README file for the
|
|
98
|
+
`MetPy project <https://github.com/Unidata/MetPy>`_.
|