IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 40083


Ignore:
Timestamp:
Jul 5, 2017, 5:31:17 PM (9 years ago)
Author:
eugene
Message:

add some extra visualizations

Location:
trunk/psModules/src/astrom
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/psModules/src/astrom/pmAstrometryObjects.c

    r39926 r40083  
    11111111    }
    11121112
     1113    pmAstromVisualPlotTweak (xHist, yHist, xBin, yBin);
     1114
    11131115    // smooth histgram vector with gaussian of 1sigma = radius
    11141116    psVector *xHistNew = psVectorSmooth(NULL, xHist, tweakSmooth, tweakNsigma);
  • trunk/psModules/src/astrom/pmAstrometryVisual.c

    r36834 r40083  
    10451045    if (!plotTweak) return true;
    10461046    if (!pmVisualTestLevel("psastro.plot13", 1)) return true;
    1047     if (!pmVisualInitWindow(&kapa1, "psastro:plots")) return false;
     1047    if (!pmVisualInitWindow(&kapa3, "psastro:plots")) return false;
    10481048
    10491049    Graphdata graphdata;
     
    10661066
    10671067    // set up plot information
    1068     KapaClearPlots(kapa1);
     1068    KapaClearPlots(kapa3);
    10691069    KapaInitGraph(&graphdata);
    10701070
    10711071    // plot the X histogram
    10721072    pmVisualScaleGraphdata(&graphdata, xIndices, xHist, false);
    1073     KapaSetSection(kapa1, &section1);
    1074     KapaSetLimits (kapa1, &graphdata);
    1075     KapaSetFont(kapa1, "helvetica", 14);
    1076     KapaBox(kapa1, &graphdata);
    1077     KapaSendLabel (kapa1, "X offset Bin", KAPA_LABEL_XM);
    1078     KapaSendLabel (kapa1, "Number of Sources", KAPA_LABEL_YM);
    1079     KapaSendLabel (kapa1, "Horizontal Profile",
     1073    KapaSetSection(kapa3, &section1);
     1074    KapaSetLimits (kapa3, &graphdata);
     1075    KapaSetFont(kapa3, "helvetica", 14);
     1076    KapaBox(kapa3, &graphdata);
     1077    KapaSendLabel (kapa3, "X offset Bin", KAPA_LABEL_XM);
     1078    KapaSendLabel (kapa3, "Number of Sources", KAPA_LABEL_YM);
     1079    KapaSendLabel (kapa3, "Horizontal Profile",
    10801080                   KAPA_LABEL_XP);
    10811081    graphdata.style = 1;
     
    10841084    graphdata.color = KapaColorByName ("black");
    10851085
    1086     KapaPrepPlot (kapa1, xHist->n, &graphdata);
    1087     KapaPlotVector (kapa1, xHist->n, xIndices->data.F32, "x");
    1088     KapaPlotVector (kapa1, xHist->n, xHist->data.F32, "y");
     1086    KapaPrepPlot (kapa3, xHist->n, &graphdata);
     1087    KapaPlotVector (kapa3, xHist->n, xIndices->data.F32, "x");
     1088    KapaPlotVector (kapa3, xHist->n, xHist->data.F32, "y");
    10891089
    10901090    // overplot the peak
     
    10921092    float y[2] = {-500, 500};
    10931093    graphdata.color = KapaColorByName ("red");
    1094     KapaPrepPlot (kapa1, 2, &graphdata);
    1095     KapaPlotVector (kapa1, 2, x, "x");
    1096     KapaPlotVector (kapa1, 2, y, "y");
     1094    KapaPrepPlot (kapa3, 2, &graphdata);
     1095    KapaPlotVector (kapa3, 2, x, "x");
     1096    KapaPlotVector (kapa3, 2, y, "y");
    10971097
    10981098    // plot the Y histogram
    10991099    pmVisualScaleGraphdata(&graphdata, yIndices, yHist, false);
    1100     KapaSetSection(kapa1, &section2);
    1101     KapaSetLimits (kapa1, &graphdata);
    1102     KapaSetFont(kapa1, "helvetica", 14);
     1100    KapaSetSection(kapa3, &section2);
     1101    KapaSetLimits (kapa3, &graphdata);
     1102    KapaSetFont(kapa3, "helvetica", 14);
    11031103    graphdata.color = KapaColorByName ("black");
    1104     KapaBox(kapa1, &graphdata);
    1105     KapaSendLabel (kapa1, "Y offset Bin", KAPA_LABEL_XM);
    1106     KapaSendLabel (kapa1, "Number of Sources", KAPA_LABEL_YM);
    1107     KapaSendLabel (kapa1, "Vertical Profile",
     1104    KapaBox(kapa3, &graphdata);
     1105    KapaSendLabel (kapa3, "Y offset Bin", KAPA_LABEL_XM);
     1106    KapaSendLabel (kapa3, "Number of Sources", KAPA_LABEL_YM);
     1107    KapaSendLabel (kapa3, "Vertical Profile",
    11081108                   KAPA_LABEL_XP);
    11091109    graphdata.style = 1;
     
    11111111    graphdata.size = 0.4;
    11121112
    1113     KapaPrepPlot (kapa1, yHist->n, &graphdata);
    1114     KapaPlotVector (kapa1, yHist->n, yIndices->data.F32, "x");
    1115     KapaPlotVector (kapa1, yHist->n, yHist->data.F32, "y");
     1113    KapaPrepPlot (kapa3, yHist->n, &graphdata);
     1114    KapaPlotVector (kapa3, yHist->n, yIndices->data.F32, "x");
     1115    KapaPlotVector (kapa3, yHist->n, yHist->data.F32, "y");
    11161116
    11171117    // overplot the peak
    11181118    x[0] = x[1] = yBin;
    11191119    graphdata.color = KapaColorByName ("red");
    1120     KapaPrepPlot (kapa1, 2, &graphdata);
    1121     KapaPlotVector (kapa1, 2, x, "x");
    1122     KapaPlotVector (kapa1, 2, y, "y");
     1120    KapaPrepPlot (kapa3, 2, &graphdata);
     1121    KapaPlotVector (kapa3, 2, x, "x");
     1122    KapaPlotVector (kapa3, 2, y, "y");
    11231123
    11241124    // plot title
    11251125    graphdata.color = KapaColorByName("black");
    11261126
    1127     KapaSetSection( kapa1, &section3);
    1128     KapaSendLabel (kapa1, "Tweaking the Astrometry Grid Solution. Smoothed profiles + peak location",
     1127    KapaSetSection( kapa3, &section3);
     1128    KapaSendLabel (kapa3, "Tweaking the Astrometry Grid Solution. Smoothed profiles + peak location",
    11291129                   KAPA_LABEL_XP);
    11301130
  • trunk/psModules/src/astrom/pmAstrometryWCS.c

    r39981 r40083  
    695695    // the region defines the FPA pixels covered by the tranformation
    696696    psFree (fpa->fromTPA);
    697 
    698697    int additional_orders = 4;  // This is the number of orders that should be added.
    699698    bool status = false;
     
    704703   
    705704    psPlaneTransform *myPT = psPlaneTransformAlloc(fpa->toTPA->x->nX+additional_orders, fpa->toTPA->x->nY+additional_orders);
     705
    706706    fpa->fromTPA = psPlaneTransformInvert(myPT, fpa->toTPA, region, 50);
    707707    psFree (myPT);
Note: See TracChangeset for help on using the changeset viewer.