Skip to content

Commit

Permalink
use_real_time reactivated
Browse files Browse the repository at this point in the history
  • Loading branch information
vitelot committed Jul 18, 2023
1 parent 453583a commit da02446
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
5 changes: 4 additions & 1 deletion configuration/configure.jl
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ source_path::String = parsed_args["source_data_path"]
target_path::String = parsed_args["target_data_path"]
nr_exo_delays::Int = parsed_args["exo_delays"];
delays_only::Bool = parsed_args["delays_only"];
# use_real_time = parsed_args["use_real_time"];
use_real_time = parsed_args["use_real_time"];
find_rotations::Bool = parsed_args["rotations"];
pad_schedule::Bool = parsed_args["pad_schedule"];
select_line::String = parsed_args["select_line"];
Expand Down Expand Up @@ -163,6 +163,9 @@ function loadPAD(file::String)::DataFrame
types = String,
skipto = 2) |> DataFrame;

# use a dirty trick to work with real time instead of scheduled
use_real_time && rename!(bigpad, :scheduledtime => :unusedtime, :realtime => :scheduledtime);

dropmissing!(bigpad, :scheduledtime);
filter!(x->length(x.scheduledtime)>0, bigpad );

Expand Down
7 changes: 3 additions & 4 deletions configuration/parser.jl
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,9 @@ function parse_commandline()
help = "Skip *ALL* the configuration actions except the sampling of delays."
action = :store_true


# "--use_real_time"
# help = "Use the real time column of the PAD timetable instead of the scheduled time."
# action = :store_true
"--use_real_time"
help = "Use the real time column of the PAD timetable instead of the scheduled time."
action = :store_true

"--pad_schedule"
help = "Use the scheduled time in the PAD file instead of the scheduled time found in XML."
Expand Down

0 comments on commit da02446

Please sign in to comment.