Will optFlow run till the time budget is totally used?

Questions refering to the Optiflow based API within PTV Developer (launched on 20.12.2023)
Post Reply
CAPcargo
Posts: 40
Joined: Tue May 19, 2015 12:53 pm

Will optFlow run till the time budget is totally used?

Post by CAPcargo »

Hi
My question is will optiFlow claculated always till the time budget is fully consumed? Since according to the description there are only two stop scenarios. User stops or the time runs out.
But what in case all possible combinations (search space) has been already evaluated earlier?
optiFlow_Doc_Setup_calculationTime.jpg
User avatar
Bernd Welter
Site Admin
Posts: 2823
Joined: Mon Apr 14, 2014 10:28 am
Contact:

Re: Will optFlow run till the time budget is totally used?

Post by Bernd Welter »

Hi CAPcargo,

sounds simple, but in fact the description does not completely explain the potential conditions:
  • manual interruption via stopOptimization : clear - termination is triggered and optimization comes to an end soon
  • maximum duration expired : clear - termination is triggered and optimization comes to an end soon
  • but what happens to a "small problem size" in combination with a "huge maximum duration value"?
    Example: duration set to 300secs. just one order... the algorithm spent the whole 5 minutes.
    Example: duration set to 300secs. just one order... the algorithm spent the whole 5 minutes.
I anticipate this follow-up question related to this:
What is a meaningful "budget duration" which we could derive from an optimization's characteristics? SUch as
  • number of orders
  • number of locations (and geographic variance)
  • number of vehicles
I will forward this question to the competence center for an explanation and also to product for an improved description.
Bernd
Bernd Welter
Technical Partner Manager Developer Components
PTV Logistics - Germany

Bernd at... The Forum,LinkedIn, Youtube, StackOverflow
I like the smell of PTV Developer in the morning... :twisted:
User avatar
Bernd Welter
Site Admin
Posts: 2823
Joined: Mon Apr 14, 2014 10:28 am
Contact:

Re: Will optFlow run till the time budget is totally used?

Post by Bernd Welter »

Here's some feedback I received from some Conundrian ;-)
Optimization budget duration depends not only on those variables, but also on the number of constraints that would need to be checked. If there are a lot of things that need to be taken into account during the optimization, there would quickly be a huge explosion of the problem space if you add 10 inter-order constraints.

I don't think this can be put into a simple formula to give you the optimal optimization duration. Experience with customer cases and seeing where the drop in kpi's stabilizes is the main way to establish how useful it is to optimize longer.
Sometimes customers experiment with copies of their production plannings to see if there are savings left on the table.

Typically, in practice, there is an operational constraint even on how long the plan can optimize without exhausting the problem space because they need the output.

Again, I don't see any options or need to keep track of the problem space in where the focus of the size of optiflow optimizations typically is. These are not tiny plans, and they have many constraints.

It is only "strange" for theoretical cases like this, so a self-inflicted problem, not a real one.
So what I could imagine to do is to implement some logic on client side that enables a dispatcher (or an automted process) to decide about a stop:
  • Are all orders scheduled? - for some parties this constraint is crucial and they immediately start to load vehicles once such a solution is available.
  • How much did the result improve in the last xx minutes? - Though this does not exclude a significant progress in the future this might be sufficient if you are impatient. So if the solution looks stable you might think about stopping the optimization.
    dev of termination.png
Best regards,
Bernd
Bernd Welter
Technical Partner Manager Developer Components
PTV Logistics - Germany

Bernd at... The Forum,LinkedIn, Youtube, StackOverflow
I like the smell of PTV Developer in the morning... :twisted:
User avatar
Bernd Welter
Site Admin
Posts: 2823
Joined: Mon Apr 14, 2014 10:28 am
Contact:

Re: Will optFlow run till the time budget is totally used?

Post by Bernd Welter »

at least important to know:

Concept: Optimization
You can set a preferred calculation duration, allowing the algorithm to halt automatically after the specified time. If you have a sequencing request containing only one vehicle with up to 500 orders, the calculation duration is capped at 2 minutes as sequencing requests are faster to optimize.
Bernd Welter
Technical Partner Manager Developer Components
PTV Logistics - Germany

Bernd at... The Forum,LinkedIn, Youtube, StackOverflow
I like the smell of PTV Developer in the morning... :twisted:
Post Reply