diff --git a/pyglance/glance/compare.py b/pyglance/glance/compare.py index 50235d40e730a3ac59bf5f52dbddb3ce09a20678..6c41c2e33d0cb6aba7951d51b10950664a592524 100644 --- a/pyglance/glance/compare.py +++ b/pyglance/glance/compare.py @@ -731,7 +731,7 @@ python -m glance.compare plotDiffs A.hdf B.hdf [optional output path] explanationName = name if (varRunInfo.has_key('alternate_name_in_B')) : explanationName = explanationName + " / " + varRunInfo['alternate_name_in_B'] - print('analyzing variable: ' + explanationName) + print('analyzing: ' + display_name + ' (' + explanationName + ')') # if B has an alternate variable name, figure that out has_alt_B_variable = False @@ -803,7 +803,7 @@ python -m glance.compare plotDiffs A.hdf B.hdf [optional output path] didPass = didPass and passedNonFinite varRunInfo['did_pass'] = didPass - print ('generating report for: ' + displayName) + print ('\tgenerating report for: ' + displayName) report.generate_and_save_variable_report(files, varRunInfo, runInfo, variableStats, diff --git a/pyglance/glance/delta.py b/pyglance/glance/delta.py index a38ab5c2e27124c3a12dbec93420f0d1bc10a339..fa314299345bdf8be226f61ca78dd96b1cd07e2a 100644 --- a/pyglance/glance/delta.py +++ b/pyglance/glance/delta.py @@ -308,9 +308,9 @@ STATISTICS_DOC = { 'general': "Finite values are non-missing and finite (not Na 'num_data_points': "number of data values in A", 'shape': "shape of A", 'spatially_invalid_pts_ignored_in_a': 'number of points with invalid latitude/longitude information in A that were' + - ' ignored for the purposes for data analysis and presentation', + ' ignored for the purposes of data analysis and presentation', 'spatially_invalid_pts_ignored_in_b': 'number of points with invalid latitude/longitude information in B that were' + - ' ignored for the purposes for data analysis and presentation', + ' ignored for the purposes of data analysis and presentation', 'trouble_points_count': 'number of points that are nonfinite or missing in either input data set (A or B),' + ' or are unacceptable when compared (according to the current epsilon value)', 'trouble_points_fraction': 'fraction of points that are nonfinite or missing in either input data set (A or B),' + diff --git a/pyglance/glance/plot.py b/pyglance/glance/plot.py index 3c81aff9ffb046074cf50a763175b563426ea4e2..254e2788fce1f1f7b41572d77888cf69a024adfc 100644 --- a/pyglance/glance/plot.py +++ b/pyglance/glance/plot.py @@ -378,7 +378,7 @@ def plot_and_save_figure_comparison(aData, bData, if 'display_name' in variableRunInfo : variableDisplayName = variableRunInfo['display_name'] - print("Creating figures for: " + variableDisplayName) + print("\tCreating figures for: " + variableDisplayName) # compare the two data sets to get our difference data and trouble info rawDiffData, goodMask, troubleMask, (aNotFiniteMask, bNotFiniteMask), \ @@ -405,33 +405,33 @@ def plot_and_save_figure_comparison(aData, bData, LOG.debug ("visible axes in Both: " + str(visibleAxesBoth)) # make the original data figures - print("\tcreating image of file a") + print("\t\tcreating image of file a") figureA = _create_mapped_figure(aData, latitudeAData, longitudeAData, visibleAxesA, (variableDisplayName + "\nin File A"), invalidMask=(spaciallyInvalidMaskA | invalidDataMaskA)) - print("\tcreating image of file b") + print("\t\tcreating image of file b") figureB = _create_mapped_figure(bData, latitudeBData, longitudeBData, visibleAxesB, (variableDisplayName + "\nin File B"), invalidMask=(spaciallyInvalidMaskB | invalidDataMaskB)) # make the data comparison figures if not shortCircuitComparisons : - print("\tcreating image of the absolute value of difference") + print("\t\tcreating image of the absolute value of difference") figureAbsDiff = _create_mapped_figure(diffData, latitudeCommonData, longitudeCommonData, visibleAxesBoth, ("Absolute value of difference in\n" + variableDisplayName), invalidMask=(everyThingWrongButEpsilon)) - print("\tcreating image of the difference") + print("\t\tcreating image of the difference") figureDiff = _create_mapped_figure(rawDiffData, latitudeCommonData, longitudeCommonData, visibleAxesBoth, ("Value of (Data File B - Data File A) for\n" + variableDisplayName), invalidMask=(everyThingWrongButEpsilon)) # this figure is more complex because we want to mark the trouble points on it - print("\tcreating image marking trouble data") + print("\t\tcreating image marking trouble data") figureBadDataInDiff = _create_mapped_figure(bData, latitudeCommonData, longitudeCommonData, visibleAxesBoth, ("Areas of trouble data in\n" + variableDisplayName), spaciallyInvalidMaskBoth | invalidDataMaskB, mediumGrayColorMap, troubleMask) # a histogram of the values of fileA - file B so that the distribution of error is visible (hopefully) - print("\tcreating histogram of the amount of difference") + print("\t\tcreating histogram of the amount of difference") numBinsToUse = 50 diffHistogramFigure = _create_histogram(rawDiffData[~everyThingWrongButEpsilon].ravel(), numBinsToUse, ("Difference in\n" + variableDisplayName), @@ -439,33 +439,33 @@ def plot_and_save_figure_comparison(aData, bData, ('Number of Data Points with a Given Difference'), True) # scatter plot of file a and b comparison - print("\tcreating scatter plot of file a values vs file b values") + print("\t\tcreating scatter plot of file a values vs file b values") diffScatterPlot = _create_scatter_plot(aData[~everyThingWrongButEpsilon].ravel(), bData[~everyThingWrongButEpsilon].ravel(), "Value in File A vs Value in File B", "File A Value", "File B Value", tooDifferentMask[~everyThingWrongButEpsilon].ravel(), variableRunInfo['epsilon']) # save the figures to disk variableName = variableRunInfo['variable_name'] - print("Saving figures for: " + variableDisplayName) - print("\tsaving image of file a") + print("\tSaving figures for: " + variableDisplayName) + print("\t\tsaving image of file a") figureA.savefig(outputPath + "/" + variableName + ".A.png", dpi=200) - print("\tsaving image of file b") + print("\t\tsaving image of file b") figureB.savefig(outputPath + "/" + variableName + ".B.png", dpi=200) if not shortCircuitComparisons : - print("\tsaving image of the absolute value of difference") + print("\t\tsaving image of the absolute value of difference") figureAbsDiff.savefig(outputPath + "/" + variableName + ".AbsDiff.png", dpi=200) - print("\tsaving image of the difference") + print("\t\tsaving image of the difference") figureDiff.savefig(outputPath + "/" + variableName + ".Diff.png", dpi=200) - print("\tsaving image marking trouble data") + print("\t\tsaving image marking trouble data") figureBadDataInDiff.savefig(outputPath + "/" + variableName + ".Trouble.png", dpi=200) - print("\tsaving histogram of the amount of difference") + print("\t\tsaving histogram of the amount of difference") diffHistogramFigure.savefig(outputPath + "/" + variableName + ".Hist.png", dpi=200) - print("\tsaving scatter plot of file a values vs file b values") + print("\t\tsaving scatter plot of file a values vs file b values") diffScatterPlot.savefig(outputPath + "/" + variableName + ".Scatter.png", dpi=200) # also save smaller versions of the figures if the parameter says the caller wants us to if (makeSmall) : - print("\tsaving smaller versions of images") + print("\t\tsaving smaller versions of images") figureA.savefig(outputPath + "/" + variableName + ".A.small.png", dpi=50) figureB.savefig(outputPath + "/" + variableName + ".B.small.png", dpi=50) if not shortCircuitComparisons :