Coding Exercise on Masked Modeling

Coding exercise on masked image modeling.

Problem statement

So far while implementing masked image modeling algorithms (SimMIM, MAEs, MSNs), we've used random patch-dropping as our masking strategy. In this exercise, we'll implement another masking strategy called focal masking. Focal masking selects a continuous local block of an image and masks everything around it. The figure below illustrates the difference between random and focal masking.

Get hands-on with 1200+ tech skills courses.