Skip to content

Commit

Permalink
Merge pull request #61 from virtual-vehicle/tg_rosbags
Browse files Browse the repository at this point in the history
closes #56 and #2
  • Loading branch information
tgoelles authored Sep 27, 2022
2 parents ef93fc2 + d1a7e0a commit 8fefa9e
Show file tree
Hide file tree
Showing 20 changed files with 471 additions and 269 deletions.
2 changes: 1 addition & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"ms-azuretools.vscode-docker",
"streetsidesoftware.code-spell-checker",
"oderwat.indent-rainbow",
"littlefoxteam.vscode-python-test-adapter"
"GitHub.vscode-pull-request-github"
],
"forwardPorts": [
5920,
Expand Down
10 changes: 10 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,16 @@ and this project adheres to `Semantic Versioning <https://semver.org/spec/v2.0.0
Unreleased
-------------

Added
~~~~~~
- added version number to file metadata. If the native file format changes in the future.
- added tests for large ROS bagfiles

Changed
~~~~~~
- using rosbags as ROS library. This avoids the conflicts of the test explorer and dependency on some poorly maintained libraries.
- renamed CLI rosbagconvert to pointcloudset-convert since its specific for pointcloudset and not rosbag. Complete rewrite of CLI.

0.6.3 - (2022-06-08)
-------------

Expand Down
8 changes: 4 additions & 4 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ pointcloudset
.. image:: https://joss.theoj.org/papers/10.21105/joss.03471/status.svg
:target: https://joss.theoj.org/papers/10.21105/joss.03471#
:alt: JOSS badge

.. image:: https://img.shields.io/badge/code%20style-black-000000.svg
:target: https://github.com/psf/black
:alt: code style black
Expand Down Expand Up @@ -133,14 +133,14 @@ This produces the plot from the animation above.
.. _tutorial notebooks: https://github.com/virtual-vehicle/pointcloudset/tree/master/doc/sphinx/source/tutorial_notebooks


CLI to convert ROS bag files: rosbagconvert
CLI to convert ROS bag files: pointcloudset-convert
################################################

The package includes a powerfull CLI to convert ROS bag files into many formats like csv, las and many more.
The package includes a powerful CLI to convert ROS bag files into many formats like csv, las and many more.

.. code-block:: console
rosbagconvert --output-format csv --output-dir converted_csv test.bag
pointcloudset-convert --output-format csv --output-dir converted_csv test.bag
.. image:: https://raw.githubusercontent.com/virtual-vehicle/pointcloudset/master/images/cli_demo.gif
Expand Down
4 changes: 1 addition & 3 deletions conda/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,9 @@ dependencies:
- ipykernel
- nbconvert
- nbformat
- rospkg
- rosbags
- kaleido
- pyntcloud
- py3rosmsgs
- pycryptodomex
- setuptools
- blackcellmagic
- isort
Expand Down
12 changes: 4 additions & 8 deletions conda/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ source:
build:
number: 0
entry_points:
- rosbagconvert = pointcloudset.io.dataset.commandline:app
- pointcloudset-convert = pointcloudset.io.dataset.commandline:app
script: "{{ PYTHON }} -m pip install . -vv"

requirements:
Expand All @@ -24,11 +24,9 @@ requirements:
- pandas
- pip
- plotly
- py3rosmsgs
- pycryptodomex
- pyntcloud
- python
- rospkg
- rosbags
- rich
- typer
run:
Expand All @@ -38,11 +36,9 @@ requirements:
- open3d>=0.15.0
- pandas
- plotly
- py3rosmsgs
- pycryptodomex
- pyntcloud
- python
- rospkg
- rosbags
- rich
- typer

Expand All @@ -58,7 +54,7 @@ test:
- pointcloudset.pipeline
- pointcloudset.plot
commands:
- rosbagconvert --help
- pointcloudset-convert --help

about:
home: https://virtual-vehicle.github.io/pointcloudset/
Expand Down
8 changes: 4 additions & 4 deletions doc/sphinx/source/commandline_interface.rst
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
rosbagconvert
pointcloudset-convert
======================

The best way to work with large ROS bagfiles is to convert the rosbag beforehand with
Expand All @@ -25,12 +25,12 @@ the converted directory.

.. code-block:: console
rosbagconvert test.bag -t /os1_cloud_node/points -d converted
pointcloudset-convert test.bag -t /os1_cloud_node/points -d converted
.. click:: pointcloudset.io.dataset.commandline:typer_click_object
:prog: rosbagconvert
:prog: pointcloudset-convert
:nested: full

rosbagconvert . -d converted -o csv
pointcloudset-convert . -d converted -o csv
3 changes: 1 addition & 2 deletions docker/base.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,7 @@ RUN apt-get update && \
COPY conda/environment.yml* /tmp/conda-tmp/
RUN /opt/conda/bin/conda env update -n base -f /tmp/conda-tmp/environment.yml

# ROSPY loggging configuation file
COPY docker/python_logging.conf /etc/ros/

# Switch back to dialog for any ad-hoc use of apt-get
ENV DEBIAN_FRONTEND=noninteractive
ENV SHELL /bin/bash
Expand Down
53 changes: 0 additions & 53 deletions docker/python_logging.conf

This file was deleted.

Binary file modified images/cli_demo.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion pointcloudset/dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ def __getitem__(
@classmethod
def from_file(cls, file_path: Path, **kwargs):
"""Reads a Dataset from a file.
For larger ROS bagfiles files use the commandline tool rosbagconvert to convert the ROS bagfile
For larger ROS bagfiles files use the commandline tool pointcloudset-convert to convert the ROS bagfile
beforehand.
Supported are the native format which is a directore filled with fastparquet frames and
Expand Down
7 changes: 4 additions & 3 deletions pointcloudset/io/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@
Functions for file input and output.
"""

from pyntcloud.io import \
FROM_FILE as POINTCLOUD_FROM_FILE # needs to be here, ignore warnings
from pyntcloud.io import (
FROM_FILE as POINTCLOUD_FROM_FILE,
) # needs to be here, ignore warnings

from pointcloudset.io.dataset.bag import dataset_from_rosbag
from pointcloudset.io.dataset.rosbag import dataset_from_rosbag
from pointcloudset.io.dataset.dir import dataset_from_dir, dataset_to_dir
from pointcloudset.io.dataset.pointcloud import dataset_from_pointclouds
from pointcloudset.io.pointcloud.csv import write_csv
Expand Down
153 changes: 0 additions & 153 deletions pointcloudset/io/dataset/bag.py

This file was deleted.

Loading

0 comments on commit 8fefa9e

Please sign in to comment.