You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$ ./build/img/wcdoctest-img -tc='clustering point tree'
[doctest] doctest version is "2.4.11"
[doctest] run with "--help" for options
===============================================================================
../img/test/doctest_clustering_prototype.cxx:111:
TEST CASE: clustering point tree
../img/test/doctest_clustering_prototype.cxx:111: ERROR: test case THREW exception: ../util/inc/WireCellUtil/Exceptions.h(58): Throw in function raise<WireCell::ValueError, long unsigned int, long unsigned int>
Dynamic exception type: boost::wrapexcept<WireCell::ValueError>
[tag_stacktrace*] = 0# void WireCell::raise<WireCell::ValueError, unsigned long, unsigned long>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, unsigned long, unsigned long) at ../util/inc/WireCellUtil/Exceptions.h:58
1# void print_dds<std::vector<std::reference_wrapper<WireCell::PointCloud::Dataset>, std::allocator<std::reference_wrapper<WireCell::PointCloud::Dataset> > > >(std::vector<std::reference_wrapper<WireCell::PointCloud::Dataset>, std::allocator<std::reference_wrapper<WireCell::PointCloud::Dataset> > > const&) at ../img/test/doctest_clustering_prototype.cxx:30
2# DOCTEST_ANON_FUNC_2() at ../img/test/doctest_clustering_prototype.cxx:150
3# doctest::Context::run() at ../util/inc/WireCellUtil/doctest.h:7008
4# main at img/wcdoctest-img.cxx:14
5# __libc_start_call_main at ../sysdeps/nptl/libc_start_call_main.h:74
6# __libc_start_main at ../csu/libc-start.c:347
7# _start in ./build/img/wcdoctest-img
[WireCell::tag_errmsg*] = element size mismatch 8 != 4
$ gdb --args ./build/img/wcdoctest-img -tc=clustering point tree
(gdb) catch throw
(gdb) r
(gdb) c
(gdb) where
(gdb) up
(gdb) up
(gdb) up
(gdb) up
(gdb) up
#5 print_dds<std::vector<std::reference_wrapper<WireCell::PointCloud::Dataset>, std::allocator<std::reference_wrapper<WireCell::PointCloud::Dataset> > > > (dds=std::vector of length 2, capacity 2 = {...}) at ../img/test/doctest_clustering_prototype.cxx:31
31 auto arr = ds.get(key)->elements<fa_float_t>();
(gdb) p key
$1 = "uwire_index"
At the top of doctest_clustering_prototype.cxx is:
voidprint_dds(const DisjointDataset& dds) {
for (size_t idx=0; idx<dds.size(); ++idx) {
const Dataset& ds = dds[idx];
std::stringstream ss;
ss << "ds: " << idx << std::endl;
// const size_t len = ds.size_major();for (constauto& key : ds.keys()) {
auto arr = ds.get(key)->elements<fa_float_t>();
So, the particular point cloud keys span values of at least types int and double. Calling elements<T> with the same type is bound to fail.
The text was updated successfully, but these errors were encountered:
Note, this issue was made prior to me merging in your latest apply-pointcloud work. The problem still exists now that this test has moved to its new sub-package:
$ ./build/clus/wcdoctest-clus -tc='clustering point tree'
Hi Brett, thanks for making the issue. I noticed the same thing last night. And temporarily disabled the print_dds in 86de40e. Will think about how to fix it. I think it is probably OK to remove that print_dds since no checks are based on it. The main reason for that was to help me understand the disjoint_rang/dataset.
Running
At the top of
doctest_clustering_prototype.cxx
is:So, the particular point cloud keys span values of at least types
int
anddouble
. Callingelements<T>
with the same type is bound to fail.The text was updated successfully, but these errors were encountered: