Index: trunk/ppImage/src/ppImageParseCamera.c
===================================================================
--- trunk/ppImage/src/ppImageParseCamera.c	(revision 20647)
+++ trunk/ppImage/src/ppImageParseCamera.c	(revision 21364)
@@ -20,6 +20,6 @@
     }
 
-    // if MASK or WEIGHT was supplied on command line, bind files to 'input'.
-    // the mask and weight will be mosaicked with the image
+    // if MASK or VARIANCE was supplied on command line, bind files to 'input'.
+    // the mask and variance will be mosaicked with the image
     pmFPAfile *inputMask = pmFPAfileBindFromArgs(&status, input, config, "PPIMAGE.INPUT.MASK", "PPIMAGE.INPUT.MASK");
     if (!status) {
@@ -34,11 +34,11 @@
     }
 
-    pmFPAfile *inputWeight = pmFPAfileBindFromArgs(&status, input, config, "PPIMAGE.INPUT.WEIGHT", "PPIMAGE.INPUT.WEIGHT");
+    pmFPAfile *inputVariance = pmFPAfileBindFromArgs(&status, input, config, "PPIMAGE.INPUT.VARIANCE", "PPIMAGE.INPUT.VARIANCE");
     if (!status) {
         psError (PS_ERR_UNKNOWN, false, "failed to load find definition");
         return NULL;
     }
-    if (inputWeight && inputWeight->type != PM_FPA_FILE_WEIGHT) {
-        psError(PS_ERR_IO, true, "PPIMAGE.INPUT.WEIGHT is not of type WEIGHT");
+    if (inputVariance && inputVariance->type != PM_FPA_FILE_VARIANCE) {
+        psError(PS_ERR_IO, true, "PPIMAGE.INPUT.VARIANCE is not of type VARIANCE");
         return NULL;
     }
@@ -195,12 +195,12 @@
         return NULL;
     }
-    pmFPAfile *outWeight = pmFPAfileDefineOutput(config, input->fpa, "PPIMAGE.OUTPUT.WEIGHT");
-    if (!outWeight) {
-        psError(PS_ERR_IO, false, _("Unable to generate output file from PPIMAGE.OUTPUT.WEIGHT"));
-        psFree(options);
-        return NULL;
-    }
-    if (outWeight->type != PM_FPA_FILE_WEIGHT) {
-        psError(PS_ERR_IO, true, "PPIMAGE.OUTPUT.WEIGHT is not of type WEIGHT");
+    pmFPAfile *outVariance = pmFPAfileDefineOutput(config, input->fpa, "PPIMAGE.OUTPUT.VARIANCE");
+    if (!outVariance) {
+        psError(PS_ERR_IO, false, _("Unable to generate output file from PPIMAGE.OUTPUT.VARIANCE"));
+        psFree(options);
+        return NULL;
+    }
+    if (outVariance->type != PM_FPA_FILE_VARIANCE) {
+        psError(PS_ERR_IO, true, "PPIMAGE.OUTPUT.VARIANCE is not of type VARIANCE");
         psFree(options);
         return NULL;
@@ -230,12 +230,12 @@
         return NULL;
     }
-    pmFPAfile *chipWeight = pmFPAfileDefineOutput(config, chipImage->fpa, "PPIMAGE.CHIP.WEIGHT");
-    if (!chipWeight) {
-        psError(PS_ERR_IO, false, _("Unable to generate output file from PPIMAGE.CHIP.WEIGHT"));
-        psFree(options);
-        return NULL;
-    }
-    if (chipWeight->type != PM_FPA_FILE_WEIGHT) {
-        psError(PS_ERR_IO, true, "PPIMAGE.CHIP.WEIGHT is not of type WEIGHT");
+    pmFPAfile *chipVariance = pmFPAfileDefineOutput(config, chipImage->fpa, "PPIMAGE.CHIP.VARIANCE");
+    if (!chipVariance) {
+        psError(PS_ERR_IO, false, _("Unable to generate output file from PPIMAGE.CHIP.VARIANCE"));
+        psFree(options);
+        return NULL;
+    }
+    if (chipVariance->type != PM_FPA_FILE_VARIANCE) {
+        psError(PS_ERR_IO, true, "PPIMAGE.CHIP.VARIANCE is not of type VARIANCE");
         psFree(options);
         return NULL;
@@ -315,9 +315,9 @@
     outImage->save   = options->BaseFITS;
     outMask->save    = options->BaseMaskFITS;
-    outWeight->save  = options->BaseWeightFITS;
+    outVariance->save  = options->BaseVarianceFITS;
 
     chipImage->save  = options->ChipFITS;
     chipMask->save   = options->ChipMaskFITS;
-    chipWeight->save = options->ChipWeightFITS;
+    chipVariance->save = options->ChipVarianceFITS;
 
     byFPA1->save     = options->FPA1FITS;
@@ -329,15 +329,15 @@
     outImage->fileLevel = PS_MIN (outImage->fileLevel, outImage->dataLevel);
 
-    // outMask and outWeight must be freed at the same level as outImage (all freed by pmFPAFreeData)
+    // outMask and outVariance must be freed at the same level as outImage (all freed by pmFPAFreeData)
     outMask->freeLevel   = outImage->freeLevel;
-    outWeight->freeLevel = outImage->freeLevel;
+    outVariance->freeLevel = outImage->freeLevel;
     outMask->dataLevel   = outImage->dataLevel;
-    outWeight->dataLevel = outImage->dataLevel;
+    outVariance->dataLevel = outImage->dataLevel;
 
     // Ditto for the chip-mosaicked version
     chipMask->freeLevel   = chipImage->freeLevel;
-    chipWeight->freeLevel = chipImage->freeLevel;
+    chipVariance->freeLevel = chipImage->freeLevel;
     chipMask->dataLevel   = chipImage->dataLevel;
-    chipWeight->dataLevel = chipImage->dataLevel;
+    chipVariance->dataLevel = chipImage->dataLevel;
 
     // the input data is the same as the outImage data : force the free levels to match
@@ -434,12 +434,12 @@
     }
 
-    // Turn off mask and weight output if we're not doing anything interesting
+    // Turn off mask and variance output if we're not doing anything interesting
     if (!options->doMaskBuild && outMask->save) {
         psWarning("output mask image (BASE.MASK.FITS) requested, but not generated: skipping.\n");
         outMask->save = false;
     }
-    if (!options->doWeightBuild && outWeight->save) {
-        psWarning("output weight image (BASE.WEIGHT.FITS) requested, but not generated: skipping.\n");
-        outWeight->save = false;
+    if (!options->doVarianceBuild && outVariance->save) {
+        psWarning("output variance image (BASE.VARIANCE.FITS) requested, but not generated: skipping.\n");
+        outVariance->save = false;
     }
     if (!options->doMaskBuild && chipMask->save) {
@@ -447,7 +447,7 @@
         chipMask->save = false;
     }
-    if (!options->doWeightBuild && chipWeight->save) {
-        psWarning("output weight image (CHIP.WEIGHT.FITS) requested, but not generated: skipping.\n");
-        chipWeight->save = false;
+    if (!options->doVarianceBuild && chipVariance->save) {
+        psWarning("output variance image (CHIP.VARIANCE.FITS) requested, but not generated: skipping.\n");
+        chipVariance->save = false;
     }
 
