Skip to content

Commit

Permalink
updated mapcam makefile (DOI-USGS#4498)
Browse files Browse the repository at this point in the history
  • Loading branch information
Kelvin Rodriguez authored and Kelvin committed Jun 10, 2021
1 parent f563524 commit eb44b2e
Showing 1 changed file with 23 additions and 29 deletions.
52 changes: 23 additions & 29 deletions isis/src/osirisrex/tsts/mapcam/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,12 @@ commands:
ocams2isis $(TSTARGS) \
from=$(INPUT)/20190303T100344S990_map_iofL2pan_V001.fits \
to=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-spiceinit.cub \
>& /dev/null;
> /dev/null;

# spiceinit first image
spiceinit $(TSTARGS) \
from=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-spiceinit.cub \
ckpredict=t \
spkpredict=t \
ckrecon=f \
spkrecon=f \
SCLK='$$osirisrex/kernels/sclk/SCLK.tsc' \
extra='$$osirisrex/kernels/pck/bennu_v10.tpc' \
>& /dev/null;
> /dev/null;

# phocube first image
# create 7 band backplane with from the following values:
Expand All @@ -42,21 +36,21 @@ commands:
emission=t \
incidence=t \
pixelres=t \
>& /dev/null;
> /dev/null;

# explode first image's backplane into 5 cubes
explode $(TSTARGS) \
from=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-bp.cub \
to=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-bp-explode \
>& /dev/null;
> /dev/null;

# reunite exploded cubes. output should be identical to phocube bp output above
$(LS) $(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-bp-explode* \
> $(OUTPUT)/phocubeBandList.txt;
cubeit $(TSTARGS) \
from=$(OUTPUT)/phocubeBandList.txt \
to=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-bp.cub \
>& /dev/null;
> /dev/null;

# for each pixel in first image, multiply by 2 then add 1
algebra $(TSTARGS) \
Expand All @@ -65,20 +59,20 @@ commands:
operator=unary \
a=2 \
a=1 \
>& /dev/null;
> /dev/null;

# (SKIP) get camera information for first image
# caminfo fails for this image using the testIsis code provided by team
caminfo $(TSTARGS) \
#caminfo $(TSTARGS) \
from=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-spiceinit.cub \
to=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-caminfo.pvl \
>& /dev/null;
> /dev/null;

# get camera statistics for first image
camstats $(TSTARGS) \
from=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-spiceinit.cub \
to=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-camstats.pvl \
>& /dev/null;
> /dev/null;

# get DN statistics for first image
stats $(TSTARGS) \
Expand All @@ -92,7 +86,7 @@ commands:
to=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-photrim.cub \
minphase=100 \
maxphase=101 \
>& /dev/null;
> /dev/null;

# photomet first image
photomet $(TSTARGS) \
Expand All @@ -107,13 +101,13 @@ commands:
albedo=1.0 \
maxemission=80 \
maxincidenc=85 \
>& /dev/null;
> /dev/null;

# (SKIP) footprint first image
# footprintinit fails for this image using the testIsis code provided by team
footprintinit $(TSTARGS) \
from=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-spiceinit.cub \
>& /dev/null;
> /dev/null;


# campt 4 corners and center of first image
Expand All @@ -124,35 +118,35 @@ commands:
SAMPLE=350 \
LINE=1 \
ALLOWOUTSIDE=no \
>& /dev/null;
> /dev/null;
campt $(TSTARGS) \
from=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-spiceinit.cub \
to=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001_campt_upperright.pvl \
SAMPLE=1024 \
LINE=1 \
ALLOWOUTSIDE=no \
>& /dev/null;
> /dev/null;
campt $(TSTARGS) \
from=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-spiceinit.cub \
to=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001_campt_lowerright.pvl \
SAMPLE=1024 \
LINE=1024 \
SAMPLE=890 \
LINE=615 \
ALLOWOUTSIDE=no \
>& /dev/null;
> /dev/null;
campt $(TSTARGS) \
from=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-spiceinit.cub \
to=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001_campt_lowerleft.pvl \
SAMPLE=350 \
LINE=1024 \
SAMPLE=256 \
LINE=750 \
ALLOWOUTSIDE=no \
>& /dev/null;
> /dev/null;
campt $(TSTARGS) \
from=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-spiceinit.cub \
to=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001_campt_imagecenter.pvl \
SAMPLE=512 \
LINE=512 \
ALLOWOUTSIDE=no \
>& /dev/null;
> /dev/null;

# get mapping group containing Equirectangular mosaic range values for the two images
$(LS) $(OUTPUT)/*spiceinit.cub > $(OUTPUT)/unprojectedSpiceinitCubeList.txt;
Expand All @@ -161,15 +155,15 @@ commands:
to=$(OUTPUT)/MCAM_equi.map \
precision=6 \
projection=Equirectangular \
>& /dev/null;
> /dev/null;

# project the two images using the map from mosrange
cam2map $(TSTARGS) \
from=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-spiceinit.cub \
to=$(OUTPUT)/20190303T100344S990_map_iofL2pan_V001-cam2map_equi.cub \
map=$(OUTPUT)/MCAM_equi.map \
pixres=map \
>& /dev/null;
> /dev/null;

# getsn from each image
echo -e "\nOutput of getsn..." > $(OUTPUT)/MCAM_getsn.txt;
Expand Down

0 comments on commit eb44b2e

Please sign in to comment.