Mickey666Maus
Germany
Asked
Resolved by EzAng!
Experiments With Google Just Launched Teachable Machine 2.0
Go over to their website to check the new features!! https://teachablemachine.withgoogle.com/
Teachable Machine is a web-based tool that makes creating machine learning models fast, easy, and accessible to everyone. You can now export code to use it offline...
Or connect an Arduino to drive your robot directly by using a web app!! So there are a lot of options... https://experiments.withgoogle.com/tiny-sorter/view
The above sketch runs an the Arduino Leonardo, which is supported hardware on the Synthiam platform!! So who will be first to do some ARC integration for this?
Related Hardware Arduino Leonardo
Thanks, very good website, more to learn
I see I can do the same thing with ARC cognitive description, vision
Thatd be a neat skill control plugin if someone were to make one for this!
Oh...My....Gawd......................................!!!!!!
Hey guys, I took the time to look at the options at hand when using teachable machine, its quiet easy to use on ARC!! as an example how to drive a servo, you could...
Just build your project, and give you classes names that represent your servo positions and train your model
Click on export, click update my cloud model...and copy the p5.js to your clipboard
Add a servo and HTTP server to your ARC Project, start the server! Make a new text document from your clipboard and rename it to index.html
Edit the index.html file, find the "// The results are in an array ordered by confidence." part and add in your HTTP server address and the servo to move!
Voila!!!
There is also some easy to use machine learning stuff besides Teachable Machine...its over here!! https://ml5js.github.io/ml5-examples/public/ or... https://github.com/ml5js/ml5-examples/tree/master
Whoa that’s super accessible. Give us a demo? I wonder if there’s a way to make a skill control that connects easily
Yes please do a demo. This is very exciting. I can think of a million uses for it.
I will try to come up with an idea for a demo...I really like the pose estimation!! And yes there are a million cool things that we can do with it!!
It should be fairly simple to make a skill control, I would like to create one myself! But all the times I tried, I failed miserably!!
So I wasted a bunch of time trying to get Teachable Machine working with a Network camera...you can open the site with ?network=true to make those controls available! https://teachablemachine.withgoogle.com/train/image?network=true
I wanted to get my Raspberry Pi camera or the EZBPi cameras stream to be available to train classes in teachable machine! But the example provided did not work well on my Raspberry Pi Zero! https://gist.github.com/HalfdanJ/32b7891aff8017a27dd36ba1f3b12130
And I could not make up my own code from what the guys, that made the Teachable Sorter had come up with!! https://github.com/google-coral/project-teachable-sorter/blob/master/Sorter/sorter.py
Also there would be the next problem of getting the Raspberry Pi camera or the EZBPi cameras stream to work with the Javascript or p5.js examples from Teachable Machine! So it might be the easiest thing to just use a webcam for now, and have it all plug and play...the way the want us to use it!
That’s the largest challenge with raspberry pi. There’s little to no standard for accessing hardware peripherals. Makes it difficult to support... almost impossible because everything has to be specifically tailored for the project.
darn Linux!
Also since you will have to flag ?network=true manually, and it is not officially supported by the site, there is no information on supported formats, size ratio, fps etc...plus it only works on localhost, so you will have to ssh tunnel into your device!
So the EZB-Camera might not work, but ARC works with the standard webcam, so there is still a lot to explore... And a skill control could be a fun feature!!
Respected Mickey666Maus ! Could you share the files of the ARC project? I can’t deal with servo classes and arrays.
I made a step by step tutorial on how to do this...I hope this helps!!
Also there is another website which is nice to check out, if you are interested in using machine learning to control your robots.. I did not have the time to really play with it, just wanted to share the site!!
https://runwayml.com/
Clever boy! Thanks for the demo. I am totally enamored with the possibilities of this.
Thank you very much !!!
In my Tech Bandits adventures I stumbled across this series of Coding Train...Teachable Machine tutorials...great stuff in here! https://www.youtube.com/watch?v=kwcillcWOg0
Hello! Mickey! Please tell me the code how to connect to this: https://editor.p5js.org/gbose/sketches/NgBTJZQktR
@dhewlett I love The Coding Train, he also has a series on Runwayml!!
@3603d I will take a look!!
@3603d To see if I can help I need to know, which device you are planning to connect...and please show me where you found that code so I can access further information on what you are trying to accomplish!! A detailed description of your idea would also help! You can also open a new question thread here on the forum, to keep things organised!
In general you can send these RGB values or the slider values to ARC the same way as in the example above!!
And I very much apologize for my "8 we write, 2 in the mind", that is, for incomplete thoughts! I want to connect a servo drive to arduino instead of the LEDs in this sketch and connect it directly with p5.js TM that you used.
I came to the sketch of controlling LEDs studying creativity: https://experiments.withgoogle.com/tiny-sorter/view
@3603d I am sorry to say that I might not be able to help here, I do not own the Arduino Leonardo which is required to connect, when using this setup! The boards I own, do not work...I tried and had no luck!! The way I used the above code, is to send those values to the ARCs native Http Server!
So if you want to build the Tiny Sorter, I would advise you to buy the Arduino Leonardo and follow the steps provided on their page!
If you want to send values from your own Teachable Machine project to ARC to eg drive a servo, you can use the example above...
If you want to send values from your own Teachable Machine project to an Arduino Leonard via serial, I cannot help because I do not have the hardware to test if this works...but maybe someone in the Forum with an Arduino Leonard could help?
I really appreciate your attention to my questions! You helped me take the first step, make friends an arduino and teachable machine with a servo drive. (After 2 of your video tutorial, I focused on the renamed Class 1, Class 2 in degrees of rotation, but I still couldn’t get it because of the Chrome cache, I disabled it in the developer’s tools and everything worked out !!! as always a grain, a trifle, the last mile ...) On my last question, I managed to connect the slider to the servo, changing the firmware of the Leonardo and p5.js. code, moving the slider I controlled the servo. But to align, connect, send the results p5.js "Teachable Machine" instead of the sliders I could not (((
Ok, if I understand correctly...
You want to send values from your own Teachable Machine project to drive a servo? If yes, upload this Firmware to your Arduino Leonardo... https://synthiam.com/GettingStarted/Build-Robots/Arduino-Leonardo-18257
Then follow the steps above, and everything should work!!
Hey, since I was remembered to close this...I just gave credits to EZang60, because he is super active at the forum!! I hope he will be happy about some kudos!!
Hi, all great information here, thanks for all
I am super active at the forum because I am excited to learn, so many things to explore and test.
be well
This is showing how Pose Estimation can be used to drive a robot with Teachable machine!