From dan.lipsa at kitware.com Thu Apr 2 10:54:16 2015 From: dan.lipsa at kitware.com (Dan Lipsa) Date: Thu, 2 Apr 2015 10:54:16 -0400 Subject: [Paraview-developers] Ghost and Blanking (Visibility) Changes Message-ID: Dear VTK and ParaView developers, We would like to draw your attention to the following updates to VTK/ParaView that change the way one interfaces to Ghost and Blanking cells and points. These changes have just been merged into master repositories for VTK/ParaView. http://www.kitware.com/blog/home/post/856 We welcome suggestions and/or bug reports on these changes. Best regards, Dan -------------- next part -------------- An HTML attachment was scrubbed... URL: From shawn.waldon at kitware.com Thu Apr 2 12:59:53 2015 From: shawn.waldon at kitware.com (Shawn Waldon) Date: Thu, 2 Apr 2015 12:59:53 -0400 Subject: [Paraview-developers] VisitBridge submodule issues Message-ID: Hi all, The VisitBridge submodule was updated as part of a branch merged into master earlier today. When you update to the current master in an old tree from before the Gitlab migration and run `git submodule update` you may get an error like this: Unable to checkout 'c9f49930c170c9c0ea8e47607a33e3d7ee66f410' in submodule path 'Utilities/VisItBridge' The solution is to run this: git submodule sync This command updates the submodules to point at the new Gitlab locations. After this running `git submodule update` again should find the commit in the VisitBridge submodule. Shawn -------------- next part -------------- An HTML attachment was scrubbed... URL: From ben.boeckel at kitware.com Thu Apr 2 15:43:24 2015 From: ben.boeckel at kitware.com (Ben Boeckel) Date: Thu, 2 Apr 2015 15:43:24 -0400 Subject: [Paraview-developers] VisitBridge submodule issues In-Reply-To: References: Message-ID: <20150402194324.GA2058@megas.kitwarein.com> On Thu, Apr 02, 2015 at 12:59:53 -0400, Shawn Waldon wrote: > This command updates the submodules to point at the new Gitlab locations. > After this running `git submodule update` again should find the commit in > the VisitBridge submodule. So that means kwrobot isn't mirroring from gitlab to the old repos? I thought that was still happening? Though `git submodule sync` does need to be run at some point. Might be worth adding to the `SetupForDevelopment.sh` script. --Ben From utkarsh.ayachit at kitware.com Thu Apr 2 18:34:50 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Thu, 2 Apr 2015 18:34:50 -0400 Subject: [Paraview-developers] VisitBridge submodule issues In-Reply-To: <20150402194324.GA2058@megas.kitwarein.com> References: <20150402194324.GA2058@megas.kitwarein.com> Message-ID: > So that means kwrobot isn't mirroring from gitlab to the old repos? I > thought that was still happening? It is for others. Maybe we decided not to do so for VisItBridge -- I can't remember. From utkarsh.ayachit at kitware.com Wed Apr 8 13:50:54 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Wed, 8 Apr 2015 13:50:54 -0400 Subject: [Paraview-developers] How to use paraview filter within another filter In-Reply-To: References: Message-ID: Custom filters may be the way to go. See this: http://www.paraview.org/Wiki/ParaView/Custom_Filters On Wed, Mar 25, 2015 at 8:09 AM, Chiranjib Sur wrote: > Hi All, > > I want to create a source (for example a cube) and embed the transformation > filter into it. > > To be more precise, I can create a new instance of cube source by > overloading the vtkCubeSource class and while doing so, I want the provision > to apply the transformation filter (translation, rotation, scaling) to it. > > I can do that in two steps, create the source > then apply the > transformation filter separately. > > Is there any way I can embed / use the transformation filter while I create > the source (which appears in the pipeline and the paraview window). In a > nutshell, is there any way to have a filter containing another filter ? > > Is there any way to do this ? Or any available example which I can use to > learn this ? > > Thanks in advance for your help. > > Chiranjib > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Search the list archives at: > http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers > From anton.piccardo-selg at stfc.ac.uk Thu Apr 9 09:44:07 2015 From: anton.piccardo-selg at stfc.ac.uk (anton.piccardo-selg at stfc.ac.uk) Date: Thu, 9 Apr 2015 13:44:07 +0000 Subject: [Paraview-developers] What is the equivalent of ShowCubeAxes in PV4.3.1 Message-ID: <593AFCE559F11049B8F268BE84170A0DC3062D@EXCHMBX03.fed.cclrc.ac.uk> Hi, We are currently migrating our system from PV3.98.1 to PV4.3.1. We were using the QuadView which is now the OrthographicSliceView as I understand it. In the previous system we set the property "ShowCubeAxes" programmatically. After migrating to PV4.3.1, we noticed that this property does not exist any longer to show the axes of the sub windows. Is there an equivalent property, which we can set in the OrthographicSliceView? Many thanks and best regards, Anton From utkarsh.ayachit at kitware.com Thu Apr 9 10:05:15 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Thu, 9 Apr 2015 10:05:15 -0400 Subject: [Paraview-developers] What is the equivalent of ShowCubeAxes in PV4.3.1 In-Reply-To: <593AFCE559F11049B8F268BE84170A0DC3062D@EXCHMBX03.fed.cclrc.ac.uk> References: <593AFCE559F11049B8F268BE84170A0DC3062D@EXCHMBX03.fed.cclrc.ac.uk> Message-ID: Anton, You set in on the Representation, similar to what's done for Render View and others. The Property is called "CubeAxesVisibility". Note, if 4.4, the preferred alternative will be use "AxesGrid" [1]. [1] http://www.kitware.com/blog/home/post/871 On Thu, Apr 9, 2015 at 9:44 AM, wrote: > Hi, > > We are currently migrating our system from PV3.98.1 to PV4.3.1. We were using the QuadView which is now the OrthographicSliceView as I understand it. In the previous system we set the property "ShowCubeAxes" programmatically. After migrating to PV4.3.1, we noticed that this property does not exist any longer to show the axes of the sub windows. Is there an equivalent property, which we can set in the OrthographicSliceView? > > Many thanks and best regards, > > Anton > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html > > Search the list archives at: http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers From ben.boeckel at kitware.com Thu Apr 9 11:22:44 2015 From: ben.boeckel at kitware.com (Ben Boeckel) Date: Thu, 9 Apr 2015 11:22:44 -0400 Subject: [Paraview-developers] [HEADSUP] Qt5 as default Message-ID: <20150409152244.GA25709@megas.kitware.com> Hi, I'm going to start migrating the superbuild to do Qt5 instead of Qt4 by default. Once this is complete, ParaView and the binaries will default to Qt5 instead of Qt4 (though Qt4 support will still be unchanged, just not the default). This does mean that older Linux machines (of 2007 or so vintage due to X and xcb being too old to get a working stack based on some prior attempts at getting Qt5 to work on our Linux binary builder) will not be able to run the default binaries and will require builds from source. Thanks, --Ben From sur.chiranjib at gmail.com Fri Apr 10 08:06:09 2015 From: sur.chiranjib at gmail.com (Chiranjib Sur) Date: Fri, 10 Apr 2015 17:36:09 +0530 Subject: [Paraview-developers] Creating custom tag for VTK points in vtkriter Message-ID: Hi All, The vtkpoint information in vtkpolydata (.vtp) is displayed as From utkarsh.ayachit at kitware.com Sun Apr 12 14:32:22 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Sun, 12 Apr 2015 14:32:22 -0400 Subject: [Paraview-developers] Creating custom tag for VTK points in vtkriter In-Reply-To: References: Message-ID: This isn't possible. However, you may want to try using FieldData instead to add additional "meta-data". Utkarsh On Fri, Apr 10, 2015 at 8:06 AM, Chiranjib Sur wrote: > Hi All, > The vtkpoint information in vtkpolydata (.vtp) is displayed as > > > format="binary" ...... > > I use the vtkXMLPolydataWriter to write this information. Is there any way > to change the tag (e.g. CustomTag) to something different, so that the > header of the vtkPOints will look like something : > > > format="binary" .... > > > Thanks, > Chiranjib > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Search the list archives at: > http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers > From windbox.energy at gmail.com Mon Apr 13 07:47:46 2015 From: windbox.energy at gmail.com (Windbox) Date: Mon, 13 Apr 2015 13:47:46 +0200 Subject: [Paraview-developers] ParaViewWeb for Windows In-Reply-To: <552B8251.2010607@gmail.com> References: <5527A759.6030308@gmail.com> <5527AC16.9090801@gmail.com> <552B8251.2010607@gmail.com> Message-ID: <552BACE2.5080604@gmail.com> Dear all, I am trying to make a static HTML5/PHP page which should include the PVW Visualizer. Up to now, I was testing the main website on Windows & WAMP stack. I was able to follow the tutorials and launch the Visualizer on PV-4.1.0, but I am not able to launch it on PV-4.3.1 as the folder structure is quite different. What I would like to know is: 1) Is PV-4.1.0 ok for a web app or the improvements on Pv-4.3.1 made web visualization much faster? 2) Can anyone explain me step-by-step how to launch the visualizer inside a div of a static web page under Windows/WAMP? 3) if 2 is not possible, should I setup a VM with Ubuntu? Any good tutorial to follow? Thanks in advance for your Reply. All the best, Christian From sebastien.jourdain at kitware.com Mon Apr 13 10:25:33 2015 From: sebastien.jourdain at kitware.com (Sebastien Jourdain) Date: Mon, 13 Apr 2015 08:25:33 -0600 Subject: [Paraview-developers] ParaViewWeb for Windows In-Reply-To: <552BACE2.5080604@gmail.com> References: <5527A759.6030308@gmail.com> <5527AC16.9090801@gmail.com> <552B8251.2010607@gmail.com> <552BACE2.5080604@gmail.com> Message-ID: Hi Christian, For ParaView 4.2+: - You are facing an issue that we did not stream out yet with Windows. It is possible to build you own ParaView with Web support on Windows, but you will need extra steps and some native dependency such as the win32api for python at build time. - But if instead, you are using our binaries, the Windows' one don't provide ParaViewWeb as we didn't wanted to embed that extra dependency. Hence your issue. 1) It is not the speed but the capabilities and flexibilities that got improved here. (Volume rendering, render view settings, more filter support...) 2) If you look at the 4.3 version, inside the index.html file, you will see what is done to do exactly that. For 4.1, it should be similar but less clear. 3) http://www.paraview.org/ParaView3/Doc/Nightly/www/js-doc/index.html#!/guide/ubuntu_14_04 Good luck, Seb On Mon, Apr 13, 2015 at 5:47 AM, Windbox wrote: > Dear all, > I am trying to make a static HTML5/PHP page which should include the PVW > Visualizer. > Up to now, I was testing the main website on Windows & WAMP stack. > I was able to follow the tutorials and launch the Visualizer on PV-4.1.0, > but I am not able to launch it on PV-4.3.1 as the folder structure is quite > different. > > What I would like to know is: > 1) Is PV-4.1.0 ok for a web app or the improvements on Pv-4.3.1 made web > visualization much faster? > 2) Can anyone explain me step-by-step how to launch the visualizer inside > a div of a static web page under Windows/WAMP? > 3) if 2 is not possible, should I setup a VM with Ubuntu? Any good > tutorial to follow? > > Thanks in advance for your Reply. > All the best, > Christian > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at http://www.kitware.com/ > opensource/opensource.html > > Search the list archives at: http://markmail.org/search/?q= > Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Gerald.Lodron at joanneum.at Mon Apr 13 13:25:59 2015 From: Gerald.Lodron at joanneum.at (Lodron, Gerald) Date: Mon, 13 Apr 2015 17:25:59 +0000 Subject: [Paraview-developers] ParaView and double precision Rendering Message-ID: <16363023d4454e1b9eb3b0d582c91bbd@RZJMBX2.jr1.local> Hello I made a paraview reader plugin which loads Point data of type double from an ASCII file (can be choosen as checkbox in reader parameter gui). It is important that point data type is double since our values have a huge offset, e.g. Coordinate in float: 3376382.75 -325198.59375 -121298.125 Coordinate in double: 3376382.849028525874 -325198.60899497801438 -121298.12806414699298 (same ASCII input file of type double, above printings come from spreadsheet view so loading is correct) (all my points have such small changes, I definitely can see those small changes in 3d) The problem is: I load the dataset once in float and once in double ( I checked result in spreadsheed view) I cannot see any differences in 3d renderer when I swap visibility of float and double input (but you can see in spreadsheet). Is the double precision rendering not correct/not supported? Any ideas? Best regards, Gerald Lodron Machine Vision Applications DIGITAL - Institute for Information and Communication Technologies JOANNEUM RESEARCH Forschungsgesellschaft mbH Steyrergasse 17, 8010 Graz, AUSTRIA phone:? +43-316-876-1751???????? fax: +43-316-876-1751 web:??? http://www.joanneum.at/digital e-mail: gerald.lodron at joanneum.at From sur.chiranjib at gmail.com Tue Apr 14 06:44:52 2015 From: sur.chiranjib at gmail.com (Chiranjib Sur) Date: Tue, 14 Apr 2015 16:14:52 +0530 Subject: [Paraview-developers] how to build a re-distributable linux plugin (.so) Message-ID: Hi All, I am trying to create a plugin with an intention to use with Paraview in any machine (just by loading the .so file from Tools>Manage Plugins..). To do that, I need to build the .so file without any hard link. Can anyone tell me how to do that ? There might be an answer from the earlier mailing list archive. If so, kindly point me towards that. I am following the following steps : 1. Download ParaView-4.3.1 (git clone..) 2. Create a build directory 3. Add my plugin under Examples/Plugins 4. Run cmake from the build directory 5. Run make for my plugin and a .so is created (e.g. : named as : myplugin.so) This myplugin.so contains hard link to different locations linked to my system/userID which I want to remove so that the .so file become portable and loaded from any machine with same level of system software. Thanking you in advance for the help. Chiranjib -------------- next part -------------- An HTML attachment was scrubbed... URL: From joachim.pouderoux at kitware.com Tue Apr 14 09:26:53 2015 From: joachim.pouderoux at kitware.com (Joachim Pouderoux) Date: Tue, 14 Apr 2015 15:26:53 +0200 Subject: [Paraview-developers] [vtk-developers] Ghost and Blanking (Visibility) Changes In-Reply-To: References: Message-ID: Thanks, this is good to now. Question: the new architecture does not provide information about ghost level anymore. Is this information useless in general and was never used by any vtk filter? Beside that , the change of VTK XML file version induced by this change can be a problem: I use to generate PVTP/PTVU files on a project I generally link with the latest VTK. I use to visualize the obtained dataset with ParaView. However, since this change, I am not able to open any of those VTK XML files with PV <=4.3.1. To do so I have to manually edit the files and reverse the version tag from 2 to 1... My dataset have no blanking or ghost cells, thus may be one could only specify version 2 in the data writer if the data *really *contains information that a previous version of the reader could not read? Best, Joachim *Joachim Pouderoux* *PhD, Technical Expert* *Kitware SAS * 2015-04-02 16:54 GMT+02:00 Dan Lipsa : > > Dear VTK and ParaView developers, > We would like to draw your attention to the following updates to > VTK/ParaView that change the way one interfaces to Ghost and Blanking cells > and points. > > These changes have just been merged into master repositories for > VTK/ParaView. > > http://www.kitware.com/blog/home/post/856 > > We welcome suggestions and/or bug reports on these changes. > > Best regards, > Dan > > > > > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Search the list archives at: http://markmail.org/search/?q=vtk-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From berk.geveci at kitware.com Tue Apr 14 09:31:33 2015 From: berk.geveci at kitware.com (Berk Geveci) Date: Tue, 14 Apr 2015 09:31:33 -0400 Subject: [Paraview-developers] [vtk-developers] Ghost and Blanking (Visibility) Changes In-Reply-To: References: Message-ID: > Question: the new architecture does not provide information about ghost level anymore. Is this information useless in > general and was never used by any vtk filter? The ghost level information was only used to strip a particular ghost level, something that was done in the filters. Since we no longer expect filters to strip ghost levels (this is done before the mapper), the levels are no longer needed. > I use to generate PVTP/PTVU files on a project I generally link with the latest VTK. I use to visualize the obtained dataset with ParaView. However, since this change, I am not able to open any of those VTK XML files with PV <=4.3.1. To do so I have to manually edit the files and reverse the version tag from 2 to 1... My dataset have no blanking or ghost cells, thus may be one could only specify version 2 in the data writer if the data *really *contains information that a previous version of the reader could not read? This is a great idea. Dan: if it is not too hard to do, please do this. -berk On Tue, Apr 14, 2015 at 9:26 AM, Joachim Pouderoux < joachim.pouderoux at kitware.com> wrote: > Thanks, this is good to now. > Question: the new architecture does not provide information about ghost > level anymore. Is this information useless in general and was never used by > any vtk filter? > > Beside that , the change of VTK XML file version induced by this change > can be a problem: > I use to generate PVTP/PTVU files on a project I generally link with the > latest VTK. I use to visualize the obtained dataset with ParaView. However, > since this change, I am not able to open any of those VTK XML files with PV > <=4.3.1. To do so I have to manually edit the files and reverse the version > tag from 2 to 1... My dataset have no blanking or ghost cells, thus may be > one could only specify version 2 in the data writer if the data *really *contains > information that a previous version of the reader could not read? > > Best, > Joachim > > *Joachim Pouderoux* > > *PhD, Technical Expert* > *Kitware SAS * > > > 2015-04-02 16:54 GMT+02:00 Dan Lipsa : > >> >> Dear VTK and ParaView developers, >> We would like to draw your attention to the following updates to >> VTK/ParaView that change the way one interfaces to Ghost and Blanking cells >> and points. >> >> These changes have just been merged into master repositories for >> VTK/ParaView. >> >> http://www.kitware.com/blog/home/post/856 >> >> We welcome suggestions and/or bug reports on these changes. >> >> Best regards, >> Dan >> >> >> >> >> >> _______________________________________________ >> Powered by www.kitware.com >> >> Visit other Kitware open-source projects at >> http://www.kitware.com/opensource/opensource.html >> >> Search the list archives at: http://markmail.org/search/?q=vtk-developers >> >> Follow this link to subscribe/unsubscribe: >> http://public.kitware.com/mailman/listinfo/vtk-developers >> >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From dan.lipsa at kitware.com Tue Apr 14 10:06:56 2015 From: dan.lipsa at kitware.com (Dan Lipsa) Date: Tue, 14 Apr 2015 10:06:56 -0400 Subject: [Paraview-developers] [vtk-developers] Ghost and Blanking (Visibility) Changes In-Reply-To: References: Message-ID: > > > > > I use to generate PVTP/PTVU files on a project I generally link with the > latest VTK. I use to visualize the obtained dataset with ParaView. However, > since this change, I am not able to open any of those VTK XML files with PV > <=4.3.1. To do so I have to manually edit the files and reverse the version > tag from 2 to 1... My dataset have no blanking or ghost cells, thus may be > one could only specify version 2 in the data writer if the data *really *contains > information that a previous version of the reader could not read? > > This is a great idea. Dan: if it is not too hard to do, please do this. > I'll take a look a this. Maybe we should change the readers to only issue a warning if the file version is newer than the reader. It should not be a problem for old readers to read new files at least in this case - the only thing that happens is that ghost levels and blanking are not read correctly - this may not matter in certain cases. Dan > > -berk > > On Tue, Apr 14, 2015 at 9:26 AM, Joachim Pouderoux < > joachim.pouderoux at kitware.com> wrote: > >> Thanks, this is good to now. >> Question: the new architecture does not provide information about ghost >> level anymore. Is this information useless in general and was never used by >> any vtk filter? >> >> Beside that , the change of VTK XML file version induced by this change >> can be a problem: >> I use to generate PVTP/PTVU files on a project I generally link with the >> latest VTK. I use to visualize the obtained dataset with ParaView. However, >> since this change, I am not able to open any of those VTK XML files with PV >> <=4.3.1. To do so I have to manually edit the files and reverse the version >> tag from 2 to 1... My dataset have no blanking or ghost cells, thus may be >> one could only specify version 2 in the data writer if the data *really *contains >> information that a previous version of the reader could not read? >> >> Best, >> Joachim >> >> *Joachim Pouderoux* >> >> *PhD, Technical Expert* >> *Kitware SAS * >> >> >> 2015-04-02 16:54 GMT+02:00 Dan Lipsa : >> >>> >>> Dear VTK and ParaView developers, >>> We would like to draw your attention to the following updates to >>> VTK/ParaView that change the way one interfaces to Ghost and Blanking cells >>> and points. >>> >>> These changes have just been merged into master repositories for >>> VTK/ParaView. >>> >>> http://www.kitware.com/blog/home/post/856 >>> >>> We welcome suggestions and/or bug reports on these changes. >>> >>> Best regards, >>> Dan >>> >>> >>> >>> >>> >>> _______________________________________________ >>> Powered by www.kitware.com >>> >>> Visit other Kitware open-source projects at >>> http://www.kitware.com/opensource/opensource.html >>> >>> Search the list archives at: >>> http://markmail.org/search/?q=vtk-developers >>> >>> Follow this link to subscribe/unsubscribe: >>> http://public.kitware.com/mailman/listinfo/vtk-developers >>> >>> >>> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From joachim.pouderoux at kitware.com Tue Apr 14 10:58:21 2015 From: joachim.pouderoux at kitware.com (Joachim Pouderoux) Date: Tue, 14 Apr 2015 16:58:21 +0200 Subject: [Paraview-developers] [vtk-developers] Ghost and Blanking (Visibility) Changes In-Reply-To: References: Message-ID: The problem is that we cannot change the behaviour of old code (the one available in PV <= 4.3.1) so to make them work (as they just refuse to read files with a version > 1) we have to change the actual writer. *Joachim Pouderoux* *PhD, Technical Expert* *Kitware SAS * 2015-04-14 16:06 GMT+02:00 Dan Lipsa : > >> >> > I use to generate PVTP/PTVU files on a project I generally link with >> the latest VTK. I use to visualize the obtained dataset with ParaView. >> However, since this change, I am not able to open any of those VTK XML >> files with PV <=4.3.1. To do so I have to manually edit the files and >> reverse the version tag from 2 to 1... My dataset have no blanking or ghost >> cells, thus may be one could only specify version 2 in the data writer if >> the data *really *contains information that a previous version of the >> reader could not read? >> >> This is a great idea. Dan: if it is not too hard to do, please do this. >> > > I'll take a look a this. Maybe we should change the readers to only issue > a warning if the file version is newer than the reader. It should not be a > problem for old readers to read new files at least in this case - the only > thing that happens is that ghost levels and blanking are not read correctly > - this may not matter in certain cases. > > Dan > > > > > > >> >> -berk >> >> On Tue, Apr 14, 2015 at 9:26 AM, Joachim Pouderoux < >> joachim.pouderoux at kitware.com> wrote: >> >>> Thanks, this is good to now. >>> Question: the new architecture does not provide information about ghost >>> level anymore. Is this information useless in general and was never used by >>> any vtk filter? >>> >>> Beside that , the change of VTK XML file version induced by this change >>> can be a problem: >>> I use to generate PVTP/PTVU files on a project I generally link with the >>> latest VTK. I use to visualize the obtained dataset with ParaView. However, >>> since this change, I am not able to open any of those VTK XML files with PV >>> <=4.3.1. To do so I have to manually edit the files and reverse the version >>> tag from 2 to 1... My dataset have no blanking or ghost cells, thus may be >>> one could only specify version 2 in the data writer if the data *really >>> *contains information that a previous version of the reader could not >>> read? >>> >>> Best, >>> Joachim >>> >>> *Joachim Pouderoux* >>> >>> *PhD, Technical Expert* >>> *Kitware SAS * >>> >>> >>> 2015-04-02 16:54 GMT+02:00 Dan Lipsa : >>> >>>> >>>> Dear VTK and ParaView developers, >>>> We would like to draw your attention to the following updates to >>>> VTK/ParaView that change the way one interfaces to Ghost and Blanking cells >>>> and points. >>>> >>>> These changes have just been merged into master repositories for >>>> VTK/ParaView. >>>> >>>> http://www.kitware.com/blog/home/post/856 >>>> >>>> We welcome suggestions and/or bug reports on these changes. >>>> >>>> Best regards, >>>> Dan >>>> >>>> >>>> >>>> >>>> >>>> _______________________________________________ >>>> Powered by www.kitware.com >>>> >>>> Visit other Kitware open-source projects at >>>> http://www.kitware.com/opensource/opensource.html >>>> >>>> Search the list archives at: >>>> http://markmail.org/search/?q=vtk-developers >>>> >>>> Follow this link to subscribe/unsubscribe: >>>> http://public.kitware.com/mailman/listinfo/vtk-developers >>>> >>>> >>>> >>> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From dan.lipsa at kitware.com Tue Apr 14 11:03:51 2015 From: dan.lipsa at kitware.com (Dan Lipsa) Date: Tue, 14 Apr 2015 11:03:51 -0400 Subject: [Paraview-developers] [vtk-developers] Ghost and Blanking (Visibility) Changes In-Reply-To: References: Message-ID: On Tue, Apr 14, 2015 at 10:58 AM, Joachim Pouderoux < joachim.pouderoux at kitware.com> wrote: > The problem is that we cannot change the behaviour of old code (the one > available in PV <= 4.3.1) so to make them work (as they just refuse to read > files with a version > 1) we have to change the actual writer. > Indeed. I will change the writer. -------------- next part -------------- An HTML attachment was scrubbed... URL: From M.Schlottke at aia.rwth-aachen.de Tue Apr 14 11:40:11 2015 From: M.Schlottke at aia.rwth-aachen.de (Schlottke, Michael) Date: Tue, 14 Apr 2015 15:40:11 +0000 Subject: [Paraview-developers] How to get raw MPI communicator in plugin Message-ID: Hi again, I was wondering what the ?canonical? way is to get the correct MPI communicator within a parallel reader plugin (e.g. for use in a parallel I/O library)? Until now I just used ?MPI_COMM_WORLD? and hoped for the best. However, I noticed that in the CosmoTools (https://github.com/Kitware/ParaView/blob/master/ParaViewCore/VTKExtensions/CosmoTools/vtkGenericIOUtilities.cxx#L25) or the AdiosReader (https://github.com/Kitware/ParaView/blob/master/Plugins/AdiosReader/vtkAdiosInternals.h#L103) the raw MPI communicator is obtained through some calls to vtkMPICommunicator objects. Is this the right way to do it? As a second part to this question, what is the correct way of initializing (and finalizing?) MPI from within a reader plugin if it was not initialized (e.g. because paraview was started without the ?mpi flag)? Is this even possible to to ?correctly? or will it always be a hack to do this from within a plugin? Regards, Michael -- Michael Schlottke Chair of Fluid Mechanics and Institute of Aerodynamics RWTH Aachen University W?llnerstra?e 5a 52062 Aachen Germany Phone: +49 (241) 80 95188 Fax: +49 (241) 80 92257 Mail: m.schlottke at aia.rwth-aachen.de Web: http://www.aia.rwth-aachen.de -------------- next part -------------- An HTML attachment was scrubbed... URL: From utkarsh.ayachit at kitware.com Tue Apr 14 12:00:30 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Tue, 14 Apr 2015 12:00:30 -0400 Subject: [Paraview-developers] How to get raw MPI communicator in plugin In-Reply-To: References: Message-ID: > However, I noticed that in the CosmoTools ... Is this the right way to do it? Yes, that'd be a good way of getting the MPI communicator. > As a second part to this question, what is the correct way of initializing > (and finalizing?) MPI from within a reader plugin if it was not initialized > (e.g. because paraview was started without the ?mpi flag)? Is this even > possible to to ?correctly? or will it always be a hack to do this from > within a plugin? It will always be a hack to do this in the plugin. "--mpi" flag was added to support such use-cases. You can mark a reader/filter as unavailable when MPI is not initialized too, if if your reader/filter needs MPI. From berk.geveci at kitware.com Tue Apr 14 12:15:49 2015 From: berk.geveci at kitware.com (Berk Geveci) Date: Tue, 14 Apr 2015 12:15:49 -0400 Subject: [Paraview-developers] ParaView and double precision Rendering In-Reply-To: <16363023d4454e1b9eb3b0d582c91bbd@RZJMBX2.jr1.local> References: <16363023d4454e1b9eb3b0d582c91bbd@RZJMBX2.jr1.local> Message-ID: OpenGL does not support double precision. VTK does not do anything special in handling large coordinates and passes them to OpenGL directly. So currently, you have to handle this yourself by rescaling your data. Best, -berk On Mon, Apr 13, 2015 at 1:25 PM, Lodron, Gerald wrote: > Hello > > I made a paraview reader plugin which loads Point data of type double from > an ASCII file (can be choosen as checkbox in reader parameter gui). It is > important that point data type is double since our values have a huge > offset, e.g. > > Coordinate in float: 3376382.75 -325198.59375 -121298.125 > Coordinate in double: 3376382.849028525874 -325198.60899497801438 > -121298.12806414699298 > (same ASCII input file of type double, above printings come from > spreadsheet view so loading is correct) > (all my points have such small changes, I definitely can see those small > changes in 3d) > > The problem is: I load the dataset once in float and once in double ( I > checked result in spreadsheed view) I cannot see any differences in 3d > renderer when I swap visibility of float and double input (but you can see > in spreadsheet). Is the double precision rendering not correct/not > supported? > Any ideas? > > Best regards, > > Gerald Lodron > Machine Vision Applications > DIGITAL - Institute for Information and Communication Technologies > > JOANNEUM RESEARCH Forschungsgesellschaft mbH > Steyrergasse 17, 8010 Graz, AUSTRIA > > phone: +43-316-876-1751 > fax: +43-316-876-1751 > web: http://www.joanneum.at/digital > e-mail: gerald.lodron at joanneum.at > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Search the list archives at: > http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers > -------------- next part -------------- An HTML attachment was scrubbed... URL: From utkarsh.ayachit at kitware.com Tue Apr 14 13:41:21 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Tue, 14 Apr 2015 13:41:21 -0400 Subject: [Paraview-developers] how to build a re-distributable linux plugin (.so) In-Reply-To: References: Message-ID: Try doing a "make install" with CMAKE_INSTALL_PREFIX set to some temporary location. That should strip the paths on the plugin. Note, however that you can only load this plugin on a build of ParaView built similarly i.e. it won't work on the ParaView binaries downloaded from paraview.org On Tue, Apr 14, 2015 at 6:44 AM, Chiranjib Sur wrote: > Hi All, > I am trying to create a plugin with an intention to use with Paraview in any > machine (just by loading the .so file from Tools>Manage Plugins..). > To do that, I need to build the .so file without any hard link. > > Can anyone tell me how to do that ? There might be an answer from the > earlier mailing list archive. If so, kindly point me towards that. > > I am following the following steps : > 1. Download ParaView-4.3.1 (git clone..) > 2. Create a build directory > 3. Add my plugin under Examples/Plugins > 4. Run cmake from the build directory > 5. Run make for my plugin and a .so is created (e.g. : named as : > myplugin.so) > > This myplugin.so contains hard link to different locations linked to my > system/userID which I want to remove so that the .so file become portable > and loaded from any machine with same level of system software. > > Thanking you in advance for the help. > > Chiranjib > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Search the list archives at: > http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers > From utkarsh.ayachit at kitware.com Tue Apr 14 15:42:33 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Tue, 14 Apr 2015 15:42:33 -0400 Subject: [Paraview-developers] Changing ColorMaps.xml format Message-ID: Folks, I am looking at adding tracing support for loading color map presets. When doing that, I am also looking at extending the "presets" mechanism to support saving/loading opacity transfer function (along with color) and other things that may be important in preset. As I am doing this, I realize that the ColorMaps XML format is very limited, for example, there's no way to save the BelowRangeColor in a preset. If we go on extending the XML to add support for other attributes on the color/opacity map that a user may potentially want to save in a color map, we would just end up with a different way to specifying what the XML state for the PVLookupTable proxy saves anyways. If I remember correctly, we invented the ColorMap XML format since we thought the lookuptable proxy's XML state will be too complex for a user to manually create. So here's a proposal: why don't we change the color map file format to be a JSON instead, that matches what we currently save in UserSettings.json file anyways. e.g. { "Annotations" : [ "100", "100" ], "BelowRangeColor" : [ 0.6666666666666666, 0, 0 ], "ColorSpace" : "HSV", "NanColor" : [ 1, 1, 0 ], "RGBPoints" : [ 37.35310363769531, 0.278431, 0.278431, 0.858824, 71.59813206481934, 0, 0, 0.360784, 105.6036847686768, 0, 1, 1, 140.0881889190674, 0, 0.501961, 0, 174.0937416229248, 1, 1, 0, 208.3387700500488, 1, 0.380392, 0, 242.5837984771728, 0.419608, 0, 0, 276.8288269042969, 0.878431, 0.301961, 0.301961 ], "UseBelowRangeColor" : 1 } All fields are of course optional. Thus for the attributes supported by the current color map xml, the JSON would only be something like: { "ColorSpace" : "HSV", "NanColor" : [ 1, 1, 0 ], "RGBPoints" : [ 37.35310363769531, 0.278431, 0.278431, 0.858824, 71.59813206481934, 0, 0, 0.360784, 105.6036847686768, 0, 1, 1, 140.0881889190674, 0, 0.501961, 0, 174.0937416229248, 1, 1, 0, 208.3387700500488, 1, 0.380392, 0, 242.5837984771728, 0.419608, 0, 0, 276.8288269042969, 0.878431, 0.301961, 0.301961 ] } This is not much more complex the current color map XML, for example: Of course, we'll support loading old style XMLs for backwards compatibiltiy as well as a tool to convert old style XMLs to the new style json. Thoughts? Objections? Alternative suggestions? Utkarsh From david.thompson at kitware.com Tue Apr 14 16:14:40 2015 From: david.thompson at kitware.com (David Thompson) Date: Tue, 14 Apr 2015 16:14:40 -0400 Subject: [Paraview-developers] Changing ColorMaps.xml format In-Reply-To: References: Message-ID: <7E754648-5B26-42E4-B943-8D422B08816A@kitware.com> Hi Utkarsh, > I am looking at adding tracing support for loading color map presets. > When doing that, > I am also looking at extending the "presets" mechanism to support > saving/loading opacity transfer function (along with color) and other > things that may be important in preset. ... I am all for moving to JSON. 1. It would be nice to make "RGBPoints" an array of arrays rather than a flat array (for legibility and possibly to distinguish between 3-component RGB and 4-component RGBA). 2. Just making sure: you plan to continue supporting categorical values, so {"IndexedLookup": true} will work? (I do not see it in the example, but since the default would be false...) 3. The format of "Annotations" in your example is easy for a machine to parse but hard for a person. I don't object to it, but if the point is to let humans edit colormaps, may this would be better: { "Annotations" : [ {"value": "100", "label": "some"}, ... {"value": "500", "label": "more"} ] } David From utkarsh.ayachit at kitware.com Tue Apr 14 16:39:59 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Tue, 14 Apr 2015 16:39:59 -0400 Subject: [Paraview-developers] Changing ColorMaps.xml format In-Reply-To: <7E754648-5B26-42E4-B943-8D422B08816A@kitware.com> References: <7E754648-5B26-42E4-B943-8D422B08816A@kitware.com> Message-ID: Yes/+1 on all accounts. I think we can make the JSON more readable, quite easily -- which would be good for the UserSettings.json too, in any case. On Tue, Apr 14, 2015 at 4:14 PM, David Thompson wrote: > Hi Utkarsh, > >> I am looking at adding tracing support for loading color map presets. >> When doing that, >> I am also looking at extending the "presets" mechanism to support >> saving/loading opacity transfer function (along with color) and other >> things that may be important in preset. ... > > I am all for moving to JSON. > > 1. It would be nice to make "RGBPoints" an array of arrays rather than a flat array (for legibility and possibly to distinguish between 3-component RGB and 4-component RGBA). > > 2. Just making sure: you plan to continue supporting categorical values, so {"IndexedLookup": true} will work? (I do not see it in the example, but since the default would be false...) > > 3. The format of "Annotations" in your example is easy for a machine to parse but hard for a person. I don't object to it, but if the point is to let humans edit colormaps, may this would be better: > > { > "Annotations" : [ > {"value": "100", "label": "some"}, > ... > {"value": "500", "label": "more"} > ] > } > > > David From ben.boeckel at kitware.com Tue Apr 14 17:15:09 2015 From: ben.boeckel at kitware.com (Ben Boeckel) Date: Tue, 14 Apr 2015 17:15:09 -0400 Subject: [Paraview-developers] [HEADSUP] Buildbot host changing Message-ID: <20150414211509.GA23965@megas.kitware.com> Hi all, We are moving the buildbot host to another machine. While this is happening, builds and their results may be interrupted until the new host is active. The plan is to do this early tomorrow (Wednesday) morning (probably around 9am). Things should be back to normal within an hour after the migration has started. Thanks, --Ben From ben.boeckel at kitware.com Wed Apr 15 10:13:51 2015 From: ben.boeckel at kitware.com (Ben Boeckel) Date: Wed, 15 Apr 2015 10:13:51 -0400 Subject: [Paraview-developers] [HEADSUP] Buildbot host changing In-Reply-To: <20150414211509.GA23965@megas.kitware.com> References: <20150414211509.GA23965@megas.kitware.com> Message-ID: <20150415141351.GA24308@megas.kitware.com> On Tue, Apr 14, 2015 at 17:15:09 -0400, Ben Boeckel wrote: > We are moving the buildbot host to another machine. While this is > happening, builds and their results may be interrupted until the new > host is active. The plan is to do this early tomorrow (Wednesday) > morning (probably around 9am). Things should be back to normal within an > hour after the migration has started. The move is complete. Some builds may show up as duplicated on CDash due to the move restarting builds. Thanks, --Ben From M.Schlottke at aia.rwth-aachen.de Fri Apr 17 04:19:24 2015 From: M.Schlottke at aia.rwth-aachen.de (Schlottke, Michael) Date: Fri, 17 Apr 2015 08:19:24 +0000 Subject: [Paraview-developers] Necessity for RequestDataObject in custom reader plugin Message-ID: Hi folks, Can somebody help me understand the purpose of the RequestDataObject() for a reader plugin? I see this method pop up now and then (typically in generic examples on how to create custom sources), but most of the readers in the Plugins/ directory do not seem to use it. Is there a simple definition I can use to decide if and how to implement it? Regards, Michael P.S.: I?m working on two readers of vtkUnstructuredGridAlgorithm and vtkMultiBlockDataSetAlgorithm type. From sur.chiranjib at gmail.com Fri Apr 17 06:34:24 2015 From: sur.chiranjib at gmail.com (Chiranjib Sur) Date: Fri, 17 Apr 2015 16:04:24 +0530 Subject: [Paraview-developers] object not displaying in the paraview window Message-ID: Hi All, I want to apply the tranform filter while I create an object in paraview. TO try with I have overloaded vtkCubeSource class and can create the object which appears in the paraview pipeline and I can visualize the object in the PV window. Now I want to apply the transformation filter (vtkTransform) to the objct when I create it. To do that I have overloaded the RequestData function like the following. The code is compiling and executing but when I create the object and apply transform, nothing is appearing in the PV visualization window. Can anybody help me pointing out what is going wrong with my implementation. I cam copying my code below Thanks, Chiranjib ------ int MyOwnCubeSource::RequestData( vtkInformation *vtkNotUsed(request), vtkInformationVector **vtkNotUsed(inputVector), vtkInformationVector *outputVector) { // get the info object vtkInformation *outInfo = outputVector->GetInformationObject(0); // get the ouptut vtkPolyData *output = vtkPolyData::SafeDownCast( outInfo->Get(vtkDataObject::DATA_OBJECT())); .... .... // output (type vtkPolyData) is already ready at this stage // If I don?t appy transform operation afterwards, I can visualize the object in the PV pipeline // -----------------------------------------------// // Implementation of vtkTransform starts here double _rotationZ = 30.0; // Define transform vtkSmartPointer transform = vtkSmartPointer::New(); // Define transformModel : transform filter vtkSmartPointer transformModel = vtkSmartPointer::New(); transformModel->SetTransform(transform); //Decoupling the pipeline and asking the transformfilter to update the newpipeline (created out of shallowcopy) vtkNew cubeCopy; cubeCopy->ShallowCopy(output); transformModel->SetInputData(cubeCopy.GetPointer()); // Describe all the transform operations transform->PostMultiply(); transform->RotateZ(10*_rotationZ); transform->Update(); // getting the transformed output vtkSmartPointer transformedOutput = transformModel->GetOutput(); // Shallowcopy the transformed output to the old pipeline output->ShallowCopy(transformedOutput); // A this stage "output" should be updated and the visualization pipeline should show the transformed object -------------- next part -------------- An HTML attachment was scrubbed... URL: From utkarsh.ayachit at kitware.com Fri Apr 17 08:24:56 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Fri, 17 Apr 2015 08:24:56 -0400 Subject: [Paraview-developers] object not displaying in the paraview window In-Reply-To: References: Message-ID: You're missing a call to `transformModel->Update()` before calling `transformModel->GetOutput()`. The filter never updated, and hence its output is empty. Utkarsh On Fri, Apr 17, 2015 at 6:34 AM, Chiranjib Sur wrote: > Hi All, > I want to apply the tranform filter while I create an object in paraview. TO > try with I have overloaded vtkCubeSource class and can create the object > which appears in the paraview pipeline and I can visualize the object in the > PV window. > > Now I want to apply the transformation filter (vtkTransform) to the objct > when I create it. To do that I have overloaded the RequestData function like > the following. > > The code is compiling and executing but when I create the object and apply > transform, nothing is appearing in the PV visualization window. > > Can anybody help me pointing out what is going wrong with my implementation. > > I cam copying my code below > > Thanks, > Chiranjib > > > ------ > > > > int MyOwnCubeSource::RequestData( vtkInformation *vtkNotUsed(request), > > vtkInformationVector **vtkNotUsed(inputVector), > > vtkInformationVector *outputVector) > > { > > // get the info object > > vtkInformation *outInfo = outputVector->GetInformationObject(0); > > > > // get the ouptut > > vtkPolyData *output = vtkPolyData::SafeDownCast( > > outInfo->Get(vtkDataObject::DATA_OBJECT())); > > .... > > .... > > > > // output (type vtkPolyData) is already ready at this stage > > > > // If I don?t appy transform operation afterwards, I can visualize the > object in the PV pipeline > > > > > > // -----------------------------------------------// > > > > // Implementation of vtkTransform starts here > > > > double _rotationZ = 30.0; > > > > // Define transform > > vtkSmartPointer transform = > vtkSmartPointer::New(); > > > > // Define transformModel : transform filter > > vtkSmartPointer transformModel = > vtkSmartPointer::New(); > > transformModel->SetTransform(transform); > > > > //Decoupling the pipeline and asking the transformfilter to update the > newpipeline (created out of shallowcopy) > > vtkNew cubeCopy; > > cubeCopy->ShallowCopy(output); > > transformModel->SetInputData(cubeCopy.GetPointer()); > > > > // Describe all the transform operations > > transform->PostMultiply(); > > transform->RotateZ(10*_rotationZ); > > transform->Update(); > > > > // getting the transformed output > > vtkSmartPointer transformedOutput = > transformModel->GetOutput(); > > > > // Shallowcopy the transformed output to the old pipeline > > > > output->ShallowCopy(transformedOutput); > > > > // A this stage "output" should be updated and the visualization pipeline > should show the transformed object > > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Search the list archives at: > http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers > From utkarsh.ayachit at kitware.com Fri Apr 17 08:38:34 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Fri, 17 Apr 2015 08:38:34 -0400 Subject: [Paraview-developers] Necessity for RequestDataObject in custom reader plugin In-Reply-To: References: Message-ID: RequestDataObject is the pass in which a vtkAlgorithm subclass can produce an instance of the dataset of the right type for the output. Another mechanism for telling the pipeline which data object type is going to be outputted would be the FillOutputPortInformation(). If a concrete output type can be determined at compile time, one simply uses FillOutputPortInformation to announce the output type. Data-type specific subclasses of vtkAlgorithm e.g. vtkPolyDataAlgorithm use this mechanism. If your reader is always going to produce vtkPolyData, for example, just subclass from vtkPolyDataAlgorithm and you'll never need to deal with RequestDataObject. Now, when a filter/reader cannot tell the output type at compile time, only at run time, then in FillOutputPortInformation one specifies a generic type for the output e.g. vtkDataObject and then overrides RequestDataObject(). In RequestDataObject(), you create an instance of the dataobject to be used as the output for the filter/reader. Now, you have access to attributes set on the reader/filter as well as the input data type -- all of which can be used to decide which output dataset type to create. Also note, RequestDataObject is not defined in vtkAlgorithm. Subclasses of vtkAlgorithm typically override vtkAlgorithm::ProcessRequest() method to call this method when the `request` contains vtkDemandDrivenPipeline::REQUEST_DATA_OBJECT() key. Hope that helps. Utkarsh On Fri, Apr 17, 2015 at 4:19 AM, Schlottke, Michael wrote: > Hi folks, > > Can somebody help me understand the purpose of the RequestDataObject() for a reader plugin? I see this method pop up now and then (typically in generic examples on how to create custom sources), but most of the readers in the Plugins/ directory do not seem to use it. Is there a simple definition I can use to decide if and how to implement it? > > Regards, > > Michael > > P.S.: I?m working on two readers of vtkUnstructuredGridAlgorithm and vtkMultiBlockDataSetAlgorithm type. > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html > > Search the list archives at: http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers From M.Schlottke at aia.rwth-aachen.de Fri Apr 17 09:12:31 2015 From: M.Schlottke at aia.rwth-aachen.de (Schlottke, Michael) Date: Fri, 17 Apr 2015 13:12:31 +0000 Subject: [Paraview-developers] Necessity for RequestDataObject in custom reader plugin In-Reply-To: References: Message-ID: <1822E9C8-D7BE-44DB-B6AD-3D583C339DED@aia.rwth-aachen.de> Hi Utkarsh, Thank you very much for this clear and succinct description. I think I now understand the purpose of RequestDataObject (and that I do not really need it, as long as I always subclass a vtkXXXAlgorithm class). Regards, Michael > On 17 Apr 2015, at 14:38 , Utkarsh Ayachit wrote: > > RequestDataObject is the pass in which a vtkAlgorithm subclass can > produce an instance of the dataset of the right type for the output. > Another mechanism for telling the pipeline which data object type is > going to be outputted would be the FillOutputPortInformation(). If a > concrete output type can be determined at compile time, one simply > uses FillOutputPortInformation to announce the output type. Data-type > specific subclasses of vtkAlgorithm e.g. vtkPolyDataAlgorithm use this > mechanism. If your reader is always going to produce vtkPolyData, for > example, just subclass from vtkPolyDataAlgorithm and you'll never need > to deal with RequestDataObject. > > Now, when a filter/reader cannot tell the output type at compile time, > only at run time, then in FillOutputPortInformation one specifies a > generic type for the output e.g. vtkDataObject and then overrides > RequestDataObject(). In RequestDataObject(), you create an instance of > the dataobject to be used as the output for the filter/reader. Now, > you have access to attributes set on the reader/filter as well as the > input data type -- all of which can be used to decide which output > dataset type to create. > > Also note, RequestDataObject is not defined in vtkAlgorithm. > Subclasses of vtkAlgorithm typically override > vtkAlgorithm::ProcessRequest() method to call this method when the > `request` contains vtkDemandDrivenPipeline::REQUEST_DATA_OBJECT() key. > > Hope that helps. > Utkarsh > > On Fri, Apr 17, 2015 at 4:19 AM, Schlottke, Michael > wrote: >> Hi folks, >> >> Can somebody help me understand the purpose of the RequestDataObject() for a reader plugin? I see this method pop up now and then (typically in generic examples on how to create custom sources), but most of the readers in the Plugins/ directory do not seem to use it. Is there a simple definition I can use to decide if and how to implement it? >> >> Regards, >> >> Michael >> >> P.S.: I?m working on two readers of vtkUnstructuredGridAlgorithm and vtkMultiBlockDataSetAlgorithm type. >> _______________________________________________ >> Powered by www.kitware.com >> >> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html >> >> Search the list archives at: http://markmail.org/search/?q=Paraview-developers >> >> Follow this link to subscribe/unsubscribe: >> http://public.kitware.com/mailman/listinfo/paraview-developers From ben.boeckel at kitware.com Mon Apr 20 14:18:26 2015 From: ben.boeckel at kitware.com (Ben Boeckel) Date: Mon, 20 Apr 2015 14:18:26 -0400 Subject: [Paraview-developers] wrapping cmake dependency issue? In-Reply-To: <54EF6D88.5070109@gmail.com> References: <54EF6D88.5070109@gmail.com> Message-ID: <20150420181826.GA11252@megas.kitware.com> On Thu, Feb 26, 2015 at 11:01:28 -0800, Burlen Loring wrote: > This is in regard to what to me seems like a bug in dependency chain of > the CS and Python wrapping. Yesterday I was debugging a segv on 4.3.1 > build on our Cray and I had to test a different a different OpenGL > build. So I opened up the CMakeCache of my build and changed the one > variable- namely the one specifying the OpenGL library. This should have > resulted in the executables and a few of the libs re-linking, however in > addition all of the CS and Python wrapping was regenerated and those > files recompiled and re linked. As a result what should have been a 5min > tweak took over an hour! I guess that the wrappers are custom > command/targets in CMake and that the dependency is not set correctly. > Am I right? I'm happy to file a bug report if this something that you'd > be willing to fix. ;-) Sorry for the delay, I'm quite backlogged on this list. Using `ninja -d explain -n` on a completed OpenGL build shows 12000+ targets need rebuilt when changing from OpenGL -> OpenGL2. The vast majority are from RenderingCore being linked ~everywhere. I do, however, see that lots of Python wrapping gets re-done that shouldn't be (namely vtkCommonCorePythonD due to a command-line change). It has `-IRending/OpenGL2` on its command line in the generated build. This is likely the cause of quite a few rebuilds, but there are still probably ~8000 or so required targets (at a guess). One problem is caused by the foreach loop in Wrapping/Python/CMakeLists.txt where `vtk_add_python_wrapping` is called. The directory-level `include_directories` are accumulating between each loop, so any module later in the list gets any module earlier's complete include line as well. Not sure why, exactly, RenderingCore and related module includes get into CommonCore's include directories. --Ben From burlen.loring at gmail.com Mon Apr 20 16:44:03 2015 From: burlen.loring at gmail.com (Burlen Loring) Date: Mon, 20 Apr 2015 13:44:03 -0700 Subject: [Paraview-developers] wrapping cmake dependency issue? In-Reply-To: <20150420181826.GA11252@megas.kitware.com> References: <54EF6D88.5070109@gmail.com> <20150420181826.GA11252@megas.kitware.com> Message-ID: <55356513.8000707@gmail.com> Hi Ben, It's nice that you are looking into it. Sounds like maybe you got some useful insight. I'm not sure changing the backend to GL2 is the best way to get at the issue. In that case you are using different classes, with different api, and hence a lot of stuff should be recompiled and re-wrapped. Wouldn't it be straight forward and give you better insight to look at what happens when you change the OpenGL install? Burlen On 04/20/2015 11:18 AM, Ben Boeckel wrote: > On Thu, Feb 26, 2015 at 11:01:28 -0800, Burlen Loring wrote: >> This is in regard to what to me seems like a bug in dependency chain of >> the CS and Python wrapping. Yesterday I was debugging a segv on 4.3.1 >> build on our Cray and I had to test a different a different OpenGL >> build. So I opened up the CMakeCache of my build and changed the one >> variable- namely the one specifying the OpenGL library. This should have >> resulted in the executables and a few of the libs re-linking, however in >> addition all of the CS and Python wrapping was regenerated and those >> files recompiled and re linked. As a result what should have been a 5min >> tweak took over an hour! I guess that the wrappers are custom >> command/targets in CMake and that the dependency is not set correctly. >> Am I right? I'm happy to file a bug report if this something that you'd >> be willing to fix. ;-) > Sorry for the delay, I'm quite backlogged on this list. > > Using `ninja -d explain -n` on a completed OpenGL build shows 12000+ > targets need rebuilt when changing from OpenGL -> OpenGL2. The vast > majority are from RenderingCore being linked ~everywhere. I do, however, > see that lots of Python wrapping gets re-done that shouldn't be (namely > vtkCommonCorePythonD due to a command-line change). > > It has `-IRending/OpenGL2` on its command line in the generated build. > This is likely the cause of quite a few rebuilds, but there are still > probably ~8000 or so required targets (at a guess). One problem is > caused by the foreach loop in Wrapping/Python/CMakeLists.txt where > `vtk_add_python_wrapping` is called. The directory-level > `include_directories` are accumulating between each loop, so any module > later in the list gets any module earlier's complete include line as > well. Not sure why, exactly, RenderingCore and related module includes > get into CommonCore's include directories. > > --Ben From foss at grueninger.de Tue Apr 21 01:22:48 2015 From: foss at grueninger.de (=?UTF-8?B?Q2hyaXN0b3BoIEdyw7xuaW5nZXI=?=) Date: Tue, 21 Apr 2015 07:22:48 +0200 Subject: [Paraview-developers] Patch: Update UseLATEX.cmake for paraview-guide Message-ID: <5535DEA8.2010209@grueninger.de> Hi Utkarsh, please find attached a patch that updates UseLATEX.cmake for the paraview-guide. This fixes CMP0046 warnings with newer CMake versions. Bye Christoph -- When you die, that does not mean that you lose to cancer, you beat cancer by how you live, why you live, and in the manner in which you live. -- Stuart Scott, 1965-2015 -------------- next part -------------- A non-text attachment was scrubbed... Name: 0001-Update-UseLATEX.cmake-to-version-1.10.5.patch Type: text/x-patch Size: 9406 bytes Desc: not available URL: From sur.chiranjib at gmail.com Wed Apr 22 14:31:47 2015 From: sur.chiranjib at gmail.com (Chiranjib Sur) Date: Thu, 23 Apr 2015 00:01:47 +0530 Subject: [Paraview-developers] how to build a re-distributable linux plugin (.so) In-Reply-To: References: Message-ID: Hi Utkarsh, Thanks for the suggestions. My goal is to build my .so and use it with any binaries downloaded from paraview.org. What is the best way to generate my own .so plugin which can be used with any paraview distribution (either locally build or binary downloaded from praview.org)? Thanks, Chiranjib On Tue, Apr 14, 2015 at 11:11 PM, Utkarsh Ayachit < utkarsh.ayachit at kitware.com> wrote: > Try doing a "make install" with CMAKE_INSTALL_PREFIX set to some > temporary location. That should strip the paths on the plugin. Note, > however that you can only load this plugin on a build of ParaView > built similarly i.e. it won't work on the ParaView binaries downloaded > from paraview.org > > On Tue, Apr 14, 2015 at 6:44 AM, Chiranjib Sur > wrote: > > Hi All, > > I am trying to create a plugin with an intention to use with Paraview in > any > > machine (just by loading the .so file from Tools>Manage Plugins..). > > To do that, I need to build the .so file without any hard link. > > > > Can anyone tell me how to do that ? There might be an answer from the > > earlier mailing list archive. If so, kindly point me towards that. > > > > I am following the following steps : > > 1. Download ParaView-4.3.1 (git clone..) > > 2. Create a build directory > > 3. Add my plugin under Examples/Plugins > > 4. Run cmake from the build directory > > 5. Run make for my plugin and a .so is created (e.g. : named as : > > myplugin.so) > > > > This myplugin.so contains hard link to different locations linked to my > > system/userID which I want to remove so that the .so file become > portable > > and loaded from any machine with same level of system software. > > > > Thanking you in advance for the help. > > > > Chiranjib > > > > _______________________________________________ > > Powered by www.kitware.com > > > > Visit other Kitware open-source projects at > > http://www.kitware.com/opensource/opensource.html > > > > Search the list archives at: > > http://markmail.org/search/?q=Paraview-developers > > > > Follow this link to subscribe/unsubscribe: > > http://public.kitware.com/mailman/listinfo/paraview-developers > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From felipe.bordeu at ec-nantes.fr Thu Apr 23 02:00:44 2015 From: felipe.bordeu at ec-nantes.fr (Felipe Bordeu Weldt) Date: Thu, 23 Apr 2015 08:00:44 +0200 Subject: [Paraview-developers] how to build a re-distributable linux plugin (.so) In-Reply-To: References: Message-ID: I build the binaries (linux/osx/windows) of my plugin with the superbuild. Then I distribute the .so/.dylib/.dll file. The only problem is in linux because I use a recent version (ubuntu 14.04) to build it, then the binary is tied to a recent version of libc6. Felipe Le 22 avr. 2015 ? 20:31, Chiranjib Sur a ?crit : > Hi Utkarsh, > Thanks for the suggestions. > My goal is to build my .so and use it with any binaries downloaded from paraview.org. What is the best way to generate my own .so plugin which can be used with any paraview distribution (either locally build or binary downloaded from praview.org)? > > Thanks, > Chiranjib > > On Tue, Apr 14, 2015 at 11:11 PM, Utkarsh Ayachit wrote: > Try doing a "make install" with CMAKE_INSTALL_PREFIX set to some > temporary location. That should strip the paths on the plugin. Note, > however that you can only load this plugin on a build of ParaView > built similarly i.e. it won't work on the ParaView binaries downloaded > from paraview.org > > On Tue, Apr 14, 2015 at 6:44 AM, Chiranjib Sur wrote: > > Hi All, > > I am trying to create a plugin with an intention to use with Paraview in any > > machine (just by loading the .so file from Tools>Manage Plugins..). > > To do that, I need to build the .so file without any hard link. > > > > Can anyone tell me how to do that ? There might be an answer from the > > earlier mailing list archive. If so, kindly point me towards that. > > > > I am following the following steps : > > 1. Download ParaView-4.3.1 (git clone..) > > 2. Create a build directory > > 3. Add my plugin under Examples/Plugins > > 4. Run cmake from the build directory > > 5. Run make for my plugin and a .so is created (e.g. : named as : > > myplugin.so) > > > > This myplugin.so contains hard link to different locations linked to my > > system/userID which I want to remove so that the .so file become portable > > and loaded from any machine with same level of system software. > > > > Thanking you in advance for the help. > > > > Chiranjib > > > > _______________________________________________ > > Powered by www.kitware.com > > > > Visit other Kitware open-source projects at > > http://www.kitware.com/opensource/opensource.html > > > > Search the list archives at: > > http://markmail.org/search/?q=Paraview-developers > > > > Follow this link to subscribe/unsubscribe: > > http://public.kitware.com/mailman/listinfo/paraview-developers > > > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html > > Search the list archives at: http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 496 bytes Desc: Message signed with OpenPGP using GPGMail URL: From Gerald.Lodron at joanneum.at Thu Apr 23 02:41:12 2015 From: Gerald.Lodron at joanneum.at (Lodron, Gerald) Date: Thu, 23 Apr 2015 06:41:12 +0000 Subject: [Paraview-developers] ParaView and double precision Rendering In-Reply-To: References: <16363023d4454e1b9eb3b0d582c91bbd@RZJMBX2.jr1.local> Message-ID: <55b17027674e4f128cf42c2dad248475@RZJMBX2.jr1.local> Hi Today i got an (maybe stupid) idea: The solution of rescaling my double data to get correct viewing is not very elegant: All filter/sources settings will be in wrong relation (e.g. if I want to insert a sphere of radius 1, or if I want to measure my data using ruler, or if I want to watch my data in spreadsheet view) Wouldn?t it better to write a ?view plugin? where all data firstly is rescaled/mean subtracted before sending to 3d polydata mapper? In that case all filter settings, ruler and so on will also work like expected. I never wrote a view plugin but is this in principle possible? Or should I use a ?representation plugin? for that..... Any suggestions? Best regards, Gerald Lodron Von: Berk Geveci [mailto:berk.geveci at kitware.com] Gesendet: Dienstag, 14. April 2015 18:16 An: Lodron, Gerald Cc: Paraview User (paraview at paraview.org); Paraview Developer (Paraview-developers at paraview.org) Betreff: Re: [Paraview-developers] ParaView and double precision Rendering OpenGL does not support double precision. VTK does not do anything special in handling large coordinates and passes them to OpenGL directly. So currently, you have to handle this yourself by rescaling your data. Best, -berk On Mon, Apr 13, 2015 at 1:25 PM, Lodron, Gerald > wrote: Hello I made a paraview reader plugin which loads Point data of type double from an ASCII file (can be choosen as checkbox in reader parameter gui). It is important that point data type is double since our values have a huge offset, e.g. Coordinate in float: 3376382.75 -325198.59375 -121298.125 Coordinate in double: 3376382.849028525874 -325198.60899497801438 -121298.12806414699298 (same ASCII input file of type double, above printings come from spreadsheet view so loading is correct) (all my points have such small changes, I definitely can see those small changes in 3d) The problem is: I load the dataset once in float and once in double ( I checked result in spreadsheed view) I cannot see any differences in 3d renderer when I swap visibility of float and double input (but you can see in spreadsheet). Is the double precision rendering not correct/not supported? Any ideas? Best regards, Gerald Lodron Machine Vision Applications DIGITAL - Institute for Information and Communication Technologies JOANNEUM RESEARCH Forschungsgesellschaft mbH Steyrergasse 17, 8010 Graz, AUSTRIA phone: +43-316-876-1751 fax: +43-316-876-1751 web: http://www.joanneum.at/digital e-mail: gerald.lodron at joanneum.at _______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Search the list archives at: http://markmail.org/search/?q=Paraview-developers Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/paraview-developers -------------- next part -------------- An HTML attachment was scrubbed... URL: From chengdi at imech.ac.cn Thu Apr 23 03:55:28 2015 From: chengdi at imech.ac.cn (Di Cheng) Date: Thu, 23 Apr 2015 15:55:28 +0800 Subject: [Paraview-developers] Is it possible to implement a POD filter in paraview using python? Message-ID: <000001d07d9a$de179f30$9a46dd90$@imech.ac.cn> Hi, everyone. I am interested in using proper orthogonal decomposition to analyze unsteady flow field data obtained from CFD in paraview. I tried to implement it using python. But I am not sure if there is a better way to implement the POD algorithm described in chapter 3.2 of http://web.mit.edu/kwillcox/Public/Web/BTTanMS.pdf The algorithm can be summarized as: 0. get timestepvalues of interest as t_i, i=1..N 1. load field P of two timesteps such as as P_i=P(t_i),P_j=P(t_j) 2. calculate the correlation R_ij = inner_product(P_i,P_j)/N, the definition of inner product could be integration of P_i*P_j over the volume. 3. get the eigen values lambda_i and corresponding right egien vector eV_ii of matrix {R_ij} 4. construct the i-th POD basis psi_i = sum(dot(eV_ij,P_j),j=1..N), usually, only the first m bases are used. 5. reconstruct Pr_m field using first m POD bases: Pr_m = sum(lambda_i * psi_i, i = 1.. m) 6.output the lambda_i, psi_i and Pr_m The algorithm is simple but the problem is to avoid loading the very large 3D dataset of all timesteps into memory. I tried to use "c1.UpdatePipeline(t_1); c2.UpdatePipeline(t_2);" to load two timesteps at one time to avoid this problem. I do not know if this method works. Then I tried to implement the following algorithm using python. A pipeline is used to calculate the inner product via Programmable Filter and Integrate Variables. And I can get the correlation matrix and eigen values and eigen vectors. The final step is the most difficult part in python. I do not know how to implement it in python. I did not implement it yet. I do not want to use Fetch method to collect all data to the master node. But the functionality of python shell seems limited and accessing the cells' structure is difficult. I want to know how TemporalAverge filter works but I cannot identify where it is in the source code. (I am not familiar with software development using C++). So, could anyone help me to finish it or tell me it is not possible? Thanks p.s. I just posted a Request a New Feature in http://paraview.uservoice.com/forums/11350-general/suggestions/7671768-prope r-orthogonal-decomposition-analysis-filter Di CHENG (Ph.D. candidate) Supersonic Combustion Group State Key Laboratory of High Temperature Gas Dynamics Institute of Mechanics, Chinese Academy of Sciences ADDRESS: No.15 Beisihuanxi Road, Beijing (100190) P. R. China E-mail: chengdi at imech.ac.cn Phone: +86-10-82544053 Fax: +86-10-82544034 -------------- next part -------------- An HTML attachment was scrubbed... URL: From andy.bauer at kitware.com Thu Apr 23 09:26:09 2015 From: andy.bauer at kitware.com (Andy Bauer) Date: Thu, 23 Apr 2015 09:26:09 -0400 Subject: [Paraview-developers] Is it possible to implement a POD filter in paraview using python? In-Reply-To: <000001d07d9a$de179f30$9a46dd90$@imech.ac.cn> References: <000001d07d9a$de179f30$9a46dd90$@imech.ac.cn> Message-ID: The best way would be to implement this in C++ but it's also doable in Python. If you want to do it in Python I'd suggest reading through Berk Geveci's blog posts on Python and VTK (http://www.kitware.com/blog/home/user/53). The one most relevant is probably http://www.kitware.com/blog/home/post/783 but the others give good background. Regards, Andy On Thu, Apr 23, 2015 at 3:55 AM, Di Cheng wrote: > Hi, everyone. > > > > I am interested in using proper orthogonal decomposition to analyze > unsteady flow field data obtained from CFD in paraview. I tried to > implement it using python. But I am not sure if there is a better way to > implement the POD algorithm described in chapter 3.2 of > http://web.mit.edu/kwillcox/Public/Web/BTTanMS.pdf > > The algorithm can be summarized as: > 0. get timestepvalues of interest as t_i, i=1..N > 1. load field P of two timesteps such as as P_i=P(t_i),P_j=P(t_j) > 2. calculate the correlation R_ij = inner_product(P_i,P_j)/N, the > definition of inner product could be integration of P_i*P_j over the volume. > > 3. get the eigen values lambda_i and corresponding right egien vector > eV_ii of matrix {R_ij} > 4. construct the i-th POD basis psi_i = sum(dot(eV_ij,P_j),j=1..N), > usually, only the first m bases are used. > 5. reconstruct Pr_m field using first m POD bases: > Pr_m = sum(lambda_i * psi_i, i = 1.. m) > > 6.output the lambda_i, psi_i and Pr_m > > The algorithm is simple but the problem is to avoid loading the very large > 3D dataset of all timesteps into memory. I tried to use ?*c1.UpdatePipeline(t_1); > c2.UpdatePipeline(t_2);? * to load two timesteps at one time to avoid > this problem. I do not know if this method works. > > Then I tried to implement the following algorithm using python. A pipeline > is used to calculate the inner product via Programmable Filter and > Integrate Variables. And I can get the correlation matrix and eigen values > and eigen vectors. > > The final step is the most difficult part in python. I do not know how to > implement it in python. I did not implement it yet. I do not want to use > Fetch method to collect all data to the master node. But the functionality > of python shell seems limited and accessing the cells? structure is > difficult. I want to know how TemporalAverge filter works but I cannot > identify where it is in the source code. (I am not familiar with software > development using C++). > > So, could anyone help me to finish it or tell me it is not possible? > > Thanks > > p.s. I just posted a Request a New Feature in > http://paraview.uservoice.com/forums/11350-general/suggestions/7671768-proper-orthogonal-decomposition-analysis-filter > > Di CHENG (Ph.D. candidate) > > Supersonic Combustion Group > > State Key Laboratory of High Temperature Gas Dynamics > > Institute of Mechanics, Chinese Academy of Sciences > ADDRESS: No.15 Beisihuanxi Road, Beijing (100190) > P. R. China > E-mail: chengdi at imech.ac.cn > > Phone: +86-10-82544053 > > Fax: +86-10-82544034 > > > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Search the list archives at: > http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From joachim.pouderoux at kitware.com Thu Apr 23 10:15:16 2015 From: joachim.pouderoux at kitware.com (Joachim Pouderoux) Date: Thu, 23 Apr 2015 16:15:16 +0200 Subject: [Paraview-developers] announce: VTK/ParaView Training - June 2 and 3, 2015, Lyon, France Message-ID: Kitware will be holding VTK and ParaView training courses respectively on June 2 and 3 in Lyon, France. Please visit our web site for more information and registration details at: VTK: http://training.kitware.fr/browse/102 ParaView: http://training.kitware.fr/browse/104 Note that the courses will be taught in English. If you have any question, please contact us at! formations at http://www.kitware.fr Thank you, *Joachim Pouderoux* *PhD, Technical Expert* *Kitware SAS * -------------- next part -------------- An HTML attachment was scrubbed... URL: From dave.demarle at kitware.com Thu Apr 23 10:37:26 2015 From: dave.demarle at kitware.com (David E DeMarle) Date: Thu, 23 Apr 2015 10:37:26 -0400 Subject: [Paraview-developers] [Paraview] ParaView and double precision Rendering In-Reply-To: <55b17027674e4f128cf42c2dad248475@RZJMBX2.jr1.local> References: <16363023d4454e1b9eb3b0d582c91bbd@RZJMBX2.jr1.local> <55b17027674e4f128cf42c2dad248475@RZJMBX2.jr1.local> Message-ID: Sounds doable and very useful to me. Conceptually it is simple, use the world space bounding box to rescale the representations appropriately. You can mock it up at first in python with the transform filter and/or display transformations. Let us and especially the pv-developers list know if you run into problems. David E DeMarle Kitware, Inc. R&D Engineer 21 Corporate Drive Clifton Park, NY 12065-8662 Phone: 518-881-4909 On Thu, Apr 23, 2015 at 2:41 AM, Lodron, Gerald wrote: > Hi > > > > Today i got an (maybe stupid) idea: > > > > The solution of rescaling my double data to get correct viewing is not > very elegant: All filter/sources settings will be in wrong relation (e.g. > if I want to insert a sphere of radius 1, or if I want to measure my data > using ruler, or if I want to watch my data in spreadsheet view) > > > > Wouldn?t it better to write a ?view plugin? where all data firstly is > rescaled/mean subtracted before sending to 3d polydata mapper? In that case > all filter settings, ruler and so on will also work like expected. I never > wrote a view plugin but is this in principle possible? Or should I use a > ?representation plugin? for that..... > > > > Any suggestions? > > > > Best regards, > > Gerald Lodron > > > > > > *Von:* Berk Geveci [mailto:berk.geveci at kitware.com] > *Gesendet:* Dienstag, 14. April 2015 18:16 > *An:* Lodron, Gerald > *Cc:* Paraview User (paraview at paraview.org); Paraview Developer ( > Paraview-developers at paraview.org) > *Betreff:* Re: [Paraview-developers] ParaView and double precision > Rendering > > > > OpenGL does not support double precision. VTK does not do anything special > in handling large coordinates and passes them to OpenGL directly. So > currently, you have to handle this yourself by rescaling your data. > > > > Best, > > -berk > > > > On Mon, Apr 13, 2015 at 1:25 PM, Lodron, Gerald > wrote: > > Hello > > I made a paraview reader plugin which loads Point data of type double from > an ASCII file (can be choosen as checkbox in reader parameter gui). It is > important that point data type is double since our values have a huge > offset, e.g. > > Coordinate in float: 3376382.75 -325198.59375 -121298.125 > Coordinate in double: 3376382.849028525874 -325198.60899497801438 > -121298.12806414699298 > (same ASCII input file of type double, above printings come from > spreadsheet view so loading is correct) > (all my points have such small changes, I definitely can see those small > changes in 3d) > > The problem is: I load the dataset once in float and once in double ( I > checked result in spreadsheed view) I cannot see any differences in 3d > renderer when I swap visibility of float and double input (but you can see > in spreadsheet). Is the double precision rendering not correct/not > supported? > Any ideas? > > Best regards, > > Gerald Lodron > Machine Vision Applications > DIGITAL - Institute for Information and Communication Technologies > > JOANNEUM RESEARCH Forschungsgesellschaft mbH > Steyrergasse 17, 8010 Graz, AUSTRIA > > phone: +43-316-876-1751 > fax: +43-316-876-1751 > web: http://www.joanneum.at/digital > e-mail: gerald.lodron at joanneum.at > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Search the list archives at: > http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers > > > > _______________________________________________ > 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 > > 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: From Gerald.Lodron at joanneum.at Fri Apr 24 01:44:06 2015 From: Gerald.Lodron at joanneum.at (Lodron, Gerald) Date: Fri, 24 Apr 2015 05:44:06 +0000 Subject: [Paraview-developers] [Paraview] ParaView and double precision Rendering In-Reply-To: References: <16363023d4454e1b9eb3b0d582c91bbd@RZJMBX2.jr1.local> <55b17027674e4f128cf42c2dad248475@RZJMBX2.jr1.local> Message-ID: Ok, thanks Good to know that it should theoretically work... The task is planned for a customer of us, the project is currently in acquisition phase so we do not definitely have the order yet... Thanks for opinions.... Von: David E DeMarle [mailto:dave.demarle at kitware.com] Gesendet: Donnerstag, 23. April 2015 16:37 An: Lodron, Gerald Cc: Berk Geveci; Paraview Developer (Paraview-developers at paraview.org); Paraview User (paraview at paraview.org) Betreff: Re: [Paraview] [Paraview-developers] ParaView and double precision Rendering Sounds doable and very useful to me. Conceptually it is simple, use the world space bounding box to rescale the representations appropriately. You can mock it up at first in python with the transform filter and/or display transformations. Let us and especially the pv-developers list know if you run into problems. David E DeMarle Kitware, Inc. R&D Engineer 21 Corporate Drive Clifton Park, NY 12065-8662 Phone: 518-881-4909 On Thu, Apr 23, 2015 at 2:41 AM, Lodron, Gerald > wrote: Hi Today i got an (maybe stupid) idea: The solution of rescaling my double data to get correct viewing is not very elegant: All filter/sources settings will be in wrong relation (e.g. if I want to insert a sphere of radius 1, or if I want to measure my data using ruler, or if I want to watch my data in spreadsheet view) Wouldn?t it better to write a ?view plugin? where all data firstly is rescaled/mean subtracted before sending to 3d polydata mapper? In that case all filter settings, ruler and so on will also work like expected. I never wrote a view plugin but is this in principle possible? Or should I use a ?representation plugin? for that..... Any suggestions? Best regards, Gerald Lodron Von: Berk Geveci [mailto:berk.geveci at kitware.com] Gesendet: Dienstag, 14. April 2015 18:16 An: Lodron, Gerald Cc: Paraview User (paraview at paraview.org); Paraview Developer (Paraview-developers at paraview.org) Betreff: Re: [Paraview-developers] ParaView and double precision Rendering OpenGL does not support double precision. VTK does not do anything special in handling large coordinates and passes them to OpenGL directly. So currently, you have to handle this yourself by rescaling your data. Best, -berk On Mon, Apr 13, 2015 at 1:25 PM, Lodron, Gerald > wrote: Hello I made a paraview reader plugin which loads Point data of type double from an ASCII file (can be choosen as checkbox in reader parameter gui). It is important that point data type is double since our values have a huge offset, e.g. Coordinate in float: 3376382.75 -325198.59375 -121298.125 Coordinate in double: 3376382.849028525874 -325198.60899497801438 -121298.12806414699298 (same ASCII input file of type double, above printings come from spreadsheet view so loading is correct) (all my points have such small changes, I definitely can see those small changes in 3d) The problem is: I load the dataset once in float and once in double ( I checked result in spreadsheed view) I cannot see any differences in 3d renderer when I swap visibility of float and double input (but you can see in spreadsheet). Is the double precision rendering not correct/not supported? Any ideas? Best regards, Gerald Lodron Machine Vision Applications DIGITAL - Institute for Information and Communication Technologies JOANNEUM RESEARCH Forschungsgesellschaft mbH Steyrergasse 17, 8010 Graz, AUSTRIA phone: +43-316-876-1751 fax: +43-316-876-1751 web: http://www.joanneum.at/digital e-mail: gerald.lodron at joanneum.at _______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Search the list archives at: http://markmail.org/search/?q=Paraview-developers Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/paraview-developers _______________________________________________ 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 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: From chengdi at imech.ac.cn Fri Apr 24 08:19:27 2015 From: chengdi at imech.ac.cn (Di Cheng) Date: Fri, 24 Apr 2015 20:19:27 +0800 Subject: [Paraview-developers] Is it possible to implement a POD filter in paraview using python? In-Reply-To: References: <000001d07d9a$de179f30$9a46dd90$@imech.ac.cn> Message-ID: <000101d07e88$e9352290$bb9f67b0$@imech.ac.cn> Hi, Andy Bauer Thanks for your reply. I just read the blogs and it seems it is possible to use ?Programmable Filter? to access data of different timesteps by writing a ?RequestUpdateExtentScript? like this: #---------------------------------------------- RUEScript = ''' info0 = inInfo[0].GetInformationObject(0) # Ask for the next timestep. info0.Set(vtk.vtkStreamingDemandDrivenPipeline.UPDATE_TIME_STEP(), {}) info1 = inInfo[1].GetInformationObject(0) # Ask for the next timestep. info1.Set(vtk.vtkStreamingDemandDrivenPipeline.UPDATE_TIME_STEP(), {}) return 1 ''' pf.RequestUpdateExtentScript = RUEScript.format(t1,t2) #---------------------------------------------- However, I get this error msg on my workstation: NameError: global name 'inInfo' is not defined I am using paraview 4.3.1, and the workstation is running on Ubuntu 12.04. I tested the code above in paraview 4.3.1 on windows 8.1 and it still does not works. And I checked the parameters of ?RequestUpdateExtentScript? by: #---------------------------------------------- print dir() print locals() #---------------------------------------------- The result shows that there is no inInfo, but there are ?request?, ?inputs?, ?output?, just like The ?Script? of ?Programmable filter?. Then I realize that this ?Programmable filter? is a proxy to the VTK?s ?Programmable filter?. And I cannot access the InformationObject behind the proxy. But I do not know much about the python interface of Proxies. Now my question is: how can I access vtk Objects directly? Should I use vtk instead of paraview to accomplish my goal? Di Cheng From: Andy Bauer [mailto:andy.bauer at kitware.com] Sent: Thursday, April 23, 2015 9:26 PM To: Di Cheng Cc: paraview-developers at paraview.org Subject: Re: [Paraview-developers] Is it possible to implement a POD filter in paraview using python? The best way would be to implement this in C++ but it's also doable in Python. If you want to do it in Python I'd suggest reading through Berk Geveci's blog posts on Python and VTK (http://www.kitware.com/blog/home/user/53). The one most relevant is probably http://www.kitware.com/blog/home/post/783 but the others give good background. Regards, Andy On Thu, Apr 23, 2015 at 3:55 AM, Di Cheng > wrote: Hi, everyone. I am interested in using proper orthogonal decomposition to analyze unsteady flow field data obtained from CFD in paraview. I tried to implement it using python. But I am not sure if there is a better way to implement the POD algorithm described in chapter 3.2 of http://web.mit.edu/kwillcox/Public/Web/BTTanMS.pdf The algorithm can be summarized as: 0. get timestepvalues of interest as t_i, i=1..N 1. load field P of two timesteps such as as P_i=P(t_i),P_j=P(t_j) 2. calculate the correlation R_ij = inner_product(P_i,P_j)/N, the definition of inner product could be integration of P_i*P_j over the volume. 3. get the eigen values lambda_i and corresponding right egien vector eV_ii of matrix {R_ij} 4. construct the i-th POD basis psi_i = sum(dot(eV_ij,P_j),j=1..N), usually, only the first m bases are used. 5. reconstruct Pr_m field using first m POD bases: Pr_m = sum(lambda_i * psi_i, i = 1.. m) 6.output the lambda_i, psi_i and Pr_m The algorithm is simple but the problem is to avoid loading the very large 3D dataset of all timesteps into memory. I tried to use ?c1.UpdatePipeline(t_1); c2.UpdatePipeline(t_2);? to load two timesteps at one time to avoid this problem. I do not know if this method works. Then I tried to implement the following algorithm using python. A pipeline is used to calculate the inner product via Programmable Filter and Integrate Variables. And I can get the correlation matrix and eigen values and eigen vectors. The final step is the most difficult part in python. I do not know how to implement it in python. I did not implement it yet. I do not want to use Fetch method to collect all data to the master node. But the functionality of python shell seems limited and accessing the cells? structure is difficult. I want to know how TemporalAverge filter works but I cannot identify where it is in the source code. (I am not familiar with software development using C++). So, could anyone help me to finish it or tell me it is not possible? Thanks p.s. I just posted a Request a New Feature in http://paraview.uservoice.com/forums/11350-general/suggestions/7671768-proper-orthogonal-decomposition-analysis-filter Di CHENG (Ph.D. candidate) Supersonic Combustion Group State Key Laboratory of High Temperature Gas Dynamics Institute of Mechanics, Chinese Academy of Sciences ADDRESS: No.15 Beisihuanxi Road, Beijing (100190) P. R. China E-mail: chengdi at imech.ac.cn Phone: +86-10-82544053 Fax: +86-10-82544034 _______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Search the list archives at: http://markmail.org/search/?q=Paraview-developers Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/paraview-developers -------------- next part -------------- An HTML attachment was scrubbed... URL: From M.Schlottke at aia.rwth-aachen.de Mon Apr 27 01:23:35 2015 From: M.Schlottke at aia.rwth-aachen.de (Schlottke, Michael) Date: Mon, 27 Apr 2015 05:23:35 +0000 Subject: [Paraview-developers] Replacement of SetInput with SetInputData (VTK5 vs. 6) Message-ID: <0361B901-93E3-4738-B449-4250311F1E91@aia.rwth-aachen.de> Dear all, I?m currently in the middle of migrating a few custom plugins (mostly filters) from VTK5 to VTK6. One of the situations I?ve frequently encountered is code like this in the `RequestData` method: vtkInformation *inInfo = inputVector[0]->GetInformationObject(0); vtkUnstructuredGrid *input = vtkUnstructuredGrid::SafeDownCast(inInfo->Get(vtkDataObject::DATA_OBJECT())); vtkCellDataToPointData * cp = vtkCellDataToPointData::New(); cp->SetInput(input); ? cp-Update(); ... Now, according to the migration guide (http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Replacement_of_SetInput), typically I need to replace SetInput with SetInputConnection when maintaining a pipeline connection, whereas for ?internal filters? usually SetInputData is the correct choice. Now I am wondering: ifinside the RequestData method of a filter, do I *ever* need to use SetInputConnection, and if yes, how? It seems like all filters I?ve had a look at always access the input data object (which I can only pass on using SetInputData, not SetInputConnection), not the input port. However, as a user with little VTK experience it seems like this might ?break? the aforementioned pipeline? And does the presence of the call to ?Update()? change anything with respect to this question? Regards, Michael -- Michael Schlottke Chair of Fluid Mechanics and Institute of Aerodynamics RWTH Aachen University W?llnerstra?e 5a 52062 Aachen Germany Phone: +49 (241) 80 95188 Fax: +49 (241) 80 92257 Mail: m.schlottke at aia.rwth-aachen.de Web: http://www.aia.rwth-aachen.de -------------- next part -------------- An HTML attachment was scrubbed... URL: From sur.chiranjib at gmail.com Mon Apr 27 06:07:02 2015 From: sur.chiranjib at gmail.com (Chiranjib Sur) Date: Mon, 27 Apr 2015 15:37:02 +0530 Subject: [Paraview-developers] object not displaying in the paraview window In-Reply-To: References: Message-ID: Wow, This works like a magic ! Thank you very much for the solution and sorry for my delay in updating about the problem I mentioned. Chiranjib On Fri, Apr 17, 2015 at 5:54 PM, Utkarsh Ayachit < utkarsh.ayachit at kitware.com> wrote: > You're missing a call to `transformModel->Update()` before calling > `transformModel->GetOutput()`. The filter never updated, and hence its > output is empty. > > Utkarsh > > On Fri, Apr 17, 2015 at 6:34 AM, Chiranjib Sur > wrote: > > Hi All, > > I want to apply the tranform filter while I create an object in > paraview. TO > > try with I have overloaded vtkCubeSource class and can create the object > > which appears in the paraview pipeline and I can visualize the object in > the > > PV window. > > > > Now I want to apply the transformation filter (vtkTransform) to the objct > > when I create it. To do that I have overloaded the RequestData function > like > > the following. > > > > The code is compiling and executing but when I create the object and > apply > > transform, nothing is appearing in the PV visualization window. > > > > Can anybody help me pointing out what is going wrong with my > implementation. > > > > I cam copying my code below > > > > Thanks, > > Chiranjib > > > > > > ------ > > > > > > > > int MyOwnCubeSource::RequestData( vtkInformation *vtkNotUsed(request), > > > > vtkInformationVector **vtkNotUsed(inputVector), > > > > vtkInformationVector *outputVector) > > > > { > > > > // get the info object > > > > vtkInformation *outInfo = outputVector->GetInformationObject(0); > > > > > > > > // get the ouptut > > > > vtkPolyData *output = vtkPolyData::SafeDownCast( > > > > outInfo->Get(vtkDataObject::DATA_OBJECT())); > > > > .... > > > > .... > > > > > > > > // output (type vtkPolyData) is already ready at this stage > > > > > > > > // If I don?t appy transform operation afterwards, I can visualize the > > object in the PV pipeline > > > > > > > > > > > > // -----------------------------------------------// > > > > > > > > // Implementation of vtkTransform starts here > > > > > > > > double _rotationZ = 30.0; > > > > > > > > // Define transform > > > > vtkSmartPointer transform = > > vtkSmartPointer::New(); > > > > > > > > // Define transformModel : transform filter > > > > vtkSmartPointer transformModel = > > vtkSmartPointer::New(); > > > > transformModel->SetTransform(transform); > > > > > > > > //Decoupling the pipeline and asking the transformfilter to update > the > > newpipeline (created out of shallowcopy) > > > > vtkNew cubeCopy; > > > > cubeCopy->ShallowCopy(output); > > > > transformModel->SetInputData(cubeCopy.GetPointer()); > > > > > > > > // Describe all the transform operations > > > > transform->PostMultiply(); > > > > transform->RotateZ(10*_rotationZ); > > > > transform->Update(); > > > > > > > > // getting the transformed output > > > > vtkSmartPointer transformedOutput = > > transformModel->GetOutput(); > > > > > > > > // Shallowcopy the transformed output to the old pipeline > > > > > > > > output->ShallowCopy(transformedOutput); > > > > > > > > // A this stage "output" should be updated and the visualization pipeline > > should show the transformed object > > > > > > _______________________________________________ > > Powered by www.kitware.com > > > > Visit other Kitware open-source projects at > > http://www.kitware.com/opensource/opensource.html > > > > Search the list archives at: > > http://markmail.org/search/?q=Paraview-developers > > > > Follow this link to subscribe/unsubscribe: > > http://public.kitware.com/mailman/listinfo/paraview-developers > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From sur.chiranjib at gmail.com Mon Apr 27 06:27:25 2015 From: sur.chiranjib at gmail.com (Chiranjib Sur) Date: Mon, 27 Apr 2015 15:57:25 +0530 Subject: [Paraview-developers] using File>Open dialogue in custom filter Message-ID: Hi, I am trying to write my own filter (C++) and want to deal with reading an existing file. I intend implement a functionality where file selection will results into popping up a window like when one does, File->Open action. In the following screen capture, I want to implement that functionality so that when one clicks mouse inside the text box, File->Open windows will popup and the user can select the file he/she wants. (The alternative is to provide the file name by typing which is error prone and I want to avoid that) [image: Inline image 1] After reading various posts from the previous mailing threads and the other documentation, I narrowed down my idea to use the class pqFileDialog. Is this the right choice or are there some alternatives? Are there any place where, I can read and learn about usage of this class ? Google search points me towards solutions in pure Qt which looks like : http://stackoverflow.com/questions/14372012/qt-standard-dialogs-example-open-file Any suggestions from the experts? Thanks, Chiranjib -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 3734 bytes Desc: not available URL: From utkarsh.ayachit at kitware.com Mon Apr 27 09:26:39 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Mon, 27 Apr 2015 09:26:39 -0400 Subject: [Paraview-developers] using File>Open dialogue in custom filter In-Reply-To: References: Message-ID: Simply add the "FileListDomain" to the property as done for the QFileName property here: https://gitlab.kitware.com/paraview/paraview/blob/master/ParaViewCore/ServerManager/SMApplication/Resources/readers.xml#L2659-2667 On Mon, Apr 27, 2015 at 6:27 AM, Chiranjib Sur wrote: > Hi, > I am trying to write my own filter (C++) and want to deal with reading an > existing file. I intend implement a functionality where file selection > will results into popping up a window like when one does, File->Open action. > > In the following screen capture, I want to implement that functionality so > that when one clicks mouse inside the text box, File->Open windows will > popup and the user can select the file he/she wants. (The alternative is to > provide the file name by typing which is error prone and I want to avoid > that) > > [image: Inline image 1] > > After reading various posts from the previous mailing threads and the > other documentation, I narrowed down my idea to use the class pqFileDialog. > Is this the right choice or are there some alternatives? Are there any > place where, I can read and learn about usage of this class ? > > Google search points me towards solutions in pure Qt which looks like : > > > http://stackoverflow.com/questions/14372012/qt-standard-dialogs-example-open-file > > > Any suggestions from the experts? > > Thanks, > Chiranjib > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Search the list archives at: > http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers > > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 3734 bytes Desc: not available URL: From chengdi at imech.ac.cn Mon Apr 27 09:40:48 2015 From: chengdi at imech.ac.cn (Di Cheng) Date: Mon, 27 Apr 2015 21:40:48 +0800 Subject: [Paraview-developers] Time streaming problem of TemporalCache in paraview python Message-ID: <000001d080ef$c5c33c70$5149b550$@imech.ac.cn> Hi, every one I am using paraview to calculate correlation of each time steps in a filter, and I am using programmable filter to implement it. I have tried three different pipelines like those: 1) Reader +-TemporalCache1->ProgrammableFilter +-TemporalCache2->ProgrammableFilter But it failed and give me a segfault after some output, And before segfault the data that TemporalCache1 transferred to ProgrammableFilter is nan. Increasing CacheSize of TemporalCache is useless. 2) Reader1->TemporalCache1->ProgrammableFilter Reader2->TemporalCache2->ProgrammableFilter No segfault, but still nan 3) Reader1 ->ProgrammableFilter Reader2 ->ProgrammableFilter It works! My question is: Why? p.s. I am using paraview 4.3.1 in Ubuntu 12.04. Here is my code: #### import the simple module from the paraview from paraview.simple import * import numpy as np # ---------------------------------------------------------------- # setup the data processing pipelines # ---------------------------------------------------------------- filename = '/home/wei/Wu/VortexStreet/100cylinder/100cylinder.foam' # create a new 'OpenFOAMReader' reader1 = OpenFOAMReader(FileName=filename) reader1.Createcelltopointfiltereddata = 0 reader1.MeshRegions = ['internalMesh'] reader1.CellArrays = ['p'] reader1.Cachemesh = 0 reader1.Decomposepolyhedra = 0 # create a new 'OpenFOAMReader' reader2 = OpenFOAMReader(FileName=filename) reader2.Createcelltopointfiltereddata = 0 reader2.MeshRegions = ['internalMesh'] reader2.CellArrays = ['p'] reader2.Cachemesh = 0 reader2.Decomposepolyhedra = 0 # create a new 'Temporal Cache' tc1 = TemporalCache(Input=reader1) tc1.CacheSize=2 # create a new 'Temporal Cache' tc2 = TemporalCache(Input=reader2) tc2.CacheSize=2 # initialize in RequestInformationScript # Ask for new timestep in RequestUpdateExtentScript # generate dataset in Script #pf2 = ProgrammableFilter(Input = [tc1,tc2]) pf2 = ProgrammableFilter(Input = [reader1,reader2]) pf2.CopyArrays = 0 pf2.OutputDataSetType = 'vtkTable' pf2.Script =\ """ print 'running: Script' # according to the c++ implementation of vtkPythonProgrammableFilter # the following script has been run # from paraview import vtk # hasnumpy = True # try: # from numpy import * # except ImportError: # hasnumpy = False # if hasnumpy: # from vtk.numpy_interface import dataset_adapter #note: all locals() will be collected by Garbage Collection after execution. #save all important variables in self.*** #pass arguments to other scripts by self.*** #use hasattr(***) function to check if there is existing self.*** # ref: The Paraview Guide v4.3 Chapter 13.2.2 # the types: # executive: vtkPVCompositeDataPipeline # inInfo: vtkInformation, ref:http://berkgeveci.github.io/2014/11/09/streaming-time/ from vtk.numpy_interface import algorithms as algs #inner product is defined as cell volume weighted integration of p1*p2 over entire volume self.R[self.i,self.j] = algs.sum(inputs[0].CellData['p']*inputs[1].CellData['p']*self.weight) print self.R[self.i,self.j] #for upper half matrix, keep this matrix symmetry if self.j!=self.i: self.R[self.j,self.i] = self.R[self.i,self.j] try: self.n += 1 self.i,self.j = self.time_value_index[self.n] request.Set(vtk.vtkStreamingDemandDrivenPipeline.CONTINUE_EXECUTING(),1) print 'CONTINUE_EXECUTING is set' except IndexError: #output output.RowData.append(self.time_steps,'time_steps') for k,t0 in enumerate(self.time_steps): output.RowData.append(self.R[k],'{}'.format(k)) #stop request.Remove(vtk.vtkStreamingDemandDrivenPipeline.CONTINUE_EXECUTING()) print 'CONTINUE_EXECUTING removed' """ pf2.RequestUpdateExtentScript=\ """ print 'running: RequestUpdateExtentScript' # Code for RequestUpdateExtentScript. executive = self.GetExecutive() inInfo0 = executive.GetInputInformation(0,0) #port 0, connection 0 inInfo1 = executive.GetInputInformation(0,1) #port 0, connection 1 inInfo0.Set(vtk.vtkStreamingDemandDrivenPipeline.UPDATE_TIME_STEP(),self.time_steps[self.i]) inInfo1.Set(vtk.vtkStreamingDemandDrivenPipeline.UPDATE_TIME_STEP(),self.time_steps[self.j]) print 'i={},j={},t0={},t1={}'.format(self.i,self.j,self.time_steps[self.i],self.time_steps[self.j]) """ pf2.RequestInformationScript=\ ''' print 'running: RequestInformationScript' # ref: The Paraview Guide v4.3 Chapter 13.2.2 # the types: # executive: vtkPVCompositeDataPipeline # outInfo: vtkInformation, ref:http://berkgeveci.github.io/2014/11/09/streaming-time/ executive = self.GetExecutive() outInfo = executive.GetOutputInformation(0) outInfo.Remove(executive.TIME_RANGE ()) outInfo.Remove(executive.TIME_STEPS ()) print 'outInfo:' print(outInfo) inInfo0 = executive.GetInputInformation(0,0) #port 0, connection 0 print 'inInfo0:' print(inInfo0) # set the sampling time steps start,end,step = 101,202,20 # None means to the end of the array self.time_steps = array(inInfo0.Get(vtk.vtkStreamingDemandDrivenPipeline.TIME_STEPS())[start:end:step]) #create object, in case of Garbage Collection print self.time_steps self.N = len(self.time_steps) from itertools import combinations_with_replacement self.time_value_index = tuple(combinations_with_replacement(range(self.N),2)) self.n = 0 self.i,self.j = self.time_value_index[self.n] #iterate to calculate correlation matrix self.R = zeros([self.N,self.N]) from vtk.numpy_interface import algorithms as algs self.weight = algs.volume(inputs[0]) self.weight = self.weight/algs.sum(self.weight) #normalization ''' pf2.UpdatePipeline() # calculate eigen values pf3 = ProgrammableFilter(Input =pf2) pf3.CopyArrays = 0 pf3.OutputDataSetType = 'vtkTable' pf3.Script=\ ''' #get R t = inputs[0].RowData['time_steps'] N = len(t) R = zeros([N,N]) for i in range(N): R[i]=inputs[0].RowData['{}'.format(i)] #calculate eigen values and vectors from numpy.linalg import eigh e,eV = eigh(R) total_energy = trace(R) #sort eV and a by a idx = argsort(e) e = e[idx[::-1]] en = e/total_energy #normalized energy eV = eV[idx[::-1]] output.RowData.append(t,'time_steps') output.RowData.append(e,'eigen_value') output.RowData.append(en,'relative_energy_fraction') for i,t0 in enumerate(t): output.RowData.append(eV[i],'{}'.format(i)) ''' pf3.UpdatePipeline() Di CHENG (Ph.D. candidate) Supersonic Combustion Group State Key Laboratory of High Temperature Gas Dynamics Institute of Mechanics, Chinese Academy of Sciences ADDRESS: No.15 Beisihuanxi Road, Beijing (100190) P. R. China E-mail: chengdi at imech.ac.cn Phone: +86-10-82544053 Fax: +86-10-82544034 From chengdi at imech.ac.cn Mon Apr 27 11:49:57 2015 From: chengdi at imech.ac.cn (Di Cheng) Date: Mon, 27 Apr 2015 23:49:57 +0800 Subject: [Paraview-developers] How to use the "Parameters" property of "Programmable Filter" in pvpython? Message-ID: <000301d08101$d0ac7d60$72057820$@imech.ac.cn> Hi, everyone I am using Programmable Filter in paraview. I noticed that there is a Parameters property in Programmable Filter. But I cannot use it in GUI, either in pvpython. I referred the C++ document about this filter in [http://www.paraview.org/ParaView3/Doc/Nightly/www/cxx-doc/classvtkPythonProgrammableFilter.html], It is used to pass arguments to python script. BUT, I CANNOT USE IT in pvpython. I think it is because it accept two or more parameters and cannot be wrapped by XML file. I know there is a undocumented GetClientSideObject() method which could work in "builtin:" mode. But it could only work locally Currently, I am using a script generator to pass arguments -----code----- def pass_arg_script(d): """ generate script to pass parameters in dictionary d={'name':value} value can be numpy arrays """ s="" for k in d: s+='self.'+k+'='+repr(d[k])+'\n' s+="print '"+k+"=', self."+k+'\n' return s pf.Script = s+ pf.Script ------end of code------ My question is: Is there any decent way to pass Parameters to Programmable Filter in pvpython? Di CHENG (Ph.D. candidate) Supersonic Combustion Group State Key Laboratory of High Temperature Gas Dynamics Institute of Mechanics, Chinese Academy of Sciences ADDRESS: No.15 Beisihuanxi Road, Beijing (100190) P. R. China E-mail: chengdi at imech.ac.cn Phone: +86-10-82544053 Fax: +86-10-82544034 From dave.demarle at kitware.com Mon Apr 27 12:04:19 2015 From: dave.demarle at kitware.com (David E DeMarle) Date: Mon, 27 Apr 2015 12:04:19 -0400 Subject: [Paraview-developers] How to use the "Parameters" property of "Programmable Filter" in pvpython? In-Reply-To: <000301d08101$d0ac7d60$72057820$@imech.ac.cn> References: <000301d08101$d0ac7d60$72057820$@imech.ac.cn> Message-ID: I think we've been meaning to expose those in the GUI ever since we added those back in about paraview 3.4. Anyway, here is the syntax from a python script I recently used them in. where gen is the proxy for a python programmable filter paramprop = gen.GetProperty("Parameters") paramprop.SetElement(0, "ntimes") paramprop.SetElement(1, str(ntimes)) paramprop.SetElement(2, "nlevels") paramprop.SetElement(3, str(nlevels)) ? gen.UpdateProperty("Parameters") gen.UpdatePipeline() For more details refer to the attached benchmarking script. David E DeMarle Kitware, Inc. R&D Engineer 21 Corporate Drive Clifton Park, NY 12065-8662 Phone: 518-881-4909 On Mon, Apr 27, 2015 at 11:49 AM, Di Cheng wrote: > Hi, everyone > > I am using Programmable Filter in paraview. I noticed that there is a > Parameters property in Programmable Filter. But I cannot use it in GUI, > either in pvpython. > > I referred the C++ document about this filter in [ > http://www.paraview.org/ParaView3/Doc/Nightly/www/cxx-doc/classvtkPythonProgrammableFilter.html], > It is used to pass arguments to python script. BUT, I CANNOT USE IT in > pvpython. I think it is because it accept two or more parameters and cannot > be wrapped by XML file. > > I know there is a undocumented GetClientSideObject() method which could > work in "builtin:" mode. But it could only work locally > > Currently, I am using a script generator to pass arguments > -----code----- > def pass_arg_script(d): > """ > generate script to pass parameters in dictionary d={'name':value} > value can be numpy arrays > """ > s="" > for k in d: > s+='self.'+k+'='+repr(d[k])+'\n' > s+="print '"+k+"=', self."+k+'\n' > return s > > pf.Script = s+ pf.Script > ------end of code------ > > My question is: Is there any decent way to pass Parameters to Programmable > Filter in pvpython? > > Di CHENG (Ph.D. candidate) > Supersonic Combustion Group > State Key Laboratory of High Temperature Gas Dynamics > Institute of Mechanics, Chinese Academy of Sciences > ADDRESS: No.15 Beisihuanxi Road, Beijing (100190) > P. R. China > E-mail: chengdi at imech.ac.cn > Phone: +86-10-82544053 > Fax: +86-10-82544034 > > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Search the list archives at: > http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: benchSynthSource.py Type: text/x-python-script Size: 8438 bytes Desc: not available URL: From utkarsh.ayachit at kitware.com Mon Apr 27 13:53:26 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Mon, 27 Apr 2015 13:53:26 -0400 Subject: [Paraview-developers] Replacement of SetInput with SetInputData (VTK5 vs. 6) In-Reply-To: <0361B901-93E3-4738-B449-4250311F1E91@aia.rwth-aachen.de> References: <0361B901-93E3-4738-B449-4250311F1E91@aia.rwth-aachen.de> Message-ID: > Now I am wondering: ifinside the RequestData method of a filter, do I *ever* > need to use SetInputConnection, and if yes, how? Here's an example: vtkMyFilter::RequestData(....) { vtkDataSet* myinput = vtkDataSet::GetData(inputInformation[0], 0); vtkNew filter1; filter1->SetInputData(myinput); vtkNew filter2; filter2->SetInputConnection(filter1->GetOutputPort()); ... filter2->Update() } Thus, for internal pipelines, it makes sense to use SetInputConnection. > It seems like all filters > I?ve had a look at always access the input data object (which I can only > pass on using SetInputData, not SetInputConnection), not the input port. > However, as a user with little VTK experience it seems like this might > ?break? the aforementioned pipeline? It the example I gave, for example, if you use SetInputData() to pass the output of filter1 to filter2, you'll need to call filter1->Update() before doing that. Otherwise, filter1 has not execute and hence doesn't have valid data to pass to filter2. Unlike the old SetInput(), setting the dataset using SetInputData() doesn't preserve the pipeline information i.e. filter2 will not update filter1 just because you called filter2->Update() if SetInputData() is used to pass the data. Hope that clarifies it a little. From sur.chiranjib at gmail.com Mon Apr 27 14:20:17 2015 From: sur.chiranjib at gmail.com (Chiranjib Sur) Date: Mon, 27 Apr 2015 23:50:17 +0530 Subject: [Paraview-developers] using File>Open dialogue in custom filter In-Reply-To: References: Message-ID: HI Utkarsh, Great, Let me try it. Currently, I have declared it like .... so that I can extract the "FileName" as a string. However, with this, I don't have an option to select the files using pop-up. If I understood it correctly, I need to use the following part along with the one I already have ? ..... Is it what you mean by adding FileListDomain ? Thanks, Chiranjib On Mon, Apr 27, 2015 at 6:56 PM, Utkarsh Ayachit < utkarsh.ayachit at kitware.com> wrote: > Simply add the "FileListDomain" to the property as done for the QFileName > property here: > https://gitlab.kitware.com/paraview/paraview/blob/master/ParaViewCore/ServerManager/SMApplication/Resources/readers.xml#L2659-2667 > > > On Mon, Apr 27, 2015 at 6:27 AM, Chiranjib Sur > wrote: > >> Hi, >> I am trying to write my own filter (C++) and want to deal with reading an >> existing file. I intend implement a functionality where file selection >> will results into popping up a window like when one does, File->Open action. >> >> In the following screen capture, I want to implement that functionality >> so that when one clicks mouse inside the text box, File->Open windows will >> popup and the user can select the file he/she wants. (The alternative is to >> provide the file name by typing which is error prone and I want to avoid >> that) >> >> [image: Inline image 1] >> >> After reading various posts from the previous mailing threads and the >> other documentation, I narrowed down my idea to use the class pqFileDialog. >> Is this the right choice or are there some alternatives? Are there any >> place where, I can read and learn about usage of this class ? >> >> Google search points me towards solutions in pure Qt which looks like : >> >> >> http://stackoverflow.com/questions/14372012/qt-standard-dialogs-example-open-file >> >> >> Any suggestions from the experts? >> >> Thanks, >> Chiranjib >> >> _______________________________________________ >> Powered by www.kitware.com >> >> Visit other Kitware open-source projects at >> http://www.kitware.com/opensource/opensource.html >> >> Search the list archives at: >> http://markmail.org/search/?q=Paraview-developers >> >> Follow this link to subscribe/unsubscribe: >> http://public.kitware.com/mailman/listinfo/paraview-developers >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 3734 bytes Desc: not available URL: From utkarsh.ayachit at kitware.com Mon Apr 27 15:12:07 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Mon, 27 Apr 2015 15:12:07 -0400 Subject: [Paraview-developers] using File>Open dialogue in custom filter In-Reply-To: References: Message-ID: Chiranjib, No, that's not what I mean. Your FileName is not being shown since you have the panel_visibility="never". Change that to "default" or "advanced" as appropriate. Utkarsh On Mon, Apr 27, 2015 at 2:20 PM, Chiranjib Sur wrote: > HI Utkarsh, > Great, Let me try it. > Currently, I have declared it like > > > > .... > > so that I can extract the "FileName" as a string. However, with this, I > don't have an option to select the files using pop-up. > > If I understood it correctly, I need to use the following part along with > the one I already have ? > > ..... > > > Is it what you mean by adding FileListDomain ? > > Thanks, > Chiranjib > > On Mon, Apr 27, 2015 at 6:56 PM, Utkarsh Ayachit < > utkarsh.ayachit at kitware.com> wrote: > >> Simply add the "FileListDomain" to the property as done for the QFileName >> property here: >> https://gitlab.kitware.com/paraview/paraview/blob/master/ParaViewCore/ServerManager/SMApplication/Resources/readers.xml#L2659-2667 >> >> >> On Mon, Apr 27, 2015 at 6:27 AM, Chiranjib Sur >> wrote: >> >>> Hi, >>> I am trying to write my own filter (C++) and want to deal with reading >>> an existing file. I intend implement a functionality where file selection >>> will results into popping up a window like when one does, File->Open action. >>> >>> In the following screen capture, I want to implement that functionality >>> so that when one clicks mouse inside the text box, File->Open windows will >>> popup and the user can select the file he/she wants. (The alternative is to >>> provide the file name by typing which is error prone and I want to avoid >>> that) >>> >>> [image: Inline image 1] >>> >>> After reading various posts from the previous mailing threads and the >>> other documentation, I narrowed down my idea to use the class pqFileDialog. >>> Is this the right choice or are there some alternatives? Are there any >>> place where, I can read and learn about usage of this class ? >>> >>> Google search points me towards solutions in pure Qt which looks like : >>> >>> >>> http://stackoverflow.com/questions/14372012/qt-standard-dialogs-example-open-file >>> >>> >>> Any suggestions from the experts? >>> >>> Thanks, >>> Chiranjib >>> >>> _______________________________________________ >>> Powered by www.kitware.com >>> >>> Visit other Kitware open-source projects at >>> http://www.kitware.com/opensource/opensource.html >>> >>> Search the list archives at: >>> http://markmail.org/search/?q=Paraview-developers >>> >>> Follow this link to subscribe/unsubscribe: >>> http://public.kitware.com/mailman/listinfo/paraview-developers >>> >>> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 3734 bytes Desc: not available URL: From sur.chiranjib at gmail.com Mon Apr 27 23:58:19 2015 From: sur.chiranjib at gmail.com (Chiranjib Sur) Date: Tue, 28 Apr 2015 09:28:19 +0530 Subject: [Paraview-developers] using File>Open dialogue in custom filter In-Reply-To: References: Message-ID: Utkarsh, This is the first thing I tried this morning and just the one liner solved my problem and made my day ! I just added the line in my xml file and the problem is solved. Thank you very much, Chiranjib On Tue, Apr 28, 2015 at 12:42 AM, Utkarsh Ayachit < utkarsh.ayachit at kitware.com> wrote: > Chiranjib, > > No, that's not what I mean. Your FileName is not being shown since you > have the panel_visibility="never". > Change that to "default" or "advanced" as appropriate. > > Utkarsh > > On Mon, Apr 27, 2015 at 2:20 PM, Chiranjib Sur > wrote: > >> HI Utkarsh, >> Great, Let me try it. >> Currently, I have declared it like >> >> >> >> .... >> >> so that I can extract the "FileName" as a string. However, with this, I >> don't have an option to select the files using pop-up. >> >> If I understood it correctly, I need to use the following part along with >> the one I already have ? >> >> ..... >> >> >> Is it what you mean by adding FileListDomain ? >> >> Thanks, >> Chiranjib >> >> On Mon, Apr 27, 2015 at 6:56 PM, Utkarsh Ayachit < >> utkarsh.ayachit at kitware.com> wrote: >> >>> Simply add the "FileListDomain" to the property as done for the >>> QFileName property here: >>> https://gitlab.kitware.com/paraview/paraview/blob/master/ParaViewCore/ServerManager/SMApplication/Resources/readers.xml#L2659-2667 >>> >>> >>> On Mon, Apr 27, 2015 at 6:27 AM, Chiranjib Sur >>> wrote: >>> >>>> Hi, >>>> I am trying to write my own filter (C++) and want to deal with reading >>>> an existing file. I intend implement a functionality where file selection >>>> will results into popping up a window like when one does, File->Open action. >>>> >>>> In the following screen capture, I want to implement that functionality >>>> so that when one clicks mouse inside the text box, File->Open windows will >>>> popup and the user can select the file he/she wants. (The alternative is to >>>> provide the file name by typing which is error prone and I want to avoid >>>> that) >>>> >>>> [image: Inline image 1] >>>> >>>> After reading various posts from the previous mailing threads and the >>>> other documentation, I narrowed down my idea to use the class pqFileDialog. >>>> Is this the right choice or are there some alternatives? Are there any >>>> place where, I can read and learn about usage of this class ? >>>> >>>> Google search points me towards solutions in pure Qt which looks like : >>>> >>>> >>>> http://stackoverflow.com/questions/14372012/qt-standard-dialogs-example-open-file >>>> >>>> >>>> Any suggestions from the experts? >>>> >>>> Thanks, >>>> Chiranjib >>>> >>>> _______________________________________________ >>>> Powered by www.kitware.com >>>> >>>> Visit other Kitware open-source projects at >>>> http://www.kitware.com/opensource/opensource.html >>>> >>>> Search the list archives at: >>>> http://markmail.org/search/?q=Paraview-developers >>>> >>>> Follow this link to subscribe/unsubscribe: >>>> http://public.kitware.com/mailman/listinfo/paraview-developers >>>> >>>> >>> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 3734 bytes Desc: not available URL: From M.Schlottke at aia.rwth-aachen.de Tue Apr 28 02:54:38 2015 From: M.Schlottke at aia.rwth-aachen.de (Schlottke, Michael) Date: Tue, 28 Apr 2015 06:54:38 +0000 Subject: [Paraview-developers] Replacement of SetInput with SetInputData (VTK5 vs. 6) In-Reply-To: References: <0361B901-93E3-4738-B449-4250311F1E91@aia.rwth-aachen.de> Message-ID: Hi Utkarsh, Thank you very much for this answer, it clears things up a lot. Am I right to sum this up as a rule of thumb to ?use SetInputConnection whenever possible, resort to SetInputData where it isn?t? for most use cases? On a related note, I?ve encountered a few filters with code like this: ////////////////////////////////////////////////////////////// vtkMyFilter::RequestData(?.) { ? vtkCellDataToPointData* cp = vtkCellDataToPointData::New(); ... vtkUnstructuredGrid* pdata = cp->GetUnstructuredGridOutput(); pdata->GetPointData()->RemoveArray(?arrayname"); pdata->GetPointData()->Update(); pdata->Update(); // will not compile with VTK6 (******) vtkInformation *outInfo = outputVector->GetInformationObject(0); vtkUnstructuredGrid *output = vtkUnstructuredGrid::SafeDownCast(outInfo->Get(vtkDataObject::DATA_OBJECT())); output->SetPoints(pdata->GetPoints()); output->CopyStructure(pdata); output->GetCellData()->PassData(pdata->GetCellData()); return 1; } ////////////////////////////////////////////////////////////// I am wondering about the line marked with (******). Is it obsolete with VTK6 (as there is no Update() method for non-vtkAlgorithm objects), should I call cp->Update() instead, or is there something entirely different to do to make this code work properly? Regards, Michael > On 27 Apr 2015, at 19:53 , Utkarsh Ayachit wrote: > >> Now I am wondering: ifinside the RequestData method of a filter, do I *ever* >> need to use SetInputConnection, and if yes, how? > > > Here's an example: > > vtkMyFilter::RequestData(....) > { > vtkDataSet* myinput = vtkDataSet::GetData(inputInformation[0], 0); > > vtkNew filter1; > filter1->SetInputData(myinput); > > vtkNew filter2; > filter2->SetInputConnection(filter1->GetOutputPort()); > ... > > filter2->Update() > } > > Thus, for internal pipelines, it makes sense to use SetInputConnection. > >> It seems like all filters >> I?ve had a look at always access the input data object (which I can only >> pass on using SetInputData, not SetInputConnection), not the input port. >> However, as a user with little VTK experience it seems like this might >> ?break? the aforementioned pipeline? > > It the example I gave, for example, if you use SetInputData() to pass > the output of filter1 to filter2, you'll need to call > filter1->Update() before doing that. Otherwise, filter1 has not > execute and hence doesn't have valid data to pass to filter2. Unlike > the old SetInput(), setting the dataset using SetInputData() doesn't > preserve the pipeline information i.e. filter2 will not update filter1 > just because you called filter2->Update() if SetInputData() is used to > pass the data. > > Hope that clarifies it a little. From M.Schlottke at aia.rwth-aachen.de Tue Apr 28 05:37:41 2015 From: M.Schlottke at aia.rwth-aachen.de (Schlottke, Michael) Date: Tue, 28 Apr 2015 09:37:41 +0000 Subject: [Paraview-developers] Removal of ExecuteData(...) Message-ID: <8016D5D5-842C-42DA-9EB1-6A353C7DC1E8@aia.rwth-aachen.de> Hi again, I am trying to follow the VTK guide (http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Removal_of_Execute) on migrating a set of ParaView plugins from VTK 5 to VTK 6. Just to be sure, what would be the correct way to replace the following implementation: ///////////////////////////////////////////////////////////////////////// void vtkMyAlgorithmSubclass::ExecuteData(vtkDataObject *output) { if (output && this->UpdateExtentIsEmpty(output)) { output->Initialize(); return; } this->Execute(); } ///////////////////////////////////////////////////////////////////////// Can I just move this whole code into RequestData (and use the vtkDataObject* output as a downcast from my output info object)? Is the call to Execute() still needed in this case? Thanks! Michael -- Michael Schlottke Chair of Fluid Mechanics and Institute of Aerodynamics RWTH Aachen University W?llnerstra?e 5a 52062 Aachen Germany Phone: +49 (241) 80 95188 Fax: +49 (241) 80 92257 Mail: m.schlottke at aia.rwth-aachen.de Web: http://www.aia.rwth-aachen.de -------------- next part -------------- An HTML attachment was scrubbed... URL: From utkarsh.ayachit at kitware.com Tue Apr 28 08:23:58 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Tue, 28 Apr 2015 08:23:58 -0400 Subject: [Paraview-developers] using File>Open dialogue in custom filter In-Reply-To: References: Message-ID: Glad it's working. On Mon, Apr 27, 2015 at 11:58 PM, Chiranjib Sur wrote: > Utkarsh, > This is the first thing I tried this morning and just the one liner solved > my problem and made my day ! > > I just added the line > > in my xml file and the problem is solved. > > Thank you very much, > Chiranjib > > On Tue, Apr 28, 2015 at 12:42 AM, Utkarsh Ayachit < > utkarsh.ayachit at kitware.com> wrote: > >> Chiranjib, >> >> No, that's not what I mean. Your FileName is not being shown since you >> have the panel_visibility="never". >> Change that to "default" or "advanced" as appropriate. >> >> Utkarsh >> >> On Mon, Apr 27, 2015 at 2:20 PM, Chiranjib Sur >> wrote: >> >>> HI Utkarsh, >>> Great, Let me try it. >>> Currently, I have declared it like >>> >>> >>> >>> .... >>> >>> so that I can extract the "FileName" as a string. However, with this, I >>> don't have an option to select the files using pop-up. >>> >>> If I understood it correctly, I need to use the following part along >>> with the one I already have ? >>> >>> ..... >>> >>> >>> Is it what you mean by adding FileListDomain ? >>> >>> Thanks, >>> Chiranjib >>> >>> On Mon, Apr 27, 2015 at 6:56 PM, Utkarsh Ayachit < >>> utkarsh.ayachit at kitware.com> wrote: >>> >>>> Simply add the "FileListDomain" to the property as done for the >>>> QFileName property here: >>>> https://gitlab.kitware.com/paraview/paraview/blob/master/ParaViewCore/ServerManager/SMApplication/Resources/readers.xml#L2659-2667 >>>> >>>> >>>> On Mon, Apr 27, 2015 at 6:27 AM, Chiranjib Sur >>> > wrote: >>>> >>>>> Hi, >>>>> I am trying to write my own filter (C++) and want to deal with reading >>>>> an existing file. I intend implement a functionality where file selection >>>>> will results into popping up a window like when one does, File->Open action. >>>>> >>>>> In the following screen capture, I want to implement that >>>>> functionality so that when one clicks mouse inside the text box, File->Open >>>>> windows will popup and the user can select the file he/she wants. (The >>>>> alternative is to provide the file name by typing which is error prone and >>>>> I want to avoid that) >>>>> >>>>> [image: Inline image 1] >>>>> >>>>> After reading various posts from the previous mailing threads and the >>>>> other documentation, I narrowed down my idea to use the class pqFileDialog. >>>>> Is this the right choice or are there some alternatives? Are there any >>>>> place where, I can read and learn about usage of this class ? >>>>> >>>>> Google search points me towards solutions in pure Qt which looks like : >>>>> >>>>> >>>>> http://stackoverflow.com/questions/14372012/qt-standard-dialogs-example-open-file >>>>> >>>>> >>>>> Any suggestions from the experts? >>>>> >>>>> Thanks, >>>>> Chiranjib >>>>> >>>>> _______________________________________________ >>>>> Powered by www.kitware.com >>>>> >>>>> Visit other Kitware open-source projects at >>>>> http://www.kitware.com/opensource/opensource.html >>>>> >>>>> Search the list archives at: >>>>> http://markmail.org/search/?q=Paraview-developers >>>>> >>>>> Follow this link to subscribe/unsubscribe: >>>>> http://public.kitware.com/mailman/listinfo/paraview-developers >>>>> >>>>> >>>> >>> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 3734 bytes Desc: not available URL: From berk.geveci at kitware.com Tue Apr 28 09:50:32 2015 From: berk.geveci at kitware.com (Berk Geveci) Date: Tue, 28 Apr 2015 09:50:32 -0400 Subject: [Paraview-developers] Replacement of SetInput with SetInputData (VTK5 vs. 6) In-Reply-To: References: <0361B901-93E3-4738-B449-4250311F1E91@aia.rwth-aachen.de> Message-ID: Replace that Update() with cp->Update(). The rule for internal filters is that you should never use SetInputConnection() to connect anything to an external filter from within RequestData(). You don't want internal pipeline executions to propagate to external filters as it may cause all kinds of problems. SetInputData() does not create a pipeline connection so it is safe to use in such circumstances. SetInputConnection() is safe to connect internal filters to each other. Best, -berk On Tue, Apr 28, 2015 at 2:54 AM, Schlottke, Michael < M.Schlottke at aia.rwth-aachen.de> wrote: > Hi Utkarsh, > > Thank you very much for this answer, it clears things up a lot. Am I right > to sum this up as a rule of thumb to > > ?use SetInputConnection whenever possible, resort to SetInputData where it > isn?t? > > for most use cases? > > On a related note, I?ve encountered a few filters with code like this: > > ////////////////////////////////////////////////////////////// > vtkMyFilter::RequestData(?.) > { > ? > vtkCellDataToPointData* cp = vtkCellDataToPointData::New(); > ... > vtkUnstructuredGrid* pdata = cp->GetUnstructuredGridOutput(); > pdata->GetPointData()->RemoveArray(?arrayname"); > pdata->GetPointData()->Update(); > pdata->Update(); // will not compile with VTK6 (******) > > vtkInformation *outInfo = outputVector->GetInformationObject(0); > vtkUnstructuredGrid *output = > vtkUnstructuredGrid::SafeDownCast(outInfo->Get(vtkDataObject::DATA_OBJECT())); > output->SetPoints(pdata->GetPoints()); > output->CopyStructure(pdata); > output->GetCellData()->PassData(pdata->GetCellData()); > > return 1; > } > ////////////////////////////////////////////////////////////// > > I am wondering about the line marked with (******). Is it obsolete with > VTK6 (as there is no Update() method for non-vtkAlgorithm objects), should > I call cp->Update() instead, or is there something entirely different to do > to make this code work properly? > > Regards, > > Michael > > > On 27 Apr 2015, at 19:53 , Utkarsh Ayachit > wrote: > > > >> Now I am wondering: ifinside the RequestData method of a filter, do I > *ever* > >> need to use SetInputConnection, and if yes, how? > > > > > > Here's an example: > > > > vtkMyFilter::RequestData(....) > > { > > vtkDataSet* myinput = vtkDataSet::GetData(inputInformation[0], 0); > > > > vtkNew filter1; > > filter1->SetInputData(myinput); > > > > vtkNew filter2; > > filter2->SetInputConnection(filter1->GetOutputPort()); > > ... > > > > filter2->Update() > > } > > > > Thus, for internal pipelines, it makes sense to use SetInputConnection. > > > >> It seems like all filters > >> I?ve had a look at always access the input data object (which I can only > >> pass on using SetInputData, not SetInputConnection), not the input port. > >> However, as a user with little VTK experience it seems like this might > >> ?break? the aforementioned pipeline? > > > > It the example I gave, for example, if you use SetInputData() to pass > > the output of filter1 to filter2, you'll need to call > > filter1->Update() before doing that. Otherwise, filter1 has not > > execute and hence doesn't have valid data to pass to filter2. Unlike > > the old SetInput(), setting the dataset using SetInputData() doesn't > > preserve the pipeline information i.e. filter2 will not update filter1 > > just because you called filter2->Update() if SetInputData() is used to > > pass the data. > > > > Hope that clarifies it a little. > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Search the list archives at: > http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers > -------------- next part -------------- An HTML attachment was scrubbed... URL: From berk.geveci at kitware.com Tue Apr 28 09:52:58 2015 From: berk.geveci at kitware.com (Berk Geveci) Date: Tue, 28 Apr 2015 09:52:58 -0400 Subject: [Paraview-developers] Removal of ExecuteData(...) In-Reply-To: <8016D5D5-842C-42DA-9EB1-6A353C7DC1E8@aia.rwth-aachen.de> References: <8016D5D5-842C-42DA-9EB1-6A353C7DC1E8@aia.rwth-aachen.de> Message-ID: Hi Michael, You will need some minor changes but yes you can move that to RequestData(). You will have to pass the input and output to Execute() somehow. Best, -berk On Tue, Apr 28, 2015 at 5:37 AM, Schlottke, Michael < M.Schlottke at aia.rwth-aachen.de> wrote: > Hi again, > > I am trying to follow the VTK guide ( > http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Removal_of_Execute) on > migrating a set of ParaView plugins from VTK 5 to VTK 6. > > Just to be sure, what would be the correct way to replace the following > implementation: > > ///////////////////////////////////////////////////////////////////////// > void vtkMyAlgorithmSubclass::ExecuteData(vtkDataObject *output) > > { > > if (output && this->UpdateExtentIsEmpty(output)) > > { > > output->Initialize(); > > return; > > } > > > > this->Execute(); > > } > ///////////////////////////////////////////////////////////////////////// > > Can I just move this whole code into RequestData (and use the > vtkDataObject* output as a downcast from my output info object)? Is the > call to Execute() still needed in this case? > > Thanks! > > Michael > > > -- > Michael Schlottke > > Chair of Fluid Mechanics and Institute of Aerodynamics > RWTH Aachen University > W?llnerstra?e 5a > 52062 Aachen > Germany > > Phone: +49 (241) 80 95188 > Fax: +49 (241) 80 92257 > Mail: m.schlottke at aia.rwth-aachen.de > Web: http://www.aia.rwth-aachen.de > > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Search the list archives at: > http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From utkarsh.ayachit at kitware.com Tue Apr 28 09:58:33 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Tue, 28 Apr 2015 09:58:33 -0400 Subject: [Paraview-developers] Replacement of SetInput with SetInputData (VTK5 vs. 6) In-Reply-To: References: <0361B901-93E3-4738-B449-4250311F1E91@aia.rwth-aachen.de> Message-ID: Michael, Let me give you some background. Once upon a time, the way to connect an upstream filter/source to a downstream filter was via the data object produced by the upstream filter. e.g. filterDownStream->SetInput(filterUpStream->GetOutput()); This meant that a data object obtained from filter::GetOutput() always was aware of which source/filter produced it (or can produce it). Hence methods like "vtkDataObject::Update()" could be used to update the producer pipeline from a pointer to the output data object. Hence, in your example, "pdata->Update()" worked. That has now changed it VTK 6. The data object no longer keeps track of which producer is producing it. There are several reasons/advantages for that, but I'll not go into those here. Hence, while you can still set a data object as an input to a filter, since the data object doesn't know about its producer, it doesn't have any information about the upstream pipeline and hence will not update it on demand when the downstream filter is updated. A way of fixing your code is as follows: ////////////////////////////////////////////////////////////// vtkMyFilter::RequestData(?.) { ? vtkCellDataToPointData* cp = vtkCellDataToPointData::New(); ... cp->Update(); // will not compile with VTK6 (******) vtkUnstructuredGrid* pdata = cp->GetUnstructuredGridOutput(); vtkInformation *outInfo = outputVector->GetInformationObject(0); vtkUnstructuredGrid *output = vtkUnstructuredGrid::SafeDownCast(outInfo->Get(vtkDataObject::DATA_OBJECT())); output->SetPoints(pdata->GetPoints()); output->CopyStructure(pdata); output->GetCellData()->PassData(pdata->GetCellData()); return 1; } ////////////////////////////////////////////////////////////// From M.Schlottke at aia.rwth-aachen.de Thu Apr 30 01:12:59 2015 From: M.Schlottke at aia.rwth-aachen.de (Schlottke, Michael) Date: Thu, 30 Apr 2015 05:12:59 +0000 Subject: [Paraview-developers] Removal of ExecuteData(...) In-Reply-To: References: <8016D5D5-842C-42DA-9EB1-6A353C7DC1E8@aia.rwth-aachen.de> Message-ID: <9FD0E576-756B-461C-91A9-8722F04899FC@aia.rwth-aachen.de> Hi Berk, Thank you for your answer. What do you mean by ?minor changes? (other than that I somehow have to obtain the correct output pointer)? And do I really need to pass data to Execute()? As far as I can tell, the particular filter I?m looking at does nothing in Execute() (really a no-op), so it seems like a good candidate to be removed completely. Michale On 28 Apr 2015, at 15:52 , Berk Geveci > wrote: Hi Michael, You will need some minor changes but yes you can move that to RequestData(). You will have to pass the input and output to Execute() somehow. Best, -berk On Tue, Apr 28, 2015 at 5:37 AM, Schlottke, Michael > wrote: Hi again, I am trying to follow the VTK guide (http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Removal_of_Execute) on migrating a set of ParaView plugins from VTK 5 to VTK 6. Just to be sure, what would be the correct way to replace the following implementation: ///////////////////////////////////////////////////////////////////////// void vtkMyAlgorithmSubclass::ExecuteData(vtkDataObject *output) { if (output && this->UpdateExtentIsEmpty(output)) { output->Initialize(); return; } this->Execute(); } ///////////////////////////////////////////////////////////////////////// Can I just move this whole code into RequestData (and use the vtkDataObject* output as a downcast from my output info object)? Is the call to Execute() still needed in this case? Thanks! Michael -- Michael Schlottke Chair of Fluid Mechanics and Institute of Aerodynamics RWTH Aachen University W?llnerstra?e 5a 52062 Aachen Germany Phone: +49 (241) 80 95188 Fax: +49 (241) 80 92257 Mail: m.schlottke at aia.rwth-aachen.de Web: http://www.aia.rwth-aachen.de _______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Search the list archives at: http://markmail.org/search/?q=Paraview-developers Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/paraview-developers -------------- next part -------------- An HTML attachment was scrubbed... URL: From M.Schlottke at aia.rwth-aachen.de Thu Apr 30 01:13:44 2015 From: M.Schlottke at aia.rwth-aachen.de (Schlottke, Michael) Date: Thu, 30 Apr 2015 05:13:44 +0000 Subject: [Paraview-developers] Replacement of SetInput with SetInputData (VTK5 vs. 6) In-Reply-To: References: <0361B901-93E3-4738-B449-4250311F1E91@aia.rwth-aachen.de> Message-ID: <3FA46114-08C6-47A5-8C14-E0ADB6496B6A@aia.rwth-aachen.de> Hi Berk, Ah, that is good to know. So my typical setup in RequestData for a custom filter should be something like the following: - connect the first internal filter to the input vtkDataObject using SetInputData() - use SetInputConnection() to chain up any internal filters I use (if possible) - finally, store the results in the output vtkDataObject Is this a good approach to follow under normal circumstances or am I missing something here? Michael On 28 Apr 2015, at 15:50 , Berk Geveci > wrote: Replace that Update() with cp->Update(). The rule for internal filters is that you should never use SetInputConnection() to connect anything to an external filter from within RequestData(). You don't want internal pipeline executions to propagate to external filters as it may cause all kinds of problems. SetInputData() does not create a pipeline connection so it is safe to use in such circumstances. SetInputConnection() is safe to connect internal filters to each other. Best, -berk On Tue, Apr 28, 2015 at 2:54 AM, Schlottke, Michael > wrote: Hi Utkarsh, Thank you very much for this answer, it clears things up a lot. Am I right to sum this up as a rule of thumb to ?use SetInputConnection whenever possible, resort to SetInputData where it isn?t? for most use cases? On a related note, I?ve encountered a few filters with code like this: ////////////////////////////////////////////////////////////// vtkMyFilter::RequestData(?.) { ? vtkCellDataToPointData* cp = vtkCellDataToPointData::New(); ... vtkUnstructuredGrid* pdata = cp->GetUnstructuredGridOutput(); pdata->GetPointData()->RemoveArray(?arrayname"); pdata->GetPointData()->Update(); pdata->Update(); // will not compile with VTK6 (******) vtkInformation *outInfo = outputVector->GetInformationObject(0); vtkUnstructuredGrid *output = vtkUnstructuredGrid::SafeDownCast(outInfo->Get(vtkDataObject::DATA_OBJECT())); output->SetPoints(pdata->GetPoints()); output->CopyStructure(pdata); output->GetCellData()->PassData(pdata->GetCellData()); return 1; } ////////////////////////////////////////////////////////////// I am wondering about the line marked with (******). Is it obsolete with VTK6 (as there is no Update() method for non-vtkAlgorithm objects), should I call cp->Update() instead, or is there something entirely different to do to make this code work properly? Regards, Michael > On 27 Apr 2015, at 19:53 , Utkarsh Ayachit > wrote: > >> Now I am wondering: ifinside the RequestData method of a filter, do I *ever* >> need to use SetInputConnection, and if yes, how? > > > Here's an example: > > vtkMyFilter::RequestData(....) > { > vtkDataSet* myinput = vtkDataSet::GetData(inputInformation[0], 0); > > vtkNew filter1; > filter1->SetInputData(myinput); > > vtkNew filter2; > filter2->SetInputConnection(filter1->GetOutputPort()); > ... > > filter2->Update() > } > > Thus, for internal pipelines, it makes sense to use SetInputConnection. > >> It seems like all filters >> I?ve had a look at always access the input data object (which I can only >> pass on using SetInputData, not SetInputConnection), not the input port. >> However, as a user with little VTK experience it seems like this might >> ?break? the aforementioned pipeline? > > It the example I gave, for example, if you use SetInputData() to pass > the output of filter1 to filter2, you'll need to call > filter1->Update() before doing that. Otherwise, filter1 has not > execute and hence doesn't have valid data to pass to filter2. Unlike > the old SetInput(), setting the dataset using SetInputData() doesn't > preserve the pipeline information i.e. filter2 will not update filter1 > just because you called filter2->Update() if SetInputData() is used to > pass the data. > > Hope that clarifies it a little. _______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Search the list archives at: http://markmail.org/search/?q=Paraview-developers Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/paraview-developers -------------- next part -------------- An HTML attachment was scrubbed... URL: From M.Schlottke at aia.rwth-aachen.de Thu Apr 30 01:20:33 2015 From: M.Schlottke at aia.rwth-aachen.de (Schlottke, Michael) Date: Thu, 30 Apr 2015 05:20:33 +0000 Subject: [Paraview-developers] Replacement of SetInput with SetInputData (VTK5 vs. 6) In-Reply-To: References: <0361B901-93E3-4738-B449-4250311F1E91@aia.rwth-aachen.de> Message-ID: <28BFFFBD-0907-4E8D-97C8-CE783E544A84@aia.rwth-aachen.de> Hi Utkarsh, Thank you for helping me understand better how the VTK pipeline works. Just to be sure: even though the data object is modified (directly, not through an algorithm object) after the call to cp->Update(), I can safely pass it on further (in this case to the output data object) without having to call Update() again on its producer? Michael ////////////////////////////////////////// cp->Update(); vtkUnstructuredGrid* pdata = cp->GetUnstructuredGridOutput(); pdata->GetPointData()->RemoveArray(?arrayname"); ? // Do I need to call cp->Update() again here? output->SetPoints(pdata->GetPoints()); ////////////////////////////////////////// > On 28 Apr 2015, at 15:58 , Utkarsh Ayachit wrote: > > Michael, > > Let me give you some background. > > Once upon a time, the way to connect an upstream filter/source to a > downstream filter was via the data object produced by the upstream > filter. > e.g. > > filterDownStream->SetInput(filterUpStream->GetOutput()); > > This meant that a data object obtained from filter::GetOutput() always > was aware of which source/filter produced it (or can produce it). > > Hence methods like "vtkDataObject::Update()" could be used to update > the producer pipeline from a pointer to the output data object. Hence, > in your example, "pdata->Update()" worked. > > That has now changed it VTK 6. The data object no longer keeps track > of which producer is producing it. There are several > reasons/advantages for that, but I'll not go into those here. Hence, > while you can still set a data object as an input to a filter, since > the data object doesn't know about its producer, it doesn't have any > information about the upstream pipeline and hence will not update it > on demand when the downstream filter is updated. > > A way of fixing your code is as follows: > > ////////////////////////////////////////////////////////////// > vtkMyFilter::RequestData(?.) > { > ? > vtkCellDataToPointData* cp = vtkCellDataToPointData::New(); > ... > > cp->Update(); // will not compile with VTK6 (******) > > vtkUnstructuredGrid* pdata = cp->GetUnstructuredGridOutput(); > > vtkInformation *outInfo = outputVector->GetInformationObject(0); > vtkUnstructuredGrid *output = > vtkUnstructuredGrid::SafeDownCast(outInfo->Get(vtkDataObject::DATA_OBJECT())); > output->SetPoints(pdata->GetPoints()); > output->CopyStructure(pdata); > output->GetCellData()->PassData(pdata->GetCellData()); > > return 1; > } > ////////////////////////////////////////////////////////////// From utkarsh.ayachit at kitware.com Thu Apr 30 10:27:53 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Thu, 30 Apr 2015 10:27:53 -0400 Subject: [Paraview-developers] Replacement of SetInput with SetInputData (VTK5 vs. 6) In-Reply-To: <28BFFFBD-0907-4E8D-97C8-CE783E544A84@aia.rwth-aachen.de> References: <0361B901-93E3-4738-B449-4250311F1E91@aia.rwth-aachen.de> <28BFFFBD-0907-4E8D-97C8-CE783E544A84@aia.rwth-aachen.de> Message-ID: > Thank you for helping me understand better how the VTK pipeline works. Just to be sure: even though the data object is modified (directly, not through an algorithm object) after the call to cp->Update(), I can safely pass it on further (in this case to the output data object) without having to call Update() again on its producer? Yes. In fact, if you modify the data object directly after cp->Update(), then calling cp->Update() again may result in the data object being overwritten if the "cp" reexecutes. Utkarsh From foss at grueninger.de Thu Apr 30 10:54:38 2015 From: foss at grueninger.de (=?windows-1252?Q?Christoph_Gr=FCninger?=) Date: Thu, 30 Apr 2015 16:54:38 +0200 Subject: [Paraview-developers] Patch: Update UseLATEX.cmake for paraview-guide In-Reply-To: <5535DEA8.2010209@grueninger.de> References: <5535DEA8.2010209@grueninger.de> Message-ID: <5542422E.90008@grueninger.de> Hi Utkarsh, I would like to remind you of my paraview-guide patch. Or is there a reason hindering its merging? Bye Christoph Am 21.04.2015 um 07:22 schrieb Christoph Gr?ninger: > Hi Utkarsh, > please find attached a patch that updates UseLATEX.cmake for the > paraview-guide. This fixes CMP0046 warnings with newer CMake versions. > > Bye > Christoph -- When you die, that does not mean that you lose to cancer, you beat cancer by how you live, why you live, and in the manner in which you live. -- Stuart Scott, 1965-2015 From utkarsh.ayachit at kitware.com Thu Apr 30 10:57:49 2015 From: utkarsh.ayachit at kitware.com (Utkarsh Ayachit) Date: Thu, 30 Apr 2015 10:57:49 -0400 Subject: [Paraview-developers] Patch: Update UseLATEX.cmake for paraview-guide In-Reply-To: <5542422E.90008@grueninger.de> References: <5535DEA8.2010209@grueninger.de> <5542422E.90008@grueninger.de> Message-ID: Christoph, I need to test it out more extensively. My brute force attempt to build with your patch caused the build to fail on my desktop (where I've been building the guide since the beginning). I realized we needed a "dashboard" to build the users guides to catch issues automatically. So I was planning to set that up too. Just been a little busy with other things :). I'll get around to it soon. Utkarsh On Thu, Apr 30, 2015 at 10:54 AM, Christoph Gr?ninger wrote: > Hi Utkarsh, > I would like to remind you of my paraview-guide patch. Or is there a > reason hindering its merging? > > Bye > Christoph > > Am 21.04.2015 um 07:22 schrieb Christoph Gr?ninger: >> Hi Utkarsh, >> please find attached a patch that updates UseLATEX.cmake for the >> paraview-guide. This fixes CMP0046 warnings with newer CMake versions. >> >> Bye >> Christoph > > > -- > When you die, that does not mean that you lose to cancer, > you beat cancer by how you live, why you live, and in the > manner in which you live. -- Stuart Scott, 1965-2015 > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html > > Search the list archives at: http://markmail.org/search/?q=Paraview-developers > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/paraview-developers From berk.geveci at kitware.com Thu Apr 30 16:58:09 2015 From: berk.geveci at kitware.com (Berk Geveci) Date: Thu, 30 Apr 2015 16:58:09 -0400 Subject: [Paraview-developers] Removal of ExecuteData(...) In-Reply-To: <9FD0E576-756B-461C-91A9-8722F04899FC@aia.rwth-aachen.de> References: <8016D5D5-842C-42DA-9EB1-6A353C7DC1E8@aia.rwth-aachen.de> <9FD0E576-756B-461C-91A9-8722F04899FC@aia.rwth-aachen.de> Message-ID: Hi Michael, If it is no-op, by all means remove it. What is the purpose of this filter, if it pretty much does nothing? :-) -berk On Thu, Apr 30, 2015 at 1:12 AM, Schlottke, Michael < M.Schlottke at aia.rwth-aachen.de> wrote: > Hi Berk, > > Thank you for your answer. What do you mean by ?minor changes? (other > than that I somehow have to obtain the correct output pointer)? And do I > really need to pass data to Execute()? As far as I can tell, the particular > filter I?m looking at does nothing in Execute() (really a no-op), so it > seems like a good candidate to be removed completely. > > Michale > > On 28 Apr 2015, at 15:52 , Berk Geveci wrote: > > Hi Michael, > > You will need some minor changes but yes you can move that to > RequestData(). You will have to pass the input and output to Execute() > somehow. > > Best, > -berk > > On Tue, Apr 28, 2015 at 5:37 AM, Schlottke, Michael < > M.Schlottke at aia.rwth-aachen.de> wrote: > >> Hi again, >> >> I am trying to follow the VTK guide ( >> http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Removal_of_Execute) on >> migrating a set of ParaView plugins from VTK 5 to VTK 6. >> >> Just to be sure, what would be the correct way to replace the following >> implementation: >> >> >> ///////////////////////////////////////////////////////////////////////// >> void vtkMyAlgorithmSubclass::ExecuteData(vtkDataObject *output) >> >> { >> >> if (output && this->UpdateExtentIsEmpty(output)) >> >> { >> >> output->Initialize(); >> >> return; >> >> } >> >> >> >> this->Execute(); >> >> } >> >> ///////////////////////////////////////////////////////////////////////// >> >> Can I just move this whole code into RequestData (and use the >> vtkDataObject* output as a downcast from my output info object)? Is the >> call to Execute() still needed in this case? >> >> Thanks! >> >> Michael >> >> >> -- >> Michael Schlottke >> >> Chair of Fluid Mechanics and Institute of Aerodynamics >> RWTH Aachen University >> W?llnerstra?e 5a >> 52062 Aachen >> Germany >> >> Phone: +49 (241) 80 95188 >> Fax: +49 (241) 80 92257 >> Mail: m.schlottke at aia.rwth-aachen.de >> Web: http://www.aia.rwth-aachen.de >> >> >> _______________________________________________ >> Powered by www.kitware.com >> >> Visit other Kitware open-source projects at >> http://www.kitware.com/opensource/opensource.html >> >> Search the list archives at: >> http://markmail.org/search/?q=Paraview-developers >> >> Follow this link to subscribe/unsubscribe: >> http://public.kitware.com/mailman/listinfo/paraview-developers >> >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From berk.geveci at kitware.com Thu Apr 30 17:00:14 2015 From: berk.geveci at kitware.com (Berk Geveci) Date: Thu, 30 Apr 2015 17:00:14 -0400 Subject: [Paraview-developers] Replacement of SetInput with SetInputData (VTK5 vs. 6) In-Reply-To: <3FA46114-08C6-47A5-8C14-E0ADB6496B6A@aia.rwth-aachen.de> References: <0361B901-93E3-4738-B449-4250311F1E91@aia.rwth-aachen.de> <3FA46114-08C6-47A5-8C14-E0ADB6496B6A@aia.rwth-aachen.de> Message-ID: Sounds good. >> Finally, store the results in the output vtkDataObject This should be done by copying the output of the inner filter to the output of the outer filter. I would advise against directly setting the internal output as the DATA_OBJECT() in the output information of the outer filter. It will probably work but you may run into weird issues downstream depending on what you do. Best, -berk On Thu, Apr 30, 2015 at 1:13 AM, Schlottke, Michael < M.Schlottke at aia.rwth-aachen.de> wrote: > Hi Berk, > > Ah, that is good to know. So my typical setup in RequestData for a > custom filter should be something like the following: > > - connect the first internal filter to the input vtkDataObject using > SetInputData() > - use SetInputConnection() to chain up any internal filters I use (if > possible) > - finally, store the results in the output vtkDataObject > > Is this a good approach to follow under normal circumstances or am I > missing something here? > > Michael > > On 28 Apr 2015, at 15:50 , Berk Geveci wrote: > > Replace that Update() with cp->Update(). > > The rule for internal filters is that you should never use > SetInputConnection() to connect anything to an external filter from within > RequestData(). You don't want internal pipeline executions to propagate to > external filters as it may cause all kinds of problems. SetInputData() does > not create a pipeline connection so it is safe to use in such > circumstances. SetInputConnection() is safe to connect internal filters to > each other. > > Best, > -berk > > On Tue, Apr 28, 2015 at 2:54 AM, Schlottke, Michael < > M.Schlottke at aia.rwth-aachen.de> wrote: > >> Hi Utkarsh, >> >> Thank you very much for this answer, it clears things up a lot. Am I >> right to sum this up as a rule of thumb to >> >> ?use SetInputConnection whenever possible, resort to SetInputData where >> it isn?t? >> >> for most use cases? >> >> On a related note, I?ve encountered a few filters with code like this: >> >> ////////////////////////////////////////////////////////////// >> vtkMyFilter::RequestData(?.) >> { >> ? >> vtkCellDataToPointData* cp = vtkCellDataToPointData::New(); >> ... >> vtkUnstructuredGrid* pdata = cp->GetUnstructuredGridOutput(); >> pdata->GetPointData()->RemoveArray(?arrayname"); >> pdata->GetPointData()->Update(); >> pdata->Update(); // will not compile with VTK6 (******) >> >> vtkInformation *outInfo = outputVector->GetInformationObject(0); >> vtkUnstructuredGrid *output = >> vtkUnstructuredGrid::SafeDownCast(outInfo->Get(vtkDataObject::DATA_OBJECT())); >> output->SetPoints(pdata->GetPoints()); >> output->CopyStructure(pdata); >> output->GetCellData()->PassData(pdata->GetCellData()); >> >> return 1; >> } >> ////////////////////////////////////////////////////////////// >> >> I am wondering about the line marked with (******). Is it obsolete with >> VTK6 (as there is no Update() method for non-vtkAlgorithm objects), should >> I call cp->Update() instead, or is there something entirely different to do >> to make this code work properly? >> >> Regards, >> >> Michael >> >> > On 27 Apr 2015, at 19:53 , Utkarsh Ayachit >> wrote: >> > >> >> Now I am wondering: ifinside the RequestData method of a filter, do I >> *ever* >> >> need to use SetInputConnection, and if yes, how? >> > >> > >> > Here's an example: >> > >> > vtkMyFilter::RequestData(....) >> > { >> > vtkDataSet* myinput = vtkDataSet::GetData(inputInformation[0], 0); >> > >> > vtkNew filter1; >> > filter1->SetInputData(myinput); >> > >> > vtkNew filter2; >> > filter2->SetInputConnection(filter1->GetOutputPort()); >> > ... >> > >> > filter2->Update() >> > } >> > >> > Thus, for internal pipelines, it makes sense to use SetInputConnection. >> > >> >> It seems like all filters >> >> I?ve had a look at always access the input data object (which I can >> only >> >> pass on using SetInputData, not SetInputConnection), not the input >> port. >> >> However, as a user with little VTK experience it seems like this might >> >> ?break? the aforementioned pipeline? >> > >> > It the example I gave, for example, if you use SetInputData() to pass >> > the output of filter1 to filter2, you'll need to call >> > filter1->Update() before doing that. Otherwise, filter1 has not >> > execute and hence doesn't have valid data to pass to filter2. Unlike >> > the old SetInput(), setting the dataset using SetInputData() doesn't >> > preserve the pipeline information i.e. filter2 will not update filter1 >> > just because you called filter2->Update() if SetInputData() is used to >> > pass the data. >> > >> > Hope that clarifies it a little. >> >> _______________________________________________ >> Powered by www.kitware.com >> >> Visit other Kitware open-source projects at >> http://www.kitware.com/opensource/opensource.html >> >> Search the list archives at: >> http://markmail.org/search/?q=Paraview-developers >> >> Follow this link to subscribe/unsubscribe: >> http://public.kitware.com/mailman/listinfo/paraview-developers >> > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: