CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Visualization & Post-Processing Software > ParaView

[General] Exporting slice as csv from state

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 31, 2014, 00:02
Default Exporting slice as csv from state
  #1
Member
 
Lingdeer
Join Date: Jul 2011
Posts: 49
Rep Power: 14
lingdeer is on a distinguished road
Hi,

I have cfd results in time and would like to obtain average velocity through a number of planes across my domains. I am writing a paraview script so that I can get all those planes in time automatically, and planning to export it as different .csv files

First I saved a state which contains:
- original volume of domain
- slice I defined at different locations at domain
- integrate variables at each slice to get average velocity

Here is a sample of my python script:
from paraview.simple import *
servermanager.LoadState("C:\\Deskktop\\State.pvsm" )

Render()
view = GetActiveView()
reader = GetActiveSource()

writer = CreateWriter("C:\\Desktop\\foo.csv", reader)
writer.FieldAssociation = "Points"
writer.UpdatePipeline()
del writer


In my state file ".pvsm", I already have the integrated slice I want to export in spreadsheet view as activeview when I save the state.

When I run the script as python macro, it loads the state as spreadsheet view, but it does not export the .csv file. And it did not show any error message.

What could have possibly gone wrong?

Thanks!!!
lingdeer is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Setting the height of the stream in the free channel kevinmccartin CFX 12 October 13, 2022 21:43
Domain Reference Pressure and mass flow inlet boundary AdidaKK CFX 75 August 20, 2018 05:37
mass flow in is not equal to mass flow out saii CFX 12 March 19, 2018 05:21
error message cuteapathy CFX 14 March 20, 2012 06:45
Constant velocity of the material Sas CFX 15 July 13, 2010 08:56


All times are GMT -4. The time now is 08:06.