Package org.nd4j.autodiff.validation
Class OpValidation
- java.lang.Object
-
- org.nd4j.autodiff.validation.OpValidation
-
public class OpValidation extends Object
-
-
Constructor Summary
Constructors Constructor Description OpValidation()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
checkDeserializedEquality(SameDiff original, ByteBuffer bbSerialized, TestCase tc)
static void
collectTensorflowImportCoverage(SameDiff graph)
protected static void
equalConsideringNull(List<String> l1, List<String> l2, String msg, Object... args)
static void
logCoverageInformation(boolean logAdequatelyTested, boolean logInadequate, boolean logUnmappedLibnd4jOps, boolean logUntestedTFImport, boolean logUnmappedTFOps)
Log the coverage informationstatic String
validate(OpTestCase testCase)
Validate the outputs of a single opstatic String
validate(TestCase testCase)
Run test casestatic String
validate(TestCase testCase, boolean exceptionsAsErrorMsg)
-
-
-
Method Detail
-
validate
public static String validate(TestCase testCase)
Run test case- Parameters:
testCase
- Test case to run- Returns:
- NULL if test passes, or error message otherwise
-
checkDeserializedEquality
public static void checkDeserializedEquality(SameDiff original, ByteBuffer bbSerialized, TestCase tc)
-
equalConsideringNull
protected static void equalConsideringNull(List<String> l1, List<String> l2, String msg, Object... args)
-
validate
public static String validate(OpTestCase testCase)
Validate the outputs of a single op- Parameters:
testCase
- Op test case to run- Returns:
- NULL if test is OK, or an error message otherwise
-
collectTensorflowImportCoverage
public static void collectTensorflowImportCoverage(SameDiff graph)
-
logCoverageInformation
public static void logCoverageInformation(boolean logAdequatelyTested, boolean logInadequate, boolean logUnmappedLibnd4jOps, boolean logUntestedTFImport, boolean logUnmappedTFOps)
Log the coverage information- Parameters:
logAdequatelyTested
- If true: log details of each op that has both forward and (if appropriate) backward testslogInadequate
- If false: log details of each op that does NOT have both forward and (if appropriate) backward tests
-
-