# Assignment#3 Road racing competition ## Team9 members: F44086181 Ping-Jung Yang E94096097 Mu-Cheng Chen Soma Ando 安戸蒼真 ## Classification Method ### Basic idea about road following by classification method - in order to make jetbot follow the road, we need to collect three types of data.(go forward, turn right, turn left) - By the data we collect, jetbot will try to run with the route we expect. - Pros: - it is easy to collect data. - it can adjust and correct the robot route which it predicts more easily - Cons: - it may not smarter than us. - it may not smooth than regression model - the dataset which is too simple will let robot don't know how to cope with the unexpected situation,while too complicated will confuse the robot and make it get lost on the map ### The details of training jetbot in the competition - round 1 We collect the dataset by speed 0.4,totally about 2000 pictures,the time robot spend is 34.4 seconds. The robot zigzag the track obviously.Two ways we think to improve is increasing the speed or making robot run more smoothly {%youtube 0JwrSo1Gde0 %} - round 2 We collect the dataset by speed 1,the reason is that we consider increase the speed could collect the situation what robot will meet when we increase the robot speed in the competition. We totally collected about 3000 pictures,the time robot spend is about 35 seconds. The robot zigzag insanely after we collected dataset by speed 1,it shows that the way we change for collecting data is wrong,dataset will be too complicated to confused the robot for distinguishing the track. - round 3 We adjusted the speed which robot run in the competition,and we also try to set deffirent speed to the left and right motors.Finaly we found that if we want to make robot run much faster and more smoothly,what we should change is our dataset.The time robot spend is 35.21 seconds. {%youtube W3PSJVsIO4U %} ## Regression Method ### Basic concept of road following by regression method - Since each pattern needs to be recognized, a lot of data is needed. - Requires a lot of data, but runs smoother than the Classification Method. - Pros: - It runs smoothly and wastes less time than the classification method. - Cons: - If there's not enough data, the gray road won't be read accurately. If there's lots of data, it is important that the data is clear or not. - Even when moving forward, it can't go very fast. - Around Kenting on the map, it found the next road first and took a shortcut. ### The details of training jetbot in the competition - round 1 The first thing I focused on was making JetBot recognize the gray lines. I used 2000 photos to try to get it to recognize them, but that didn't get me to the goal.But, I figured that if I took more pictures, it would follow. - round 2 I challenged myself to take a total of 4000 photos to see if I could improve it. When the speed was reduced to 0.2, the JetBot was able to follow the gray road. However, it took JetBot more than 50 seconds to reach the goal. - round 3 This time I challenged myself to take a total of 6,000 photos. Then the speed even worked at 0.3. The record at that time was 35.21 seconds. I found out that I could make it run faster by increasing the number of photos, so I decided to increase the number of photos. {%youtube y908IK7R1L0 %} ## The experience of training jetbot in the competition In the first round, we use the classification method. At first, we tried to let jetbot collect data naturally,so when collecting data, we did not interfere with jetbot route.If the route is skewed, we use the computer to turn left or right to adjust it back,and when the number of pictures reaches about 600,our jetbot can occasionally complete a lap smoothly,but it may not perform as expected at some turning points (such as northern Taiwan and southern Taiwan),so we decided to continue collecting data. In order to make the training model more suitable for our ideas,we have strengthened the collection of data in the error-prone parts.When there are about 2000 pictures,our jetbot can successfully complete three laps at a motor speed of about 0.31.We are also in the first 2nd place in the first round.   In the second round of the competition, we tried many means to increase the speed of our motor. In addition to collecting more data, we also increased the speed of the motor when collecting data. We hope that the high-speed data collected in this way will allow our jetbot to travel at high speed and it will be no shortage of whether data is enough or not. However, we were too focused on collecting information, we found out that it was overtime by two minutes when the film was be uploaded, so we did not participate in the second round of the competition. From the second round of competition, we deeply learned : Don't always think about procrastinating until the last minute, everything needs to be given some time to avoid situations that we can't deal with when they happen. In the third round, we learn the lessons of the second round, so we pay attention to the time especially. In terms of data, we think that the first two rounds have already collected a lot, so instead of spending time collecting data, we have been testing jetbot at different motor speed. At high revs, we found that although the travel speed would be faster, the smoothness of the route was not as good as at low revs, so we focused on the balance of high and low revs for the third round. Although we did not get a satisfactory one in the end, but we learned the lesson and successfully uploaded the video within this time, and finally got the fifth place.   We found that we could improve the jetbot’s road following, and we were not willing to give up the improvement attempt after the game, so our group decided to improve the road following as the theme of our final report.