This notebook provide and a set of example of how to manipulate the Cassini VIMS data using the python pyvims
module.
To start this example your need to download some data.
Here we will start with a cube (1487096932_1
) calibrated with USGS-ISIS3 sofware and available on the vims.univ-nantes.fr data portal:
import os,wget
url = 'https://vims.univ-nantes.fr/data/isis'
flyby = 'T3'
image_id = '1487096932_1'
channel = 'ir'
f_cal = 'C' + image_id + '_' + channel + '.cub'
f_nav = 'N' + image_id + '_' + channel + '.cub'
if not os.path.isfile(f_cal):
wget.download(url + '/' + flyby + '/' + f_cal) # Calibrated cube (IR)
if not os.path.isfile(f_nav):
wget.download(url + '/' + flyby + '/' + f_nav) # Navigation cube (IR)
Import the VIMS
class from the pyvims
package
from pyvims import VIMS
cube = VIMS('1487096932_1')
print(repr(cube))
VIMS cube: 1487096932_1 [ISIS3]
# Acquisition start time (as `datetime` object)
print('Start: {}'.format(cube.start))
# Acquisition stop time (as `datetime` object)
print('Stop: {}'.format(cube.stop))
# Acquisition mid-time (as `datetime` object or `%Y-%m-%dT%H:%M:%S.%f` format)
print('Mid-Time: {} / {}'.format(cube.dtime,cube.time))
# Image year
print('Year: {}'.format(cube.year))
# Image day of the year
print('DOY: {}'.format(cube.doy))
# Image decimal year
print('Decimal year: {}'.format(cube.year_d))
# Image date (as `%Y/%m/%d` format)
print('Date: {}'.format(cube.date))
Start: 2005-02-14 18:02:29.023000 Stop: 2005-02-14 18:07:32.930000 Mid-Time: 2005-02-14 18:05:00.976500 / 2005-02-14T18:05:00.976500 Year: 2005 DOY: 45 Decimal year: 2005.12054795 Date: 2005/02/14