Skip to content
Snippets Groups Projects
Commit a4dc78c9 authored by Lauren Adoram-Kershner's avatar Lauren Adoram-Kershner Committed by GitHub
Browse files

shifting apriori line/sample during read in/write out (#145)

* shifting apriori line/sample during read in/write out

* making apriori values optional
parent 03d046cd
No related branches found
No related tags found
No related merge requests found
...@@ -208,6 +208,9 @@ class IsisStore(object): ...@@ -208,6 +208,9 @@ class IsisStore(object):
# Convert the (0.5, 0.5) origin pixels back to (0,0) pixels # Convert the (0.5, 0.5) origin pixels back to (0,0) pixels
df['line'] -= 0.5 df['line'] -= 0.5
df['sample'] -= 0.5 df['sample'] -= 0.5
if 'aprioriline' in df.columns:
df['aprioriline'] -= 0.5
df['apriorisample'] -= 0.5
df.header = pvl_header df.header = pvl_header
return df return df
...@@ -295,6 +298,9 @@ class IsisStore(object): ...@@ -295,6 +298,9 @@ class IsisStore(object):
# ISIS pixels are centered on (0.5, 0.5). NDArrays are (0,0) based. # ISIS pixels are centered on (0.5, 0.5). NDArrays are (0,0) based.
measure_spec.sample = m['sample'] + 0.5 measure_spec.sample = m['sample'] + 0.5
measure_spec.line = m['line'] + 0.5 measure_spec.line = m['line'] + 0.5
if 'apriorisample' in g.columns:
measure_spec.apriorisample = m['apriorisample'] + 0.5
measure_spec.aprioriline = m['aprioriline'] + 0.5
measure_iterable.append(measure_spec) measure_iterable.append(measure_spec)
self.nmeasures += 1 self.nmeasures += 1
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment