Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 207 for cc_status (0.4 sec)

  1. tensorflow/c/experimental/next_pluggable_device/c_api.cc

      absl::Status cc_status;
      if (var_info == nullptr) {
        cc_status = absl::InvalidArgumentError("TF_VariableInfo is NULL.");
        status->status = cc_status;
        return nullptr;
      }
      if (var_info->var_info.var() == nullptr) {
        cc_status = absl::InvalidArgumentError(
            "VariableInfo does not track a resource variable.");
        status->status = cc_status;
        return nullptr;
      }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Apr 22 05:48:24 UTC 2024
    - 13.9K bytes
    - Viewed (0)
  2. tensorflow/c/tf_status_helper_test.cc

    namespace tsl {
    namespace {
    
    TEST(StatusHelper, TestStatusHelper) {
      TSL_Status* s = TSL_NewStatus();
      absl::Status cc_status(absl::InvalidArgumentError("some error"));
      cc_status.SetPayload("key1", absl::Cord("value1"));
      cc_status.SetPayload("key2", absl::Cord("value2"));
      Set_TF_Status_from_Status(s, cc_status);
      ASSERT_EQ(TSL_INVALID_ARGUMENT, TSL_GetCode(s));
      ASSERT_EQ(std::string("some error"), TSL_Message(s));
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Sun Apr 14 21:57:32 UTC 2024
    - 1.7K bytes
    - Viewed (0)
  3. tensorflow/c/kernels.cc

                                                       TF_Status* status) {
      auto* cc_ctx = reinterpret_cast<::tensorflow::OpKernelConstruction*>(ctx);
      tensorflow::NameAttrList function;
      auto cc_status = cc_ctx->GetAttr(attr_name, &function);
      if (!cc_status.ok()) {
        tsl::Set_TF_Status_from_Status(status, cc_status);
        return nullptr;
      }
      TF_Buffer* buffer = TF_NewBuffer();
      cc_status = tensorflow::MessageToBuffer(function, buffer);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 28 22:53:47 UTC 2024
    - 36K bytes
    - Viewed (0)
  4. tensorflow/c/tf_tensor.cc

    }
    
    void TF_TensorBitcastFrom(const TF_Tensor* from, TF_DataType type,
                              TF_Tensor* to, const int64_t* new_dims,
                              int num_new_dims, TF_Status* status) {
      TF_SetStatus(status, TF_OK, "");
      Status cc_status(
          tensorflow::down_cast<tensorflow::TensorInterface*>(to->tensor)
              ->BitcastFrom(
                  *tensorflow::down_cast<const tensorflow::TensorInterface*>(
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Sun Apr 14 21:57:32 UTC 2024
    - 11.5K bytes
    - Viewed (0)
  5. tensorflow/c/kernels_experimental.cc

      }
    
      TF_SetStatus(tf_status, TF_OK, "");
    }
    
    void TF_DestroyTemporaryVariable(TF_OpKernelContext* ctx, const int index,
                                     TF_StringView* var_name,
                                     TF_Status* tf_status) {
      auto* context = reinterpret_cast<::tensorflow::OpKernelContext*>(ctx);
      if (!IsRefType(context->input_dtype(0))) {
        tf_status->status =
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Apr 23 06:12:29 UTC 2024
    - 30.9K bytes
    - Viewed (0)
  6. tensorflow/c/tf_status_helper.h

    #include <utility>
    
    #include "tensorflow/c/tf_status.h"
    #include "tsl/platform/status.h"
    
    namespace tsl {
    // Set the attribute of "tf_status" from the attributes of "status".
    void Set_TF_Status_from_Status(TF_Status* tf_status,
                                   const absl::Status& status);
    
    // Returns a "status" from "tf_status".
    absl::Status StatusFromTF_Status(const TF_Status* tf_status);
    }  // namespace tsl
    
    namespace tensorflow {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Sun Apr 14 21:57:32 UTC 2024
    - 2.9K bytes
    - Viewed (0)
  7. tensorflow/c/tf_status.cc

    #ifndef LIBTPU_EXCLUDE_C_API_IMPL
    
    #include "tensorflow/c/tf_status.h"
    
    #include "tensorflow/c/tf_status_internal.h"
    
    // Trampoline implementation to redirect to TSL. Kept here for backward
    // compatibility only.
    
    TF_Status* TF_NewStatus() { return TSL_NewStatus(); }
    void TF_DeleteStatus(TF_Status* s) { TSL_DeleteStatus(s); }
    void TF_SetStatus(TF_Status* s, TF_Code code, const char* msg) {
      TSL_SetStatus(s, TSL_Code(code), msg);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Aug 24 18:40:14 UTC 2023
    - 1.7K bytes
    - Viewed (0)
  8. tensorflow/c/tf_status.h

    // Return a new status object.
    TF_CAPI_EXPORT extern TF_Status* TF_NewStatus(void);
    
    // Delete a previously created status object.
    TF_CAPI_EXPORT extern void TF_DeleteStatus(TF_Status*);
    
    // Record <code, msg> in *s.  Any previous information is lost.
    // A common use is to clear a status: TF_SetStatus(s, TF_OK, "");
    TF_CAPI_EXPORT extern void TF_SetStatus(TF_Status* s, TF_Code code,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Mar 12 20:00:09 UTC 2024
    - 3.9K bytes
    - Viewed (0)
  9. tensorflow/c/experimental/stream_executor/stream_executor.cc

        stats.num_allocs = c_stats.num_allocs;
        stats.bytes_in_use = c_stats.bytes_in_use;
        stats.peak_bytes_in_use = c_stats.peak_bytes_in_use;
        stats.largest_alloc_size = c_stats.largest_alloc_size;
        if (c_stats.has_bytes_limit) {
          stats.bytes_limit = c_stats.bytes_limit;
        }
        stats.bytes_reserved = c_stats.bytes_reserved;
        stats.peak_bytes_reserved = c_stats.peak_bytes_reserved;
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Jun 14 07:39:19 UTC 2024
    - 27.1K bytes
    - Viewed (0)
  10. tensorflow/c/env.cc

                     TF_Status* status) {
      ::tensorflow::FileStatistics cc_stats;
      TF_SetStatus(status, TF_OK, "");
      ::tensorflow::Status s =
          ::tensorflow::Env::Default()->Stat(filename, &cc_stats);
      ::tensorflow::Set_TF_Status_from_Status(status, s);
      if (s.ok()) {
        stats->length = cc_stats.length;
        stats->mtime_nsec = cc_stats.mtime_nsec;
        stats->is_directory = cc_stats.is_directory;
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Aug 11 01:20:50 UTC 2021
    - 7K bytes
    - Viewed (0)
Back to top