According to the NCI (2018), aerobic or, cardiovascular exercise is classified as “Any physical activity that increases the heart rate and the body's use of oxygen”. Therefore, from purely a calorie burn & O2 consumption stand point, your body will not be able to distinguish between burning “x” amount of kcals from working at a heart rate of 140bpm during squats or a 140bpm during intense sexy time lol. So yes, sex can act as cardio however it may be more difficult to standardise compared to a typical cardio MACHINE in the gym lol.
In fact, Frappier et al (2013) even conducted a study set out to determine the energy expenditure during sexual activity in young healthy couples compared to a session of endurance exercise lol. They found that, mean energy expenditure during sexual activity was 101kcal or 4.2 kcal/min in men and 69.1kcal or 3.1kcal/min in women corresponding to a mean intensity of 6.0 & 5.6 METS respectively thus being able to be classified as “moderate intensity exercise”.
Their conclusion: “These results suggest that sexual activity may potentially be considered, at times, as a significant exercise” so if you want to get shredded but hate doing cardio, have sex lol.