fix IO for LazyMask stuff