How Karnataka insulated itself from power crisis that hit many states