Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
remove cyclic target reference from landmarks #395
Following from #394 we identified Landmarks and Image Features as the two places in Menpo where we had circular references. Although weakref sorted out the memory problems, we still have to handle the complexity of holding onto a target in Landmarks - a complexity that we arguably don't gain much from. This PR removes
foo.landmarks.view() # view foo and it's landmarks foo.landmarks[None].lms.view() # view landmarks on their own as PC
we now more explicitly do
foo.view_landmarks() # view foo and it's landmarks foo.landmarks.view() # view landmarks on their own.
this method is provided by a new mixin,
I've fixed all unit tests and everything seems to be working, this could do with some testing though.