UNPKG

636 BTypeScriptView Raw
1/// <amd-module name="@tensorflow/tfjs-core/dist/ops/add_n" />
2import { Tensor } from '../tensor';
3import { TensorLike } from '../types';
4/**
5 * Adds a list of `tf.Tensor`s element-wise, each with the same shape and dtype.
6 *
7 * ```js
8 * const a = tf.tensor1d([1, 2]);
9 * const b = tf.tensor1d([3, 4]);
10 * const c = tf.tensor1d([5, 6]);
11 *
12 * tf.addN([a, b, c]).print();
13 * ```
14 * @param tensors A list of tensors with the same shape and dtype.
15 * @doc {heading: 'Operations', subheading: 'Arithmetic'}
16 */
17declare function addN_<T extends Tensor>(tensors: Array<T | TensorLike>): T;
18export declare const addN: typeof addN_;
19export {};