OpenEnergyPlatform / oeplatform

Repository for the code of the Open Energy Platform (OEP) website. The OEP provides an interface to the Open Energy Family
http://openenergyplatform.org/
GNU Affero General Public License v3.0
61 stars 19 forks source link

Implement pgrouting #263

Open Elmervdw opened 6 years ago

Elmervdw commented 6 years ago

(kopie von Outlook-E-Mail)

Hey Martin (&Ludwig),

am Anfang meines Praktikums hatte ich euch mal gefragt, ob pgrouting vielleicht als Extension hätte installiert werden können, das ist aber damals nicht passiert und ich habe ähnliche Sachen inzwischen vor allem in Python gemacht. Jedoch, mit networkx in Python komme ich nicht ganz klar, und ich denke, dass die pgrouting-Funktionalität doch echt richtig hilfreich sein kann. Ich würde ganz gerne in meinem Tool das hier implementieren (unten).

Ich kann mir auch vorstellen, dass pgrouting Funktionalität enthält, die für Energy Systems modelling richtig hilfreich ist (ich meine, meine Elektromobilitätsforschung ist eigentlich auch zum Teil eine Energiefrage). Deswegen: kann die Extension installiert werden, oder steht da irgendwas im Wege? Wenn das geht, sag mir bitte Bescheid wann ich was erwarten könnte, dann kann ich ein bisschen planen. Vielen Dank :) Elmer

https://anitagraser.com/2011/05/13/catchment-areas-with-pgrouting-driving_distance/

nesnoj commented 6 years ago

NetworkX provides similar functions which we make use of in eDisGo. But in terms of functions which include more spatial operations (such as driving_distance() in your example), pgrouting could be helpful. For more complex tasks than finding a single route from A to B, the computational effort may get too large for the OEP server if several queries are executed?

Elmervdw commented 6 years ago

NetworkX is definitely helpful, however my case is that I want to pull an OSM street network from the OEDB, then add some data to the edges and nodes. Eventually, I have to put those data back into the OEDB because I need to visualise the data in QGIS. A lot is indeed possible with NetworkX, however this requires a lot of steps and workaround which can take up quite some time - the same is possible in pgrouting instantly. I also think it is too much of a hassle for users who do not necessarily want to program in Python but do want to execute some routing queries in the DB for visualisation reasons etc. ( Especially as we are working with a lot of interns at the RLI)

Uiii, I don't know about the computational requirements, does anybody know that? I did not experience that many problems on my personal laptop with pgrouting, however that was also an A* and Dijkstra algorithm, I don't know about the other algorithms and to what extent they might paralyse server activity. Is anybody more knowledgeable on this?

Elmervdw commented 6 years ago

I just spoke to my thesis professor and he mentioned pgrouting could indeed be quite heavy on a server. However, he's not an expert and only knew that it's also very dependent on the hardware, configuration etc. There are apparantly quite some tweaks which can help, etc.. I have no idea. Maybe it's possible to limit the computational effort the query can take up? @nesnoj @MGlauer any ideas?