A cell has a size, however, when choosing a cell, it is not easy to know how many agents are already assigned to that cell in a given time, if the cell assignment computation is happening in parallel on multiple cells.
The only way to do this is to assign a category/type, rather than a cell, within the itinerary generation process.
Then, the assignment of the actual cell can happen in 1 thread, only assigning a number in each cell which is proportional to the sizes of all the cells.
A cell has a size, however, when choosing a cell, it is not easy to know how many agents are already assigned to that cell in a given time, if the cell assignment computation is happening in parallel on multiple cells.
The only way to do this is to assign a category/type, rather than a cell, within the itinerary generation process.
Then, the assignment of the actual cell can happen in 1 thread, only assigning a number in each cell which is proportional to the sizes of all the cells.