LCA-ActivityBrowser / activity-browser

GUI for brightway2
GNU Lesser General Public License v3.0
140 stars 54 forks source link

Add support for WebAssembly to run online / in the browser #816

Open raphaeljolivet opened 2 years ago

raphaeljolivet commented 2 years ago

I see the latest version of Qt support WebAssembly, enabling any Qt application to run smoothly in the browser : https://www.qt.io/qt-examples-for-webassembly

That would be a great improvement for AB : In our lab, we deployed Brightway2 on an internal Jupyter Hub : This allows students and researchers to play around with Brightway without installing anything on their machine.

Having AB online would be really nice.

Do you think it would be feasible to build AB for WebAssembly ? I am willing to help if needed : https://doc.qt.io/qt-5/wasm.html

marc-vdm commented 2 years ago

We are exploring this idea currently, but moving AB to an application that can utilize external calculation will be quite a big project. I'm also not sure whether pyside2 (our python QT wrapper) currently supports webassembly.

We're looking at this and interested, but to manage expectations; this will be a long term thing if we'd go through with this. Of course, depending on the help you could offer, we can see if this could be implemented faster.

raphaeljolivet commented 2 years ago

Thanks for your answer.

I was looking for a "quick win" to port AB to the web. But indeed, moving all the inner engine to WebAssembly might be a big deal.

Maybe the best option is to take the time to build a Web API over the main features, and clone AB as a modern web app on top of it. I really feel Brightway2 should go into this direction and move toward web API to request & update Dbs and run LCIA.

The perfect goal would be an open web platform like "github" on which people can build & share LCA inventories, with support for versioning and referring each others.

marc-vdm commented 2 years ago

I'm afraid it wouldn't be a quick win. Though again, this is something we're interested in for the longer term, so stay up to date with us :).

I really feel Brightway2 should go into this direction and move toward web API to request & update Dbs and run LCIA.

This could indeed be interesting, but we're not the Brightway team ;) -though there's some cross over-. Perhaps contact the Brightway GH team?

The perfect goal would be an open web platform like "github" on which people can build & share LCA inventories, with support for versioning and referring each others.

This sounds like you'd find GLAD interesting.