I would expect a firearms instructor to recommend shouting at the loser to “GET OUT”. Make it loud enough for the neighbors to hear. It may get the perp to leave. If not, then it helps creates a defense against charges for the homeowner.
Shooting is justified if you fear death or great bodily harm. Providing any kind of warning or not shooting for any reason, can be interpreted as NOT fearing death or bodily harm.
If a person is clmbing through one of my windows at 1am, I can't think of many innocent explanations.
Some people live in homes that can be mistaken for each other. A drunk coming home in the middle of the night and without his key might attempt to enter through a window.
The problem with giving the intruder the benefit of the doubt is that the intruder might be armed and just might choose to shoot at the sound of a warning. I would not want to make my children orphans due to such a misjudgement. I would opt to make somebody else an orphan.
The other problem with a warning is that it provides extra time for an intruder's accomplice to kill you or yours.
I don't remember any guidance to provide a warning in the defensive handgun course that I took. We went through drills involving "shoot / don't shoot" which involved taking time to identify the threat. Once the threat of death or great bodily harm was identified, we took two shots to center of mass and then considered a head shot if the threat remained.