[Paraview] [EXTERNAL] Re: Parallel reads in ParaView

Moreland, Kenneth kmorel at sandia.gov
Wed Jan 7 12:48:47 EST 2015


Yeah, I can certainly see that as a problem. We could change the behavior to be more like other modern readers where you have to list all the files, but that would break backward compatibility and some other features (such as restart case files <http://www.paraview.org/Wiki/Restarted_Simulation_Readers#Exodus_Time_Series_Case_Files> and who knows what else).

I don't have a good fix.

-Ken

From: <Scott>, Walter Scott <wascott at sandia.gov<mailto:wascott at sandia.gov>>
Date: Wednesday, January 7, 2015 at 10:33 AM
To: Kenneth Moreland <kmorel at sandia.gov<mailto:kmorel at sandia.gov>>, Andy Bauer <andy.bauer at kitware.com<mailto:andy.bauer at kitware.com>>
Cc: "paraview at paraview.org<mailto:paraview at paraview.org>" <paraview at paraview.org<mailto:paraview at paraview.org>>
Subject: RE: [EXTERNAL] Re: [Paraview] Parallel reads in ParaView

Yep, that did it.  Only option I didn't try.  I will pass this on to my user.

This is also an issue, since if a user wants to only open file 'z_pinch1.exo.8.0', or 'z_pinch1.exo.8.5' which does happen fairly often, they can't.  Any ideas how to get that to work?  Maybe we need to rethink how we open all files?

Thanks,

Alan

From: Moreland, Kenneth
Sent: Wednesday, January 07, 2015 9:46 AM
To: Andy Bauer; Scott, W Alan
Cc: paraview at paraview.org<mailto:paraview at paraview.org>
Subject: Re: [EXTERNAL] Re: [Paraview] Parallel reads in ParaView

Most filters would have to do something like Andy suggests, but the Exodus reader just so happens to have the ability to find all relevant files if you point to the first one (for historical reasons). So using the following should work:

z_pinch1exo8 = ExodusIIReader(FileName='z_pinch1.exo.8.0')

-Ken

From: Andy Bauer <andy.bauer at kitware.com<mailto:andy.bauer at kitware.com>>
Date: Wednesday, January 7, 2015 at 7:34 AM
To: Walter Scott <wascott at sandia.gov<mailto:wascott at sandia.gov>>
Cc: "paraview at paraview.org<mailto:paraview at paraview.org>" <paraview at paraview.org<mailto:paraview at paraview.org>>
Subject: [EXTERNAL] Re: [Paraview] Parallel reads in ParaView

Hi Alan,
I'm thinking it may be easiest to let Python do the heavy lifting on this to figure out the files to read in. You can use glob from the glob module and then sort the files. So that would look like:
=======
import glob
files = glob.glob("z_pinch*")
files.sort() # if the order of the files isn't important you can probably skip this
========
You can use more advanced regex's in the glob() method to get pickier about the desired files, do a bit of playing around with sort() to get non-default sorting and then play with the list to get the files you want from them like the last 4 files.
Cheers,
Andy

On Tue, Jan 6, 2015 at 10:12 PM, Scott, W Alan <wascott at sandia.gov<mailto:wascott at sandia.gov>> wrote:
I have a user that is trying to write a python script that reads in a dataset with a large number of files (say hundreds to thousands of files).  The dataset is Exodus.  This user wants to read in a large number of these datasets (dozens to hundreds), with each dataset comprised of a different number of individual files than the other datasets.  Thus, he doesn't want to read in files like this (example, only 8 files):

z_pinch1exo8 = ExodusIIReader(FileName=['z_pinch1.exo.8.0', 'z_pinch1.exo.8.1', z_pinch1.exo.8.2', 'z_pinch1.exo.8.3', 'z_pinch1.exo.8.4', 'z_pinch1.exo.8.5', 'z_pinch1.exo.8.6', 'z_pinch1.exo.8.7'])


But would rather like this:
z_pinch1exo8 = ExodusIIReader(FileName=['z_pinch1.exo.8.*'])
or
z_pinch1exo8 = ExodusIIReader(FileName=['z_pinch1.exo."totalFileCount".*'])


Is this possible in Python?  What is the format?

If the user wants to window into his data, say take the last 4 files, is this possible?

Thanks,

Alan




_______________________________________________
Powered by www.kitware.com<http://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

Search the list archives at: http://markmail.org/search/?q=ParaView

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/paraview

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/paraview/attachments/20150107/f5e895af/attachment.html>


More information about the ParaView mailing list