Simplify jupyter notebooks and add way to use Debian packages
Signed-off-by: Christophe Bedard <bedard.christophe@gmail.com>
This commit is contained in:
parent
3fb2c697e4
commit
653d731d79
3 changed files with 30 additions and 21 deletions
|
@ -10,10 +10,7 @@
|
||||||
"#\n",
|
"#\n",
|
||||||
"# Get trace data using the provided launch file:\n",
|
"# Get trace data using the provided launch file:\n",
|
||||||
"# $ ros2 launch tracetools_analysis pingpong.launch.py\n",
|
"# $ ros2 launch tracetools_analysis pingpong.launch.py\n",
|
||||||
"# (wait a few seconds, then kill with Ctrl+C)\n",
|
"# (wait at least a few seconds, then kill with Ctrl+C)\n",
|
||||||
"#\n",
|
|
||||||
"# (optional) convert trace data:\n",
|
|
||||||
"# $ ros2 run tracetools_analysis convert ~/.ros/tracing/pingpong/ust\n",
|
|
||||||
"#\n",
|
"#\n",
|
||||||
"# OR\n",
|
"# OR\n",
|
||||||
"#\n",
|
"#\n",
|
||||||
|
@ -38,11 +35,16 @@
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"import sys\n",
|
"import sys\n",
|
||||||
"# Assuming a workspace with:\n",
|
"# Add paths to tracetools_analysis and tracetools_read.\n",
|
||||||
|
"# There are two options:\n",
|
||||||
|
"# 1. from source, assuming a workspace with:\n",
|
||||||
"# src/tracetools_analysis/\n",
|
"# src/tracetools_analysis/\n",
|
||||||
"# src/ros-tracing/ros2_tracing/tracetools_read/\n",
|
"# src/ros-tracing/ros2_tracing/tracetools_read/\n",
|
||||||
"sys.path.insert(0, '../')\n",
|
"sys.path.insert(0, '../')\n",
|
||||||
"sys.path.insert(0, '../../../ros-tracing/ros2_tracing/tracetools_read/')\n",
|
"sys.path.insert(0, '../../../ros-tracing/ros2_tracing/tracetools_read/')\n",
|
||||||
|
"# 2. from Debian packages, setting the right ROS 2 distro:\n",
|
||||||
|
"#ROS_DISTRO = 'rolling'\n",
|
||||||
|
"#sys.path.insert(0, f'/opt/ros/{ROS_DISTRO}/lib/python3.8/site-packages')\n",
|
||||||
"import datetime as dt\n",
|
"import datetime as dt\n",
|
||||||
"\n",
|
"\n",
|
||||||
"from bokeh.plotting import figure\n",
|
"from bokeh.plotting import figure\n",
|
||||||
|
@ -225,7 +227,7 @@
|
||||||
"name": "python",
|
"name": "python",
|
||||||
"nbconvert_exporter": "python",
|
"nbconvert_exporter": "python",
|
||||||
"pygments_lexer": "ipython3",
|
"pygments_lexer": "ipython3",
|
||||||
"version": "3.8.5"
|
"version": "3.8.10"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nbformat": 4,
|
"nbformat": 4,
|
||||||
|
|
|
@ -28,11 +28,16 @@
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"import sys\n",
|
"import sys\n",
|
||||||
"# Assuming a workspace with:\n",
|
"# Add paths to tracetools_analysis and tracetools_read.\n",
|
||||||
|
"# There are two options:\n",
|
||||||
|
"# 1. from source, assuming a workspace with:\n",
|
||||||
"# src/tracetools_analysis/\n",
|
"# src/tracetools_analysis/\n",
|
||||||
"# src/micro-ROS/ros_tracing/ros2_tracing/tracetools_read/\n",
|
"# src/ros-tracing/ros2_tracing/tracetools_read/\n",
|
||||||
"sys.path.insert(0, '../')\n",
|
"sys.path.insert(0, '../')\n",
|
||||||
"sys.path.insert(0, '../../../micro-ROS/ros_tracing/ros2_tracing/tracetools_read/')\n",
|
"sys.path.insert(0, '../../../ros-tracing/ros2_tracing/tracetools_read/')\n",
|
||||||
|
"# 2. from Debian packages, setting the right ROS 2 distro:\n",
|
||||||
|
"#ROS_DISTRO = 'rolling'\n",
|
||||||
|
"#sys.path.insert(0, f'/opt/ros/{ROS_DISTRO}/lib/python3.8/site-packages')\n",
|
||||||
"import datetime as dt\n",
|
"import datetime as dt\n",
|
||||||
"\n",
|
"\n",
|
||||||
"from bokeh.palettes import Category10\n",
|
"from bokeh.palettes import Category10\n",
|
||||||
|
@ -154,7 +159,7 @@
|
||||||
"name": "python",
|
"name": "python",
|
||||||
"nbconvert_exporter": "python",
|
"nbconvert_exporter": "python",
|
||||||
"pygments_lexer": "ipython3",
|
"pygments_lexer": "ipython3",
|
||||||
"version": "3.8.2"
|
"version": "3.8.10"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nbformat": 4,
|
"nbformat": 4,
|
||||||
|
|
|
@ -10,10 +10,7 @@
|
||||||
"#\n",
|
"#\n",
|
||||||
"# Get trace data using the provided launch file:\n",
|
"# Get trace data using the provided launch file:\n",
|
||||||
"# $ ros2 launch tracetools_analysis memory_usage.launch.py\n",
|
"# $ ros2 launch tracetools_analysis memory_usage.launch.py\n",
|
||||||
"# (wait a few seconds, then kill with Ctrl+C)\n",
|
"# (wait at least a few seconds, then kill with Ctrl+C)"
|
||||||
"#\n",
|
|
||||||
"# (optional) convert trace data:\n",
|
|
||||||
"# $ ros2 trace-analysis convert ~/.ros/tracing/memory-usage"
|
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -32,11 +29,16 @@
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"import sys\n",
|
"import sys\n",
|
||||||
"# Assuming a workspace with:\n",
|
"# Add paths to tracetools_analysis and tracetools_read.\n",
|
||||||
|
"# There are two options:\n",
|
||||||
|
"# 1. from source, assuming a workspace with:\n",
|
||||||
"# src/tracetools_analysis/\n",
|
"# src/tracetools_analysis/\n",
|
||||||
"# src/ros-tracing/ros2_tracing/tracetools_read/\n",
|
"# src/ros-tracing/ros2_tracing/tracetools_read/\n",
|
||||||
"sys.path.insert(0, '../')\n",
|
"sys.path.insert(0, '../')\n",
|
||||||
"sys.path.insert(0, '../../../ros-tracing/ros2_tracing/tracetools_read/')\n",
|
"sys.path.insert(0, '../../../ros-tracing/ros2_tracing/tracetools_read/')\n",
|
||||||
|
"# 2. from Debian packages, setting the right ROS 2 distro:\n",
|
||||||
|
"#ROS_DISTRO = 'rolling'\n",
|
||||||
|
"#sys.path.insert(0, f'/opt/ros/{ROS_DISTRO}/lib/python3.8/site-packages')\n",
|
||||||
"import datetime as dt\n",
|
"import datetime as dt\n",
|
||||||
"\n",
|
"\n",
|
||||||
"from bokeh.palettes import viridis\n",
|
"from bokeh.palettes import viridis\n",
|
||||||
|
@ -165,7 +167,7 @@
|
||||||
"name": "python",
|
"name": "python",
|
||||||
"nbconvert_exporter": "python",
|
"nbconvert_exporter": "python",
|
||||||
"pygments_lexer": "ipython3",
|
"pygments_lexer": "ipython3",
|
||||||
"version": "3.6.9"
|
"version": "3.8.10"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nbformat": 4,
|
"nbformat": 4,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue