1. Test Modules
  2. Differential Validation
    1. Feedback Validation
    2. Learning Validation
    3. Total Accuracy
    4. Frozen and Alive Status
  3. Results

Target Description: The type Mean sq loss layer.

Report Description: The type Basic.

Subreport: Logs for com.simiacryptus.ref.lang.ReferenceCountingBase

Test Modules

Using Seed 4657136400314649600

Differential Validation

SingleDerivativeTester.java:153 executed in 0.01 seconds (0.000 gc):

        log.info(RefString.format("Inputs: %s", prettyPrint(inputPrototype)));
        log.info(RefString.format("Inputs Statistics: %s", printStats(inputPrototype)));
        log.info(RefString.format("Output: %s", outputPrototype.prettyPrint()));
        assert outputPrototype != null;
        log.info(RefString.format("Outputs Statistics: %s", outputPrototype.getScalarStatistics()));
      },
      outputPrototype.addRef(),
      RefUtil.addRef(inputPrototype)));
Logging
Inputs: [
[ [ 0.08 ], [ 1.208 ], [ 1.108 ], [ 1.032 ], [ 1.612 ], [ 1.552 ], [ -0.804 ], [ -1.832 ] ],
[ [ 0.7 ], [ -1.72 ], [ 0.028 ], [ 0.3 ], [ 1.64 ], [ 1.876 ], [ 0.148 ], [ 1.368 ] ],
[ [ -0.128 ], [ -1.028 ], [ -0.712 ], [ 0.636 ], [ 0.392 ], [ -0.408 ], [ -0.032 ], [ -1.54 ] ],
[ [ 0.496 ], [ -0.384 ], [ 1.048 ], [ -0.176 ], [ 0.092 ], [ -0.384 ], [ -0.892 ], [ -0.876 ] ],
[ [ -0.608 ], [ -0.852 ], [ -1.616 ], [ 1.556 ], [ -0.556 ], [ -1.572 ], [ 1.62 ], [ 1.652 ] ],
[ [ 1.764 ], [ 1.912 ], [ 1.356 ], [ 0.788 ], [ -1.476 ], [ -1.516 ], [ -1.856 ], [ -1.424 ] ],
[ [ 0.048 ], [ -1.688 ], [ 1.512 ], [ -0.768 ], [ 1.704 ], [ -0.636 ], [ 0.996 ], [ -0.464 ] ],
[ [ 1.524 ], [ -0.804 ], [ 1.556 ], [ -0.068 ], [ -1.228 ], [ -1.492 ], [ 0.048 ], [ -0.012 ] ]
],
[
[ [ -0.472 ], [ -0.316 ], [ -1.552 ], [ -1.484 ], [ -1.248 ], [ 0.56 ], [ -0.312 ], [ 0.812 ] ],
[ [ -0.504 ], [ 1.156 ], [ 0.016 ], [ 1.352 ], [ 1.324 ], [ -1.656 ], [ -0.968 ], [ -1.808 ] ],
[ [ -1.156 ], [ 0.972 ], [ 1.288 ], [ -0.888 ], [ 0.344 ], [ -0.856 ], [ -0.892 ], [ 0.644 ] ],
[ [ 0.184 ], [ -1.116 ], [ 1.628 ], [ -1.256 ], [ -1.34 ], [ -1.16 ], [ -0.808 ], [ 0.66 ] ],
[ [ 1.98 ], [ 0.52 ], [ -1.564 ], [ 1.916 ], [ 1.776 ], [ 0.688 ], [ -1.1 ], [ -1.76 ] ],
[ [ -0.628 ], [ -1.456 ], [ -1.764 ], [ -1.724 ], [ 0.52 ], [ -0.124 ], [ -0.968 ], [ 0.82 ] ],
[ [ -0.368 ], [ -2.0 ], [ 0.692 ], [ -1.664 ], [ 1.444 ], [ -1.176 ], [ -0.784 ], [ 1.24 ] ],
[ [ -1.16 ], [ 1.42 ], [ 1.628 ], [ 0.82 ], [ 1.956 ], [ -1.256 ], [ 0.012 ], [ -1.58 ] ]
]
Inputs Statistics: {meanExponent=-0.1923523558471011, negative=32, min=-1.856, max=1.912, mean=0.059375000000000025, count=64, sum=3.8000000000000016, positive=32, stdDev=1.1518728703181615, zeros=0},
{meanExponent=-0.06999649029273047, negative=36, min=-2.0, max=1.98, mean=-0.19524999999999998, count=64, sum=-12.495999999999999, positive=28, stdDev=1.186466998066107, zeros=0}
Output: [ 3.2553054999999995 ]
Outputs Statistics: {meanExponent=0.5125917519636185, negative=0, min=3.2553054999999995, max=3.2553054999999995, mean=3.2553054999999995, count=1, sum=3.2553054999999995, positive=1, stdDev=0.0, zeros=0}

