Welcome, Guest
Username: Password: Remember me

TOPIC: Combined variable output

Combined variable output 6 years 5 months ago #30476

  • SDAC
  • SDAC's Avatar
Hi,

When loading Telemac 3D results *.slf file, BlueKenue automatically separates the result for each variable. I want to have a combined results file where I can extract all variables at every point for a single time-step i.e. a single text file for the all the variables. I can extract data at the same time-step for each variable, but recombining the variables into a single *.txt file for every output to be processed by my code is tedious.

Is it possible for bluekenue to open the results as a single mesh visualisation/combine the results into a single file?

Kind regards.
The administrator has disabled public write access.

Combined variable output 6 years 5 months ago #30501

  • a.barton
  • a.barton's Avatar
  • OFFLINE
  • Moderator
  • Posts: 683
  • Thank you received: 178
Hi SDAC,

Could you please email me a small example with steps to reproduce what what you want? Then, once I understand what you want more fully, I can respond...

Kindly,
Alan

PS Either email me through this forum or via the email available on CHyMS. Thanks
The administrator has disabled public write access.

Combined variable output 6 years 5 months ago #30506

  • pprodano
  • pprodano's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 96
  • Thank you received: 55
Hello,

There is a PPUTILS script that does exactly what you are looking for. Simply place your 3d_result.slf file in the root directory, and run:

python3 extract.py -i 3d_result.slf -t 1 -o 3d_result.csv

where -i is the 3d result file, -t is the index of the time step you want (in pythonic fashion, my indexes start at zero), and -o is the ascii comma separated result file. The script will output all of the variables, for all nodes, for the time step specified. You then load the output in GIS, just to make sure you got what you asked for.

When I envisioned this script, I never thought someone would want to use it for 3d files. Comment out the part that exits the script if NPLAN > 1, and it will work (I just checked).

Let me know how it goes,

Pat
The administrator has disabled public write access.
Moderators: Serrer, a.barton

The open TELEMAC-MASCARET template for Joomla!2.5, the HTML 4 version.