Everything we've got
Project description
almanac
almanac scrapes headers from raw image files and cross-matches those against the SDSS database to create a comprehensive summary of everything ever observed with an APOGEE instrument.
Getting Started
Here are a few example cases of how almanac might be helpful:
List all exposures taken yesterday from either telescope:
almanac --mjd -1 -vv
Or just from Apache Point Observatory:
almanac --mjd -1 -vv --apo
Write out all exposures taken in the last month to january.h5:
almanac -o january.h5 --mjd-start -30
Write out all fiber observations during 2021, where we switched from plates to robotic fiber positioners:
almanac -vv --date-start 2021-01-01 --date-end 2021-31-12 --fibers
And it looks pretty, even when it warns you about missing exposures:
Installation
At Utah
If you want to use this at Utah, you can install it with:
module load almanac
[!TIP] We recommend you manage your own Python environment, but if you don't have one set up at Utah then you can use
module load miniconda/3.8.5_astra.
Anywhere else
almanac needs local disk access to raw APOGEE data frames. If you are going to run it somewhere else, you should set up a Globus transfer of raw APOGEE frames, and ensure your internet address is whitelisted to remotely access the SDSS database.
We recommend using uv to manage Python environments. Using uv, you can install almanac with:
uv add sdss-almanac
Usage
Use almanac to see details on data taken today from both observatories, or specify the observatory:
almanac
almanac --apo # Apache Point Observatory
almanac --lco # Las Campanas Observatory
Specifying a date
If you want a particular day, either use the --mjd or --date (UTC) flags:
almanac --mjd 59300
almanac --date 2021-01-01
You can use negative MJD values to indicate days relative to today:
almanac --mjd -1 # Yesterday
almanac --mjd -7 # Last week
You can also specify a range of days:
almanac --mjd-start 59300 --mjd-end 59310 # Give me these 10 days
almanac --date-start 2021-01-01 --date-end 2021-01-31 # Give me all of January 2021
Fiber mappings
You can also use almanac to see the fiber mappings for a given plate (SDSS-IV) or FPS pointing (SDSS-V) by specifing the --fibers (or --fibres) flag. This will give you the mapping of fibers to targets, and the target properties.
almanac --mjd 60000 --fibres
The fiber mapping tables are cross-matched to the SDSS database to include the SDSS identifiers for each target. If you don't want to do this cross-match, you can use the --no-x-match flag. The --no-x-match flag is ignored if --fibers is not used.
Verbosity
By default there is minimal output to the terminal. You can adjust the verbosity level using -v:
-v: show progress display only-vv: show progress display and exposure metadata
In verbose mode you can see exposure information in the terminal, and additional per-fiber metadata is stored in the HDF5 files that almanac creates.
Outputs
You can write the outputs to a structured HDF5 file by specifying an output path with the --output (or -O) flag. If the output path already exists, the default behaviour is to overwrite existing entries only. So if you run almanac once for MJD 60000 and output to a file, and then run it again for MJD 60001 and output to the same file, your file will have data for both MJDs.
almanac --output /path/to/file.h5 # Append today's data to existing file
An example structure of the HDF5 file is below:
apo/59300/exposures # a data table of exposures
apo/59300/sequences # a Nx2 array of exposure numbers (inclusive) that form a sequence
apo/59300/fibers/fps/1 # a data table of fiber mappings for FPS configuration id 1
apo/59300/fibers/plates/2 # a data table of fiber mappings for plate id 2
Configuration
You can view and change the almanac configuration settings through the almanac config interface. To view all current settings and to see the configuration file path:
almanac config show
To get a single configuration value
almanac config get logging_level
To set a configuration value
almanac config set logging_level 10
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sdss_almanac-0.2.5.tar.gz.
File metadata
- Download URL: sdss_almanac-0.2.5.tar.gz
- Upload date:
- Size: 39.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
96dfa4030db095419ce75c5113cac8136d46075b17f5c6f758579ee0cf382d55
|
|
| MD5 |
a140d8265421bc39838a488041ca8be7
|
|
| BLAKE2b-256 |
df072b863c62de385ed71f2323627a7c584f5f9734141ac47037d8d355fc9407
|
Provenance
The following attestation bundles were made for sdss_almanac-0.2.5.tar.gz:
Publisher:
publish.yml on sdss/almanac
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
sdss_almanac-0.2.5.tar.gz -
Subject digest:
96dfa4030db095419ce75c5113cac8136d46075b17f5c6f758579ee0cf382d55 - Sigstore transparency entry: 582900437
- Sigstore integration time:
-
Permalink:
sdss/almanac@24e42474d706fb43e90149b5cde764ee0a991966 -
Branch / Tag:
refs/tags/v0.2.5 - Owner: https://github.com/sdss
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@24e42474d706fb43e90149b5cde764ee0a991966 -
Trigger Event:
push
-
Statement type:
File details
Details for the file sdss_almanac-0.2.5-py3-none-any.whl.
File metadata
- Download URL: sdss_almanac-0.2.5-py3-none-any.whl
- Upload date:
- Size: 41.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6fd22ff5600fc56fb7a64e4df7542f8b92d4616765a09b0acd23ed1b68b6fe49
|
|
| MD5 |
afec92d8938c325aa348f8a7efd253af
|
|
| BLAKE2b-256 |
99456539c7287542e7494c264c8297cf862bf4a171151cb44c8748b5a9ae26c7
|
Provenance
The following attestation bundles were made for sdss_almanac-0.2.5-py3-none-any.whl:
Publisher:
publish.yml on sdss/almanac
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
sdss_almanac-0.2.5-py3-none-any.whl -
Subject digest:
6fd22ff5600fc56fb7a64e4df7542f8b92d4616765a09b0acd23ed1b68b6fe49 - Sigstore transparency entry: 582900441
- Sigstore integration time:
-
Permalink:
sdss/almanac@24e42474d706fb43e90149b5cde764ee0a991966 -
Branch / Tag:
refs/tags/v0.2.5 - Owner: https://github.com/sdss
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@24e42474d706fb43e90149b5cde764ee0a991966 -
Trigger Event:
push
-
Statement type: