The AoE stamina healing effect unlocked when you have the Respite perk will heal the stamina of undead, machines, and daedra within range of the effect due to there being no condition checks to prevent it. The AoE healing effect, on the other hand, will not affect undead, machines, or daedra within range.
Attacking an enemy while undetected will still allow the spell to heal them. Example: Hitting a Giant inside a camp, then casting Grand Healing will sometimes heal it. ?