Apache Arrow (C++)
A columnar in-memory analytics layer designed to accelerate big data.
numpy_to_arrow.h
Go to the documentation of this file.
1 // Licensed to the Apache Software Foundation (ASF) under one
2 // or more contributor license agreements. See the NOTICE file
3 // distributed with this work for additional information
4 // regarding copyright ownership. The ASF licenses this file
5 // to you under the Apache License, Version 2.0 (the
6 // "License"); you may not use this file except in compliance
7 // with the License. You may obtain a copy of the License at
8 //
9 // http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing,
12 // software distributed under the License is distributed on an
13 // "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14 // KIND, either express or implied. See the License for the
15 // specific language governing permissions and limitations
16 // under the License.
17 
18 // Converting from pandas memory representation to Arrow data structures
19 
20 #ifndef ARROW_PYTHON_NUMPY_TO_ARROW_H
21 #define ARROW_PYTHON_NUMPY_TO_ARROW_H
22 
23 #include "arrow/python/platform.h"
24 
25 #include <memory>
26 
27 #include "arrow/util/visibility.h"
28 
29 namespace arrow {
30 
31 class Array;
32 class ChunkedArray;
33 class DataType;
34 class MemoryPool;
35 class Status;
36 
37 namespace py {
38 
47 ARROW_EXPORT
48 Status NdarrayToArrow(MemoryPool* pool, PyObject* ao, PyObject* mo,
49  bool use_pandas_null_sentinels,
50  const std::shared_ptr<DataType>& type,
51  std::shared_ptr<ChunkedArray>* out);
52 
53 } // namespace py
54 } // namespace arrow
55 
56 #endif // ARROW_PYTHON_NUMPY_TO_ARROW_H
Top-level namespace for Apache Arrow C++ API.
Definition: allocator.h:29
Status NdarrayToArrow(MemoryPool *pool, PyObject *ao, PyObject *mo, bool use_pandas_null_sentinels, const std::shared_ptr< DataType > &type, std::shared_ptr< ChunkedArray > *out)
Convert NumPy arrays to Arrow.