Skip to contents

Function for installing the necessary python modules

Usage

install_py_modules(
  envname = "aifeducation",
  install = "pytorch",
  tf_version = "2.15",
  pytorch_cuda_version = "12.1",
  python_version = "3.9",
  remove_first = FALSE,
  cpu_only = FALSE
)

Arguments

envname

string Name of the environment where the packages should be installed.

install

character determining which machine learning frameworks should be installed. install="all" for 'pytorch' and 'tensorflow'. install="pytorch" for 'pytorch', and install="tensorflow" for 'tensorflow'.

tf_version

string determining the desired version of 'tensorflow'.

pytorch_cuda_version

string determining the desired version of 'cuda' for 'PyTorch'.

python_version

string Python version to use.

remove_first

bool If TRUE removes the environment completely before recreating the environment and installing the packages. If FALSE the packages are installed in the existing environment without any prior changes.

cpu_only

bool TRUE installs the cpu only version of the machine learning frameworks.

Value

Returns no values or objects. Function is used for installing the necessary python libraries in a conda environment.