Permalink
Browse files

dg_mosaic: Support for single entry TLC

  • Loading branch information...
Zack Moratto
Zack Moratto committed Feb 21, 2013
1 parent e9e050b commit ddd7554680039edbb4c7d6b102935a3644d84831
Showing with 6 additions and 0 deletions.
  1. +6 −0 src/asp/Tools/dg_mosaic.py.in
@@ -63,6 +63,12 @@ def read_tlc( filename ):
for tlc_item in IMAGE.find("TLCLISTList").findall("TLCLIST"):
tokens = tlc_item.text.strip().split(' ')
tlclist.append([float(tokens[0]), float(tokens[1])])
+ if len(tlclist) == 1:
+ direction = 1.0
+ if IMAGE.find("SCANDIRECTION").text.lower() != "forward":
+ direction = -1.0
+ linerate = float(IMAGE.find("AVGLINERATE").text)
+ tlclist.append([(linerate+tlclist[0][0]), (tlclist[0][1]+direction)])
firstlinetime = datetime.strptime(IMAGE.find("FIRSTLINETIME").text,
"%Y-%m-%dT%H:%M:%S.%fZ")
image_size = []

0 comments on commit ddd7554

Please sign in to comment.