Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 57 for Memcpy (0.37 sec)

  1. tensorflow/c/c_api.cc

      status->status = s->session->PRunSetup(input_names, output_names,
                                             target_oper_names, &new_handle);
      if (status->status.ok()) {
        char* buf = new char[new_handle.size() + 1];
        memcpy(buf, new_handle.c_str(), new_handle.size() + 1);
        *handle = buf;
      }
    }
    
    void TF_PRun(TF_DeprecatedSession* s, const char* handle,
                 // Input tensors
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Apr 15 03:35:10 UTC 2024
    - 102.3K bytes
    - Viewed (0)
  2. tensorflow/c/eager/c_api_cluster_test.cc

      ASSERT_EQ(TF_OK, TF_GetCode(status.get())) << TF_Message(status.get());
      std::unique_ptr<float[]> actual_values(new float[expected_values.size()]);
      EXPECT_EQ(sizeof(float) * expected_values.size(), TF_TensorByteSize(t));
      memcpy(actual_values.get(), TF_TensorData(t), TF_TensorByteSize(t));
      TF_DeleteTensor(t);
    
      for (int i = 0; i < expected_values.size(); i++) {
        EXPECT_EQ(expected_values[i], actual_values[i])
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Apr 14 10:03:59 UTC 2023
    - 19.3K bytes
    - Viewed (0)
  3. tensorflow/c/experimental/filesystem/plugins/gcs/gcs_filesystem.cc

        size_t copy_size = 0;
        if (offset < buffer_end && gcs_file->buffer_start) {
          copy_size = (std::min)(n, static_cast<size_t>(buffer_end - offset));
          memcpy(buffer,
                 gcs_file->buffer.data() + (offset - gcs_file->buffer_start),
                 copy_size);
        }
        bool consumed_buffer_to_eof =
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Aug 23 06:55:53 UTC 2023
    - 46.9K bytes
    - Viewed (0)
  4. tensorflow/c/experimental/filesystem/plugins/gcs/ram_file_block_cache_test.cc

                            char* buffer, TF_Status* status) -> int64_t {
        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;
      };
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Oct 15 03:16:57 UTC 2021
    - 23.2K bytes
    - Viewed (0)
  5. tensorflow/cc/experimental/libtf/object.h

        return tensorflow::errors::InvalidArgument(absl::StrCat(
            "Mismatched number of elements: \n", "Expected: ", data.size(), "\n",
            "Actual: ", t->NumElements(), "\n"));
      }
      memcpy(data.data(), t->Data(), t->ByteSize());
      return ::tensorflow::OkStatus();
    }
    
    /// @brief The Tuple class for holding TaggedValues of type TUPLE.
    class Tuple : public Handle {
     public:
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 11 08:05:36 UTC 2023
    - 23.6K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/quantization/stablehlo/passes/bridge/convert_tf_quant_to_mhlo_int_test.cc

          TF_RETURN_IF_ERROR(
              tensorflow::XLAShapeToTensorShape(xla_literal->shape(), &shape));
          tensorflow::Tensor tensor(data_type, shape);
          std::memcpy(static_cast<char*>(tensor.data()),
                      xla_literal->untyped_data(),
                      xla::ShapeUtil::ByteSizeOfPrimitiveType(
                          xla_literal->shape().element_type()) *
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Apr 03 01:03:21 UTC 2024
    - 35.8K bytes
    - Viewed (0)
  7. tensorflow/c/kernels_test.cc

      OpKernelContext* cc_ctx = reinterpret_cast<OpKernelContext*>(ctx);
      cc_ctx->eigen_gpu_device().memcpyHostToDevice(data, values,
                                                    tensor_size_bytes);
    #else
      memcpy(data, values, tensor_size_bytes);
    #endif
    }
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Sep 06 19:12:29 UTC 2023
    - 50.4K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/lite/flatbuffer_import.cc

        auto status = absl::OkStatus();
    
        std::vector<uint8_t> custom_options;
    
        if (IsValidBufferOffset(op.large_custom_options_offset)) {
          custom_options.resize(op.large_custom_options_size);
          memcpy(custom_options.data(),
                 reinterpret_cast<const uint8_t*>(model_ptr->allocation()->base()) +
                     op.large_custom_options_offset,
                 op.large_custom_options_size);
        } else {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 21 18:21:50 UTC 2024
    - 66.8K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/lite/transforms/optimize_patterns.td

    //             [11, 23]]   # == 2nd column in filter
    // This is exactly what the EmbeddedLookup operator is doing, on the transposed
    // matrix, without doing any arithmetic but only memcpy.
    def ReplaceOneHotFullyConnectedWithLookup : Pat<
      (TFL_FullyConnectedOp:$outputs
        (TFL_OneHotOp
          AnyStaticShapeTensor:$indices,
          (Arith_ConstantOp $depth),
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu May 16 20:31:41 UTC 2024
    - 66.4K bytes
    - Viewed (0)
  10. tensorflow/c/c_api_test.cc

      }
    
      TF_Tensor* FloatTensor2x2(const float* values) {
        const int64_t dims[2] = {2, 2};
        TF_Tensor* t = TF_AllocateTensor(TF_FLOAT, dims, 2, sizeof(float) * 4);
        memcpy(TF_TensorData(t), values, sizeof(float) * 4);
        return t;
      }
    
      TF_Operation* FloatConst2x2(TF_Graph* graph, TF_Status* s,
                                  const float* values, const char* name) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Apr 15 03:35:10 UTC 2024
    - 96.9K bytes
    - Viewed (0)
Back to top