Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 26 for byte (0.14 sec)

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

      xla::Shape shape = xla::ShapeUtil::MakeShape(xla::S32, {1});
    
      auto buffer = c_api_client->pjrt_c_client()->client->BufferFromHostBuffer(
          data.data(), shape.element_type(), shape.dimensions(),
          /*byte_strides=*/std::nullopt,
          xla::PjRtClient::HostBufferSemantics::kImmutableOnlyDuringCall, nullptr,
          c_api_client->pjrt_c_client()->client->addressable_devices()[0]);
      CHECK_OK(buffer.status());
    
    C++
    - Registered: Tue Feb 27 12:39:08 GMT 2024
    - Last Modified: Mon Oct 30 19:20:20 GMT 2023
    - 7.2K bytes
    - Viewed (0)
  2. 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)
  3. tensorflow/c/c_api.h

    //   For example, neither the C99 nor the C++11 standard force a byte
    //   size on the bool type, so the macro defined in stdbool.h could
    //   be inconsistent with the bool keyword in C++. Thus, the use
    //   of stdbool.h is avoided and unsigned char is used instead.
    // * size_t is used to represent byte sizes of objects that are
    //   materialized in the address space of the calling process.
    C
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Thu Oct 26 21:08:15 GMT 2023
    - 82.3K bytes
    - Viewed (3)
  4. 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)
  5. tensorflow/c/experimental/filesystem/plugins/posix/copy_file.h

    #include <sys/stat.h>
    
    namespace tf_posix_filesystem {
    
    // Transfers up to `size` bytes from `dst_fd` to `src_fd`.
    //
    // This method uses `sendfile` if available (i.e., linux 2.6.33 or later) or an
    // intermediate buffer if not.
    //
    // Returns number of bytes transferred or -1 on failure.
    int CopyFileContents(int dst_fd, int src_fd, off_t size);
    
    }  // namespace tf_posix_filesystem
    
    C
    - Registered: Tue Apr 23 12:39:09 GMT 2024
    - Last Modified: Fri Nov 22 21:23:55 GMT 2019
    - 1.2K bytes
    - Viewed (0)
  6. 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)
  7. tensorflow/c/experimental/filesystem/plugins/gcs/gcs_filesystem.h

              uint64_t block_size, size_t max_bytes, uint64_t max_staleness,
              uint64_t stat_cache_max_age, size_t stat_cache_max_entries);
    } GCSFile;
    
    // This function is used to initialize a filesystem without the need of setting
    // manually environement variables.
    void InitTest(TF_Filesystem* filesystem, bool compose, uint64_t block_size,
                  size_t max_bytes, uint64_t max_staleness,
    C
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Mon Aug 31 04:37:41 GMT 2020
    - 5.2K bytes
    - Viewed (0)
  8. tensorflow/c/env.h

    typedef struct TF_StringStream TF_StringStream;
    typedef struct TF_Thread TF_Thread;
    
    typedef struct TF_ThreadOptions {
      // Thread stack size to use (in bytes), zero implies that the system default
      // will be used.
      size_t stack_size;
    
      // Guard area size to use near thread stacks to use (in bytes), zero implies
      // that the system default will be used.
      size_t guard_size;
    
    C
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Sat Jan 09 02:53:27 GMT 2021
    - 9.6K bytes
    - Viewed (0)
  9. tensorflow/c/experimental/filesystem/plugins/gcs/gcs_filesystem_test.cc

        if (file_size != content.size())
          TF_SetStatus(
              status_, TF_DATA_LOSS,
              std::string("expected " + std::to_string(file_size) + " got " +
                          std::to_string(content.size()) + " bytes")
                  .c_str());
        return content;
      }
    
     protected:
      TF_Filesystem* filesystem_;
      TF_Status* status_;
    
     private:
      std::string root_dir_;
    };
    
    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)
  10. tensorflow/c/experimental/filesystem/modular_filesystem_test.cc

      if (!status.ok())
        GTEST_SKIP() << "NewRandomAccessFile() not supported: " << status;
    
      char scratch[64 /* must be bigger than test_data */] = {0};
      StringPiece result;
      // read at least 1 byte more than test_data
      status = read_file->Read(0, test_data.size() + 1, &result, scratch);
      EXPECT_PRED2(UnimplementedOrReturnsCode, status, Code::OUT_OF_RANGE);
    }
    
    C++
    - Registered: Tue Apr 30 12:39:09 GMT 2024
    - Last Modified: Fri May 27 20:25:58 GMT 2022
    - 71K bytes
    - Viewed (0)
Back to top