Feedback Validation

We validate the agreement between the implemented derivative of the inputs apply finite difference estimations:

SingleDerivativeTester.java:169 executed in 0.07 seconds (0.000 gc):

        return testFeedback(
            statistics,
            component.addRef(),
            RefUtil.addRef(inputPrototype),
            outputPrototype.addRef());
      },
      outputPrototype.addRef(),
      RefUtil.addRef(inputPrototype),
      component.addRef()));
Logging
Feedback for input 0
Inputs Values: [
[ [ 0.08 ], [ 1.208 ], [ 1.108 ], [ 1.032 ], [ 1.612 ], [ 1.552 ], [ -0.804 ], [ -1.832 ] ],
[ [ 0.7 ], [ -1.72 ], [ 0.028 ], [ 0.3 ], [ 1.64 ], [ 1.876 ], [ 0.148 ], [ 1.368 ] ],
[ [ -0.128 ], [ -1.028 ], [ -0.712 ], [ 0.636 ], [ 0.392 ], [ -0.408 ], [ -0.032 ], [ -1.54 ] ],
[ [ 0.496 ], [ -0.384 ], [ 1.048 ], [ -0.176 ], [ 0.092 ], [ -0.384 ], [ -0.892 ], [ -0.876 ] ],
[ [ -0.608 ], [ -0.852 ], [ -1.616 ], [ 1.556 ], [ -0.556 ], [ -1.572 ], [ 1.62 ], [ 1.652 ] ],
[ [ 1.764 ], [ 1.912 ], [ 1.356 ], [ 0.788 ], [ -1.476 ], [ -1.516 ], [ -1.856 ], [ -1.424 ] ],
[ [ 0.048 ], [ -1.688 ], [ 1.512 ], [ -0.768 ], [ 1.704 ], [ -0.636 ], [ 0.996 ], [ -0.464 ] ],
[ [ 1.524 ], [ -0.804 ], [ 1.556 ], [ -0.068 ], [ -1.228 ], [ -1.492 ], [ 0.048 ], [ -0.012 ] ]
]
Value Statistics: {meanExponent=-0.1923523558471011, negative=32, min=-1.856, max=1.912, mean=0.059375000000000025, count=64, sum=3.8000000000000016, positive=32, stdDev=1.1518728703181615, zeros=0}
Implemented Feedback: [ [ 0.017249999999999998 ], [ 0.037625 ], [ 0.032125 ], [ 0.00975 ], [ -0.080875 ], [ 0.07475 ], [ 0.013 ], [ 0.083875 ], ... ]
Implemented Statistics: {meanExponent=-1.5341469852812004, negative=26, min=-0.0995, max=0.110375, mean=0.007957031249999998, count=64, sum=0.5092499999999999, positive=38, stdDev=0.055818410323389474, zeros=0}
Measured Feedback: [ [ 0.01725156249854365 ], [ 0.03762656249683971 ], [ 0.032126562494738664 ], [ 0.00975156249971576 ], [ -0.0808734375024045 ], [ 0.07475156249547865 ], [ 0.013001562493286656 ], [ 0.08387656249553288 ], ... ]
Measured Statistics: {meanExponent=-1.5341114309618213, negative=26, min=-0.09949843750689524, max=0.11037656249435202, mean=0.007958593747497966, count=64, sum=0.5093499998398698, positive=38, stdDev=0.05581841032305263, zeros=0}
Feedback Error: [ [ 1.5624985436508976E-6 ], [ 1.5624968397118244E-6 ], [ 1.5624947386633226E-6 ], [ 1.5624997157601822E-6 ], [ 1.5624975955030873E-6 ], [ 1.562495478654724E-6 ], [ 1.562493286656405E-6 ], [ 1.562495532875241E-6 ], ... ]
Error Statistics: {meanExponent=-5.8061806694216935, negative=0, min=1.5624922947432562E-6, max=1.562503043148894E-6, mean=1.562497497965568E-6, count=64, sum=9.999983986979635E-5, positive=64, stdDev=2.622201144429436E-12, zeros=0}
Feedback for input 1
Inputs Values: [
[ [ -0.472 ], [ -0.316 ], [ -1.552 ], [ -1.484 ], [ -1.248 ], [ 0.56 ], [ -0.312 ], [ 0.812 ] ],
[ [ -0.504 ], [ 1.156 ], [ 0.016 ], [ 1.352 ], [ 1.324 ], [ -1.656 ], [ -0.968 ], [ -1.808 ] ],
[ [ -1.156 ], [ 0.972 ], [ 1.288 ], [ -0.888 ], [ 0.344 ], [ -0.856 ], [ -0.892 ], [ 0.644 ] ],
[ [ 0.184 ], [ -1.116 ], [ 1.628 ], [ -1.256 ], [ -1.34 ], [ -1.16 ], [ -0.808 ], [ 0.66 ] ],
[ [ 1.98 ], [ 0.52 ], [ -1.564 ], [ 1.916 ], [ 1.776 ], [ 0.688 ], [ -1.1 ], [ -1.76 ] ],
[ [ -0.628 ], [ -1.456 ], [ -1.764 ], [ -1.724 ], [ 0.52 ], [ -0.124 ], [ -0.968 ], [ 0.82 ] ],
[ [ -0.368 ], [ -2.0 ], [ 0.692 ], [ -1.664 ], [ 1.444 ], [ -1.176 ], [ -0.784 ], [ 1.24 ] ],
[ [ -1.16 ], [ 1.42 ], [ 1.628 ], [ 0.82 ], [ 1.956 ], [ -1.256 ], [ 0.012 ], [ -1.58 ] ]
]
Value Statistics: {meanExponent=-0.06999649029273047, negative=36, min=-2.0, max=1.98, mean=-0.19524999999999998, count=64, sum=-12.495999999999999, positive=28, stdDev=1.186466998066107, zeros=0}
Implemented Feedback: [ [ -0.017249999999999998 ], [ -0.037625 ], [ -0.032125 ], [ -0.00975 ], [ 0.080875 ], [ -0.07475 ], [ -0.013 ], [ -0.083875 ], ... ]
Implemented Statistics: {meanExponent=-1.5341469852812004, negative=38, min=-0.110375, max=0.0995, mean=-0.007957031249999998, count=64, sum=-0.5092499999999999, positive=26, stdDev=0.055818410323389474, zeros=0}
Measured Feedback: [ [ -0.017248437504946423 ], [ -0.037623437503242485 ], [ -0.03212343750114144 ], [ -0.009748437506118535 ], [ 0.08087656249600172 ], [ -0.07474843750188143 ], [ -0.01299843749968943 ], [ -0.08387343750193565 ], ... ]
Measured Statistics: {meanExponent=-1.5341826917910613, negative=38, min=-0.11037343750075479, max=0.09950156250049247, mean=-0.007955468752790518, count=64, sum=-0.5091500001785931, positive=26, stdDev=0.05581841032326156, zeros=0}
Feedback Error: [ [ 1.562495053574614E-6 ], [ 1.5624967575136872E-6 ], [ 1.562498858562189E-6 ], [ 1.5624938814653294E-6 ], [ 1.5624960017224243E-6 ], [ 1.5624981185707876E-6 ], [ 1.5625003105691065E-6 ], [ 1.5624980643502706E-6 ], ... ]
Error Statistics: {meanExponent=-5.806180749605114, negative=0, min=1.5624924206980584E-6, max=1.5625024658433295E-6, mean=1.5624972094829682E-6, count=64, sum=9.999982140690997E-5, positive=64, stdDev=2.5929261188267952E-12, zeros=0}

