forked from CamilleNAVEL/projetinfo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
test2.py
37 lines (30 loc) · 1.42 KB
/
test2.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
from Dijkstra.dijkstra_source_vers_destination import dijkstra_source_vers_destination
import pandas as pd
import __init__
from preparationdata.appurement_correspondances import appurement_correspondances
from preparationdata.creation_tableTrajets import creation_tableTrajets
from preparationdata.filtre_type import filtre_type
from preparationdata.filtre_depreg import filtre_depreg
from preparationdata.filtre_tgv import filtre_tgv
from preparationdata.filtre_ter import filtre_ter
# On charge la table de tous les trajets
tableTrajets = creation_tableTrajets()
# TGV bretons
table11=filtre_type(tableTrajets, delete="TER")
table11=filtre_depreg(table11,regions=["53"])
table11[["reg_origine","dep_origine","type"]].value_counts()
table11[["reg_destination","dep_destination","type"]].value_counts()
table11
dijkstra_source_vers_destination(table11, "RENNES", "BREST")
# Trajets TGV
table3=filtre_type(tableTrajets, delete="TER")
table3=appurement_correspondances(table3)
table3[["type"]].value_counts()
dijkstra_source_vers_destination(table3, "LILLE FLANDRES", "POITIERS")
dijkstra_source_vers_destination(table3, "POITIERS", "LILLE FLANDRES")
dijkstra_source_vers_destination(table3, "REIMS", "LE MANS")
# Ensemble des trajets possibles
table1=appurement_correspondances(tableTrajets)
table1[["type"]].value_counts()
dijkstra_source_vers_destination(table1, "RENNES", "STRASBOURG")
dijkstra_source_vers_destination(table1, "RENNES", "PAIMPOL")