Skip to content

Commit 8d30711

Browse files
Change duration in csv import command from minutes to seconds
1 parent d4aa289 commit 8d30711

File tree

4 files changed

+4
-3
lines changed

4 files changed

+4
-3
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ All notable changes to this project will be documented in this file.
1313
* improve managing packages with cargo's workspace
1414
* update dependencies
1515
* `breaking`: refactor internal models to simplify cost/telemetry handling
16+
* change duration in csv import command from minutes to seconds
1617

1718
### Added
1819

docs/src/concepts/pragmatic/problem/jobs.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ defined. Each task has the following properties:
4040
Each `place` consists of the following properties:
4141

4242
- **location** (required): a place location
43-
- **duration** (required): service (operational) time to serve task here
43+
- **duration** (required): service (operational) time to serve task here (in seconds)
4444
- **times** (optional): time windows
4545
- **tag** (optional): a job place tag which will be returned within job's activity in result solution.
4646

docs/src/getting-started/import.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ Jobs csv defines a `plan` of the problem and should have the following columns:
2828
* positive: `pickup`
2929
* negative: `delivery`
3030
* zero: `service`
31-
* `DURATION` __(integer)__: job duration in minutes
31+
* `DURATION` __(integer)__: job duration in seconds
3232
* `TW_START` __(date in RFC3999)__: earliest time when job can be served
3333
* `TW_END` __(date in RFC3999)__: latest time when job can be served
3434

vrp-cli/src/extensions/import/csv.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ mod actual {
6767
let get_task = |job: &CsvJob| JobTask {
6868
places: vec![JobPlace {
6969
location: Location::Coordinate { lat: job.lat, lng: job.lng },
70-
duration: job.duration as f64 * 60.,
70+
duration: job.duration as f64,
7171
times: parse_tw(job.tw_start.clone(), job.tw_end.clone()).map(|tw| vec![tw]),
7272
tag: None,
7373
}],

0 commit comments

Comments
 (0)