- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 28 for dims2 (0.05 sec)
-
tensorflow/c/eager/c_api_test_util.cc
constexpr int64_t dims[] = {100, 100}; constexpr int num_elements = dims[0] * dims[1]; float data[num_elements]; for (int i = 0; i < num_elements; ++i) { data[i] = 1.0f; } TF_Status* status = TF_NewStatus(); TF_Tensor* t = TFE_AllocateHostTensor(ctx, TF_FLOAT, &dims[0], sizeof(dims) / sizeof(int64_t), status);
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Wed Feb 21 22:37:46 UTC 2024 - 23.5K bytes - Viewed (0) -
tensorflow/c/c_api_experimental.cc
std::vector<DimensionHandle> dims; const TF_ShapeAndType& input_shape = input_shapes->items[i]; if (input_shape.num_dims == InferenceContext::kUnknownRank) { c.SetInput(i, c.UnknownShape()); continue; } dims.reserve(input_shape.num_dims); for (int j = 0; j < input_shape.num_dims; ++j) { dims.push_back(c.MakeDim(input_shape.dims[j])); } c.SetInput(i, c.MakeShape(dims));
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 16:27:48 UTC 2024 - 29.5K bytes - Viewed (0) -
tensorflow/c/eager/c_api_unified_experimental_test.cc
*/ // Build an abstract input tensor. int64_t dims[] = {2, 2}; // Matrices will be 2 x 2 int num_dims = sizeof(dims) / sizeof(dims[0]); float vals[] = {0.0f, 0.0f, 0.0f, 0.0f}; TFE_Context* eager_ctx = TF_ExecutionContextGetTFEContext(ctx, status.get()); TFE_TensorHandle* t = TestMatrixTensorHandleWithInput(eager_ctx, vals, dims, num_dims);
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 39.1K bytes - Viewed (0) -
tensorflow/c/eager/c_api_unified_experimental_graph.cc
return absl::OkStatus(); } std::vector<int64_t> dims(num_dims, kUnknownDim); TF_GraphGetTensorShape(graph_, output_, reinterpret_cast<int64_t*>(dims.data()), num_dims, &status); TF_RETURN_IF_ERROR(StatusFromTF_Status(&status)); TF_RETURN_IF_ERROR(tensorflow::TensorShapeUtils::MakeShape(dims, shape)); return absl::OkStatus(); }
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 15.7K bytes - Viewed (0) -
tensorflow/c/c_api_experimental_test.cc
int num_dims = output_shapes->items[0].num_dims; int64_t* dims = output_shapes->items[0].dims; if (!expected_shape.has_value()) { EXPECT_EQ(num_dims, -1); EXPECT_EQ(dims, nullptr); return; } EXPECT_EQ(num_dims, expected_shape->size()); for (size_t i = 0; i < num_dims; ++i) { EXPECT_EQ(dims[i], (*expected_shape)[i]); }
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Tue Jan 17 22:27:52 UTC 2023 - 13.1K bytes - Viewed (0) -
tensorflow/c/c_test_util.cc
} TF_Tensor* Int8Tensor(const int64_t* dims, int num_dims, const char* values) { int64_t num_values = 1; for (int i = 0; i < num_dims; ++i) { num_values *= dims[i]; } TF_Tensor* t = TF_AllocateTensor(TF_INT8, dims, num_dims, sizeof(char) * num_values); memcpy(TF_TensorData(t), values, sizeof(char) * num_values); return t; } TF_Tensor* Int32Tensor(const int64_t* dims, int num_dims,
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Fri Oct 15 03:16:52 UTC 2021 - 17.8K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/primitives/BytesTest.java
int dim1 = 1 << 16; int dim2 = 1 << 15; assertThat(dim1 * dim2).isLessThan(0); testConcatOverflow(dim1, dim2); } @GwtIncompatible // different overflow behavior; could probably be made to work by using ~~ public void testConcat_overflow_nonNegative() { int dim1 = 1 << 16; int dim2 = 1 << 16; assertThat(dim1 * dim2).isAtLeast(0); testConcatOverflow(dim1, dim2); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 02:56:12 UTC 2024 - 17.3K bytes - Viewed (0) -
guava-tests/test/com/google/common/primitives/BytesTest.java
int dim1 = 1 << 16; int dim2 = 1 << 15; assertThat(dim1 * dim2).isLessThan(0); testConcatOverflow(dim1, dim2); } @GwtIncompatible // different overflow behavior; could probably be made to work by using ~~ public void testConcat_overflow_nonNegative() { int dim1 = 1 << 16; int dim2 = 1 << 16; assertThat(dim1 * dim2).isAtLeast(0); testConcatOverflow(dim1, dim2); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 02:56:12 UTC 2024 - 17.3K bytes - Viewed (0) -
tensorflow/c/eager/gradients.cc
if (num_dims < 0) { proto.set_unknown_rank(true); } else { for (int d = 0; d < num_dims; ++d) { proto.add_dim()->set_size(dims[d]); } } forward_op_->attrs.Set(attr_name, proto); return op_->SetAttrShape(attr_name, dims, num_dims); } absl::Status SetAttrFunction(AbstractOperation* op_, const char* attr_name, const AbstractOperation* value,
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 19.7K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/primitives/CharsTest.java
int dim1 = 1 << 16; int dim2 = 1 << 15; assertThat(dim1 * dim2).isLessThan(0); testConcatOverflow(dim1, dim2); } @GwtIncompatible // different overflow behavior; could probably be made to work by using ~~ public void testConcat_overflow_nonNegative() { int dim1 = 1 << 16; int dim2 = 1 << 16; assertThat(dim1 * dim2).isAtLeast(0); testConcatOverflow(dim1, dim2); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 02:56:12 UTC 2024 - 25.6K bytes - Viewed (0)