modulus-sym icon indicating copy to clipboard operation
modulus-sym copied to clipboard

🐛[BUG]: unable to install due to type error

Open mlopez-ntop opened this issue 4 months ago • 0 comments

Version

1.7.0

On which installation method(s) does this occur?

No response

Describe the issue

When attempting to install the subprocess exits due to an error: TypeError: float() argument must be a string or a real number, not 'NoneType'

This issue occurs when installing from pypi or from source

Minimum reproducible example

To reproduce from source:

git clone [email protected]:NVIDIA/modulus-sym.git && cd modulus-sym

pip install --upgrade pip
pip install . 

Relevant log output

(modulus-sym) C:\dev\modulus-sym>pip install .
Processing c:\dev\modulus-sym
  Installing build dependencies ... done
  Getting requirements to build wheel ... error
  error: subprocess-exited-with-error

  × Getting requirements to build wheel did not run successfully.
  │ exit code: 1
  ╰─> [21 lines of output]
      C:\Users\<user_name>\AppData\Local\Temp\pip-build-env-igsxkvtb\overlay\Lib\site-packages\torch\_subclasses\functional_tensor.py:258: UserWarning: Failed to initialize NumPy: No module named 'numpy' (Triggered internally at C:\actions-runner\_work\pytorch\pytorch\builder\windows\pytorch\torch\csrc\utils\tensor_numpy.cpp:84.)
        cpu = _conversion_method_template(device=torch.device("cpu"))
      Traceback (most recent call last):
        File "C:\Users\<user_name>\miniconda3\envs\modulus-sym\Lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 353, in <module>
          main()
        File "C:\Users\<user_name>\miniconda3\envs\modulus-sym\Lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 335, in main
          json_out['return_val'] = hook(**hook_input['kwargs'])
                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "C:\Users\<user_name>\miniconda3\envs\modulus-sym\Lib\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 118, in get_requires_for_build_wheel
          return hook(config_settings)
                 ^^^^^^^^^^^^^^^^^^^^^
        File "C:\Users\<user_name>\AppData\Local\Temp\pip-build-env-igsxkvtb\overlay\Lib\site-packages\setuptools\build_meta.py", line 332, in get_requires_for_build_wheel
          return self._get_build_requires(config_settings, requirements=[])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "C:\Users\<user_name>\AppData\Local\Temp\pip-build-env-igsxkvtb\overlay\Lib\site-packages\setuptools\build_meta.py", line 302, in _get_build_requires
          self.run_setup()
        File "C:\Users\<user_name>\AppData\Local\Temp\pip-build-env-igsxkvtb\overlay\Lib\site-packages\setuptools\build_meta.py", line 318, in run_setup
          exec(code, locals())
        File "<string>", line 45, in <module>
        File "<string>", line 25, in cuda_extension
      TypeError: float() argument must be a string or a real number, not 'NoneType'
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.

Environment details

Install was attempted on Windows 10 in a python virtual env (anaconda) with python version 3.11.2. Prior to installing both torch and numpy were manually installed via pip. Additional attempts were made on a new virtual env using python 3.10.5 and outside of anaconda (python 3.10.5 as well)

Other/Misc.

No response

mlopez-ntop avatar Oct 09 '24 18:10 mlopez-ntop