The majority of my work this week revolved around starting the creation of the Python backend using the OpenCV library. I started by laying out a basic workflow for how I envisioned this part of the system working. It consists of 2 main threads, one taking in images and creating frame packets to store and another taking those complete frame packets and then dispatching them in batches to be processed by the CNN. Currently the setup utilizes N threads total, where N is the number of hardware concurrent threads that Python can use according to a call using the multiprocessing module (‘multiprocessing.cpu_count()’). The code I’ve written so far is able to take in video, build and dispatch the complete frame packets of the correct between the appropriate lists, and then dispatch the appropriate number of threads. I also helped create the visualization for this for our upcoming presentation using draw.io, making sure that the Python components of the DSP/CNN part of the system were all correctly represented.

Next up on my todo list for this part of the system is to take a step back and write a master Python method that controls these independent threads, then working on taking back in the dispatched threads and rebuilding the post processed frames in the appropriate order. Even further down the line is to figure out how to save this video to an SD card but that is an issue I don’t plan on tackling until we’ve got a better idea of how the SD card interface with the board looks in general.

 


0 Comments

Leave a Reply

Your email address will not be published. Required fields are marked *