Skip to content

Commit

Permalink
Build example 3 if CUDA and MPI enabled
Browse files Browse the repository at this point in the history
  • Loading branch information
jwallwork23 committed Jan 7, 2025
1 parent 6055a7d commit 6cc94c8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
4 changes: 3 additions & 1 deletion examples/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
if(CMAKE_BUILD_TESTS)
add_subdirectory(1_SimpleNet)
add_subdirectory(2_ResNet18)
# add_subdirectory(3_MultiGPU)
if(ENABLE_CUDA AND ENABLE_MPI)
add_subdirectory(3_MultiGPU)
endif()
add_subdirectory(4_MultiIO)
# add_subdirectory(5_Looping)
add_subdirectory(6_Autograd)
Expand Down
6 changes: 4 additions & 2 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,10 @@ if(CMAKE_BUILD_TESTS)
DESTINATION ${CMAKE_CURRENT_SOURCE_DIR}/test/examples)
file(COPY ${CMAKE_CURRENT_SOURCE_DIR}/../examples/2_ResNet18
DESTINATION ${CMAKE_CURRENT_SOURCE_DIR}/test/examples)
# file(COPY ${CMAKE_CURRENT_SOURCE_DIR}/../examples/3_MultiGPU
# DESTINATION ${CMAKE_CURRENT_SOURCE_DIR}/test/examples)
if(ENABLE_CUDA AND ENABLE_MPI)
file(COPY ${CMAKE_CURRENT_SOURCE_DIR}/../examples/3_MultiGPU
DESTINATION ${CMAKE_CURRENT_SOURCE_DIR}/test/examples)
endif()
file(COPY ${CMAKE_CURRENT_SOURCE_DIR}/../examples/4_MultiIO
DESTINATION ${CMAKE_CURRENT_SOURCE_DIR}/test/examples)
# file(COPY ${CMAKE_CURRENT_SOURCE_DIR}/../examples/5_Looping
Expand Down

0 comments on commit 6cc94c8

Please sign in to comment.