- Sort Score
- Result 10 results
- Languages All
Results 1 - 9 of 9 for TFE_NewOp (0.06 sec)
-
tensorflow/c/eager/parallel_device/parallel_device_lib_test.cc
"/job:localhost/replica:0/task:0/device:CPU:1"}; ParallelDevice parallel_device(std::move(devices)); std::unique_ptr<TFE_Op, decltype(&TFE_DeleteOp)> handle_op( TFE_NewOp(context.get(), "VarHandleOp", status.get()), TFE_DeleteOp); ASSERT_TRUE(TF_GetCode(status.get()) == TF_OK) << TF_Message(status.get()); TFE_OpSetAttrType(handle_op.get(), "dtype", TF_FLOAT);
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Mon Oct 21 04:14:14 UTC 2024 - 15.6K bytes - Viewed (0) -
tensorflow/c/eager/c_api_test_util.cc
TFE_TensorHandle* TestVariable(TFE_Context* ctx, float value, const tensorflow::string& device_name) { TF_Status* status = TF_NewStatus(); // Create the variable handle. TFE_Op* op = TFE_NewOp(ctx, "VarHandleOp", status); if (TF_GetCode(status) != TF_OK) return nullptr; TFE_OpSetAttrType(op, "dtype", TF_FLOAT); TFE_OpSetAttrShape(op, "shape", {}, 0, 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/eager/c_api_cluster_test.cc
// Read the value of variable `var` and save it into `out_value`. void ReadVariable(TFE_Context* ctx, TFE_TensorHandle* var, TFE_TensorHandle** out_value) { TF_Status* status = TF_NewStatus(); TFE_Op* op = TFE_NewOp(ctx, "ReadVariableOp", status); ASSERT_EQ(TF_OK, TF_GetCode(status)) << TF_Message(status); TFE_OpSetAttrType(op, "dtype", TF_FLOAT); TFE_OpAddInput(op, var, status);
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 19.2K bytes - Viewed (0) -
tensorflow/c/eager/parallel_device/parallel_device_test.cc
<< TF_Message(status.get()); } { // Try to pass a non-parallel tensor to TPUReplicatedOutput std::unique_ptr<TFE_Op, decltype(&TFE_DeleteOp)> op( TFE_NewOp(context.get(), "TPUReplicatedOutput", status.get()), TFE_DeleteOp); if (TF_GetCode(status.get()) != TF_OK) return; TFE_OpSetAttrInt(op.get(), "num_replicas", 1);
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Tue Aug 06 23:56:17 UTC 2024 - 29.4K bytes - Viewed (0) -
tensorflow/c/eager/c_api_distributed_test.cc
TFE_ContextAddFunctionDef(ctx, function_def.data(), function_def.size(), status); ASSERT_EQ(TF_GetCode(status), TF_OK) << TF_Message(status); TFE_Op* func = TFE_NewOp(ctx, "AddVariablesFunction", status); ASSERT_EQ(TF_GetCode(status), TF_OK) << TF_Message(status); TFE_OpAddInput(func, packed_handle, status); ASSERT_EQ(TF_GetCode(status), TF_OK) << TF_Message(status); if (remote) {
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 23.4K bytes - Viewed (0) -
tensorflow/c/eager/c_api.cc
return 0; } const tensorflow::Tensor* tensor; status->status = handle->Tensor(&tensor); if (!status->status.ok()) { return 0; } return tensor->TotalBytes(); } TFE_Op* TFE_NewOp(TFE_Context* ctx, const char* op_or_function_name, TF_Status* status) { tensorflow::ImmediateExecutionOperation* new_op = tensorflow::unwrap(ctx)->CreateOperation();
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Sat Oct 12 05:11:17 UTC 2024 - 43.9K bytes - Viewed (0) -
tensorflow/c/eager/parallel_device/parallel_device_lib.cc
std::vector<TensorHandlePtr>* outputs, TF_Status* status) const { if (op_ == nullptr) { TFE_ContextSetExecutorForThread(context, executor_.get()); op_.reset(TFE_NewOp(context, operation_name, status)); if (TF_GetCode(status) != TF_OK) return; TFE_OpSetDevice(op_.get(), device_.c_str(), status); if (TF_GetCode(status) != TF_OK) return; } else {
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Mon Oct 21 04:14:14 UTC 2024 - 25.9K bytes - Viewed (0) -
tensorflow/c/eager/parallel_device/parallel_device_lib.h
// on to one TFE_Op per device and just call TFE_ResetOp to avoid parsing // device names repeatedly. std::unique_ptr<TFE_Op, decltype(&TFE_DeleteOp)> const_op( TFE_NewOp(context, "Const", status), TFE_DeleteOp); if (TF_GetCode(status) != TF_OK) return nullptr; TFE_OpSetDevice(const_op.get(), underlying_devices_[device_index].c_str(), status);
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Mon Oct 21 04:14:14 UTC 2024 - 13.1K bytes - Viewed (0) -
tensorflow/c/eager/parallel_device/parallel_device.cc
return result; } else if (operation_name == std::string("TPUReplicatedOutput")) { // Special-cased operation for un-packing one parallel tensor into // per-device tensors. OpPtr op(TFE_NewOp(context, operation_name, status)); TFE_OpAddAttrs(op.get(), attributes); int expected_outputs = TFE_OpGetOutputLength(op.get(), "outputs", status); if (TF_GetCode(status) != TF_OK) return result;
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Mon Oct 21 04:14:14 UTC 2024 - 18.3K bytes - Viewed (0)