Add cache so that contrast checks aren't done every time for every file