trying to fix problem with numEvents being too large