making the transition computation process faster by chunking the queries