Returns

    {
      "absoluteTol" : {
        "count" : 128,
        "sum" : 1.9999966127670632E-4,
        "min" : 1.5624922947432562E-6,
        "max" : 1.562503043148894E-6,
        "sumOfSquare" : 3.124989414914767E-10,
        "standardDeviation" : 2.6117061242212326E-12,
        "average" : 1.5624973537242681E-6
      },
      "relativeTol" : {
        "count" : 128,
        "sum" : 0.011934274055131259,
        "min" : 7.078067010530235E-6,
        "max" : 0.0020876784643436637,
        "sumOfSquare" : 1.1216465955180126E-5,
        "standardDeviation" : 2.8095478701854775E-4,
        "average" : 9.323651605571296E-5
      }
    }

Learning Validation

We validate the agreement between the implemented derivative of the internal weights apply finite difference estimations:

SingleDerivativeTester.java:185 executed in 0.00 seconds (0.000 gc):

        return testLearning(
            statistics,
            component.addRef(),
            RefUtil.addRef(inputPrototype),
            outputPrototype.addRef());
      },
      outputPrototype.addRef(),
      RefUtil.addRef(inputPrototype),
      component.addRef()));

Returns

    {
      "absoluteTol" : {
        "count" : 128,
        "sum" : 1.9999966127670632E-4,
        "min" : 1.5624922947432562E-6,
        "max" : 1.562503043148894E-6,
        "sumOfSquare" : 3.124989414914767E-10,
        "standardDeviation" : 2.6117061242212326E-12,
        "average" : 1.5624973537242681E-6
      },
      "relativeTol" : {
        "count" : 128,
        "sum" : 0.011934274055131259,
        "min" : 7.078067010530235E-6,
        "max" : 0.0020876784643436637,
        "sumOfSquare" : 1.1216465955180126E-5,
        "standardDeviation" : 2.8095478701854775E-4,
        "average" : 9.323651605571296E-5
      }
    }

