Skip to content

Latest commit

 

History

History
15 lines (10 loc) · 602 Bytes

File metadata and controls

15 lines (10 loc) · 602 Bytes

Operation Namespaces

All operations in ND4J and SameDiff are available in "Operation Namespaces". Each namespace is available on the Nd4j and SameDiff classes with its lowercase name.

For example, if you want to use the absoluteDifference operation it would look like this

// ND4J mode
INDArray output = Nd4j.loss.absoluteDifference(labels, predictions, null);

// SameDiff mode
SDVariable output = SameDiff.loss.absoluteDifference(labels, predictions, null);

Namespaces