Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 16 for bytes (0.14 sec)

  1. tensorflow/c/experimental/filesystem/plugins/gcs/ram_file_block_cache_test.cc

        int64_t bytes_transferred;
        if (offset < buf.size()) {
          size_t bytes_to_copy = std::min<size_t>(buf.size() - offset, n);
          memcpy(buffer, buf.data() + offset, bytes_to_copy);
          bytes_transferred = bytes_to_copy;
        } else {
          bytes_transferred = 0;
        }
        TF_SetStatus(status, TF_OK, "");
        return bytes_transferred;
      };
    C++
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Fri Oct 15 03:16:57 GMT 2021
    - 23.2K bytes
    - Viewed (0)
  2. tensorflow/c/c_api_test.cc

        tensorflow::AttrValue attr;
        for (const string& v : list) {
          attr.mutable_list()->add_s(v);
        }
        string bytes;
        attr.SerializeToString(&bytes);
        TF_SetAttrValueProto(desc, tensorflow::kColocationAttrName, bytes.data(),
                             bytes.size(), s_);
        ASSERT_EQ(TF_OK, TF_GetCode(s_)) << TF_Message(s_);
      }
    
      void VerifyCollocation(TF_Operation* op,
    C++
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Mon Apr 15 03:35:10 GMT 2024
    - 96.9K bytes
    - Viewed (3)
  3. tensorflow/c/c_test_util.cc

    }
    
    TF_Tensor* Int32Tensor(int32_t v) {
      const int num_bytes = sizeof(int32_t);
      int32_t* values = new int32_t[1];
      values[0] = v;
      return TF_NewTensor(TF_INT32, nullptr, 0, values, num_bytes,
                          &Int32Deallocator, nullptr);
    }
    
    TF_Tensor* DoubleTensor(double v) {
      const int num_bytes = sizeof(double);
      double* values = new double[1];
      values[0] = v;
    C++
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Fri Oct 15 03:16:52 GMT 2021
    - 17.8K bytes
    - Viewed (2)
  4. tensorflow/c/eager/dlpack.cc

      void* data = dl_tensor->data;
    
      if (dl_tensor->byte_offset != 0) {
        status->status = tensorflow::errors::InvalidArgument(
            "Unsupported byte_offset (", dl_tensor->byte_offset,
            ") from DLPack, must be zero");
        return nullptr;
      }
    
      size_t total_bytes = dl_tensor->dtype.bits / 8;
      for (int i = 0; i < num_dims; i++) {
        total_bytes *= dims[i];
      }
    
      if (dl_tensor->strides != nullptr &&
    C++
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Thu Feb 15 09:49:45 GMT 2024
    - 12.8K bytes
    - Viewed (0)
  5. tensorflow/c/experimental/filesystem/plugins/gcs/gcs_filesystem.cc

        block_size = value * 1024 * 1024;
      }
      const char* max_bytes_env = std::getenv(kMaxCacheSize);
      if (max_bytes_env && absl::SimpleAtoi(max_bytes_env, &value)) {
        max_bytes = static_cast<size_t>(value * 1024 * 1024);
      }
      const char* max_staleness_env = std::getenv(kMaxStaleness);
      if (max_staleness_env && absl::SimpleAtoi(max_staleness_env, &value)) {
        max_staleness = value;
      }
    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/experimental/grappler/grappler.h

    // must point to an array of length at least `num_values`.
    //
    // The elements of values will point to addresses in `storage` which must be at
    // least `storage_size` bytes in length.  `num_values` and `storage` can be
    // obtained from TF_GetNodesToPreserveSize
    //
    // Fails if storage_size is too small to hold the requested number of strings.
    TF_CAPI_EXPORT extern void TF_GetNodesToPreserveList(
    C
    - Registered: Tue Feb 27 12:39:08 GMT 2024
    - Last Modified: Wed Aug 03 18:08:43 GMT 2022
    - 12.5K bytes
    - Viewed (0)
  7. tensorflow/c/experimental/filesystem/filesystem_interface.h

      void (*cleanup)(TF_RandomAccessFile* file);
    
      /// Reads up to `n` bytes from `*file` starting at `offset`.
      ///
      /// The output is in `buffer`, core TensorFlow owns the buffer and guarantees
      /// that at least `n` bytes are available.
      ///
      /// Returns number of bytes read or -1 in case of error. Because of this
      /// constraint and the fact that `ssize_t` is not defined in `stdint.h`/C++
    C
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Fri May 27 17:36:54 GMT 2022
    - 53.1K bytes
    - Viewed (0)
  8. tensorflow/c/eager/parallel_device/parallel_device_testlib.cc

                                            TF_Status* status) {
      const int num_bytes = v.size() * sizeof(float);
      float* values = new float[v.size()];
      memcpy(values, v.data(), num_bytes);
      int64_t dims = v.size();
      std::unique_ptr<TF_Tensor, decltype(&TF_DeleteTensor)> tensor(
          TF_NewTensor(TF_FLOAT, &dims, 1 /* num_dims */, values, num_bytes,
                       &FloatDeallocator, nullptr),
          TF_DeleteTensor);
    C++
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Tue Jun 15 15:44:44 GMT 2021
    - 12.5K bytes
    - Viewed (0)
  9. tensorflow/c/c_api_function_test.cc

      TF_DeleteBuffer(attr_buf);
    
      // Set attr
      tensorflow::AttrValue attr;
      attr.set_s("test_attr_value");
      string bytes;
      attr.SerializeToString(&bytes);
      TF_FunctionSetAttrValueProto(func_, "test_attr_name", bytes.data(),
                                   bytes.size(), s_);
      ASSERT_EQ(TF_OK, TF_GetCode(s_)) << TF_Message(s_);
    
      // Get attr
      AttrValue read_attr;
    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)
  10. tensorflow/c/c_api.cc

      // make sure there is no information loss.
      if (proto_len > std::numeric_limits<int>::max()) {
        status->status = InvalidArgument(
            "proto_len (", proto_len,
            " bytes) is too large to be parsed by the protocol buffer library");
        return;
      }
      TensorShapeProto shape;
      if (shape.ParseFromArray(proto, static_cast<int>(proto_len))) {
        desc->node_builder.Attr(attr_name, shape);
    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)
Back to top