Skip to content
Snippets Groups Projects
Commit c09aaebf authored by Kristin's avatar Kristin Committed by Jesse Mapel
Browse files

Update format of range conversion coefficients isd (#354)

* Update format of range conversion coefficients isd output to include a separate list for times. Also update driver, test data, and remove unneeded semicolons

* Fix documentaion error

* fix other documentation error
parent 382819ff
Branches
Tags
No related merge requests found
......@@ -194,3 +194,14 @@ class Radar():
"""
raise NotImplementedError
@property
def range_conversion_times(self):
"""
Returns the times associated with the range conversion coefficients
Returns
-------
: list
Times for the range conversion coefficients
"""
raise NotImplementedError
......@@ -563,7 +563,7 @@ class LroMiniRfIsisLabelNaifSpiceDriver(Radar, NaifSpice, IsisLabel, Driver):
: double
scaled pixel width
"""
return self.label['IsisCube']['Instrument']['LineExposureDuration'];
return self.label['IsisCube']['Instrument']['LineExposureDuration']
@property
def range_conversion_coefficients(self):
......@@ -576,10 +576,27 @@ class LroMiniRfIsisLabelNaifSpiceDriver(Radar, NaifSpice, IsisLabel, Driver):
range conversion coefficients
"""
range_coefficients_utc = self.label['IsisCube']['Instrument']['RangeCoefficientSet'];
range_coefficients_et = [[spice.str2et(elt[0])] + elt[1:] for elt in range_coefficients_utc]
range_coefficients_orig = self.label['IsisCube']['Instrument']['RangeCoefficientSet']
# The first elt of each list is time, which we handle separately in range_conversion_time
range_coefficients = [elt[1:] for elt in range_coefficients_orig]
return range_coefficients
@property
def range_conversion_times(self):
"""
Times, in et, associated with range conversion coefficients
Returns
-------
: List
times for range conversion coefficients
"""
range_coefficients_utc = self.label['IsisCube']['Instrument']['RangeCoefficientSet']
range_coefficients_et = [spice.str2et(elt[0]) for elt in range_coefficients_utc]
return range_coefficients_et
@property
def ephemeris_start_time(self):
"""
......
......@@ -161,6 +161,7 @@ def to_usgscsm(driver):
isd_data['wavelength'] = driver.wavelength
isd_data['line_exposure_duration'] = driver.line_exposure_duration
isd_data['scaled_pixel_width'] = driver.scaled_pixel_width
isd_data['range_conversion_times'] = driver.range_conversion_times
isd_data['range_conversion_coefficients'] = driver.range_conversion_coefficients
# check that there is a valid sensor model name
......
......@@ -10129,27 +10129,33 @@
"wavelength": 0.12596322416750805,
"line_exposure_duration": 0.004704421474,
"scaled_pixel_width": 7.5,
"range_conversion_times": [ 3.25441417470548e+08, 3.25441439850548e+08, 3.25441454898548e+08,
3.25441469946548e+08, 3.25441484995548e+08, 3.25441500043548e+08, 3.25441515091548e+08,
3.25441530140548e+08, 3.25441545188548e+08, 3.25441560236548e+08, 3.25441575284548e+08,
3.25441590333548e+08, 3.25441605381548e+08, 3.25441620429548e+08, 3.25441635477548e+08,
3.25441650526548e+08, 3.25441665574548e+08, 3.25441680622548e+08, 3.25441695670548e+08,
3.25441718039548e+08],
"range_conversion_coefficients": [
[ 3.25441417470548e+08, 7.99423808710000e+04, 6.92122900000000e-01, 3.40193700000000e-06, -2.39924200000000e-11],
[ 3.25441439850548e+08, 7.99423795700000e+04, 6.90795300000000e-01, 3.41377900000000e-06, -2.40431400000000e-11],
[ 3.25441454898548e+08, 7.99423784790000e+04, 6.89923300000000e-01, 3.42142300000000e-06, -2.40714100000000e-11],
[ 3.25441469946548e+08, 7.99423782970000e+04, 6.89091700000000e-01, 3.42877300000000e-06, -2.41021200000000e-11],
[ 3.25441484995548e+08, 7.99423774910000e+04, 6.88258400000000e-01, 3.43615000000000e-06, -2.41318800000000e-11],
[ 3.25441500043548e+08, 7.99423754720000e+04, 6.87466400000000e-01, 3.44310000000000e-06, -2.41596100000000e-11],
[ 3.25441515091548e+08, 7.99423758230000e+04, 6.86672900000000e-01, 3.45009800000000e-06, -2.41882400000000e-11],
[ 3.25441530140548e+08, 7.99423758680000e+04, 6.85920500000000e-01, 3.45672500000000e-06, -2.42163000000000e-11],
[ 3.25441545188548e+08, 7.99423737430000e+04, 6.85166800000000e-01, 3.46335100000000e-06, -2.42427900000000e-11],
[ 3.25441560236548e+08, 7.99423758150000e+04, 6.84453800000000e-01, 3.46968000000000e-06, -2.42686600000000e-11],
[ 3.25441575284548e+08, 7.99423733480000e+04, 6.83783000000000e-01, 3.47554900000000e-06, -2.42912800000000e-11],
[ 3.25441590333548e+08, 7.99423731540000e+04, 6.83111300000000e-01, 3.48141500000000e-06, -2.43158100000000e-11],
[ 3.25441605381548e+08, 7.99423745960000e+04, 6.82480900000000e-01, 3.48693900000000e-06, -2.43373700000000e-11],
[ 3.25441620429548e+08, 7.99423723580000e+04, 6.81849000000000e-01, 3.49252600000000e-06, -2.43599300000000e-11],
[ 3.25441635477548e+08, 7.99423734150000e+04, 6.81259600000000e-01, 3.49765400000000e-06, -2.43799400000000e-11],
[ 3.25441650526548e+08, 7.99423726230000e+04, 6.80711700000000e-01, 3.50247300000000e-06, -2.43988600000000e-11],
[ 3.25441665574548e+08, 7.99423708550000e+04, 6.80163500000000e-01, 3.50722300000000e-06, -2.44181200000000e-11],
[ 3.25441680622548e+08, 7.99423717720000e+04, 6.79614100000000e-01, 3.51201600000000e-06, -2.44370400000000e-11],
[ 3.25441695670548e+08, 7.99423706730000e+04, 6.79149600000000e-01, 3.51607500000000e-06, -2.44520600000000e-11],
[ 3.25441718039548e+08, 7.99423710670000e+04, 6.78430200000000e-01, 3.52233100000000e-06, -2.44771700000000e-11]
[7.99423808710000e+04, 6.92122900000000e-01, 3.40193700000000e-06, -2.39924200000000e-11],
[7.99423795700000e+04, 6.90795300000000e-01, 3.41377900000000e-06, -2.40431400000000e-11],
[7.99423784790000e+04, 6.89923300000000e-01, 3.42142300000000e-06, -2.40714100000000e-11],
[7.99423782970000e+04, 6.89091700000000e-01, 3.42877300000000e-06, -2.41021200000000e-11],
[7.99423774910000e+04, 6.88258400000000e-01, 3.43615000000000e-06, -2.41318800000000e-11],
[7.99423754720000e+04, 6.87466400000000e-01, 3.44310000000000e-06, -2.41596100000000e-11],
[7.99423758230000e+04, 6.86672900000000e-01, 3.45009800000000e-06, -2.41882400000000e-11],
[7.99423758680000e+04, 6.85920500000000e-01, 3.45672500000000e-06, -2.42163000000000e-11],
[7.99423737430000e+04, 6.85166800000000e-01, 3.46335100000000e-06, -2.42427900000000e-11],
[7.99423758150000e+04, 6.84453800000000e-01, 3.46968000000000e-06, -2.42686600000000e-11],
[7.99423733480000e+04, 6.83783000000000e-01, 3.47554900000000e-06, -2.42912800000000e-11],
[7.99423731540000e+04, 6.83111300000000e-01, 3.48141500000000e-06, -2.43158100000000e-11],
[7.99423745960000e+04, 6.82480900000000e-01, 3.48693900000000e-06, -2.43373700000000e-11],
[7.99423723580000e+04, 6.81849000000000e-01, 3.49252600000000e-06, -2.43599300000000e-11],
[7.99423734150000e+04, 6.81259600000000e-01, 3.49765400000000e-06, -2.43799400000000e-11],
[7.99423726230000e+04, 6.80711700000000e-01, 3.50247300000000e-06, -2.43988600000000e-11],
[7.99423708550000e+04, 6.80163500000000e-01, 3.50722300000000e-06, -2.44181200000000e-11],
[7.99423717720000e+04, 6.79614100000000e-01, 3.51201600000000e-06, -2.44370400000000e-11],
[7.99423706730000e+04, 6.79149600000000e-01, 3.51607500000000e-06, -2.44520600000000e-11],
[7.99423710670000e+04, 6.78430200000000e-01, 3.52233100000000e-06, -2.44771700000000e-11]
],
"dt_ephemeris": 0.3013815733766745
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment