Several hours and a headache I need some painkillers for later, and now I have successfully got my object extraction program working perfectly.

I needed training data for training a CNN, but needed to make it myself so I could train it on something that hasn't got an image dataset available online. Did some recordings against a small green screen, chopped out lots of frames, then slowly learned over 3 nights how to convert to OpenCV's weird representation of HSV. Then detect the background colour and try to remove it in order to extract my object. So much pesky noise in a lot of my frames (I had pointed my camera away from the green screen a little but really still wanted those precious images..).

Understanding contouring in OpenCV was also a pain in my ass. My project is ML focused but I ended up spending 3 nights on coding image processing alone 😂

Ah well.. it's done now.. I can sleep.
2 weeks until final project handin... no pressure

  • 1
    sounds interesting, and whats the goal of greenscreen ai?
  • 1
    @heyheni well this is just the preprocessing step. My goal is to train a CNN from an initially small dataset, just to hopefully show that it can be done from home without needing to rely on a huge dataset online.
    I aim to artificially inflate my dataset by using video footage to get lots of pictures, which I use my object extractor to take out only the object I want. Then take a bunch of backgrounds from online (or by yourself, this is the least important part), and create many permutations from 1 object image and many background images, alternating the scale of the object, rotation and position to perform the inflation.

    Then create a CNN model to train using this data and see if it works well enough to put in a robot running on a pi for object detection/following :')
  • 2
    @SoulSkrix cool! good luck!
Your Job Suck?
Get a Better Job
Add Comment