Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
Tesi
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Marco Aceti
Tesi
Commits
8f5d094a
Verified
Commit
8f5d094a
authored
May 8, 2023
by
Marco Aceti
Browse files
Options
Downloads
Patches
Plain Diff
Drop cancelled stops and trains in trajectories map
parent
8d6909fd
No related branches found
No related tags found
No related merge requests found
Pipeline
#2829
passed
May 8, 2023
Stage: test
Stage: lint
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/analysis/trajectories_map.py
+3
-0
3 additions, 0 deletions
src/analysis/trajectories_map.py
with
3 additions
and
0 deletions
src/analysis/trajectories_map.py
+
3
−
0
View file @
8f5d094a
...
...
@@ -274,6 +274,9 @@ def build_map(st: pd.DataFrame, df: pd.DataFrame) -> None:
"""
m
=
folium
.
Map
(
**
MAP_KWARGS
)
# Drop cancelled stops and trains
df
=
df
.
loc
[(
df
.
stop_type
!=
"
C
"
)
&
(
df
.
cancelled
==
False
)].
copy
()
logging
.
info
(
"
Generating GeoJSON features...
"
)
features
=
Parallel
(
n_jobs
=-
1
,
verbose
=
5
)(
train_stop_geojson
(
st
,
train_df
)
for
_
,
train_df
in
df
.
groupby
(
"
train_hash
"
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment