[Paraview] Python Script - access the raw data loaded from a dataset and creating new dataset (UNCLASSIFIED)

Burlen Loring bloring at lbl.gov
Fri May 9 18:23:53 EDT 2014


Hi Simon,

Fetching the data to the client is generally a bad idea. Instead you 
could use a python programmable filter which allows you to operate on 
the data in place on the server side. 
http://www.paraview.org/Wiki/Python_Programmable_Filter

Burlen

On 05/09/2014 10:44 AM, Su, Simon M CTR USARMY ARL (US) wrote:
> Classification: UNCLASSIFIED
> Caveats: NONE
>
> Hello,
>
> Are there examples python script on accessing the raw data from the data
> loaded in paraview from python script?
>
> If I have the data loader selected on ParaView GUI and then I do the
> following from the Python Shell,
>
>>>> tt = GetActiveSource()
>>>> tt.ElementVariables.Available
> ['CAUCHY_STRESS2XX', 'CAUCHY_STRESS2YY', 'CAUCHY_STRESS2ZZ',
> 'CAUCHY_STRESS2XY', 'CAUCHY_STRESS2YZ', 'CAUCHY_STRESS2XZ']
>
>>>> dtt = servermanager.Fetch(tt)
> use composite data append
>>>> dtt
> (vtkMultiBlockDataSet)0x9441c50
>
> How do I get the raw data for 'CAUCHY_STRESS2XX'?
>
> And since I have to fetch the data to the client side, what do I need to do
> to the data that I calculated and placed in the data structure that I
> created on the client side to make it available to ParaView (for example, I
> want to color the Surface using the newly calculated variable).
>
> thanks
> -simon
>
>
>
>
>
> Classification: UNCLASSIFIED
> Caveats: NONE
>
>
>
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the ParaView Wiki at: http://paraview.org/Wiki/ParaView
>
> Follow this link to subscribe/unsubscribe:
> http://www.paraview.org/mailman/listinfo/paraview

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.paraview.org/pipermail/paraview/attachments/20140509/f989a116/attachment.html>


More information about the ParaView mailing list