- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 100 for num_elements (0.27 sec)
-
tensorflow/compiler/mlir/tensorflow/tests/compile_mlir_util/replicate-tensor-list-init-ops.mlir
%elem_shape_2 = "tf.Const"() {value = dense<-1> : tensor<1xi32>} : () -> tensor<1xi32> %tls = "tf.TensorListStack"(%tl_set_item, %elem_shape_2) {num_elements = 300 : i64} : (tensor<!tf_type.variant<tensor<*xf32>>>, tensor<1xi32>) -> tensor<300x?xf32> %elem_2 = "tf.Const"() {value = dense<10.0> : tensor<9xf32>} : () -> tensor<9xf32>
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Fri Feb 03 09:30:08 UTC 2023 - 1.9K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/stablehlo/transforms/fold_broadcast_pass.cc
operand_new_shape[dimensions[i]] = operand.getType().getDimSize(i); } llvm::SmallVector<ElementValueT, 16> new_values; auto num_elements = result_type.getNumElements(); new_values.reserve(num_elements); auto operand_values = operand.getValues<ElementValueT>(); for (int64_t i = 0; i < num_elements; ++i) { const int64_t operand_index = GetElementIndex(operand_new_shape, current_index);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 10.5K bytes - Viewed (0) -
tensorflow/compiler/mlir/quantization/tensorflow/passes/quantize_weights.cc
int num_elements_threshold = quant_options_.min_num_elements_for_weights(); int num_elements = cast<ShapedType>(op.getType()).getNumElements(); if (num_elements < num_elements_threshold) { op->emitRemark("Quantization is skipped because the op has ") << num_elements << " elements which is fewer than the threshold(" << num_elements_threshold << " elements)."; return failure();
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Tue Mar 05 07:39:40 UTC 2024 - 11.3K bytes - Viewed (0) -
tensorflow/cc/experimental/base/tests/tensorhandle_test.cc
EXPECT_EQ(tensor.dtype(), dtype); EXPECT_EQ(*reinterpret_cast<typename TypeParam::type*>(tensor.data()), 42); EXPECT_EQ(tensor.num_bytes(), sizeof(typename TypeParam::type)); EXPECT_EQ(tensor.num_elements(), 1); } template <typename T> class Construct1DTensorHandleTest : public ::testing::Test {}; TYPED_TEST_SUITE(Construct1DTensorHandleTest, SimpleTypes);
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Sat Apr 13 09:56:08 UTC 2024 - 6.9K bytes - Viewed (0) -
tensorflow/c/experimental/saved_model/core/test_utils.h
int8_t value); // Fills a numeric tensor's buffer with `value`. // dtype must be any integer dtype, float or double. void FillNumericTensorBuffer(DataType dtype, size_t num_elements, void* buffer, int8_t value); // Checks the underlying data is equal for the buffers for two numeric tensors. // Note: The caller must ensure to check that the dtypes and sizes of the
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Aug 11 01:20:50 UTC 2021 - 3.5K bytes - Viewed (0) -
tensorflow/cc/framework/gradient_checker.cc
const int64_t x_size = x_shapes[x_idx].num_elements() * JacobianStride<X_T>::value; for (int y_idx = 0; y_idx < y_num; y_idx++) { // The number of columns is the number of elements in the y tensor // multiplied by the number of Jacobian entries needed to represent each // y type. const int64_t y_size = y_shapes[y_idx].num_elements() * JacobianStride<Y_T>::value;
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Sat Apr 13 05:57:22 UTC 2024 - 18.2K bytes - Viewed (0) -
tensorflow/cc/experimental/base/public/tensor.h
// Returns the data type of the tensor. TF_DataType dtype() const; // Returns the number of elements in the tensor. For a tensor with a partially // defined shape, -1 means not fully defined. int64_t num_elements() const; // Returns the size of the underlying data in bytes. size_t num_bytes() const; private: friend class TensorHandle; friend class Runtime;
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Oct 28 20:10:33 UTC 2020 - 6.3K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/utils/low_bit_utils.h
// Returns a vector where each int8 element contains a int4 sign-extended value. std::vector<char> UnpackDenseInt4IntoInt8( const std::vector<uint8_t>& src_buffer, int64_t num_elements); } // namespace tflite
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Wed Oct 12 20:13:51 UTC 2022 - 1.5K bytes - Viewed (0) -
tensorflow/compiler/mlir/lite/transforms/dense_to_sparse.cc
b_size->push_back(block_size[i]); } } } inline float GetSparsity(const int num_zeros, const int num_elements) { return (1.0 * num_zeros / num_elements); } float CalculateRandomSparsity(const ElementsAttr& attr, const ShapedType& type) { int num_elements = type.getNumElements(); int num_zeros = 0; if (mlir::isa<FloatType>(type.getElementType())) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Apr 25 16:01:03 UTC 2024 - 16.1K bytes - Viewed (0) -
tensorflow/compiler/jit/pjrt_tensor_buffer_util.cc
#include "tensorflow/core/framework/types.h" #include "tsl/platform/statusor.h" namespace tensorflow { static size_t GetTensorSize(const TensorShape& shape, const DataType dtype) { return shape.num_elements() * DataTypeSize(dtype); } absl::StatusOr<Tensor> MakeTensorFromPjRtBuffer( const DataType dtype, const TensorShape& shape, std::unique_ptr<xla::PjRtBuffer> pjrt_buffer) {
Registered: Sun Jun 16 05:45:23 UTC 2024 - Last Modified: Thu Sep 14 18:14:47 UTC 2023 - 3.5K bytes - Viewed (0)