I am trying to find the largest or best fitting ellipse inside an irregularly shaped object from a binarized image, in order to get a more consistent center of mass and orientation angle.
I am trying to analyze a video that contains many of these objects and track the object as it moves around in the frame. I have cut out the other objects in the original video to just focus on one object at a time, and have it as centered as I can. Currently region_props gives me centroid coordinates and an orientation angle. But because of small pixel variations throughout, those coordinates change, giving a very unsteady video.
Here is the image from the video:
The main blob in the center doesn't change over the course of the video, but the curly things coming out slightly bend and change, giving me problems. My goal is to find the largest ellipse inside the object and get the center of mass from that as well as the orientation angle. I will be analyzing a lot of videos, and also a lot of object of various sizes, but if I can get some idea of how to do it for one image I can build up. I have seen some things regarding inscribing ellipses inside bounding boxes but because these objects are all very irregular a bounding box won't work.
How could I approach a problem like this?

