Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 7 of 7 for substr (0.15 sec)

  1. tensorflow/c/eager/immediate_execution_tensor_handle.cc

        value_string = "<error computing value>";
      }
      if (value_string.length() > 100) {
        // The default NumPy-style output can be distractingly long in error
        // messages.
        value_string = absl::StrCat(value_string.substr(0, 100), " [...]");
      }
      Status s;
      const char* device_name = DeviceName(&s);
      if (!s.ok()) {
        device_name = "<error fetching device name>";
      }
    C++
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Thu Feb 15 09:49:45 GMT 2024
    - 2.1K bytes
    - Viewed (0)
  2. tensorflow/c/experimental/filesystem/plugins/gcs/gcs_filesystem_test.cc

      // `string_view`
      if (length == read && content_view.substr(offset, length) ==
                                absl::string_view(result).substr(0, read))
        return ::testing::AssertionSuccess();
      else
        return ::testing::AssertionFailure()
               << "Result: " << absl::string_view(result).substr(0, read)
               << " Read: " << read;
    }
    
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Mon Aug 31 12:04:23 GMT 2020
    - 24.9K bytes
    - Viewed (0)
  3. tensorflow/c/c_api.cc

          session->graph->sessions[session].clear();
        }
    
        const auto num_nodes = graph.num_node_ids();
        if (session->last_num_graph_nodes < num_nodes) {
          // TODO(nolivia): check this on a subset of the graph instead of all of
          // it.
          status->status = graph::ValidateGraphHasNoCycle(session->graph->graph);
          if (!status->status.ok()) {
            session->graph->mu.unlock();
            return false;
    C++
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Mon Apr 15 03:35:10 GMT 2024
    - 102.3K bytes
    - Viewed (0)
  4. tensorflow/c/eager/c_api_experimental_test.cc

    using tensorflow::string;
    
    namespace tensorflow {
    namespace {
    
    static bool HasSubstr(absl::string_view base, absl::string_view substr) {
      bool ok = absl::StrContains(base, substr);
      EXPECT_TRUE(ok) << base << ", expected substring " << substr;
      return ok;
    }
    
    TEST(CAPI, MonitoringCounter0) {
      TF_Status* status = TF_NewStatus();
      auto* counter =
    C++
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Thu Aug 03 03:14:26 GMT 2023
    - 31.5K bytes
    - Viewed (1)
  5. tensorflow/c/experimental/filesystem/plugins/gcs/gcs_filesystem.cc

        TF_SetStatus(status, TF_INVALID_ARGUMENT,
                     "GCS path doesn't contain a bucket name.");
        return;
      }
    
      *bucket = fname.substr(scheme_end + 1, bucket_end - scheme_end - 1);
      *object = fname.substr(bucket_end + 1);
    
      if (object->empty() && !object_empty_ok) {
        TF_SetStatus(status, TF_INVALID_ARGUMENT,
                     "GCS path doesn't contain an object name.");
      }
    }
    
    C++
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Wed Aug 23 06:55:53 GMT 2023
    - 46.9K bytes
    - Viewed (0)
  6. tensorflow/c/c_api_function_test.cc

      TF_Operation* func_feed = Placeholder(host_graph_, s_);
      TF_Operation* func_op = Use({func_feed, five});
      Run({{func_feed, Int32Tensor(2)}}, func_op, 2 /*+=*/ + 5 + 1);
    
      // Verify input, output, and subset of edges in fdef.
      // The subset of edges we verify is a chain between feed1 and output to
      // make sure that the correct output is picked.
      tensorflow::FunctionDef fdef;
      ASSERT_TRUE(GetFunctionDef(func_, &fdef));
    C++
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Thu Jul 20 22:08:54 GMT 2023
    - 63.6K bytes
    - Viewed (6)
  7. tensorflow/c/eager/c_api_test.cc

        const char* device_name = TFE_OpGetDevice(matmul, status);
        ASSERT_TRUE(strstr(device_name, "GPU:0") != nullptr);
    
        TFE_OpSetDevice(matmul, "CPU:0", status);
        ASSERT_TRUE(TF_GetCode(status) == TF_OK) << TF_Message(status);
        device_name = TFE_OpGetDevice(matmul, status);
        ASSERT_TRUE(strstr(device_name, "CPU:0") != nullptr);
      }
    
      TFE_DeleteOp(matmul);
      TFE_DeleteTensorHandle(m);
    C++
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Thu Aug 03 20:50:20 GMT 2023
    - 94.6K bytes
    - Viewed (1)
Back to top