Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Autofix all notebook linting errors #290

Merged
merged 1 commit into from
Dec 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions examples/02a_tabular_read_write.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
"import os\n",
"\n",
"import pandas as pd\n",
"\n",
"from pam import read"
]
},
Expand Down
1 change: 1 addition & 0 deletions examples/03_read_modify_write.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
"import geopandas as gp\n",
"import pandas as pd\n",
"from matplotlib import pyplot as plt\n",
"\n",
"from pam import policy, read\n",
"from pam.policy import apply_policies\n",
"\n",
Expand Down
1 change: 1 addition & 0 deletions examples/04_point_sampling.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
"import geopandas as gp\n",
"import pandas as pd\n",
"from matplotlib import pyplot as plt\n",
"\n",
"from pam import read\n",
"from pam.samplers.spatial import RandomPointSampler"
]
Expand Down
1 change: 1 addition & 0 deletions examples/05_activity_plots.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
"import os\n",
"\n",
"import pandas as pd\n",
"\n",
"from pam import read\n",
"from pam.plot.stats import plot_activity_times, plot_leg_times"
]
Expand Down
1 change: 1 addition & 0 deletions examples/07_travel_survey_to_matsim.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
"\n",
"import geopandas as gp\n",
"import pandas as pd\n",
"\n",
"from pam import read, write\n",
"from pam.core import Population\n",
"from pam.plot.stats import plot_activity_times, plot_leg_times\n",
Expand Down
1 change: 1 addition & 0 deletions examples/08_toy_matsim_population.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@
"import matplotlib.pyplot as plt\n",
"import numpy as np\n",
"import pandas as pd\n",
"\n",
"from pam.activity import Activity, Leg\n",
"from pam.core import Household, Person, Population\n",
"from pam.plot.stats import plot_activity_times\n",
Expand Down
7 changes: 4 additions & 3 deletions examples/10_advanced_spatial_sampling.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -75,13 +75,14 @@
"import geopandas as gp\n",
"import matplotlib.pyplot as plt\n",
"import numpy as np\n",
"import pam\n",
"import pandas as pd\n",
"from shapely.geometry import Point, Polygon\n",
"\n",
"import pam\n",
"from pam.activity import Activity, Leg\n",
"from pam.core import Household, Person, Population\n",
"from pam.samplers import facility\n",
"from pam.utils import minutes_to_datetime\n",
"from shapely.geometry import Point, Polygon"
"from pam.utils import minutes_to_datetime"
]
},
{
Expand Down
1 change: 1 addition & 0 deletions examples/13_Advanced_Freight_Synthesis.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
"import numpy as np\n",
"import pandas as pd\n",
"from matplotlib import pyplot as plt\n",
"\n",
"from pam.core import Household, Person, Population\n",
"from pam.samplers import tour\n",
"from pam.samplers.facility import FacilitySampler\n",
Expand Down
5 changes: 3 additions & 2 deletions examples/14_Advanced_Plan_Cropping.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,13 @@
"\n",
"import geopandas as gp\n",
"import matplotlib.pyplot as plt\n",
"from shapely.geometry import Point, Polygon\n",
"\n",
"from pam.activity import Activity, Leg, Plan\n",
"from pam.core import Household, Person, Population\n",
"from pam.operations import cropping\n",
"from pam.utils import minutes_to_datetime as mtdt\n",
"from pam.variables import END_OF_DAY\n",
"from shapely.geometry import Point, Polygon"
"from pam.variables import END_OF_DAY"
]
},
{
Expand Down
3 changes: 2 additions & 1 deletion examples/15_advanced_choice_modelling.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,12 @@
"\n",
"import numpy as np\n",
"import pandas as pd\n",
"from prettytable import PrettyTable\n",
"\n",
"from pam.operations.cropping import link_population\n",
"from pam.planner import choice_location as choice\n",
"from pam.planner.od import ODFactory, ODMatrix\n",
"from pam.read import read_matsim\n",
"from prettytable import PrettyTable\n",
"\n",
"logging.basicConfig(level=logging.DEBUG)\n",
"random.seed(0)"
Expand Down
5 changes: 3 additions & 2 deletions examples/17_advanced_discretionary_locations.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -55,15 +55,16 @@
"\n",
"import numpy as np\n",
"import pandas as pd\n",
"from prettytable import PrettyTable\n",
"from shapely.geometry import Point\n",
"\n",
"from pam.activity import Activity, Leg, Plan\n",
"from pam.location import Location\n",
"from pam.planner.choice_location import DiscretionaryTripOD, DiscretionaryTrips\n",
"from pam.planner.od import ODFactory, ODMatrix\n",
"from pam.planner.utils_planner import get_trip_chains_either_anchor\n",
"from pam.utils import minutes_to_datetime as mtdt\n",
"from pam.variables import END_OF_DAY\n",
"from prettytable import PrettyTable\n",
"from shapely.geometry import Point\n",
"\n",
"logging.getLogger(\"pam\").setLevel(logging.DEBUG)\n",
"random.seed(0)"
Expand Down
1 change: 1 addition & 0 deletions examples/18_advanced_ipf.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
"import itertools\n",
"\n",
"import pandas as pd\n",
"\n",
"from pam.core import Person, Population\n",
"from pam.planner import ipf"
]
Expand Down
Loading