try to fix a bug in InterGenSample