Oh! sorry, I didn't see this message until now. Sorry for the late reply!
Not in the constructor (since by the time the constructor is called, we don't know the map yet). But there is a function called "preGameAnalysis", which will be called in competition mode right before a game starts, with the initial game state. So, you can do all the precomputations you want there. Would that work?