Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 8 of 8 for Memcpy (0.26 sec)

  1. tensorflow/compiler/mlir/lite/utils/string_utils.cc

      // big-endian platform.
      memcpy(*buffer, &num_strings, sizeof(int32_t));
    
      // Set offset of strings.
      int32_t start = sizeof(int32_t) * (num_strings + 2);
      for (size_t i = 0; i < offset_.size(); i++) {
        // TODO(b/165919229): This code will need changing if/when we port to a
        // big-endian platform.
        int32_t offset = start + offset_[i];
        memcpy(*buffer + sizeof(int32_t) * (i + 1), &offset, sizeof(int32_t));
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Jun 12 21:41:49 UTC 2024
    - 2.9K bytes
    - Viewed (0)
  2. tensorflow/c/experimental/gradients/grad_test_helper.cc

        ASSERT_EQ(num_elem_numerical, num_elem_analytical);
    
        float* dnumerical = new float[num_elem_numerical]{0};
        memcpy(&dnumerical[0], TF_TensorData(numerical_tensor),
               TF_TensorByteSize(numerical_tensor));
        float* danalytical = new float[num_elem_analytical]{0};
        memcpy(&danalytical[0], TF_TensorData(analytical_tensor),
               TF_TensorByteSize(analytical_tensor));
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Feb 28 13:53:47 UTC 2024
    - 5K bytes
    - Viewed (0)
  3. tensorflow/c/eager/gradient_checker.cc

      TF_RETURN_IF_ERROR(GetValue(theta, &theta_tensor));
    
      // Get number of elements and fill data.
      int num_elems = TF_TensorElementCount(theta_tensor);
      vector<float> theta_data(num_elems);
      memcpy(theta_data.data(), TF_TensorData(theta_tensor),
             TF_TensorByteSize(theta_tensor));
    
      // Initialize space for the numerical gradient.
      vector<float> dtheta_approx(num_elems);
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Feb 15 09:49:45 UTC 2024
    - 7.3K bytes
    - Viewed (0)
  4. tensorflow/compiler/jit/xla_host_recv_device_context.cc

      Status status = XLAShapeToTensorShape(shape_, &tensor_shape);
      if (!status.ok()) {
        done(status);
        return;
      }
    
      *cpu_tensor = Tensor(dtype, tensor_shape);
    
      status = stream_->Memcpy(cpu_tensor->data(), device_memory_base_,
                               device_memory_base_.size());
      if (!status.ok()) {
        done(status);
        return;
      }
      status = stream_->RecordEvent(done_event_.get().get());
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 17 22:46:36 UTC 2024
    - 1.9K bytes
    - Viewed (0)
  5. tensorflow/compiler/jit/xla_host_send_recv_device_context_test.cc

      xla::Shape shape;
      TF_ASSERT_OK(TensorShapeToXLAShape(DT_FLOAT, TensorShape({2, 2}), &shape));
    
      // Copy the cpu_tensor to the GPU first before trying to copy it back.
      TF_ASSERT_OK(
          stream->Memcpy(&gpu_dst, origin_cpu_tensor.data(), gpu_dst.size()));
      TF_ASSERT_OK(stream->BlockHostUntilDone());
    
      TF_ASSERT_OK_AND_ASSIGN(auto se_event, executor->CreateEvent());
      tsl::AsyncValueRef<std::unique_ptr<se::Event>> done_event =
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 17 22:46:36 UTC 2024
    - 7.2K bytes
    - Viewed (0)
  6. tensorflow/compiler/jit/xla_host_send_device_context.cc

    namespace tensorflow {
    
    void XlaHostSendDeviceContext::CopyCPUTensorToDevice(
        const Tensor* cpu_tensor, Device* device, Tensor* device_tensor,
        StatusCallback done, bool sync_dst_compute) const {
      auto status = stream_->Memcpy(device_memory_base_, cpu_tensor->data(),
                                    device_memory_base_->size());
      if (!status.ok()) {
        done(status);
        return;
      }
      status = stream_->RecordEvent(done_event_.get().get());
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri May 17 22:46:36 UTC 2024
    - 1.6K bytes
    - Viewed (0)
  7. tensorflow/c/tf_buffer.cc

    extern "C" {
    
    TF_Buffer* TF_NewBuffer() { return new TF_Buffer{nullptr, 0, nullptr}; }
    
    TF_Buffer* TF_NewBufferFromString(const void* proto, size_t proto_len) {
      void* copy = tensorflow::port::Malloc(proto_len);
      std::memcpy(copy, proto, proto_len);
    
      TF_Buffer* buf = new TF_Buffer;
      buf->data = copy;
      buf->length = proto_len;
      buf->data_deallocator = [](void* data, size_t length) {
        tensorflow::port::Free(data);
      };
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Sun Apr 14 21:57:32 UTC 2024
    - 3K bytes
    - Viewed (0)
  8. src/main/java/org/codelibs/fess/validation/UriTypeValidator.java

            case FILE -> ComponentUtil.getFessConfig().getCrawlerFileProtocolsAsArray();
            default -> throw new ConstraintDefinitionException("protocolType is emtpy.");
            };
        }
    
        @Override
        public boolean isValid(final String value, final ConstraintValidatorContext context) {
            if (StringUtil.isNotBlank(value)) {
                return check(protocols, value);
    Registered: Wed Jun 12 13:08:18 UTC 2024
    - Last Modified: Thu Feb 22 01:37:57 UTC 2024
    - 2.3K bytes
    - Viewed (0)
Back to top