Giter Site home page Giter Site logo

Comments (8)

balakumar-s avatar balakumar-s commented on September 15, 2024

How did you install pytorch?

from curobo.

Shihao-Feng-98 avatar Shihao-Feng-98 commented on September 15, 2024

I installed using "pip install -e . --no-build-isolation" in a conda environment

from curobo.

balakumar-s avatar balakumar-s commented on September 15, 2024

Can you paste the terminal output for the tests?

from curobo.

Shihao-Feng-98 avatar Shihao-Feng-98 commented on September 15, 2024

I got the following output in terminal

============================================================================================= ERRORS =============================================================================================
____________________________________________________________________________ ERROR collecting tests/ik_config_test.py ____________________________________________________________________________
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/runner.py:341: in from_call
    result: Optional[TResult] = func()
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/runner.py:372: in <lambda>
    call = CallInfo.from_call(lambda: list(collector.collect()), "collect")
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/python.py:531: in collect
    self._inject_setup_module_fixture()
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/python.py:545: in _inject_setup_module_fixture
    self.obj, ("setUpModule", "setup_module")
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/python.py:310: in obj
    self._obj = obj = self._getobj()
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/python.py:528: in _getobj
    return self._importtestmodule()
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/python.py:617: in _importtestmodule
    mod = import_path(self.path, mode=importmode, root=self.config.rootpath)
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/pathlib.py:567: in import_path
    importlib.import_module(module_name)
../anaconda3/envs/rvbust/lib/python3.7/importlib/__init__.py:127: in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
<frozen importlib._bootstrap>:1006: in _gcd_import
    ???
<frozen importlib._bootstrap>:983: in _find_and_load
    ???
<frozen importlib._bootstrap>:967: in _find_and_load_unlocked
    ???
<frozen importlib._bootstrap>:677: in _load_unlocked
    ???
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/assertion/rewrite.py:186: in exec_module
    exec(co, module.__dict__)
tests/ik_config_test.py:134: in <module>
    (ik_base_config(), True),
tests/ik_config_test.py:36: in ik_base_config
    load_yaml(join_path(get_robot_configs_path(), robot_file))["robot_cfg"]
src/curobo/types/robot.py:49: in from_dict
    CudaRobotGeneratorConfig(**data_dict_in["kinematics"], tensor_args=tensor_args)
<string>:30: in __init__
    ???
src/curobo/cuda_robot_model/cuda_robot_generator.py:203: in __post_init__
    self.extra_links[k] = LinkParams.from_dict(self.extra_links[k])
src/curobo/cuda_robot_model/kinematics_parser.py:43: in from_dict
    Pose.from_list(dict_data["fixed_transform"], tensor_args=TensorDeviceType())
src/curobo/types/math.py:226: in from_list
    return Pose(position=position, quaternion=quaternion)
<string>:9: in __init__
    ???
src/curobo/types/math.py:83: in __post_init__
    self.quaternion = normalize_quaternion(self.quaternion)
E   RuntimeError: The following operation failed in the TorchScript interpreter.
E   Traceback of TorchScript (most recent call last):
E     File "/home/feng_shihao/curobo/src/curobo/types/math.py", line 521, in normalize_quaternion
E       k = torch.sign(in_quaternion[..., 0:1])
E       # NOTE: torch sign returns 0 as sign value when value is 0.0
E       k = torch.where(k == 0, 1.0, k)
E           ~~~~~~~~~~~ <--- HERE
E       k2 = k / torch.linalg.norm(in_quaternion, dim=-1, keepdim=True)
E       # normalize quaternion
E   RuntimeError: expected scalar type double but found float
_________________________________________________________________________ ERROR collecting tests/trajopt_config_test.py __________________________________________________________________________
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/runner.py:341: in from_call
    result: Optional[TResult] = func()
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/runner.py:372: in <lambda>
    call = CallInfo.from_call(lambda: list(collector.collect()), "collect")
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/python.py:531: in collect
    self._inject_setup_module_fixture()
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/python.py:545: in _inject_setup_module_fixture
    self.obj, ("setUpModule", "setup_module")
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/python.py:310: in obj
    self._obj = obj = self._getobj()
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/python.py:528: in _getobj
    return self._importtestmodule()
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/python.py:617: in _importtestmodule
    mod = import_path(self.path, mode=importmode, root=self.config.rootpath)
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/pathlib.py:567: in import_path
    importlib.import_module(module_name)
../anaconda3/envs/rvbust/lib/python3.7/importlib/__init__.py:127: in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
<frozen importlib._bootstrap>:1006: in _gcd_import
    ???
<frozen importlib._bootstrap>:983: in _find_and_load
    ???
<frozen importlib._bootstrap>:967: in _find_and_load_unlocked
    ???
<frozen importlib._bootstrap>:677: in _load_unlocked
    ???
../anaconda3/envs/rvbust/lib/python3.7/site-packages/_pytest/assertion/rewrite.py:186: in exec_module
    exec(co, module.__dict__)
tests/trajopt_config_test.py:115: in <module>
    (trajopt_base_config(), True),
tests/trajopt_config_test.py:31: in trajopt_base_config
    load_yaml(join_path(get_robot_configs_path(), robot_file))["robot_cfg"]
src/curobo/types/robot.py:49: in from_dict
    CudaRobotGeneratorConfig(**data_dict_in["kinematics"], tensor_args=tensor_args)
<string>:30: in __init__
    ???
src/curobo/cuda_robot_model/cuda_robot_generator.py:203: in __post_init__
    self.extra_links[k] = LinkParams.from_dict(self.extra_links[k])
src/curobo/cuda_robot_model/kinematics_parser.py:43: in from_dict
    Pose.from_list(dict_data["fixed_transform"], tensor_args=TensorDeviceType())
src/curobo/types/math.py:226: in from_list
    return Pose(position=position, quaternion=quaternion)
<string>:9: in __init__
    ???
src/curobo/types/math.py:83: in __post_init__
    self.quaternion = normalize_quaternion(self.quaternion)
E   RuntimeError: The following operation failed in the TorchScript interpreter.
E   Traceback of TorchScript (most recent call last):
E     File "/home/feng_shihao/curobo/src/curobo/types/math.py", line 521, in normalize_quaternion
E       k = torch.sign(in_quaternion[..., 0:1])
E       # NOTE: torch sign returns 0 as sign value when value is 0.0
E       k = torch.where(k == 0, 1.0, k)
E           ~~~~~~~~~~~ <--- HERE
E       k2 = k / torch.linalg.norm(in_quaternion, dim=-1, keepdim=True)
E       # normalize quaternion
E   RuntimeError: expected scalar type double but found float

from curobo.

balakumar-s avatar balakumar-s commented on September 15, 2024

Can you upgrade your pytorch to a newer version? Looks like this was an issue in pytorch that was fixed: pytorch/pytorch#64161

from curobo.

Shihao-Feng-98 avatar Shihao-Feng-98 commented on September 15, 2024

I upgraded pytorch to 1.12, and the above pytest error was fixed. And a new error about "ValueError: string is not a file: /home/feng_shihao/curobo/src/curobo/content/assets/scene/nvblox/srl_ur10_bins.obj" occured in pytest, does it mean the nvblox should installed?

from curobo.

balakumar-s avatar balakumar-s commented on September 15, 2024

That could mean that you don't have lfs installed.

Try this: #14 (comment)

from curobo.

balakumar-s avatar balakumar-s commented on September 15, 2024

Closing this issue assuming the issue was not having lfs installed.

from curobo.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.