How to get enclosed mask from points in differentiable way?


I am doing key points regression problem. To be concrete, I selected some points as gt points from the boundary of targets with irregular shape. Now, I can get predicted points from a regression network. What I want to do is implementing a function to get the enclosed mask from the predicted points in differentiable way.

Do you have any suggestions? Thanks in advance! :wink: