I started this week debugging CPFA on Gazebo. I found an error in which the rovers are unable to read pheromones. Instead they leave the function without changing the target location, so the rover ends up traveling back to where it was before it entered the nest. The error has to do with the update function which is called before selecting a pheromone. That code automatically makes the pheromone inactive. We appear to have implemented it exactly as it was implemented in Argos, so I suspect the problem maybe due to differences in the time functions between the two languages used. One thing to keep in mind, however, is that this function was actually commented out in the Argos code. I need to ask Antonio why it was commented out in the first place to ensure we should even be using it.
At our weekly meeting, we updated our mentors on our progress thus far, mostly how the mock Hackathon had gone. Since the real Hackathon is in 3 weeks and the person in charge of setting up would be here Friday, we have a time crunch to have everything ready. All other projects are on hold. Our task for this week - after helping out with a demo for visitors on Tuesday - was to complete the modified mock Hackathon and be ready to present our code and results by Friday. I also needed to start working on the final report since the internship is almost over for me. On demo day, I reviewed the final report guidelines and read example reports from other DREU students to get an idea of how to present my summer work. It's not quite straightforward because my work has been mostly helping prepare for the hackathon and implementing an algorithm in simulation versus answering a particular research question. I need to figure out how to turn this into a research report. On demo day, I also helped set-up the new nooks that would be used to control the cameras in the hackathon the next day. The actual demo did not go as planned. We set-up the rovers outside and expected them to pick up the scattered blocks and bring them to the center tag. Instead the robots behaved erratically, driving in circles and seeming unable to find the center tag when they did get a block. We suspect that the reflection of the sun made it hard for the rovers to see the center tag. During our Mock Hackathon, Round 2, we had a solid plan in place for what steps were needed to accomplish the task. However, as usual, unexpected errors came up. Some errors though we spent more time than needed on trying to resolve since they could have been addressed after the Hackathon presentation. Because of this we made progress, but did not complete all the tasks, though we came close. We hard-coded the robots to go to particular tags and the team considered leaving that for the demo. I worked on implementing a tag assignment scheme to work replace this, but we ran out of time to debug it. One error that slowed down everyone was that not all the rovers had correctly configured host files. Code that worked fine appeared erroneous when debugging because the rovers were not using camera data. Unfortunately, we did not realize this was the issue until during the presentation. We now have a base code from which the Hackathon teams can work. However, we still have a few more features and bugs to work out to make it completely presentable. This will be our work next week.
0 Comments
Every Monday, the lab has its weekly meetings where we set the goals for the rest of the week. This Monday, I completed the DREU progress report and my Week Four blog summary. I also completed the Hackathon Approach brainstorm task, in which I was to brainstorm how I would approach the hackathon in general as a competitor. At the meeting, I and the rest of the team presented our progress thus far on implementing the CPFA algorithm on Gazebo. Unfortunately, though we had done all our work on a desktop, we needed to present on a laptop so we could use the projector. The simulation was extremely slow, taking away from some of the excitement others might feel at seeing the implementation mostly realized.
We planned to spend the rest of the week mostly debugging the CPFA code and also to spend some time reading the MPFA paper so we can start to think about how we would modify the CPFA code to implement MPFA. As a side project, we were to do a mock Hackathon in which all four DREU students would work together to attempt to get rovers to bring blocks surrounded by various obstacles to a collection zone. The set up was different than the usual Swarmathon competition. For example, each block had a tag by it which was sensed by cameras that broadcast the location of the tags and the rovers (which were tagged too). Also, a lot of functionality was missing from the code: the ability to pick up blocks, to avoid obstacles well, to localize, etc. Our biggest tasks were to figure out how get the robots to move reliably without GPS since the Hackathon was indoors, how to coordinate which robots get which blocks, and how to avoid obstacles more reliably. Though it wasn't the intention, we spent most of this week working on the mock Hackathon. The first day was mostly fixing a bug with the camera set-up. The other days were spent getting the robot to move reliably from point to point using camera data and trying to complete the remaining tasks in time. We had issues in determining how to divide the tasks since all the team members had varying experience with ROS and the code and we were only allowed to use two laptops. We ended up getting the robot to move reliably, to receive and move to a tag location, and to pick up blocks. We were working on the algorithm for parceling the tags to each rover, improving obstacle handling, and fixing bugs in localization when we ran out of time. I can't believe it's already Week 5. I only have 3 weeks left and while I learned a lot I feel like there's so much more to learn and do! However, I'm glad I've had the opportunity to participate in Dr. Moses' lab this summer however short a time. This week we focused our energy primarily towards getting the Central Place Foraging Algorithm (CPFA) implemented in Gazebo a simulator for ROS. Once the code runs appropriately in Gazebo, we can begin the testing and tweaking for the actual rovers.
We decided that the best way to complete this project is to peer code, alternating the main and assistant coder roles. It took us the entire week, but we finally finished the first stage of coding. Next week we'll debug and optimize the parameters. This week we also meet with the other team to learn more about the progress of the base code refactor. Once they finish, we'll have to re-implement the CPFA algorithm using their improved code framework. Fortunately, their overview showed that we would not have to make too many adjustments. Mid-week we got the opportunity to attend the Swarmathon Award Ceremony for the Southwestern Indian Polytechnic Institute, the first place winners. Also, at the end of the week, we celebrated our progress by hanging out in Nob Hill and getting ice cream. The other REU students arrived this week, so our mentor gave us more defined goals for the summer. The lab is currently involved in many projects. High priority tasks for the summer include implementing foraging algorithms on the robots to compare their theoretical performance with real life performance and preparing Swarmathon Hackathon tasks for the competition in July. I was placed on a new team with a new mentor, Antonio, and one of the other REU students. Our first task is to implement the Central Place Foraging Algorithm(CPFA) on the swarm bots.
This required that I use a laptop instead of a desktop, so I spent some time setting up the ROS environment on the Desktop. With the environment set-up, we then read the CPFA paper carefully noting what we'd need to know to implement the algorithm in ROS. Afterward we had several meetings brainstorming how to breakdown this task. We wrote skeleton code and made design decisions that were revised throughout the week. We also collaborated with the other team which was finishing the refactoring of the Mobility code (that is, code relevant to the rover's motion) to be more object-oriented and readable. Their design decisions would affect how we would proceed. I worked on a ROS tutorial to get more to speed with how the operating system works and how that affected design decisions. It was a shorter week because of Memorial Day.
I read one of the research papers Dr. Moses gave me and also spent some time designing this website. The Swarmathon code has begun making more sense to me so Jarrett gave me my first official assignment. The base code he has been working on is finished now but very raw. We're currently in the process of cleaning it up to make it more object-oriented and understandable for the teams. My project is refactoring the code for the DropOffController class to handle most of the logic related to taking a block to a drop-off location and dropping it off. |