urbanaccess icon indicating copy to clipboard operation
urbanaccess copied to clipboard

Multiple networks in memory at once

Open smmaurer opened this issue 4 years ago • 0 comments

I'm having trouble loading more than one network into memory at the same time using urbanaccess.load_network(). Earlier network variables end up pointing to the most recently loaded network:

Screen Shot 2020-10-05 at 3 21 34 PM

Diagnosis

UrbanAccess maintains a record of the current network, since most of the time users are only working with one at a time. It looks like the problem might be with how load_network() updates it -- it's overwriting the nodes and edges rather than replacing the object. I'll see if i can fix this. network.py#L539-L542

Environment

actransit_with_headways.h5
actransit_bart_with_headways.h5

MacOS 10.14
Python 3.8
UrbanAccess 0.2.1 Pandas 1.1
Jupyter 1.0

smmaurer avatar Oct 12 '20 19:10 smmaurer