Spacecraft Pixel footprint Projection
Project description
SPiP : Spacecraft Pixel footprint Projection
Projection of the pixel footprint from an instrument onboard an orbital spacecraft on a planetary surface.
Installation & Update
Method 1: from PyPI (recommended)
Installation: pip3 install planetary-spip
Update: pip3 install planetary-spip --upgrade
Method 2: from the GitHub repository (development version)
Installation: Clone the repository and install with pip:
git clone https://github.com/NAU-PIXEL/spip.git
cd spip
pip3 install .
Update: Go to the previously cloned repository, pull the last updates, and install them with pip:
cd spip
git pull
pip3 install .
Usage
# Package importation
import spip
import numpy as np
# Genaration of a longitude/latitude grid to project the footprint
lon_array = np.arange(0.25, 360, 0.5) # 0° -> 360°, 2 points per degree
lat_array = np.arange(-89.75, 90, 0.5) # -90° -> 90°, 2 points per degree
lon_grid, lat_grid = np.meshgrid(lon_array, lat_array)
# Pixel parameters
lon_px, lat_px = 58.2, 79.3 # Longitude/Latitude of the pixel center [deg]
emer = 61.7 # Emergence angle of the pixel on the surface [deg]
lon_subsc, lat_subsc = 28.0, 24.9 # Longitude/Latitude sub-spacecraft [deg]
d_Mars_sc = 27212 # Distance aeroid-spacraft [km]
Rmars = spip.emm_emirs.Rmars # 3390 [km]
ifov = spip.emm_emirs.ifov_emirs # 2.7e-3 [rad]
# Generation of the mask map of the pixel footprint
#-- EMM/EMIRS spacecraft
mask_footprint = spip.emm_emirs.emirs_ifov_px_projection(
lon_grid,
lat_grid,
lon_px,
lat_px,
emer,
lon_subsc,
lat_subsc,
d_Mars_sc,
Rmars,
ifov
)
# To easily handle multiple pixels, there is the spip.emm_emirs.emirs_ifov_multi_px_projection() function.
#-- General case, cirular pixel
a, b, θ = spip.circular_pixels.params_ellipse_fov(
lon_px,
lat_px,
emer,
lon_subsc,
lat_subsc,
d_Mars_sc,
ifov
)
mask_footprint = spip.circular_pixels.in_ellipse_spherical(
lon_grid,
lat_grid,
Rmars,
a,
b,
lon_px,
lat_px,
θ
) * 1.
# > mask_footprint
# For each point of the longitude/latitude grid:
# | 1 -> Within the pixel footprint ellipse.
# | 0 -> Outside.
Documentation
Planetary Data Workshop 2023: abstract & poster
Credits
© Aurélien Stcherbinine (2023) NAU-PIXEL
Department of Astronomy and Planetary Science, Northern Arizona University, Flagstaff, AZ, USA
License
This package is released under a MIT open source license. See LICENSE
for more details.
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 planetary-spip-1.2.tar.gz
.
File metadata
- Download URL: planetary-spip-1.2.tar.gz
- Upload date:
- Size: 7.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | dd5f17095c9a3d831470d442cc89a837fb21f8777bf63d90841d427e97de5987 |
|
MD5 | 2c08a8c76bfef67f1a16a3e01238175d |
|
BLAKE2b-256 | d561742955989bffb2314ed8be411b2c66de01bae452dd19ec99fce0711fe715 |
File details
Details for the file planetary_spip-1.2-py3-none-any.whl
.
File metadata
- Download URL: planetary_spip-1.2-py3-none-any.whl
- Upload date:
- Size: 8.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ea18e1daf781fd736a0cb20337f0a22014c1d775e628addde9554a2879b9ade3 |
|
MD5 | 28ff508e021fe9146db3a1b507d6c874 |
|
BLAKE2b-256 | 1ed62ef2830eb844db8726c169b0438fccfd934d5dd299bd12351cd9fd9324ff |