could be a dehydration effect. Though I would think that for a spin class you are doing a good job of hydrating. I've only had it happen at the end of a long outdoor ride when it was really hot out.