Total Accuracy

The overall agreement accuracy between the implemented derivative and the finite difference estimations:

SingleDerivativeTester.java:200 executed in 0.00 seconds (0.000 gc):

    //log.info(String.format("Component: %s\nInputs: %s\noutput=%s", component, Arrays.toStream(inputPrototype), outputPrototype));
    log.info(RefString.format("Finite-Difference Derivative Accuracy:"));
    log.info(RefString.format("absoluteTol: %s", statistics.absoluteTol));
    log.info(RefString.format("relativeTol: %s", statistics.relativeTol));
Logging
Finite-Difference Derivative Accuracy:
absoluteTol: 1.5625e-06 +- 2.6117e-12 [1.5625e-06 - 1.5625e-06] (128#)
relativeTol: 9.3237e-05 +- 2.8095e-04 [7.0781e-06 - 2.0877e-03] (128#)

Frozen and Alive Status

SingleDerivativeTester.java:208 executed in 0.01 seconds (0.000 gc):

    testFrozen(component.addRef(), RefUtil.addRef(inputPrototype));
    testUnFrozen(component.addRef(), RefUtil.addRef(inputPrototype));

LayerTests.java:605 executed in 0.00 seconds (0.000 gc):

    throwException(exceptions.addRef());

Results

classdetailsresult
com.simiacryptus.mindseye.test.unit.SingleDerivativeTesterToleranceStatistics{absoluteTol=1.5625e-06 +- 2.6117e-12 [1.5625e-06 - 1.5625e-06] (128#), relativeTol=9.3237e-05 +- 2.8095e-04 [7.0781e-06 - 2.0877e-03] (128#)}OK
  {
    "result": "OK",
    "performance": {
      "execution_time": "0.226",
      "gc_time": "0.117"
    },
    "created_on": 1587004897341,
    "file_name": "derivativeTest",
    "report": {
      "simpleName": "Basic",
      "canonicalName": "com.simiacryptus.mindseye.layers.java.MeanSqLossLayerTest.Basic",
      "link": "https://github.com/SimiaCryptus/mindseye-java/tree/c9a1867488dc7e77a975f095285b5882c0486db6/src/test/java/com/simiacryptus/mindseye/layers/java/MeanSqLossLayerTest.java",
      "javaDoc": "The type Basic."
    },
    "archive": "s3://code.simiacrypt.us/tests/com/simiacryptus/mindseye/layers/java/MeanSqLossLayer/Basic/derivativeTest/202004164137",
    "id": "90ef0baa-2a6e-433d-a9f4-77e0947c2a4e",
    "report_type": "Components",
    "display_name": "Derivative Validation",
    "target": {
      "simpleName": "MeanSqLossLayer",
      "canonicalName": "com.simiacryptus.mindseye.layers.java.MeanSqLossLayer",
      "link": "https://github.com/SimiaCryptus/mindseye-java/tree/c9a1867488dc7e77a975f095285b5882c0486db6/src/main/java/com/simiacryptus/mindseye/layers/java/MeanSqLossLayer.java",
      "javaDoc": "The type Mean sq loss layer."
    }
  }