Open danielhuppmann opened 2 years ago
lazy_read_iiasa()
For example, if you
df = lazy_read_iiasa("some/file.csv", TEST_API, model="model_a")
and later
df = lazy_read_iiasa("some/file.csv", TEST_API, model="model_b")
you will get a different result for the second call depending on whether any data in model_b changed in the database in the meantime.
I think that @phackstock implemented some smart solutions for such a problem in the downscaling-package...
696 added a top-level function
lazy_read_iiasa()
which tries to load from file before querying the database. One problem with the current implementation is that the file does not "remember" the filters applied for querying an existing file.For example, if you
and later
you will get a different result for the second call depending on whether any data in model_b changed in the database in the meantime.
I think that @phackstock implemented some smart solutions for such a problem in the downscaling-package...