Closed zengtaiping closed 1 year ago
Hello!
I think the problem might be because you need to configure the environment before launching JupyterLab.
Let's say your environment is called ros_env
where you already have jupyterlab
, jupyterlab-ros
, jupyterlab-urdf
and ros-noetic-desktop
. From a single terminal:
conda activate ros_env
jupyterlab-urdf/examples
folder. Inside you will find a src
directory so essentially examples/
is treated as a workspace.From examples/
catkin build
source devel/setup.bash
$ROS_PACKAGE_PATH
should now contain the paths to the robot descriptionsjupyter lab
Let me know if this works :)
Hi, @ihuicatl thanks for the quick reply.
My guess is there is a conflict between envs jupyterlab-urdf
and catkin source
.
When I reinstall jupyterlab-urdf
, the path becomes home/*/anaconda3/envs/robostackenv/share/
.
When I did catkin build
and source devel/setup.bash
, then I start jupyter lab
the jupyter urdf is not properly started.
It includes the mesh and ros path, but does not includejupyterlab-urdf
, e.g. /*/jupyterlab-urdf/examples/src/ned_description:/*/jupyterlab-urdf/examples/src/spot_description:/*/jupyterlab-urdf/examples/src/t12_description:/opt/ros/noetic/share
.
Then I manually used export ROS_PACKAGE_PATH to append the necessary path for both jupyter-urdf
and catkin
. It also did not work. It seems there are some other envs variables needed to be set.
I am looking forward to your reply.
Hi @zengtaiping!
I think the best idea would be to start with a fresh environment. Also, make sure there is nothing in your .bashrc file which could be modifying your ROS paths. Do you have noetic installed locally? It looks like one of your paths includes /opt/ros/noetic/share
ros_env
(or anything else) with the required packages. All of these packages need to be installed in the same environment.
conda create -n ros_env jupyterlab jupyterlab-urdf jupyterlab-ros ros-noetic-desktop -c conda-forge -c robostack
conda activate ros_env
$ROS_PACKAGE_PATH
. This should only contain home/*/anaconda3/envs/ros_env/share/
. If this is not correct, there may be an issue with the conda configuration.cd jupyterlab-urdf/examples/
catkin clean
catkin build
and run source devel/setup.bash
from the examples directoryAnd just to double check, make sure you are only working with a single conda environment since you mentioned there might be a conflict between environments.
Let me know how it goes.
Hi @ihuicatl ,
I am so sorry for the late response. Thanks so much for your detailed information. It works now.
I am sorry for the wrong click. Please close this issue.
Hi, thanks for a handy tool for URDF visualization. When I tried the example, I got the following errors:
[W 2022-08-13 18:46:09.980 ServerApp] 404 GET /ros/pkgs/t12_description/meshes/Body.STL (127.0.0.1) 24.62ms referer=http://localhost:8890/lab
How to properly configure the ROS environment to access mesh '*.stl'? After I install
jupyterlab-ros
andjupyterlab-urdf
(conda install jupyterlab-urdf -c conda-forge
), the path is changed and checked byecho $ROS_PACKAGE_PATH
. Even if I added the current catkin project to this variable, it also cannot access the mesh files.How could I change the folder
/ros/pkgs/
to the one I want to access?Thanks. Best.