Weird sleeping positions sometimes happen when the cham is surprised by the lights going off suddenly - so it doesn't have enough time to find a suitable spot to sleep (because it can't find its way around in the dark).
By providing cues of darkness before all the lights go off, you can warn the cham that the lights will soon be off, and it should start finding a place to sleep.
One way to do this is to have the cham's cage face an outside window, so that as the light subsides outside, the cham will realise darkness is approaching and get ready for sleep.
Another way, is to set your UV and heat bulbs on separate timers, and to have the heat bulb switch off before the UV bulbs. When the heat switches off, the drop in temps will alert the cham that night time is approaching, and it will start looking for a place to sleep.
If you give the cham enough time after it has been alerted that it is almost night time, it will invariably head off to the same spot every night.
My adult Veiled sleeps without fail on the same branch every night - he starts moving towards it almost immediately after the heat bulb at his basking spot switches off. By the time the UB bulb goes off, he is curled up there and ready to sleep.
It does take some time to get the cham adjusted to the routine though. Even with the same light schedule as the adult, my baby female Veiled still sometimes takes too long to find a place to sleep and ends up sleeping in awkward spots such as this: