Skip to content

Commit 71cfb13

Browse files
install Rcpp and dfoptim locally in a folder Pt.2
1 parent 5c16d9b commit 71cfb13

File tree

2 files changed

+15
-7
lines changed

2 files changed

+15
-7
lines changed

BCN/BCNClassifier.py

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,13 @@
3939
)
4040
try:
4141
utils.install_packages(StrVector(packages_to_install))
42-
except Exception as e:
43-
subprocess.run(['mkdir', '-p', 'bcn_r'])
44-
utils.install_packages(StrVector(packages_to_install), lib_loc = StrVector(['bcn_r']))
42+
except Exception as e1:
43+
try:
44+
subprocess.run(['mkdir', '-p', 'bcn_r'])
45+
utils.install_packages(StrVector(packages_to_install), lib_loc = StrVector(['bcn_r']))
46+
except Exception as e2:
47+
pass
48+
4549
check_packages = True
4650

4751
base = importr("base")

BCN/BCNRegressor.py

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,14 @@
3838
)
3939
)
4040
try:
41-
utils.install_packages(StrVector(packages_to_install))
42-
except Exception as e:
43-
subprocess.run(['mkdir', '-p', 'bcn_r'])
44-
utils.install_packages(StrVector(packages_to_install), lib_loc = StrVector(['bcn_r']))
41+
utils.install_packages(StrVector(packages_to_install))
42+
except Exception as e1:
43+
try:
44+
subprocess.run(['mkdir', '-p', 'bcn_r'])
45+
utils.install_packages(StrVector(packages_to_install), lib_loc = StrVector(['bcn_r']))
46+
except Exception as e2:
47+
pass
48+
4549
check_packages = True
4650

4751
base = importr("base")

0 commit comments

Comments
 (0)