UNPKG

1.48 kBTypeScriptView Raw
1/// <amd-module name="@tensorflow/tfjs-core/dist/ops/sparse_to_dense_util" />
2/**
3 * @license
4 * Copyright 2018 Google LLC. All Rights Reserved.
5 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 * =============================================================================
17 */
18import { Tensor } from '../tensor';
19/**
20 * Validate sparseToDense inputs.
21 *
22 * @param sparseIndices A 0-D, 1-D, or 2-D Tensor of type int32.
23 * sparseIndices[i] contains the complete index where sparseValues[i] will be
24 * placed.
25 * @param sparseValues A 0-D or 1-D Tensor. Values
26 * corresponding to each row of sparseIndices, or a scalar value to be used for
27 * all sparse indices.
28 * @param outputShape number[]. Shape of the dense output tensor.
29 * @param validateIndices boolean. indice validation is not supported, error
30 * will be thrown if it is set.
31 */
32export declare function validateInput(sparseIndices: Tensor, sparseValues: Tensor, outputShape: number[], defaultValues: Tensor): void;