mirror of
https://github.com/wassname/ray.git
synced 2026-07-21 12:50:45 +08:00
Fixes Mac OSX installation error (#464)
* changes to address ARROW-826 and ARROW-444 * changes to address ARROW-826 and ARROW-444 * ignoring cmake-build-debug * additional IDEA ignore files * additional IDEA ignore files * remove arrow ipc and arrow io libraries * add boost dependencies * fix arrow origin and remove submodule
This commit is contained in:
committed by
Philipp Moritz
parent
c802e51d36
commit
0189b09581
+21
@@ -80,6 +80,9 @@ scripts/nodes.txt
|
||||
*.dSYM/
|
||||
*.su
|
||||
|
||||
# CMake
|
||||
cmake-build-debug/
|
||||
|
||||
# Python setup files
|
||||
*.egg-info
|
||||
|
||||
@@ -92,3 +95,21 @@ scripts/nodes.txt
|
||||
|
||||
# Generated documentation files
|
||||
/doc/_build
|
||||
|
||||
# User-specific stuff:
|
||||
.idea/**/workspace.xml
|
||||
.idea/**/tasks.xml
|
||||
.idea/dictionaries
|
||||
|
||||
# Sensitive or high-churn files:
|
||||
.idea/**/dataSources/
|
||||
.idea/**/dataSources.ids
|
||||
.idea/**/dataSources.xml
|
||||
.idea/**/dataSources.local.xml
|
||||
.idea/**/sqlDataSources.xml
|
||||
.idea/**/dynamic.xml
|
||||
.idea/**/uiDesigner.xml
|
||||
|
||||
# Gradle:
|
||||
.idea/**/gradle.xml
|
||||
.idea/**/libraries
|
||||
|
||||
@@ -34,10 +34,6 @@ set(ARROW_DIR "${CMAKE_CURRENT_LIST_DIR}/thirdparty/arrow/"
|
||||
|
||||
set(ARROW_LIB "${CMAKE_CURRENT_LIST_DIR}/thirdparty/arrow/cpp/build/release/libarrow.a"
|
||||
CACHE STRING "Path to libarrow.a (needs to be changed if arrow is build in debug mode)")
|
||||
set(ARROW_IO_LIB "${CMAKE_CURRENT_LIST_DIR}/thirdparty/arrow/cpp/build/release/libarrow_io.a"
|
||||
CACHE STRING "Path to libarrow_io.a (needs to be changed if arrow is build in debug mode)")
|
||||
set(ARROW_IPC_LIB "${CMAKE_CURRENT_LIST_DIR}/thirdparty/arrow/cpp/build/release/libarrow_ipc.a"
|
||||
CACHE STRING "Path to libarrow_ipc.a (needs to be changed if arrow is build in debug mode)")
|
||||
set(ARROW_PYTHON_LIB "${CMAKE_CURRENT_LIST_DIR}/thirdparty/arrow/cpp/build/release/libarrow_python.a"
|
||||
CACHE STRING "Path to libarrow_python.a (needs to be changed if arrow is build in debug mode)")
|
||||
|
||||
@@ -69,15 +65,15 @@ if(APPLE)
|
||||
endif(APPLE)
|
||||
|
||||
if(APPLE)
|
||||
target_link_libraries(numbuf ${ARROW_LIB} ${ARROW_IO_LIB} ${ARROW_IPC_LIB} ${ARROW_PYTHON_LIB} ${PYTHON_LIBRARIES} -lpthread)
|
||||
target_link_libraries(numbuf ${ARROW_LIB} ${ARROW_PYTHON_LIB} ${PYTHON_LIBRARIES} -lpthread -lboost_regex -lboost_system -lboost_filesystem)
|
||||
else()
|
||||
target_link_libraries(numbuf -Wl,--whole-archive ${ARROW_LIB} -Wl,--no-whole-archive ${ARROW_IO_LIB} ${ARROW_IPC_LIB} ${ARROW_PYTHON_LIB} ${PYTHON_LIBRARIES} -lpthread)
|
||||
target_link_libraries(numbuf -Wl,--whole-archive ${ARROW_LIB} -Wl,--no-whole-archive ${ARROW_PYTHON_LIB} ${PYTHON_LIBRARIES} -lpthread -lboost_regex -lboost_system -lboost_filesystem)
|
||||
endif()
|
||||
|
||||
if(HAS_PLASMA)
|
||||
target_link_libraries(numbuf ${ARROW_LIB} ${ARROW_IO_LIB} ${ARROW_IPC_LIB} ${ARROW_PYTHON_LIB} ${PYTHON_LIBRARIES} plasma_lib common ${FLATBUFFERS_STATIC_LIB} -lpthread)
|
||||
target_link_libraries(numbuf ${ARROW_LIB} ${ARROW_PYTHON_LIB} ${PYTHON_LIBRARIES} plasma_lib common ${FLATBUFFERS_STATIC_LIB} -lpthread -lboost_regex -lboost_system -lboost_filesystem)
|
||||
else()
|
||||
target_link_libraries(numbuf ${ARROW_LIB} ${ARROW_IO_LIB} ${ARROW_IPC_LIB} ${ARROW_PYTHON_LIB} ${PYTHON_LIBRARIES} -lpthread)
|
||||
target_link_libraries(numbuf ${ARROW_LIB} ${ARROW_PYTHON_LIB} ${PYTHON_LIBRARIES} -lpthread -lboost_regex -lboost_system -lboost_filesystem)
|
||||
endif()
|
||||
|
||||
install(TARGETS numbuf DESTINATION ${CMAKE_SOURCE_DIR}/numbuf/)
|
||||
|
||||
@@ -22,7 +22,7 @@ namespace numbuf {
|
||||
|
||||
Status get_value(std::shared_ptr<Array> arr, int32_t index, int32_t type, PyObject* base,
|
||||
const std::vector<std::shared_ptr<Tensor>>& tensors, PyObject** result) {
|
||||
switch (arr->type()->type) {
|
||||
switch (arr->type()->id()) {
|
||||
case Type::BOOL:
|
||||
*result =
|
||||
PyBool_FromLong(std::static_pointer_cast<BooleanArray>(arr)->Value(index));
|
||||
@@ -55,13 +55,13 @@ Status get_value(std::shared_ptr<Array> arr, int32_t index, int32_t type, PyObje
|
||||
case Type::STRUCT: {
|
||||
auto s = std::static_pointer_cast<StructArray>(arr);
|
||||
auto l = std::static_pointer_cast<ListArray>(s->field(0));
|
||||
if (s->type()->child(0)->name == "list") {
|
||||
if (s->type()->child(0)->name() == "list") {
|
||||
return DeserializeList(l->values(), l->value_offset(index),
|
||||
l->value_offset(index + 1), base, tensors, result);
|
||||
} else if (s->type()->child(0)->name == "tuple") {
|
||||
} else if (s->type()->child(0)->name() == "tuple") {
|
||||
return DeserializeTuple(l->values(), l->value_offset(index),
|
||||
l->value_offset(index + 1), base, tensors, result);
|
||||
} else if (s->type()->child(0)->name == "dict") {
|
||||
} else if (s->type()->child(0)->name() == "dict") {
|
||||
return DeserializeDict(l->values(), l->value_offset(index),
|
||||
l->value_offset(index + 1), base, tensors, result);
|
||||
} else {
|
||||
|
||||
+1
-1
@@ -11,4 +11,4 @@ if [ ! -d $TP_DIR/arrow ]; then
|
||||
git clone https://github.com/apache/arrow/ "$TP_DIR/arrow"
|
||||
fi
|
||||
cd $TP_DIR/arrow
|
||||
git checkout b0863cb63d62ae7c4a429164e5a2e350d3c1f21a
|
||||
git checkout 30e03a90718971c2a1d773145fb042d0c2857036
|
||||
|
||||
Reference in New Issue
Block a user