VlachosGroup / openmkm

Opensource software to model heterogeneous catalytic reactions. Based on Cantera
MIT License
14 stars 10 forks source link

ReNView Integration #40

Closed jonlym closed 4 years ago

jonlym commented 4 years ago

Hi Bharat,

Quick question. Can ReNView be called from OpenMKM or do users have to run it manually? If yes to the former, what keywords are required?

mbkumar commented 4 years ago

Hello Jon,

Short answer is no.

Here are my thoughts on this matter.

Personally, I don't like the approach of calling RenView from openmkm, so I didn't implement it. The reason is Renview is a python code and openmkm is C++ code. Another reason is having that many dependencies on a C++ software is not a good idea from development point of view. Another point is python codebase is a faster moving software, so renview needs more updates in the longer run. On the other hand, OpenMKM won't have to be touched much after getting stabilized.

A better approach would be UNIX philosophy where each piece of software does one thing well and by combining them at command line or in scripts you can do many things. In that approach, I'd like to have the option for someone to write a small python script using pMuTT to generate inputs to OpenMKM, run openmkm using subprocess module and then use renview to visualize.

Best approach would be to implement such a functionality in pMuTT. In addition to generating and OpenMKM inputs, you could add a module/function in pMuTT to run OpenMKM using subprocess module, parse its outputs and interface with pandas and matplotlib for raw output data visualization, and also call Renview from pMuTT for more complex analysis. This will make pMuTT the front-end for microkinetic modeling.

jonlym commented 4 years ago

Fair enough. We could perhaps put that in the submission script then. A problem I faced was the Anaconda valet package that I use for pMuTT was not compatible with OpenMKM's valet package.

I forget if it's problematic to run vpkg_rollback all after OpenMKM has run. I'll see what we can do.

mbkumar commented 4 years ago

Or I could make the OpenMKM valet package compatible with the anaconda version you are using for pMuTT. Let me know which anaconda version you are using.

jonlym commented 4 years ago

That could work too. I am using anaconda/5.2.0:python3

mbkumar commented 4 years ago

I installed the latest version with anaconda/5.2.0. Could you please test if it works.

Could you please also test for the convergence problem you faced when running a system few days ago on caviness?

jonlym commented 4 years ago

I believe the issue with Anaconda has been fixed. Thanks!