wouterkool / attention-learn-to-route

Attention based model for learning to solve different routing problems
MIT License
1.11k stars 345 forks source link

Why arent lengths directly sent into the get_costs function? I am trying to modify the code and also implement a min-max version of it for my paper. #60

Open Casualite opened 1 year ago

Casualite commented 1 year ago

Firstly, I want to thank you for this paper and making the code public. It was a good place for me to start my implementation . I might have misunderstood the code, but isn't the get_costs function being used to generate rewards? If no, could you tell me why that is used? If yes, why not pass the lengths from the state directly?

wouterkool commented 1 year ago

Hi! Not sure if I fully understand your question but the code is set up to be general. For example for prize collecting TPS or orienteering, costs is not just the length, hence we use the cost function.