@@ -838,7 +838,7 @@ void opt_traj_publisher_colored_by_world( const NodeDataManager * manager, const
838838
839839
840840
841- ros::Rate loop_rate (20 );
841+ ros::Rate loop_rate (10 );
842842 // ros::Rate loop_rate(5);
843843 map<int , vector<Matrix4d> > jmb;
844844 vector< Vector3d > lbm; // a corrected poses. Same index as the node. These are used for loopedges.
@@ -881,7 +881,8 @@ void opt_traj_publisher_colored_by_world( const NodeDataManager * manager, const
881881 }
882882 #endif
883883
884-
884+ ElapsedTime _time_jmb;
885+ _time_jmb.tic ();
885886 for ( int i=0 ; i<manager->getNodeLen () ; i++ )
886887 {
887888 int world_id = manager->which_world_is_this ( manager->getNodeTimestamp (i) );
@@ -1021,13 +1022,16 @@ void opt_traj_publisher_colored_by_world( const NodeDataManager * manager, const
10211022
10221023 }
10231024
1025+ cout << TermColor::BLUE () << " [opt_traj_publisher_colored_by_world] Took " << _time_jmb.toc_milli () << " ms to compute #nodes=" << manager->getNodeLen () << TermColor::RESET () << endl;
10241026 // -----------------------------------------------------------------------------------------------//
10251027 // ------------------------- After this only uses jmb and lmb to publish -------------------------//
10261028 // -----------------------------------------------------------------------------------------------//
10271029
10281030 // ---
10291031 // --- Decide offset's (for plotting) different co-ordinate systems
10301032 // ---
1033+ ElapsedTime _time_publih;
1034+ _time_publih.tic ();
10311035 #if 1
10321036 map< int , int > setids_to_udumbes;
10331037 if ( jmb.size () > 0 )
@@ -1232,7 +1236,7 @@ void opt_traj_publisher_colored_by_world( const NodeDataManager * manager, const
12321236
12331237 }
12341238
1235-
1239+ cout << TermColor::BLUE () << " [opt_traj_publisher_colored_by_world] Publish took " << _time_publih. toc_milli () << " ms " << endl;
12361240 // book keeping
12371241 // cerr << "\nSLEEP\n";
12381242 loop_rate.sleep ();
@@ -1455,7 +1459,7 @@ int main( int argc, char ** argv)
14551459
14561460 // setup manager publishers threads - adhoc
14571461 // std::thread th3( periodic_publish_optimized_poses_smart, manager, slam, viz );
1458- std::thread th4 ( periodic_publish_odoms, manager, viz );
1462+ // std::thread th4( periodic_publish_odoms, manager, viz );
14591463 std::thread th5 ( monitor_disjoint_set_datastructure, manager, viz );
14601464
14611465 opt_traj_publisher_options options;
@@ -1484,7 +1488,7 @@ int main( int argc, char ** argv)
14841488 // th1.join();
14851489 // th2.join();
14861490 // th3.join();
1487- th4.join ();
1491+ // th4.join();
14881492 th5.join ();
14891493 th6.join ();
14901494
0 commit comments