NumCpp  1.0
A C++ implementation of the Python Numpy library
fromBuffer.hpp
Go to the documentation of this file.
1 #pragma once
30 
31 #include "NumCpp/Core/Types.hpp"
32 #include "NumCpp/NdArray.hpp"
33 
34 namespace nc
35 {
36  //============================================================================
37  // Method Description:
47  template<typename dtype>
48  NdArray<dtype> frombuffer(char* inBufferPtr, uint32 inNumBytes) noexcept
49  {
50  return NdArray<dtype>(reinterpret_cast<dtype*>(inBufferPtr), inNumBytes);
51  }
52 }
NdArray< dtype > frombuffer(char *inBufferPtr, uint32 inNumBytes) noexcept
Definition: fromBuffer.hpp:48
Definition: Coordinate.hpp:45
uint32_t uint32
Definition: Types.hpp:41
Holds 1D and 2D arrays, the main work horse of the NumCpp library.
Definition: NdArrayCore.hpp:66