Hello,
I require to select chunks of my data, by specific values of, for example IDs. following the results showed here, i am using the function that i described as extractSelectionByListOfValues_old in my second comment, as it showed to be the one that performed better.
This ‘works’, with a slight issue, if i use this inside a python function, when the function does the QuerySelect it will automatically Show my filter where i am applying it. where if i simply do the
QuerySelect by copy paste on the python console, this does not happen.
here is a simple example:
from paraview.simple import *
paraview.simple._DisableFirstRenderCameraReset()
sphere1 = Sphere(registrationName='Sphere1')
UpdatePipeline(time=0.0, proxy=sphere1)
def check(filter=[]):
filter = GetActiveSource()
QuerySelect(QueryString='(id == 0)',FieldType='CELL',InsideOut=0)
return ExtractSelection(Input=filter)
cell0=check(sphere1)
If i run this on the terminal (copy paste), it will create the sphere, show it select the id==0 and extract it.
now if i hide everything and do:
SetActiveSource(sphere1)
QuerySelect(QueryString='(id == 0)',FieldType='CELL',InsideOut=0)
ExtractSelection(Input=filter)
the sphere will not be shown.
is there any way to avoid this display? i would be okey with a ‘block all show signals with a function and then allow them again with another one’
is there any more intelligent easy (specially fast) way to achieve this without QuerySelect? as this is bringing me some issues (the display being created each time, and in the newer versions of paraview a bunch of warnings, which ‘polutes’ the output of the terminal)