Untitled
unknown
plain_text
14 days ago
1.2 kB
1
Indexable
Never
cmake_minimum_required(VERSION 3.0 FATAL_ERROR) project(custom_ops) find_package(Torch REQUIRED) find_package(PythonLibs REQUIRED) # Add this line to find Python libraries include_directories(${PYTHON_INCLUDE_DIRS}) # Add this line to include Python headers add_executable(loadModel loadModel.cc) target_link_libraries(loadModel "${TORCH_LIBRARIES}" ${PYTHON_LIBRARIES}) # Link Python libs set_property(TARGET loadModel PROPERTY CXX_STANDARD 17) add_executable(analyzer analyzer.cc) target_link_libraries(analyzer "${TORCH_LIBRARIES}" ${PYTHON_LIBRARIES}) # Link Python libs set_property(TARGET analyzer PROPERTY CXX_STANDARD 17) add_executable(listAttribute listAttribute.cc) target_link_libraries(listAttribute "${TORCH_LIBRARIES}" ${PYTHON_LIBRARIES}) # Link Python libs set_property(TARGET listAttribute PROPERTY CXX_STANDARD 17) add_executable(extractExecuteOrder extractExecuteOrder.cc) target_link_libraries(extractExecuteOrder "${TORCH_LIBRARIES}" ${PYTHON_LIBRARIES}) # Link Python libs set_property(TARGET extractExecuteOrder PROPERTY CXX_STANDARD 17) add_executable(stack stack.cc) target_link_libraries(stack "${TORCH_LIBRARIES}" ${PYTHON_LIBRARIES}) # Link Python libs set_property(TARGET stack PROPERTY CXX_STANDARD 17)
Leave a Comment