compas-dev / compas-dev/compas_fab

trouble scaling from meters to millimeters (+ other related issues when loading scene)

Open
#192 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
137
Forks
47
PR merge metrics
No merged PRs in 30d

Description

### **Describe the bug**
> Scaling of a robot from meters to millimeters does not seem to work properly
> There are other aspects of the setup not loading properly that may be related

### **To Reproduce**
grasshopper file including geometry inputs in meters and millimeters

**when in m:**
* robot loads fine from urdfs or from ROS
* collision mesh can be loaded only if loading robot directly from urdf

**when in mm:**
* robot loads fine from ROS if switching unit in gh file, but setup is different from meters setup

mm:
![ScreenHunter 68](https://user-images.githubusercontent.com/9400811/90762924-23406680-e2e6-11ea-8c28-ebba3b075c5e.png)
m:
![ScreenHunter 67](https://user-images.githubusercontent.com/9400811/90763206-8df1a200-e2e6-11ea-8f20-bd0133b77358.png)

* robot fails to load directly from the urdfs
* collision mesh cannot be loaded:
```Runtime error (PythonException): This method is only callable once a client is assigned

Traceback:
line 7, in script
line 111, in ensure_client, "C:\Users\Ines\AppData\Roaming\McNeel\Rhinoceros\6.0\Plug-ins\IronPython (814d908a-e25c-493d-97e9-ee3861957f49)\settings\lib\compas_fab\robots\planning_scene.py"
line 139, in add_collision_mesh, "C:\Users\Ines\AppData\Roaming\McNeel\Rhinoceros\6.0\Plug-ins\IronPython (814d908a-e25c-493d-97e9-ee3861957f49)\settings\lib\compas_fab\robots\planning_scene.py"
```
* calculated path is not located where the geometry input is located, it is sort of moved the distance from the urdf model location:
![ScreenHunter 65](https://user-images.githubusercontent.com/9400811/90763754-8b437c80-e2e7-11ea-8df9-7e04dee19f01.png)

### **Expected behavior**
either:
* load from ROS in mm (working but with a different setup) + be able to load collision meshes (not working in mm)
or:
* load directly from an urdf in mm

but I am not sure I understand the implications of loading from ROS or urdfs, what is more practical, etc.

thank you!!

**Desktop (please complete the following information):**
- OS: `Windows 10`
- Python version `3.7`
- Python package manager `conda`

[waam_setup_m_mm.zip](https://github.com/compas-dev/compas_fab/files/5102655/waam_setup_m_mm.zip)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.