A sunpy plugin for accessing data in the Solar Orbiter Archive (SOAR).
Project description
sunpy-soar
A sunpy plugin for accessing data in the Solar Orbiter Archive (SOAR).
When interacting with the sunpy-soar project you are asked to follow the SunPy Code of Conduct .
Installation
sunpy-soar requires python >= 3.7 and sunpy >= 2.1. Currently it can only be installed from PyPI using:
pip install sunpy-soar
or conda using
conda install -c conda-forge sunpy-soar
Example usage
The code below gives an example of how to search and download Solar Orbiter data using sunpy.net.Fido:
# Importing sunpy_soar registers the client with sunpy
import sunpy_soar
from sunpy.net import Fido
import sunpy.net.attrs as a
# Create search attributes
instrument = a.Instrument('EUI')
time = a.Time('2021-02-01', '2021-02-02')
level = a.Level(1)
product = a.soar.Product('EUI-FSI174-IMAGE')
# Do search
result = Fido.search(instrument & time & level & product)
print(result)
# Download files
files = Fido.fetch(result)
print(files)
Available search attributes
The easiest way to access search attributes is using import sunpy.net.attrs as a. When constructing a search for SOAR a.Time must be provided. Other search attributes can be used too - sunpy-soar recognises the following:
a.Instrument
a.Level - one of L0, L1, L2, L3, LL01, LL02, LL03
a.soar.Product
The third near argument to a.Time is not currently supported - you will have to manually filter the results if you want to find the one closest to a given time.
sunpy-soar and the VSO
sunpy-soar queries the official repository of Solar Orbiter data, the SOAR. The Virtual Solar Observatory (VSO) as of writing (September 2022) mirrors a subset of the Solar Orbiter archive alongside many other solar physics data sources. The VSO allows data from multiple missions/observatories to be easily queried in one go, but users should be aware that the VSO is not the official repository for Solar Orbiter data and does not currently (as of September 2022) provide a comprehensive listing of all available Solar Orbiter data.
Development
The SunPy developers maintain this package. Contributions for new features and bug fixes are welcome.
Changelog
1.6
Registered a list of instruments available from the SOAR, with the a.Instrument attribute.
Registered the SOAR in the a.Provider attribute, meaning that a user can specifiy to the Fido search to only query the SOAR by use of a.Provider.soar.
The _can_handle_query function within the SOARClient now checks to make sure if the SOAR supplies the queried data which fixes a bug which searched the SOAR for any data (e.g. AIA data).
1.5
Registered a list of valid data product identifiers with the a.soar.Product attribute. To see these use print(a.soar.Product).
1.4
Added support for searching for and fetching low latency data.
1.3
Added support for path string interpolation, which allows you to do (for example) Fido.fetch(query, path=tmp_path / '{instrument}') and the name of the intrument will be used in the save path. This works for all supported Fido attrs.
1.2
The Identifier attribute is deprecated - use Product instead, which is a direct replacement (with a better name!).
Allow time-only searches to be made.
Registered the Product attribute in the sunpy.net.attrs.soar namespace. After running import sunpy.net.attrs as a, the attribute can now be accessed using a.soar.Product.
The "Filesize" column in returned results now has units of astropy.units.Mbyte (previously it had no units).
Removed a validation check on a.Level. If an level that SOAR doesn’t understand is passed, zero results will now be returned instead of an error being raised.
1.1
Fixed download of data where multiple versions of the requested file are available. Only the most recent version will be downloaded.
Added some log messages to the sunpy logger at DEBUG level
1.0
First stable sunpy-soar release.
Fixed searches where there are no results.
Added filesize to the result table
Raise an error if the SOAR server can’t be reached
1.0b1
First sunpy-soar release.
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
File details
Details for the file sunpy-soar-1.6.2.tar.gz
.
File metadata
- Download URL: sunpy-soar-1.6.2.tar.gz
- Upload date:
- Size: 15.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | fda90912eef854805f766f8b4d81ade48be49781b3c11a313777060e2adce324 |
|
MD5 | 8a1a15e476be9373810f13d20c9ada3e |
|
BLAKE2b-256 | f775d56f371029d3bbbe7190abc2d67856ee6096d1b03931400079b55a2f96e1 |
File details
Details for the file sunpy_soar-1.6.2-py3-none-any.whl
.
File metadata
- Download URL: sunpy_soar-1.6.2-py3-none-any.whl
- Upload date:
- Size: 12.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0a821f1a8b8e7b0326777b65224d51b43ee59ce89a31e3e75f3147d5acf7721b |
|
MD5 | 06b50c8d1dbe362c8227dcf709895864 |
|
BLAKE2b-256 | a3282c54401a94b1ea997ad9677124fe9863814964bb438265dbadd5e3fcea9c |