EV3-G vs ev3dev Python - Comparison and Benchmark

Sdílet
Vložit
  • čas přidán 30. 11. 2018
  • Starting 2019 WRO (World Robot Olympiad) is going to allow ALL programming languages for ALL categories and not mandate the use of Lego's own Software. Hence it's time to play a bit with ev3dev + Python and see how it compares to Lego's own EV3 programming environment. Let's find out which programming language performs better.... at least in a very particular and super simple scenario.
    Check following URLs to get more details about ev3dev2 and Python:
    www.ev3dev.org/
    sites.google.com/site/ev3devp...

Komentáře • 16

  • @CASSAPEIA
    @CASSAPEIA Před 5 lety

    Ein interessanter Test, den ihr da durchgeführt habt! Ich befürchte allerdings fast, dass er etwas unglücklich gewählt ist. Mit dem HiTechnic Farbsensor haben wir auch schon so unsere Erfahrungen gemacht, der misst einfach viel langsamer (die 70 mal pro sek hatten wir auch so ungefähr) als ein EV3 Farbsensor. Und da der Aufruf in der EV3 Software blockierend ist, d.h. das Programm währenddessen nicht weiterläuft, kommt man so auf eine sehr miese Performance. Nun kann es durchaus sein, dass andere Firmwares die Aufrufe in tiefergelegenen Ebenen anders (nicht blockierend) strukturiert haben. Das hat zur Folge, dass sie vermeintlich schneller/mehr Messwerte liefern, was aber auch nur ein Schein ist, da das halt mehrmals den gleichen liefert. Ich habe es nicht mehr getestet, aber glaube mich zu erinnern, dass das auch so war, wenn man den HT-Sensor in der EV3-Software mit dem blauen Raw-Sensor-Block ausgelesen hat.
    Interessant ist dann auch ev3fast, das sich ja theoretisch auch auf ev3dev pythonv2 umschreiben lässt, um die sonst nach unseren Erfahrungen wirklich nicht so tolle Performance wieder etwas zu pushen...

    • @roboteck5056
      @roboteck5056  Před 5 lety

      Guter Einwand... war nur unser erster Test und sicher nicht allgemein gültig. Tatsächlich liefert der EV3 Sensor unter ev3dev/python eine etwas bessere Performance.... unter EV3-G hängt er aber den HiTEC sogar um Längen ab. In unserem Roboter haben wir daher nun beide Sensoren.... EV3 (für schnelle Linienerkennung) und Hitec um Farben zuverlässig zu erkennen. Die Farberkennung des EV3 Sensors ist leider um Lichtjahre schlechter....
      Mit ev3fast haben wir auch "gepielt".... unter "stretch" variiert das Ergebnis aber dramatisch. Mal ist es doppelt so schnell wie "ev3dev2", mal nur 10% schneller. Man weiss also nicht, was man bekommt... eine Wundertüte. Wir sind wieder zu ev3dev zurück gegangen.

  • @ae7world466
    @ae7world466 Před 5 lety

    can you share the wro jounior programming

  • @minhbaolegos_8bp
    @minhbaolegos_8bp Před rokem

    Can you use EV3 color sensor?

  •  Před 5 lety +2

    Hi, can you share the python program for the benchmark?

    • @roboteck5056
      @roboteck5056  Před 5 lety

      It's shown in the video... just copy & paste what you get there :-)

  • @ericshenyi
    @ericshenyi Před 4 lety

    We are a rookie team, coaching kids using ev3dev2, but our question is, how to improve or shorten the loading time of their Python program when executing it on EV3... seems takes long time to load before running... is there a way to compile Python scripts and run binary codes on EV3? Thanks in advance!

    • @fandelfrc3617
      @fandelfrc3617 Před 4 lety

      The same!
      We played in FLL Laguna Regional Mexico 2020, and we decided to change from LabVIEW to Python, the code is easier and faster to be written but the times are so long to deploy, save and execute code on the brick, so we looked around and we found that the brick can be programmed on Language C
      That way, the brick acts faster and more instructions can be executed in less time
      I hope that helped

  • @migueljaeger4087
    @migueljaeger4087 Před 2 lety

    Puedo conectar más d en lego con phyton?

  • @fandelfrc3617
    @fandelfrc3617 Před 4 lety

    Well, for that benchmark python seems to be better than the standard LabVIEW-Based Programming Language, but, there are some problems with Python
    Some of them are;
    The time to deploy, save and execute the code from your PC to the EV3 Brick is longer in Python than in the standard Programming Language that provides LEGO
    So in competitions where the time is so important, I'd recommend to choose another language program not LabVIEW or Python, but C Language
    The grammar in C is so simple as in Python, those times are shorter, and also, in C the LEGO brick can execute more loops/instructions per second
    But yeah, in general Python (excluding that problem) is way better than standard LEGO Software
    Regards from Mexico!

    • @ahmetselim1166
      @ahmetselim1166 Před 3 lety +1

      C or C++ and how can i download it and is there any official site for C or C++ Thanks in advance

  • @redone8213
    @redone8213 Před 5 lety +1

    your benchmark is incorrect in many ways :) ev3dev actually much slower in terms of calculation power and runs with inapropriate (for WRO at least) delay. try it multi-thread mode with PID-controller involved and you'll see the real situation. Interpreted program cannot be faster than compiled one by default.

    • @roboteck5056
      @roboteck5056  Před 5 lety

      We agree... and do not agree at the same time :-).
      Benchmark results vary based on the test cases. Native EV3-G OS performs horribly bad if you're using Hitecv2 sensors.... with Lego's EV3 color sensors the results will clearly favor EV3-G OS. We got the impression that ev3dev2-python also improved performance by some margin. Furthermore ev3dev allows overclocking of the brick to further reduce the performance penalty which come along with running a heavy weight Linux. So it's clearly not as bad as you think. We're competing in WRO2019 using python3 on ev3dev and we're still doing well, so far. What mattered most to us was the learning experience... we just were sick of struggling with the graphical programming UI and just re-use what we already knew.

    • @redone8213
      @redone8213 Před 5 lety

      @@roboteck5056 HiTechnik frequency is 100Hz (10 times slower than LEGO sensor). It's damn slow and should be used in parallel thread and under certain circumstances. There are plenty ways to increase LEGO Color Sensor efficiency.
      p.s. There is text-based EV3 Basic for those who want alternative to EV3-G. It compiles to native rbf and work brilliantly on stock firmware.

    • @scprotz8102
      @scprotz8102 Před 4 lety

      @@redone8213 Check out LEGO's own micropython implementation (based on ev3, but much more optimized). Not sure if it works on HiTechnik yet, but you could probably roll your own based on the ev3dev2 kit if it doesn't. I've found it performs quite well, and should be fairly competitive.

  • @TechWorldwithImran
    @TechWorldwithImran Před 5 lety

    how i calculate energy cunsumption on hadoop cluster? using python Benchmarking?