vaporgui crashes when testing Python script defining a new variable

3 posts / 0 new
Last post
yulq
vaporgui crashes when testing Python script defining a new variable
I just need to define a new variable Wind from U,V,and W using python program. I followed the steps below: (1) From “Data” menu, select “Import data into current session, WRF-ARW”. Open the 60 jangmi hires data files. (2) Select menu item “Edit, Edit Python program defining a new variable” (3) In “Python Derived Variable Script Editor” window, select U, V, and W in section “Input 3D Variables”. (4) Click “Add 3D Variable” button, and enter “Wind” in the “Add 3D Output Variable” dialog. (5) Type in the one-line python script: Wind = sqrt(U*U+V*V+W*W) (6) Click “Test” button. The issue is that vaporgui program crashes after the last (6th) step. By debugging the code, I find that something is wrong in function PythonPipeLine::initialize(). To be exact, the vaporModule variable is NULL after executing the code: PyObject* vaporname = PyString_FromFormat("vapor"); vaporModule = PyImport_Import(vaporname); So the program crashes at the code thereafter: int rc = PyModule_AddObject(vaporModule, "LOD", lodObj); More information: 1. Build vapor 2.3.0 from source with VS 2010 on Windows 8. Same issue with 2.5.0. 2. Install and run vapor 2.3.0 binary (installed at C:\Program Files\UCAR\VAPOR), the python test succeeds after the same steps. 3. PYTHONHOME environment variable is defined as D:\Projects\vapor\vapor-2.3.0\Vapor3rdParty\Python-2.7.3-64. This issue exists no matter whether PYTHONHOME is defined or not.
clyne

Hi,

 

Could you try the vapor 2.6.0 release candiate? Please use the *binary* installer. There have been a number of changes that impact the python enviroment in version 2.6.

 

thanks - jc

yulq
Thanks, I'll try 2.6 to see new features.