-
Notifications
You must be signed in to change notification settings - Fork 169
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix ckwriter failing test - update to use fixed kernels aside from th…
…e sclks (#3350) * Update date and other metadata * ckwriter_test_fix * Fix unintentional cmakelists change
- Loading branch information
1 parent
ca0ce60
commit 6dcd2fc
Showing
1 changed file
with
57 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,69 @@ | ||
APPNAME = ckwriter | ||
BASES = $(basename $(notdir $(wildcard $(INPUT)/*.cub))) | ||
|
||
|
||
include $(ISISROOT)/make/isismake.tsts | ||
|
||
.PHONY: commands | ||
commands: | ||
# Steup and create output CK from ckwriter | ||
$(CP) $(INPUT)/*.cub $(OUTPUT) | ||
ls -1 $(OUTPUT)/*.cub > $(OUTPUT)/files.lis; | ||
|
||
# It is necessary to spiceinit the input cubes fixing all the kernels except for the sclks. | ||
# All but the last 10 sclks are cleaned up from the kernels area, and a changing sclk | ||
# is unlikely to affect the resulting position / pointing (unlike the other kernels, which | ||
# are fixed for the purposes of this test.) | ||
spiceinit from=$(OUTPUT)/M103189611LE.cub \ | ||
ls='$$base/kernels/lsk/naif0012.tls' \ | ||
pck='($$base/kernels/pck/pck00009.tpc,$$lro/kernels/pck/moon_080317.tf,$$lro/kernels/pck/moon_assoc_me.tf)' \ | ||
tspk='($$lro/kernels/tspk/moon_pa_de421_1900-2050.bpc,$$lro/kernels/tspk/de421.bsp)' \ | ||
ik='$$lro/kernels/ik/lro_lroc_v18.ti' \ | ||
ck='($$lro/kernels/ck/lrolc_2009181_2009213_v10.bc, $$lro/kernels/ck/moc42r_2009181_2009213_v14.bc)' \ | ||
spk='$$lro/kernels/spk/fdf29r_2009182_2009213_v01.bsp' \ | ||
fk='$$lro/kernels/fk/lro_frames_2014049_v01.tf' \ | ||
iak='$$lro/kernels/iak/lro_instrumentAddendum_v04.ti' \ | ||
shape=user \ | ||
model='$$base/dems/ldem_128ppd_Mar2011_clon180_radius_pad.cub' > /dev/null; | ||
|
||
spiceinit from=$(OUTPUT)/M136241759RE.cub | ||
ls='$$base/kernels/lsk/naif0012.tls' \ | ||
pck='($$base/kernels/pck/pck00009.tpc,$$lro/kernels/pck/moon_080317.tf,$$lro/kernels/pck/moon_assoc_me.tf)' \ | ||
tspk='($$lro/kernels/tspk/moon_pa_de421_1900-2050.bpc,$$lro/kernels/tspk/de421.bsp)' \ | ||
ik='$$lro/kernels/ik/lro_lroc_v18.ti' \ | ||
ck='($$lro/kernels/ck/lrolc_2010212_2010244_v03.bc,$$lro/kernels/ck/moc42r_2010212_2010244_v04.bc)' \ | ||
spk='$$lro/kernels/spk/fdf29r_2010213_2010244_v50.bsp' \ | ||
fk='$$lro/kernels/fk/lro_frames_2014049_v01.tf' \ | ||
iak='$$lro/kernels/iak/lro_instrumentAddendum_v04.ti' \ | ||
shape=user \ | ||
model='$$base/dems/ldem_128ppd_Mar2011_clon180_radius_pad.cub' > /dev/null; | ||
|
||
$(APPNAME) FROMLIST=$(OUTPUT)/files.lis TO=$(OUTPUT)/lroc.bc > /dev/null; | ||
$(RM) $(OUTPUT)/files.lis | ||
|
||
commands: $(BASES) | ||
$(RM) $(OUTPUT)/lrock.bc | ||
# Only use 12 digits in the output of tabledump due to precision issues | ||
# do for each cube | ||
getkey from=$(OUTPUT)/M136241759RE.cub objnam=isiscube grpname=Kernels keyword=InstrumentPointing keyindex=2 > $(OUTPUT)/extra.ck; | ||
spiceinit from=$(OUTPUT)/M136241759RE.cub ck=$(OUTPUT)/lroc.bc \ | ||
extra=`cat $(OUTPUT)/extra.ck` > /dev/null; | ||
tabledump from=$(OUTPUT)/M136241759RE.cub to=$(OUTPUT)/M136241759RE.dat \ | ||
name=InstrumentPointing > /dev/null; | ||
cat $(OUTPUT)/M136241759RE.dat \ | ||
| sed 's/\([0-9][0-9]*\.[0-9]\{12\}\)\([0-9][0-9]*\)/\1/g' \ | ||
> $(OUTPUT)/M136241759RE.txt; | ||
|
||
# Only use 12 digits in the output of tabledump due to precision issues | ||
$(BASES): $(OUTPUT)/lrock.bc | ||
$(CP) $(INPUT)/$@.cub $(OUTPUT) | ||
$(RM) $(OUTPUT)/extra.ck | ||
getkey from=$(INPUT)/$@.cub objnam=isiscube grpname=Kernels keyword=InstrumentPointing keyindex=2 > $(OUTPUT)/extra.ck; | ||
spiceinit from=$(OUTPUT)/$@.cub ck=$(OUTPUT)/lrock.bc extra=`cat $(OUTPUT)/extra.ck` > /dev/null; | ||
tabledump from=$(OUTPUT)/$@.cub to=$(OUTPUT)/$@.dat \ | ||
getkey from=$(OUTPUT)/M103189611LE.cub objnam=isiscube grpname=Kernels keyword=InstrumentPointing keyindex=2 > $(OUTPUT)/extra.ck; | ||
spiceinit from=$(OUTPUT)/M103189611LE.cub ck=$(OUTPUT)/lroc.bc \ | ||
extra=`cat $(OUTPUT)/extra.ck` > /dev/null; | ||
tabledump from=$(OUTPUT)/M103189611LE.cub to=$(OUTPUT)/M103189611LE.dat \ | ||
name=InstrumentPointing > /dev/null; | ||
cat $(OUTPUT)/$@.dat \ | ||
cat $(OUTPUT)/M103189611LE.dat \ | ||
| sed 's/\([0-9][0-9]*\.[0-9]\{12\}\)\([0-9][0-9]*\)/\1/g' \ | ||
> $(OUTPUT)/$@.txt; | ||
$(RM) $(OUTPUT)/$@.cub | ||
$(RM) $(OUTPUT)/$@.dat | ||
$(RM) $(OUTPUT)/extra.ck | ||
> $(OUTPUT)/M103189611LE.txt; | ||
|
||
ck: $(OUTPUT)/lrock.bc | ||
$(RM) $(OUTPUT)/M103189611LE.dat; | ||
$(RM) $(OUTPUT)/M103189611LE.cub; | ||
$(RM) $(OUTPUT)/M136241759RE.dat; | ||
$(RM) $(OUTPUT)/M136241759RE.cub; | ||
$(RM) $(OUTPUT)/lroc.bc; | ||
$(RM) $(OUTPUT)/extra.ck; | ||
|
||
$(OUTPUT)/lrock.bc: | ||
mkdir -p $(OUTPUT); | ||
ls -1 $(INPUT)/*.cub > $(OUTPUT)/files.lis; | ||
$(APPNAME) FROMLIST=$(OUTPUT)/files.lis TO=$@ > /dev/null; | ||
$(RM) $(OUTPUT)/files.lis | ||
|
||
|