Skip to content

Commit 797f453

Browse files
committed
Use intended mechanism for Python deps of RBatchGenerator tutorials
This makes the configuration less error prone.
1 parent ccf4fa2 commit 797f453

File tree

1 file changed

+17
-4
lines changed

1 file changed

+17
-4
lines changed

tutorials/CMakeLists.txt

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -330,14 +330,12 @@ else()
330330
list(APPEND tmva_veto machine_learning/TMVA_SOFIE_Models.py)
331331
list(APPEND tmva_veto machine_learning/TMVA_SOFIE_Inference.py)
332332
list(APPEND tmva_veto machine_learning/TMVA_SOFIE_RSofieReader.C)
333-
list(APPEND tmva_veto machine_learning/RBatchGenerator_TensorFlow.py)
334333
endif()
335334
if (NOT ROOT_SKLEARN_FOUND)
336335
list(APPEND tmva_veto machine_learning/TMVA_SOFIE_Models.py roofit/roofit/rf617_simulation_based_inference_multidimensional.py)
337336
endif()
338337
if (NOT ROOT_TORCH_FOUND)
339338
list(APPEND tmva_veto machine_learning/TMVA_SOFIE_PyTorch.C)
340-
list(APPEND tmva_veto machine_learning/RBatchGenerator_PyTorch.py)
341339
endif()
342340
#veto this tutorial since it is added directly
343341
list(APPEND tmva_veto machine_learning/TMVA_SOFIE_GNN_Parser.py)
@@ -929,10 +927,25 @@ if(ROOT_pyroot_FOUND)
929927
analysis/dataframe/df035_RDFFromPandas.py
930928
roofit/roofit/rf409_NumPyPandasToRooFit.py)
931929
file(GLOB requires_keras RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} machine_learning/keras/*.py)
932-
file(GLOB requires_torch RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} machine_learning/pytorch/*.py)
930+
file(GLOB requires_torch RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
931+
machine_learning/pytorch/*.py
932+
machine_learning/RBatchGenerator_PyTorch.py
933+
)
933934
file(GLOB requires_xgboost RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} machine_learning/tmva10*.py)
934935
file(GLOB requires_sklearn RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} roofit/roofit/rf617*.py)
935-
set(fixtureLists requires_numpy requires_numba requires_pandas requires_keras requires_xgboost requires_torch requires_sklearn)
936+
file(GLOB requires_tensorflow RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
937+
machine_learning/RBatchGenerator_TensorFlow.py
938+
)
939+
set(fixtureLists
940+
requires_keras
941+
requires_numba
942+
requires_numpy
943+
requires_pandas
944+
requires_sklearn
945+
requires_tensorflow
946+
requires_torch
947+
requires_xgboost
948+
)
936949

937950
# Now set up all the tests
938951
foreach(t ${pytutorials})

0 commit comments

Comments
 (0)