Artificial Intelligence

@kypyro, yes, what you are saying is very similar to my own thoughts. The reason I wrote the previous post was because it felt like different people were meaning different things when using term “artificial intelligence.” I wanted to spell out alternative definitions to make sure we better understand each other when talking about various levels of artificial intelligence that would be possible to implement for our purposes.

AI must be a hot topic these days. Few weeks ago technik jr decided that we should be doing AI for the next season and started learning about neural networks and stuff like that. Is there something trending on the Internet that I didn’t get the memo about? :slight_smile:

Let me give a couple of very close to home examples, that should be easier to relate to.

The first one is from the Nothing But Net season. Anyone who had programmed flywheel PID must remember how you would spend a lot of time calibrating PID coefficients for the stable flyweel speed control. Yet it would still be very sensitive to the external factors like frame alignment or friction in the bearings.

We had PI loop with additional battery voltage scaling and the most important piece of telemetry for us was the value of “I” which would estimate amount of power loses or friction resistance in the system. We got LCD specifically to monitor it, as it was indicating the health of our flywheel. If one of the motor screws got loose or a piece of foam got into the flywheel bearing then we would see it immediately in the changed value of “I”.

Now if we look at our system from the artificial intelligence point of view, then instead of saying that “we programmed the system where ‘I’ estimates any unexpected power losses” we could say that “when we turn the power on, the robot ‘wakes up’ and ‘learns’ how much friction there is in the flywheel assembly and then adapts its speed control accordingly”. To allow that, we still had to calibrate Ki offline based on the multiple runs.

If we relied only on the human drivers to adjust motor power up and down, it would never be able to be as accurate as it was. So this is a good example, where a little bit of “artificial intelligence” could make a big difference when it applied to tasks where computer has an edge over the humans.

Here is another example from the Starstruck season. Less than a week before our States we figured out how to get our robot to high-hang. The hanging sequence turned out to be more complicated than anyone wanted or anticipated, since it needed motors to run close to their PTC limits. There was almost no way for a driver to execute the hanging without overheating PTCs. The proper way to fix it would be to rebuild the robot to be more mechanically adapted for the hanging. However, there was no time for that.

So the hanging sequence was implemented in software. To make things even more interesting / complicated there are two ways our robot could achieve the high-hanging. The first is fast, but risky (robot fell twice off the pole during the practice) and the second is safe but slow. So there is a piece of code which, at the beginning of hanging, looks at the battery level and the amount of time left in the match and decides whether to go for the safe or risky hang. I thought it is a crazy way of doing things, but kids thought it is cool, invested a lot of their time into programming it, and ended up winning Innovate Award for “thinking outside of the box.”

From these examples you can see that for some tasks, that are easier for computers than for humans, you could relatively easy incorporate the elements of the “artificial intelligence” such as (limited) learning and autonomous decision making. They could make a lot of difference for the gameplay but without the large costs that are usually associated with the full scale machine learning.

You could head into the “artificial intelligence” direction, one step at a time, incorporating more and more sensors where it makes sense, but still rely on human intelligence to program aspects of the operation where our understanding of the problem is superior. If this automatic cube detection works as suggested, it would be a great example of that:

Essentially, you need to look at the time it takes to train the driver vs the time to program and train (calibrate) the robot: