A really simple mask cleaning plugin for AviSynth based on mt_hysteresis. It discards all areas of less than length pixels with values bigger or equal to thresh. You probably don't want to use it.
Provided binary is built with vc110.
This project is licensed under the MIT license. Binaries are GPL v2 because if I understand licensing stuff right (please tell me if I don't) they must be.