IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 18025


Ignore:
Timestamp:
Jun 9, 2008, 12:10:17 PM (18 years ago)
Author:
Paul Price
Message:

Only average concepts for chip if they exist!

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ppMerge/src/ppMergeLoop.c

    r17424 r18025  
    306306            }
    307307        }
    308         psList *inChips = psListAlloc(NULL);
    309         for (int i=0; i < numFiles; i++) {
    310             pmChip *chip = pmFPAviewThisChip(view, ((pmFPAfile *)inputs->data[i])->fpa);
    311             psListAdd(inChips, PS_LIST_TAIL, chip);
    312         }
    313         if (!pmConceptsAverageChips(outChip, inChips, true)) {
    314             psError(PS_ERR_UNKNOWN, false, "Unable to average Chip concepts.");
     308
     309        if (outChip->data_exists) {
     310            psList *inChips = psListAlloc(NULL);
     311            for (int i=0; i < numFiles; i++) {
     312                pmChip *chip = pmFPAviewThisChip(view, ((pmFPAfile *)inputs->data[i])->fpa);
     313                psListAdd(inChips, PS_LIST_TAIL, chip);
     314            }
     315            if (!pmConceptsAverageChips(outChip, inChips, true)) {
     316                psError(PS_ERR_UNKNOWN, false, "Unable to average Chip concepts.");
     317                psFree(inChips);
     318                goto ERROR;
     319            }
    315320            psFree(inChips);
    316             goto ERROR;
    317         }
    318         psFree(inChips);
     321        }
    319322        if (!pmFPAfileIOChecks(config, view, PM_FPA_AFTER)) {
    320323            goto ERROR;
Note: See TracChangeset for help on using the changeset viewer.