The current method for adjusting the sensitivity of the tests is to change the PDF_DENSITY variable in gregorio-test.rc. However, in looking at gregorio-project/gregorio#1412 I came some information which may indicate that this is not the best way to adjust the sensitivity of the tests:
Using gabc-output/glyphs/broken-shapes as the trial case (with the old, and wrong expectation), I get the following results from the compare test at various settings for PDF_DENSITY:
This shows that while in general increasing the PDF_DENSITY will result in a lower (i.e. closer to failure) result, not all increases in its value are created equal (the change from 600 to 900 barely moves the metric while the change from 150 to 300 is almost 20 times larger) and some are even counter-productive (the change from 1500 to 1800 goes away from failure, not towards it).
Now, since PDF_DENSITY also affects the speed of the tests (compare takes much longer at the higher values) I do not think we should eliminate this parameter, but instead should look at a way to adjust the comparison that controls pass/fail determination more directly and in a user settable way. I need to do some more research, but my first results seem to indicate that using bc for the test would allow one to compare $metric to $THRESHOLD as floating point (instead of using the current coercion which allows bash's integer comparison operator to do the job), thereby making it easy to set $THRESHOLD in gregorio-test.rc
The current method for adjusting the sensitivity of the tests is to change the
PDF_DENSITY
variable ingregorio-test.rc
. However, in looking at gregorio-project/gregorio#1412 I came some information which may indicate that this is not the best way to adjust the sensitivity of the tests:Using
gabc-output/glyphs/broken-shapes
as the trial case (with the old, and wrong expectation), I get the following results from thecompare
test at various settings forPDF_DENSITY
:This shows that while in general increasing the
PDF_DENSITY
will result in a lower (i.e. closer to failure) result, not all increases in its value are created equal (the change from 600 to 900 barely moves the metric while the change from 150 to 300 is almost 20 times larger) and some are even counter-productive (the change from 1500 to 1800 goes away from failure, not towards it).Now, since
PDF_DENSITY
also affects the speed of the tests (compare
takes much longer at the higher values) I do not think we should eliminate this parameter, but instead should look at a way to adjust the comparison that controls pass/fail determination more directly and in a user settable way. I need to do some more research, but my first results seem to indicate that usingbc
for the test would allow one to compare$metric
to$THRESHOLD
as floating point (instead of using the current coercion which allowsbash
's integer comparison operator to do the job), thereby making it easy to set$THRESHOLD
ingregorio-test.rc