Video analysis is a fun and interesting way to study motion in Physics. How can you do this when the video is on YouTube? The attached python program, youtube_grab.ipynb uses the pytube module to save a Youtube video as an mp4 video.
The program was run from the Jupyter Notebook interface, which is a standard part of the Anaconda Python 3 distribution.
Notes on the video analysis, which was done with Vernier's Logger Pro:
- As the camera moves, I used the upper right corner ofthe left window as an origin. The orange points are the vertical difference between the position of the bottom of the bear and the upper corner of this window. In LoggerPro this is accomplished with "Data>New Calculated Column".
- I assumed the trampoline was 1m off the ground and used this as a "pixel to distance" calibration.
- The bear hit the trampoline at ~ 14m/s. The bear then hit the ground at ~7m/s. The Trampoline reduces possible injury to the bear!
As this is used (by me) for research and education purposes (ie, I'm not selling the video I had python download), I believe this falls under fair use. However, I am not an attorney and this is not legal advice.
There's a short howto that walks through the video analysis on youtube at https://youtu.be/dJZ3RiUT_BA.
Notes on the python code
- There's currently an error in the pytube module that pip downloads by default. A stackoverflow page pointed me to an updated version of the library.
- The code uses the standard Youtube download format in the pytube tutorial. I'm sure you could make it fancier.
Nathan Moore Winona State University 2019-Jan-14