MCPcopy Create free account
hub / github.com/deepjavalibrary/djl / add

Method add

api/src/main/java/ai/djl/ndarray/NDArray.java:1395–1395  ·  view source on GitHub ↗

Adds a number to this NDArray element-wise. Examples jshell> NDArray array = manager.create(new float[] {1f, 2f}); jshell> array.add(2f); ND: (2) cpu() float32 [3., 4.] @param n the number to add @return the result NDArray

(Number n)

Source from the content-addressed store, hash-verified

1393 * @return the result {@code NDArray}
1394 */
1395 NDArray add(Number n);
1396
1397 /**
1398 * Adds other {@code NDArray}s to this {@code NDArray} element-wise.

Callers 15

testAllCloseMethod · 0.95
testAllMethod · 0.95
forwardInternalMethod · 0.95
xywh2xyxyMethod · 0.95
evaluateOneOutputMethod · 0.95
calculateIOUMethod · 0.95
forwardInternalMethod · 0.95
forwardInternalMethod · 0.95
forwardInternalMethod · 0.95
extractFeaturesMethod · 0.95
buildMethod · 0.95
logProbMethod · 0.95

Implementers 4

NDArrayAdapterapi/src/main/java/ai/djl/ndarray/NDArr
RsNDArrayextensions/tokenizers/src/main/java/ai
TfNDArrayengines/tensorflow/tensorflow-engine/s
PtNDArrayengines/pytorch/pytorch-engine/src/mai

Calls

no outgoing calls

Tested by 15

testAllCloseMethod · 0.76
testAllMethod · 0.76
runIntegrationTestsMethod · 0.52
processOutputMethod · 0.52
listTestClassesMethod · 0.52
addTestMethodMethod · 0.52
addBeforeClassMethod · 0.52
addAfterClassMethod · 0.52
addBeforeTestMethod · 0.52
addAfterTestMethod · 0.52