Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash during splitting with plys written from cartographer_ros #389

Closed
erikreed opened this issue Nov 19, 2019 · 2 comments
Closed

Crash during splitting with plys written from cartographer_ros #389

erikreed opened this issue Nov 19, 2019 · 2 comments

Comments

@erikreed
Copy link

@erikreed erikreed commented Nov 19, 2019

I seem to be crashing on plys written from cartographer_ros -- I'm not sure whether the bug is with the ply_writer from that repo or the parsing of the ply from this one. I think the latter since I am able to open the ply generated from cartographer_ros in Meshlab.

My current solution is loading the ply in Meshlab and re-exporting it. After that I am able to run build_octree successfully.

Stack trace:

$ RUST_BACKTRACE=1 ./target/debug/build_octree SNIP --output_directory SNIP --num_threads 12
Determining bounding box: 42624301 / 42624301 [===============================] 100.00 % 965727.77/s Creating octree structure.
Splitting r which has 42624301 points (426.24x MAX_POINTS_PER_NODE).
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: Error(NodeNotFound, State { next_error: None, backtrace: InternalBacktrace { backtrace: Some(stack backtrace:
   0: error_chain::backtrace::imp::InternalBacktrace::new
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/error-chain-0.12.1/src/backtrace.rs:56
   1: <error_chain::State as core::default::Default>::default
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/error-chain-0.12.1/src/lib.rs:671
   2: point_viewer::errors::Error::from_kind
             at <::error_chain::error_chain::impl_error_chain_processed macros>:72
   3: <point_viewer::errors::Error as core::convert::From<point_viewer::errors::ErrorKind>>::from
             at src/errors.rs:18
   4: <T as core::convert::Into<U>>::into
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libcore/convert.rs:547
   5: point_viewer::data_provider::on_disk::OnDiskDataProvider::number_of_points
             at src/data_provider/on_disk.rs:27
   6: point_viewer::octree::generation::split_node::{{closure}}
             at src/octree/generation.rs:178
   7: scoped_pool::Scope::recurse::{{closure}}
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:316
   8: <F as scoped_pool::Task>::run
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:509
   9: scoped_pool::Pool::run_thread
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:185
  10: scoped_pool::Pool::expand::{{closure}}
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:160
  11: std::sys_common::backtrace::__rust_begin_short_backtrace
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/sys_common/backtrace.rs:126
  12: std::thread::Builder::spawn_unchecked::{{closure}}::{{closure}}
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/thread/mod.rs:470
  13: <std::panic::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/panic.rs:315
  14: std::panicking::try::do_call
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/panicking.rs:292
  15: __rust_maybe_catch_panic
             at src/libpanic_unwind/lib.rs:80
  16: std::panicking::try
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/panicking.rs:271
  17: std::panic::catch_unwind
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/panic.rs:394
  18: std::thread::Builder::spawn_unchecked::{{closure}}
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/thread/mod.rs:469
  19: core::ops::function::FnOnce::call_once{{vtable.shim}}
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libcore/ops/function.rs:227
  20: <alloc::boxed::Box<F> as core::ops::function::FnOnce<A>>::call_once
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/liballoc/boxed.rs:922
  21: <alloc::boxed::Box<F> as core::ops::function::FnOnce<A>>::call_once
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/liballoc/boxed.rs:922
      std::sys_common::thread::start_thread
             at src/libstd/sys_common/thread.rs:13
      std::sys::unix::thread::Thread::new::thread_start
             at src/libstd/sys/unix/thread.rs:79
  22: start_thread
  23: __clone
) } })', src/libcore/result.rs:1165:5
stack backtrace:
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: Error(NodeNotFound, State { next_error: None, backtrace: InternalBacktrace { backtrace: Some(stack backtrace:
   0: error_chain::backtrace::imp::InternalBacktrace::new
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/error-chain-0.12.1/src/backtrace.rs:56
   1: <error_chain::State as core::default::Default>::default
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/error-chain-0.12.1/src/lib.rs:671
   2: point_viewer::errors::Error::from_kind
             at <::error_chain::error_chain::impl_error_chain_processed macros>:72
   3: <point_viewer::errors::Error as core::convert::From<point_viewer::errors::ErrorKind>>::from
             at src/errors.rs:18
   4: <T as core::convert::Into<U>>::into
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libcore/convert.rs:547
   5: point_viewer::data_provider::on_disk::OnDiskDataProvider::number_of_points
             at src/data_provider/on_disk.rs:27
   6: point_viewer::octree::generation::split_node::{{closure}}
             at src/octree/generation.rs:178
   7: scoped_pool::Scope::recurse::{{closure}}
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:316
   8: <F as scoped_pool::Task>::run
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:509
   9: scoped_pool::Pool::run_thread
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:185
  10: scoped_pool::Pool::expand::{{closure}}
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:160
  11: std::sys_common::backtrace::__rust_begin_short_backtrace
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/sys_common/backtrace.rs:126
  12: std::thread::Builder::spawn_unchecked::{{closure}}::{{closure}}
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/thread/mod.rs:470
  13: <std::panic::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/panic.rs:315
  14: std::panicking::try::do_call
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/panicking.rs:292
  15: __rust_maybe_catch_panic
             at src/libpanic_unwind/lib.rs:80
  16: std::panicking::try
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/panicking.rs:271
  17: std::panic::catch_unwind
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/panic.rs:394
  18: std::thread::Builder::spawn_unchecked::{{closure}}
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/thread/mod.rs:469
  19: core::ops::function::FnOnce::call_once{{vtable.shim}}
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libcore/ops/function.rs:227
  20: <alloc::boxed::Box<F> as core::ops::function::FnOnce<A>>::call_once
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/liballoc/boxed.rs:922
  21: <alloc::boxed::Box<F> as core::ops::function::FnOnce<A>>::call_once
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/liballoc/boxed.rs:922
      std::sys_common::thread::start_thread
             at src/libstd/sys_common/thread.rs:13
      std::sys::unix::thread::Thread::new::thread_start
             at src/libstd/sys/unix/thread.rs:79
  22: start_thread
  23: __clone
) } })', src/libcore/result.rs:1165:5
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: Error(NodeNotFound, State { next_error: None, backtrace: InternalBacktrace { backtrace: Some(stack backtrace:
   0: error_chain::backtrace::imp::InternalBacktrace::new
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/error-chain-0.12.1/src/backtrace.rs:56
   1: <error_chain::State as core::default::Default>::default
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/error-chain-0.12.1/src/lib.rs:671
   2: point_viewer::errors::Error::from_kind
             at <::error_chain::error_chain::impl_error_chain_processed macros>:72
   3: <point_viewer::errors::Error as core::convert::From<point_viewer::errors::ErrorKind>>::from
             at src/errors.rs:18
   4: <T as core::convert::Into<U>>::into
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libcore/convert.rs:547
   5: point_viewer::data_provider::on_disk::OnDiskDataProvider::number_of_points
             at src/data_provider/on_disk.rs:27
   6: point_viewer::octree::generation::split_node::{{closure}}
             at src/octree/generation.rs:178
   7: scoped_pool::Scope::recurse::{{closure}}
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:316
   8: <F as scoped_pool::Task>::run
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:509
   9: scoped_pool::Pool::run_thread
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:185
  10: scoped_pool::Pool::expand::{{closure}}
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:160
  11: std::sys_common::backtrace::__rust_begin_short_backtrace
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/sys_common/backtrace.rs:126
  12: std::thread::Builder::spawn_unchecked::{{closure}}::{{closure}}
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/thread/mod.rs:470
  13: <std::panic::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/panic.rs:315
  14: std::panicking::try::do_call
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/panicking.rs:292
  15: __rust_maybe_catch_panic
             at src/libpanic_unwind/lib.rs:80
  16: std::panicking::try
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/panicking.rs:271
  17: std::panic::catch_unwind
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/panic.rs:394
  18: std::thread::Builder::spawn_unchecked::{{closure}}
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/thread/mod.rs:469
  19: core::ops::function::FnOnce::call_once{{vtable.shim}}
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libcore/ops/function.rs:227
  20: <alloc::boxed::Box<F> as core::ops::function::FnOnce<A>>::call_once
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/liballoc/boxed.rs:922
  21: <alloc::boxed::Box<F> as core::ops::function::FnOnce<A>>::call_once
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/liballoc/boxed.rs:922
      std::sys_common::thread::start_thread
             at src/libstd/sys_common/thread.rs:13
      std::sys::unix::thread::Thread::new::thread_start
             at src/libstd/sys/unix/thread.rs:79
  22: start_thread
  23: __clone
) } })', src/libcore/result.rs:1165:5
   0: backtrace::backtrace::libunwind::trace
             at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.37/src/backtrace/libunwind.rs:88
   1: backtrace::backtrace::trace_unsynchronized
             at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.37/src/backtrace/mod.rs:66
   2: std::sys_common::backtrace::_print_fmt
             at src/libstd/sys_common/backtrace.rs:76
   3: <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt
             at src/libstd/sys_common/backtrace.rs:60
   4: core::fmt::write
             at src/libcore/fmt/mod.rs:1030
   5: std::io::Write::write_fmt
             at src/libstd/io/mod.rs:1412
   6: std::sys_common::backtrace::_print
             at src/libstd/sys_common/backtrace.rs:64
   7: std::sys_common::backtrace::print
             at src/libstd/sys_common/backtrace.rs:49
   8: std::panicking::default_hook::{{closure}}
             at src/libstd/panicking.rs:196
   9: std::panicking::default_hook
             at src/libstd/panicking.rs:210
  10: std::panicking::rust_panic_with_hook
             at src/libstd/panicking.rs:473
  11: std::panicking::continue_panic_fmt
             at src/libstd/panicking.rs:380
  12: rust_begin_unwind
             at src/libstd/panicking.rs:307
  13: core::panicking::panic_fmt
             at src/libcore/panicking.rs:85
  14: core::result::unwrap_failed
             at src/libcore/result.rs:1165
  15: core::result::Result<T,E>::unwrap
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libcore/result.rs:933
  16: point_viewer::octree::generation::split_node::{{closure}}
             at ./src/octree/generation.rs:178
  17: scoped_pool::Scope::recurse::{{closure}}
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:316
  18: <F as scoped_pool::Task>::run
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:509
  19: scoped_pool::Pool::run_thread
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:185
  20: scoped_pool::Pool::expand::{{closure}}
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:160
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
stack backtrace:
   0: backtrace::backtrace::libunwind::trace
             at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.37/src/backtrace/libunwind.rs:88
   1: backtrace::backtrace::trace_unsynchronized
             at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.37/src/backtrace/mod.rs:66
   2: std::sys_common::backtrace::_print_fmt
             at src/libstd/sys_common/backtrace.rs:76
   3: <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt
             at src/libstd/sys_common/backtrace.rs:60
   4: core::fmt::write
             at src/libcore/fmt/mod.rs:1030
   5: std::io::Write::write_fmt
             at src/libstd/io/mod.rs:1412
   6: std::sys_common::backtrace::_print
             at src/libstd/sys_common/backtrace.rs:64
   7: std::sys_common::backtrace::print
             at src/libstd/sys_common/backtrace.rs:49
   8: std::panicking::default_hook::{{closure}}
             at src/libstd/panicking.rs:196
   9: std::panicking::default_hook
             at src/libstd/panicking.rs:210
  10: std::panicking::rust_panic_with_hook
             at src/libstd/panicking.rs:473
  11: std::panicking::continue_panic_fmt
             at src/libstd/panicking.rs:380
  12: rust_begin_unwind
             at src/libstd/panicking.rs:307
  13: core::panicking::panic_fmt
             at src/libcore/panicking.rs:85
  14: core::result::unwrap_failed
             at src/libcore/result.rs:1165
  15: core::result::Result<T,E>::unwrap
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libcore/result.rs:933
  16: point_viewer::octree::generation::split_node::{{closure}}
             at ./src/octree/generation.rs:178
  17: scoped_pool::Scope::recurse::{{closure}}
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:316
  18: <F as scoped_pool::Task>::run
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:509
  19: scoped_pool::Pool::run_thread
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:185
  20: scoped_pool::Pool::expand::{{closure}}
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:160
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
stack backtrace:
   0: backtrace::backtrace::libunwind::trace
             at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.37/src/backtrace/libunwind.rs:88
   1: backtrace::backtrace::trace_unsynchronized
             at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.37/src/backtrace/mod.rs:66
   2: std::sys_common::backtrace::_print_fmt
             at src/libstd/sys_common/backtrace.rs:76
   3: <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt
             at src/libstd/sys_common/backtrace.rs:60
   4: core::fmt::write
             at src/libcore/fmt/mod.rs:1030
   5: std::io::Write::write_fmt
             at src/libstd/io/mod.rs:1412
   6: std::sys_common::backtrace::_print
             at src/libstd/sys_common/backtrace.rs:64
   7: std::sys_common::backtrace::print
             at src/libstd/sys_common/backtrace.rs:49
   8: std::panicking::default_hook::{{closure}}
             at src/libstd/panicking.rs:196
   9: std::panicking::default_hook
             at src/libstd/panicking.rs:210
  10: std::panicking::rust_panic_with_hook
             at src/libstd/panicking.rs:473
  11: std::panicking::continue_panic_fmt
             at src/libstd/panicking.rs:380
  12: rust_begin_unwind
             at src/libstd/panicking.rs:307
  13: core::panicking::panic_fmt
             at src/libcore/panicking.rs:85
  14: core::result::unwrap_failed
             at src/libcore/result.rs:1165
  15: core::result::Result<T,E>::unwrap
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libcore/result.rs:933
  16: point_viewer::octree::generation::split_node::{{closure}}
             at ./src/octree/generation.rs:178
  17: scoped_pool::Scope::recurse::{{closure}}
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:316
  18: <F as scoped_pool::Task>::run
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:509
  19: scoped_pool::Pool::run_thread
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:185
  20: scoped_pool::Pool::expand::{{closure}}
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:160
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
thread 'main' panicked at 'WaitGroup explicitly poisoned!', /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:457:13
stack backtrace:
   0: backtrace::backtrace::libunwind::trace
             at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.37/src/backtrace/libunwind.rs:88
   1: backtrace::backtrace::trace_unsynchronized
             at /cargo/registry/src/github.com-1ecc6299db9ec823/backtrace-0.3.37/src/backtrace/mod.rs:66
   2: std::sys_common::backtrace::_print_fmt
             at src/libstd/sys_common/backtrace.rs:76
   3: <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt
             at src/libstd/sys_common/backtrace.rs:60
   4: core::fmt::write
             at src/libcore/fmt/mod.rs:1030
   5: std::io::Write::write_fmt
             at src/libstd/io/mod.rs:1412
   6: std::sys_common::backtrace::_print
             at src/libstd/sys_common/backtrace.rs:64
   7: std::sys_common::backtrace::print
             at src/libstd/sys_common/backtrace.rs:49
   8: std::panicking::default_hook::{{closure}}
             at src/libstd/panicking.rs:196
   9: std::panicking::default_hook
             at src/libstd/panicking.rs:210
  10: std::panicking::rust_panic_with_hook
             at src/libstd/panicking.rs:473
  11: std::panicking::begin_panic
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/panicking.rs:407
  12: scoped_pool::WaitGroup::join
             at ./<::std::macros::panic macros>:3
  13: scoped_pool::Scope::join
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:341
  14: scoped_pool::Scope::zoom::{{closure}}
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:328
  15: <scopeguard::Guard<T,F> as core::ops::drop::Drop>::drop
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scopeguard-0.1.2/src/lib.rs:63
  16: core::ptr::real_drop_in_place
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libcore/ptr/mod.rs:175
  17: scoped_pool::Scope::zoom
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:332
  18: scoped_pool::Pool::scoped
             at /home/erik/.cargo/registry/src/github.com-1ecc6299db9ec823/scoped-pool-1.0.0/src/lib.rs:117
  19: point_viewer::octree::generation::build_octree
             at ./src/octree/generation.rs:328
  20: point_viewer::octree::generation::build_octree_from_file
             at ./src/octree/generation.rs:290
  21: build_octree::main
             at src/bin/build_octree.rs:43
  22: std::rt::lang_start::{{closure}}
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/rt.rs:64
  23: std::rt::lang_start_internal::{{closure}}
             at src/libstd/rt.rs:49
  24: std::panicking::try::do_call
             at src/libstd/panicking.rs:292
  25: __rust_maybe_catch_panic
             at src/libpanic_unwind/lib.rs:80
  26: std::panicking::try
             at src/libstd/panicking.rs:271
  27: std::panic::catch_unwind
             at src/libstd/panic.rs:394
  28: std::rt::lang_start_internal
             at src/libstd/rt.rs:48
  29: std::rt::lang_start
             at /rustc/4560ea788cb760f0a34127156c78e2552949f734/src/libstd/rt.rs:64
  30: main
  31: __libc_start_main
  32: _start
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.

Maybe relevant versions:

@feuerste

This comment has been minimized.

Copy link
Contributor

@feuerste feuerste commented Nov 19, 2019

Hi @erikreed
Your ply doesn't have color information:

$ head failing.ply
ply
format binary_little_endian 1.0
comment generated by Cartographer
element vertex 000000042624301
property float x
property float y
property float z
property float intensity
end_header

build_octree assumes to have rgb values set. Is there an option in cartographer_ros to output rgb colors?

@erikreed

This comment has been minimized.

Copy link
Author

@erikreed erikreed commented Nov 19, 2019

Ah much appreciated, that explains it. The cartographer_ros docs do suggest colorizing the output but I wasn't aware it was a requirement for building the octree.

I colored by intensity and am able to build the octree successfully. The new header is:

$ head working.ply
ply
format binary_little_endian 1.0
comment generated by Cartographer
element vertex 000000042624301
property float x
property float y
property float z
property uchar red
property uchar green
property uchar blue

Cheers!

@erikreed erikreed closed this Nov 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.