Ask Your Question
0

ROAR trainer-microphone functionality verification problem?

asked 2012-10-23 02:24:21 -0500

updated 2012-10-23 10:33:20 -0500

Hi, My microphone is working perfectly. But, when I try to run the ROAR trainer program(Tutorial),Could not able to run no 7 option. Could you please help me to configure this? Errors as follows :

-------------------------My console Error---------------------------

===== Audio Learner =====
  1. Estimate background subtraction
  2. Create a new model or open an existing model
  3. Inspect size of currently open model
  4. Learn new model entries
  5. Learn new model entries (continuous mode)
  6. Save current model to file
  7. Test microphone (1.5s)
  8. Quit Select a menu option: 7

Traceback (most recent call last): File "/home/hiranya/ros_workspace/roar_stack/roar/scripts/audio_trainer.py", line 211, in <module> mono = aa.get_audio_chunk(1.5,True); File "/home/hiranya/ros_workspace/roar_stack/roar/scripts/alsa_subscriber.py", line 168, in get_audio_chunk audat = self.get_windowed_audio(); File "/home/hiranya/ros_workspace/roar_stack/roar/scripts/alsa_subscriber.py", line 151, in get_windowed_audio self.audioBuffer = self.audioBuffer[self.nremove:]; TypeError: only integer arrays with one element can be converted to an index [roar/roar_trainer_server-2] process has died [pid 2830, exit code 1]. log files: /home/hiranya/.ros/log/86a1e7e0-1d09-11e2-a989-20cf30f31663/roar-roar_trainer_server-2*.log

---------------log file----------------------------

[rospy.client][INFO] 2012-10-23 19:02:33,212: init_node, name[/roar/roar_trainer_server], pid[2830] [xmlrpc][INFO] 2012-10-23 19:02:33,212: XML-RPC server binding to 0.0.0.0 [xmlrpc][INFO] 2012-10-23 19:02:33,213: Started XML-RPC server [http://hiranya-AIT:37890/] [rospy.init][INFO] 2012-10-23 19:02:33,213: ROS Slave URI: [http://hiranya-AIT:37890/] [rospy.impl.masterslave][INFO] 2012-10-23 19:02:33,213: _ready: http://hiranya-AIT:37890/ [xmlrpc][INFO] 2012-10-23 19:02:33,214: xml rpc node: starting XML-RPC server [rospy.registration][INFO] 2012-10-23 19:02:33,215: Registering with master node http://localhost:11311 [rospy.init][INFO] 2012-10-23 19:02:33,314: registered with master [rospy.rosout][INFO] 2012-10-23 19:02:33,349: initializing /rosout core topic [rospy.rosout][INFO] 2012-10-23 19:02:33,351: connected to core topic /rosout [rospy.simtime][INFO] 2012-10-23 19:02:33,353: /use_sim_time is not set, will not subscribe to simulated time [/clock] topic [rospy.core][INFO] 2012-10-23 19:02:38,747: signal_shutdown [atexit] [rospy.impl.masterslave][INFO] 2012-10-23 19:02:38,753: atexit

Thank you very much.

Best Regards, Hiranya

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2012-10-24 19:41:30 -0500

this post is marked as community wiki

This post is a wiki. Anyone with karma >75 is welcome to improve it.

I change the lines in get_windowed_audio(self) method in alsa_subscriber.py as follows self.audioBuffer = self.audioBuffer[int(self.nremove):]; self.stampBuffer = self.stampBuffer[int(self.nremove):];

it works, Thank you very much ROAR authors.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2012-10-23 02:24:21 -0500

Seen: 241 times

Last updated: Oct 24 '12