N-Wouda / ALNS

Adaptive large neighbourhood search (and more!) in Python.
https://alns.readthedocs.io/en/latest/
MIT License
442 stars 123 forks source link

Require help in understanding and coding the ALNS algorithm using alns package #169

Closed atharvanachankar closed 9 months ago

atharvanachankar commented 9 months ago

I'm having doubts in understanding and coding the ALNS algorithm in Python using "alns" package in the literature below.

Yimeng Zhang, Wenjing Guo, Rudy R. Negenborn, Bilge Atasoy, Synchromodal transport planning with flexible services: Mathematical model and heuristic algorithm, Transportation Research Part C: Emerging Technologies, Volume 140, 2022, 103711, ISSN 0968-090X, https://doi.org/10.1016/j.trc.2022.103711. (https://www.sciencedirect.com/science/article/pii/S0968090X22001486)

I've attached the same in the files along with Dr Yimeng Zhang's provided data.

Below is my understanding of the parameters in the pseudocode (ALNS algorithm on page 12 of the literature). Please correct me if I’m wrong.

In Input,

  1. K : Fixed_vehicles_Demir.xlsx which has terminal name, time windows for pickup and delivery.
  2. N : Distance_Demir.xlsx which has terminals and the distance between them for all modes(barge, train and truck)
  3. A : suitable_routes which has origin(o) and destination(d) names
  4. What’s the input file for R (requests set)?
  5. Also how do I get Xcurrent (current solution) for input?
  6. Or Intermodal_Demir_data.xlsx the input file for all K,R,N,A and Xcurrent?
  7. Also in Intermodal_Demir_data.xlsx,
    • In K sheet,
      • what’s ‘u’?
      • Assuming speed’s units to be km/hr
      • c1 to be transport cost/hr, c1’ to be transport cost/km, c4 to be carbon tax coefficient per ton.
    • In N sheet,
      • What are time and emmission units?
    • In o sheet,
      • o and o2 stand for origin and origin2 respectively
    • In R sheet,
      • What’s qr?
      • How to decide on penalty?

Then,

  1. What to do in “Preprocessing”?
  2. How to decide on current weight of operator and choose c (cooling rate)?

Literature: Transportation Research Part C (Journal) - Synchromodal transport planning with flexible services- Mathematical model and heuristic algorithm.pdf

Data Files: cost and time at terminals.txt Distance_Demir.xlsx Fixed_vehicles_Demir.xlsx Intermodal_Demir_data.xlsx suitable_routes_Demir.xlsx

N-Wouda commented 9 months ago

Hi @atharvanachankar! 👋

I'm happy to help out if you run into an issue when working with the alns package, but I do not have the time to help you implement a specific ALNS variant from the literature. I suggest you have a look at some of the examples in our documentation to build a basic implementation first, and then work to add the specifics from your linked paper later. Good luck!

N-Wouda commented 9 months ago

I'm closing this issue because I cannot help implementing a whole paper. If you run into a specific, focused question while implementing the paper's ALNS, please feel free to open another issue!