Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 7 of 7 for TFE_OpSetAttrShape (0.22 sec)

  1. tensorflow/c/eager/parallel_device/parallel_device_lib_test.cc

          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);
      TFE_OpSetAttrShape(handle_op.get(), "shape", /*dims=*/nullptr, /*num_dims=*/0,
                         status.get());
      ASSERT_TRUE(TF_GetCode(status.get()) == TF_OK) << TF_Message(status.get());
      auto outputs =
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Thu Jul 08 23:47:35 GMT 2021
    - 15.3K bytes
    - Viewed (0)
  2. tensorflow/c/eager/custom_device_test.cc

          TFE_NewOp(context.get(), "VarHandleOp", status.get()), TFE_DeleteOp);
      ASSERT_TRUE(TF_GetCode(status.get()) == TF_OK) << TF_Message(status.get());
      TFE_OpSetAttrType(op.get(), "dtype", TF_FLOAT);
      TFE_OpSetAttrShape(op.get(), "shape", {}, 0, status.get());
      TFE_OpSetAttrString(op.get(), "container", "", 0);
      TFE_OpSetAttrString(op.get(), "shared_name", "", 0);
      TFE_OpSetDevice(op.get(), name, status.get());
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Thu Aug 27 23:39:24 GMT 2020
    - 18.4K bytes
    - Viewed (0)
  3. tensorflow/c/eager/parallel_device/parallel_device_testlib.cc

      std::unique_ptr<TFE_Op, decltype(&TFE_DeleteOp)> op(
          TFE_NewOp(context, "VarHandleOp", status), TFE_DeleteOp);
      if (TF_GetCode(status) != TF_OK) return nullptr;
      TFE_OpSetAttrType(op.get(), "dtype", type);
      TFE_OpSetAttrShape(op.get(), "shape", dims, num_dims, status);
      TFE_OpSetAttrString(op.get(), "container", "", 0);
      // Use the special GUID for no buffer sharing
      //
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Tue Jun 15 15:44:44 GMT 2021
    - 12.5K bytes
    - Viewed (0)
  4. tensorflow/c/eager/c_api.cc

          if (tensor_shape.unknown_rank()) {
            TFE_OpSetAttrShape(op, attr_name, nullptr, -1, status);
          } else {
            const auto num_dims = tensor_shape.dim_size();
            std::unique_ptr<int64_t[]> dims(new int64_t[num_dims]);
            for (int i = 0; i < num_dims; ++i) {
              dims[i] = tensor_shape.dim(i).size();
            }
            TFE_OpSetAttrShape(op, attr_name, dims.get(), num_dims, status);
          }
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Tue Mar 12 20:00:09 GMT 2024
    - 43.9K bytes
    - Viewed (2)
  5. tensorflow/c/eager/c_api_test_util.cc

      // 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);
      TFE_OpSetAttrString(op, "container", "localhost", 0);
      TFE_OpSetAttrString(op, "shared_name", "", 0);
      if (!device_name.empty()) {
        TFE_OpSetDevice(op, device_name.c_str(), status);
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Wed Feb 21 22:37:46 GMT 2024
    - 23.5K bytes
    - Viewed (2)
  6. tensorflow/c/eager/c_api.h

    // If the number of dimensions is unknown, `num_dims` must be set to
    // -1 and `dims` can be null.  If a dimension is unknown, the
    // corresponding entry in the `dims` array must be -1.
    TF_CAPI_EXPORT extern void TFE_OpSetAttrShape(TFE_Op* op, const char* attr_name,
                                                  const int64_t* dims,
                                                  const int num_dims,
    C
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Thu Apr 27 21:07:00 GMT 2023
    - 22.8K bytes
    - Viewed (1)
  7. tensorflow/c/eager/c_api_test.cc

      CHECK_EQ(TF_OK, TF_GetCode(status)) << TF_Message(status);
      TFE_DeleteContextOptions(opts);
    
      TFE_Op* var_op = TFE_NewOp(ctx, "VarHandleOp", status);
      TFE_OpSetAttrType(var_op, "dtype", TF_INT64);
      TFE_OpSetAttrShape(var_op, "shape", {}, 0, status);
      const TFE_OpAttrs* attributes = TFE_OpGetAttrs(var_op);
    
      TFE_Op* copy_op = TFE_NewOp(ctx, "VarHandleOp", status);
      TFE_OpSetAttrType(copy_op, "dtype", TF_FLOAT);
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Thu Aug 03 20:50:20 GMT 2023
    - 94.6K bytes
    - Viewed (1)
Back to top