Modulus v22.03 Installation error on cluster

Hi:
I installed Nvidia Modulus v22.03 successfully on my laptop. However, when I was trying to install Nvidia Modulus v22.03 on a cluster with a Conda environment (no root). After installation, the job helmholtz.py cannot run with the following error, I wish to ask how to solve this:

Traceback (most recent call last):
File “/project/user/DL/anaconda3/envs/modulus2203/lib/python3.9/site-packages/modulus-22.3-py3.9.egg/modulus/distributed/manager.py”, line 124, in initialize
DistributedManager.initialize_env()
File “/project/user/DL/anaconda3/envs/modulus2203/lib/python3.9/site-packages/modulus-22.3-py3.9.egg/modulus/distributed/manager.py”, line 67, in initialize_env
rank = int(os.environ.get(“RANK”))
TypeError: int() argument must be a string, a bytes-like object or a number, not ‘NoneType’

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “/project/user/DL/modulus2203/examples/helmholtz/helmholtz.py”, line 95, in
run()
File “/project/user/DL/anaconda3/envs/modulus2203/lib/python3.9/site-packages/modulus-22.3-py3.9.egg/modulus/hydra/utils.py”, line 58, in func_decorated
DistributedManager.initialize()
File “/project/user/DL/anaconda3/envs/modulus2203/lib/python3.9/site-packages/modulus-22.3-py3.9.egg/modulus/distributed/manager.py”, line 127, in initialize
DistributedManager.initialize_slurm(port)
File “/project/user/DL/anaconda3/envs/modulus2203/lib/python3.9/site-packages/modulus-22.3-py3.9.egg/modulus/distributed/manager.py”, line 108, in initialize_slurm
DistributedManager.setup(
File “/project/user/DL/anaconda3/envs/modulus2203/lib/python3.9/site-packages/modulus-22.3-py3.9.egg/modulus/distributed/manager.py”, line 150, in setup
os.environ[“MASTER_ADDR”] = addr
File “/project/user/DL/anaconda3/envs/modulus2203/lib/python3.9/os.py”, line 684, in setitem
value = self.encodevalue(value)
File “/project/user/DL/anaconda3/envs/modulus2203/lib/python3.9/os.py”, line 756, in encode
raise TypeError(“str expected, not %s” % type(value). name )
TypeError: str expected, not NoneType

I got the same error months ago. See my previous posts. I am using Nvidia Modulus through a python venv not Conda. The problem is that the Hydra i.e. the configuration manager is not able to set some of the environment variables from the conda env, which is not a problem in python venv.

Just check for python --version. If the default python version is very old create an empty conda env and then use that env to create a python venv. please let me know if you need detailed instructions.