Detecting and adapting to crisis pattern with context based Deep Reinforcement Learning