For experiments, we generally use the REDUCED_MODEL_SET which has
15 models. At that order, you should definitely not exceed 7Gb.
When trying more than 30 models though we ran into similar
problems, like Peter mentioned.
For the next release we are hoping to provide a remote service
running on one of our own machines that will have many models
already loaded in memory, but that is still in the works and
probably won't be out for another couple of weeks at earliest...
Thanks for your answer, I'll look into that and try to build
a subset of the models.
By the way, it seems to be taking a lot more than 2Gb (I
tried to load it and it took more than 7Gb (and then
crashed)).
Cheers,
Ugo
On 05/12/10 00:26, Peter Brook wrote:
Hey Ugo,
In my experience with the
tabletop_object_detector, the memory usage can be
quite bad. The usage depends on the number of models
in the model_set, but I have seen the node use over
2GB of memory.
You can change the number of models being loaded
by creating a new model set with fewer models than
the default one. Since you have your own local copy
of the database, take a look at the model_set table
of household_objects_database.
I'm trying to use the tabletop_object_detector.
It works fine when I'm
setting use_database to false.
The problem I have is when I'm trying to use the
database: I installed a
local copy of the household_objects_database.
The
household_objects_database node seems to be
working fine. However, when
I start the
tabletop_object_detector/tabletop_node, the node
crashes
while loading the models (it loads lots of
models before crashing).
Any idea ?
I also had an other quick question: how much RAM
does the tabletop_node
need to load the database? With 4Gb I'm swapping
constantly.
You can find the backtrace below.
Cheers,
Ugo
[ INFO] [1291308286.662052341]: Loaded
database model with id 18737
[ INFO] [1291308289.346903337]: Loaded
database model with id 18736
terminate called after throwing an instance of
'std::bad_alloc'
what(): std::bad_alloc
Program received signal SIGABRT, Aborted.
0xb7fe2430 in __kernel_vsyscall ()
(gdb) backtrace
#0 0xb7fe2430 in __kernel_vsyscall ()
#1 0xb7238651 in raise () from
/lib/tls/i686/cmov/libc.so.6
#2 0xb723ba82 in abort () from
/lib/tls/i686/cmov/libc.so.6
#3 0xb748552f in
__gnu_cxx::__verbose_terminate_handler() ()
from /usr/lib/libstdc++.so.6
#4 0xb7483465 in ?? () from
/usr/lib/libstdc++.so.6
#5 0xb74834a2 in std::terminate() () from
/usr/lib/libstdc++.so.6
#6 0xb74835e1 in __cxa_throw () from
/usr/lib/libstdc++.so.6
#7 0xb7483c5f in operator new(unsigned int) ()
from /usr/lib/libstdc++.so.6
#8 0xb7483d3d in operator new[](unsigned int)
() from
/usr/lib/libstdc++.so.6
#9 0xb7a7f616 in VoxelGrid (this=0x1cd82d0,
size_x=0.28061000210046771,
size_y=0.27929999691247942,
size_z=0.12600000074505804,
resolution=0.002,
origin_x=-0.14644000318646433,
origin_y=-0.14591999891400337,
origin_z=-0.0050000000000000001,
default_object=...)
at
/tmp/buildd/ros-cturtle-collision-environment-0.2.2/debian/ros-cturtle-collision-environment/opt/ros/cturtle/stacks/collision_environment/distance_field/include/distance_field/voxel_grid.h:193
#10 DistanceField (this=0x1cd82d0,
size_x=0.28061000210046771,
size_y=0.27929999691247942,
size_z=0.12600000074505804,
resolution=0.002,
origin_x=-0.14644000318646433,
origin_y=-0.14591999891400337,
origin_z=-0.0050000000000000001,
default_object=...)
at
/tmp/buildd/ros-cturtle-collision-environment-0.2.2/debian/ros-cturtle-collision-environment/opt/ros/cturtle/stacks/collision_environment/distance_field/---Type
<return> to continue, or q <return>
to quit---
include/distance_field/distance_field.h:145
#11 0xb7a7c53b in PropagationDistanceField
(this=0x1cd82d0,
size_x=0.28061000210046771,
size_y=0.27929999691247942,
size_z=0.12600000074505804, resolution=0.002,
origin_x=-0.14644000318646433,
origin_y=-0.14591999891400337,
origin_z=-0.0050000000000000001,
max_distance=0.10000000149011612)
at
/tmp/buildd/ros-cturtle-collision-environment-0.2.2/debian/ros-cturtle-collision-environment/opt/ros/cturtle/stacks/collision_environment/distance_field/src/propagation_distance_field.cpp:49
#12 0x080d42f5 in
tabletop_object_detector::DistanceFieldFitter::initializeFromBtVectors
(this=0x2070080, points=...)
at
/tmp/buildd/ros-cturtle-tabletop-object-perception-0.2.1/debian/ros-cturtle-tabletop-object-perception/opt/ros/cturtle/stacks/tabletop_object_perception/tabletop_object_detector/src/model_fitter.cpp:98
#13 0x080d4a3f in
tabletop_object_detector::DistanceFieldFitter::initializeFromMesh
(this=0x2070080, mesh=...)
at
/tmp/buildd/ros-cturtle-tabletop-object-perception-0.2.1/debian/ros-cturtle-tabletop-object-perception/opt/ros/cturtle/stacks/tabletop_object_perception/tabletop_object_detector/src/model_fitter.cpp:210
#14 0x080b3fbb in
tabletop_object_detector::ExhaustiveFitDetector<tabletop_object_detector::IterativeTranslationFitter>::loadDatabaseModels
(this=0xbfffec74,
model_set=...)
at
/tmp/buildd/ros-cturtle-tabletop-object-perception-0.2.1/debian/ros-cturt---Type
<return> to continue, or q <return>
to quit---
le-tabletop-object-perception/opt/ros/cturtle/stacks/tabletop_object_perception/tabletop_object_detector/include/tabletop_object_detector/exhaustive_fit_detector.h:216
#15 0x080b9fc7 in TabletopNode (this=0xbfffeba4,
nh=...)
at
/tmp/buildd/ros-cturtle-tabletop-object-perception-0.2.1/debian/ros-cturtle-tabletop-object-perception/opt/ros/cturtle/stacks/tabletop_object_perception/tabletop_object_detector/src/tabletop_node.cpp:231
#16 0x0807d457 in main (argc=1, argv=0xbffff004)
at
/tmp/buildd/ros-cturtle-tabletop-object-perception-0.2.1/debian/ros-cturtle-tabletop-object-perception/opt/ros/cturtle/stacks/tabletop_object_perception/tabletop_object_detector/src/tabletop_node.cpp:942