Giter VIP home page Giter VIP logo

cartographer-read-pbstream's People

Contributors

meyerjo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

cartographer-read-pbstream's Issues

export all proto files to python failure

Running the command
find cartographer -name *.proto -printf "%P\n" -exec protoc -I=cartographer --python_out=python_out {} \;
The error is as follows
mapping/proto/submap.proto cartographer/mapping/proto/grid_2d.proto: File not found. cartographer/mapping/proto/hybrid_grid.proto: File not found. cartographer/transform/proto/transform.proto: File not found. mapping/proto/submap.proto:19:1: Import "cartographer/mapping/proto/grid_2d.proto" was not found or had errors. mapping/proto/submap.proto:20:1: Import "cartographer/mapping/proto/hybrid_grid.proto" was not found or had errors. mapping/proto/submap.proto:21:1: Import "cartographer/transform/proto/transform.proto" was not found or had errors.

Cannot import cartographer

Hi,

This is an amazing tool for python to read pbstream files. It could be very helpful.

However, I run into some problem while running the example main.py.

Error Output

Traceback (most recent call last):
  File "main.py", line 5, in <module>
    from pbstream.reader import PBstream_Reader
  File "<frozen zipimport>", line 259, in load_module
  File "/home/biomotion/.local/lib/python3.8/site-packages/pbstream-0.0.1-py3.8.egg/pbstream/reader.py", line 9, in <module>
ModuleNotFoundError: No module named 'cartographer'

My Installation Steps

  • export environment variable: export CARTOGRAPHER_PATH=/path/to/the/repo
  • execute the find command
  • running the install script with --user option as I don't have permission to system packages: python3.8 setup.py install --user

After the installation, an .egg file is created under my local user site-package (a.k.a ~/.local/lib/python3.8/site-packages/pbstream-0.0.1-py3.8.egg). Inside the .egg, there is only pbstream/ and EGG-INFO directories. I can't find the cartographer package while it did exists in the src/ of this repo. Is the setup.py missing any content for install the cartographer packages?

Here are my installation commands and full outputs:

user@ubuntu18-ee904:~/thirdparty/cartographer-read-pbstream$ find $CARTOGRAPHER_PATH -name *.proto -printf "%P\n" -exec protoc -I=$CARTOGRAPHER_PATH --python_out=src/ {} \;
cartographer/transform/proto/timestamped_transform.proto
cartographer/transform/proto/transform.proto
cartographer/mapping/proto/normal_estimation_options_2d.proto
cartographer/mapping/proto/trajectory_builder_options.proto
cartographer/mapping/proto/range_data_inserter_options.proto
cartographer/mapping/proto/motion_filter_options.proto
cartographer/mapping/proto/connected_components.proto
cartographer/mapping/proto/local_trajectory_builder_options_2d.proto
cartographer/mapping/proto/probability_grid.proto
cartographer/mapping/proto/pose_graph/constraint_builder_options.proto
cartographer/mapping/proto/pose_graph/optimization_problem_options.proto
cartographer/mapping/proto/range_data_inserter_options_3d.proto
cartographer/mapping/proto/grid_2d_options.proto
cartographer/mapping/proto/submaps_options_2d.proto
cartographer/mapping/proto/map_limits.proto
cartographer/mapping/proto/pose_graph.proto
cartographer/mapping/proto/local_trajectory_builder_options_3d.proto
cartographer/mapping/proto/submap.proto
cartographer/mapping/proto/trajectory_node_data.proto
cartographer/mapping/proto/map_builder_options.proto
cartographer/mapping/proto/cell_limits_2d.proto
cartographer/mapping/proto/submaps_options_3d.proto
cartographer/mapping/proto/scan_matching/ceres_scan_matcher_options_3d.proto
cartographer/mapping/proto/scan_matching/fast_correlative_scan_matcher_options_2d.proto
cartographer/mapping/proto/scan_matching/real_time_correlative_scan_matcher_options.proto
cartographer/mapping/proto/scan_matching/fast_correlative_scan_matcher_options_3d.proto
cartographer/mapping/proto/scan_matching/ceres_scan_matcher_options_2d.proto
cartographer/mapping/proto/pose_extrapolator_options.proto
cartographer/mapping/proto/tsdf_range_data_inserter_options_2d.proto
cartographer/mapping/proto/probability_grid_range_data_inserter_options_2d.proto
cartographer/mapping/proto/trajectory.proto
cartographer/mapping/proto/submap_visualization.proto
cartographer/mapping/proto/serialization.proto
cartographer/mapping/proto/pose_graph_options.proto
cartographer/mapping/proto/tsdf_2d.proto
cartographer/mapping/proto/grid_2d.proto
cartographer/mapping/proto/hybrid_grid.proto
cartographer/sensor/proto/sensor.proto
cartographer/sensor/proto/adaptive_voxel_filter_options.proto
cartographer/cloud/proto/map_builder_service.proto
cartographer/cloud/proto/map_builder_server_options.proto
cartographer/common/proto/ceres_solver_options.proto
cartographer/ground_truth/proto/relations.proto

user@ubuntu18-ee904:~/thirdparty/cartographer-read-pbstream$ python3.8 setup.py install --user
running install
running bdist_egg
running egg_info
creating src/pbstream.egg-info
writing src/pbstream.egg-info/PKG-INFO
writing dependency_links to src/pbstream.egg-info/dependency_links.txt
writing requirements to src/pbstream.egg-info/requires.txt
writing top-level names to src/pbstream.egg-info/top_level.txt
writing manifest file 'src/pbstream.egg-info/SOURCES.txt'
reading manifest file 'src/pbstream.egg-info/SOURCES.txt'
writing manifest file 'src/pbstream.egg-info/SOURCES.txt'
installing library code to build/bdist.linux-x86_64/egg
running install_lib
running build_py
creating build
creating build/lib
creating build/lib/pbstream
copying src/pbstream/reader.py -> build/lib/pbstream
copying src/pbstream/__init__.py -> build/lib/pbstream
creating build/bdist.linux-x86_64
creating build/bdist.linux-x86_64/egg
creating build/bdist.linux-x86_64/egg/pbstream
copying build/lib/pbstream/reader.py -> build/bdist.linux-x86_64/egg/pbstream
copying build/lib/pbstream/__init__.py -> build/bdist.linux-x86_64/egg/pbstream
byte-compiling build/bdist.linux-x86_64/egg/pbstream/reader.py to reader.cpython-38.pyc
byte-compiling build/bdist.linux-x86_64/egg/pbstream/__init__.py to __init__.cpython-38.pyc
creating build/bdist.linux-x86_64/egg/EGG-INFO
copying src/pbstream.egg-info/PKG-INFO -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/pbstream.egg-info/SOURCES.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/pbstream.egg-info/dependency_links.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/pbstream.egg-info/requires.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/pbstream.egg-info/top_level.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
zip_safe flag not set; analyzing archive contents...
creating dist
creating 'dist/pbstream-0.0.1-py3.8.egg' and adding 'build/bdist.linux-x86_64/egg' to it
removing 'build/bdist.linux-x86_64/egg' (and everything under it)
Processing pbstream-0.0.1-py3.8.egg
Copying pbstream-0.0.1-py3.8.egg to /home/biomotion/.local/lib/python3.8/site-packages
Adding pbstream 0.0.1 to easy-install.pth file

Installed /home/biomotion/.local/lib/python3.8/site-packages/pbstream-0.0.1-py3.8.egg
Processing dependencies for pbstream==0.0.1
Searching for protobuf>3.9
Reading https://pypi.org/simple/protobuf/
Downloading https://files.pythonhosted.org/packages/92/a3/b9b2714f079d0ab25cfcdc286c9c15b5462c7426bd6fc2938591e99edc2c/protobuf-4.21.1-py2.py3-none-any.whl#sha256=b309fda192850ac4184ca1777aab9655564bc8d10a9cc98f10e1c8bf11295c22
Best match: protobuf 4.21.1
Processing protobuf-4.21.1-py2.py3-none-any.whl
Installing protobuf-4.21.1-py2.py3-none-any.whl to /home/biomotion/.local/lib/python3.8/site-packages
Adding protobuf 4.21.1 to easy-install.pth file

Installed /home/biomotion/.local/lib/python3.8/site-packages/protobuf-4.21.1-py3.8.egg
Searching for setuptools>42
Reading https://pypi.org/simple/setuptools/
Downloading https://files.pythonhosted.org/packages/d0/12/412167a1f80290555c557a556fb1fc294a6e889924fcf2b2db3a789b11a4/setuptools-62.4.0-py3-none-any.whl#sha256=5a844ad6e190dccc67d6d7411d119c5152ce01f7c76be4d8a1eaa314501bba77
Best match: setuptools 62.4.0
Processing setuptools-62.4.0-py3-none-any.whl
Installing setuptools-62.4.0-py3-none-any.whl to /home/biomotion/.local/lib/python3.8/site-packages
writing requirements to /home/biomotion/.local/lib/python3.8/site-packages/setuptools-62.4.0-py3.8.egg/EGG-INFO/requires.txt
Adding setuptools 62.4.0 to easy-install.pth file

Installed /home/biomotion/.local/lib/python3.8/site-packages/setuptools-62.4.0-py3.8.egg
Finished processing dependencies for pbstream==0.0.1

My Environment

  • Python version: python3.8.0
  • Linux: Ubuntu 18.04 LTS
  • Cartographer version: master branch at commit b8228ee6564f5a7ad0d6d0b9a30516521cff2ee9
  • setuptools version: setuptools==62.4.0

Hope these information are enough for finding out the problem.
Thank you for creating this tool.

not sure how to setup

Greetings @meyerjo

I do not undestand the setup procedure. Am I supposed to clone Cartographer if I already possess Cartographer_ROS?

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.