Re: [Paraview] Overriding the maximal cylinder source resolution

2017-05-29 Thread kenichiro yoshimi
Hi Tomislav,

I find restriction on the resolution number of a cyliner source in
vtkCylinderSource.h, that is:
  vtkSetClampMacro(Resolution,int,2,VTK_CELL_SIZE).
This macro amounts to saying that the resolution is restricted to a
range between 2 and VTK_CELL_SIZE(=512). Hence, I think it difficult
to override.

In order to increase the resolution of the cylinder, one thing you can
try is to apply the loop subdivision filter after triangulating it.

Thanks,
yoshimi

2017-05-30 0:06 GMT+09:00 Tomislav Maric :
> Hello everyone,
>
> I have exported the paraview trace into the attached script that
> generates a cylinder source without caps, triangulates and saves an STL
> file.
>
> I have noticed that the cylinder resolution can be prescribed to any
> number in the python script:
>
> ~~~
> # create a new 'Cylinder'
> cylinder1 = Cylinder()
>
> # Properties modified on cylinder1
> cylinder1.Resolution = 10
> ~~~
>
> And this number is reported by the print command as well
>
> ~~~
> print(cylinder1.Resolution)
> ~~~
>
> However, the actual resolution of the cylinder source never exceeds the
> number 512. This I have figured out after manually inspecting the number
> of triangles in the 'cylinder.stl' file generated by the attached script.
>
> I have browsed the VTK code as well, but I could not find the point
> where the maximal cylinder source resolution is restricted to 512.
>
> My question is: can I somehow (in python, or in VTK) override the
> resolution that is actually then applied to the cylinder? I am using
> paraview version 4.4.0. Does it work in a newer paraview version?
>
> Kind Regards,
>
> Tomislav
>
>
>
> ___
> 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
>
___
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


Re: [Paraview] Question

2017-05-29 Thread Sebastien Jourdain
Q1: Yes but you will need to use open-swr or llvm-pipe (extra args with
distributed binaries if you have X) or build ParaView with OSMesa (no need
to build the Qt part)
Q2: http://kitware.github.io/paraviewweb/docs/multi_user_setup.html

Sorry for the very short answer but I have to go. ;-)

On Mon, May 29, 2017 at 4:04 PM, Hayk Grigoryan 
wrote:

> Hello All,
>
> My name is Hayk, I'm phd student and working on visualization of
> scientific data.
> I'm interested in ParaViewWeb component and used it on my desktop server.
> My goal is to make multi-user support service with this.
> I have a couple of questions which will be very helpful.
>
> Q1: Can I run and use ParaVieWeb in virtual environment without having a
> real graphical processing unit(GPU)?
> Q2: Which is the best way for deploying ParaViewWev as a service.
>
> Thanks in advice,
> Hayk
>
> ___
> 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
>
>
___
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


[Paraview] Question

2017-05-29 Thread Hayk Grigoryan
Hello All,

My name is Hayk, I'm phd student and working on visualization of scientific
data.
I'm interested in ParaViewWeb component and used it on my desktop server.
My goal is to make multi-user support service with this.
I have a couple of questions which will be very helpful.

Q1: Can I run and use ParaVieWeb in virtual environment without having a
real graphical processing unit(GPU)?
Q2: Which is the best way for deploying ParaViewWev as a service.

Thanks in advice,
Hayk
___
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


[Paraview] Overriding the maximal cylinder source resolution

2017-05-29 Thread Tomislav Maric
Hello everyone,

I have exported the paraview trace into the attached script that
generates a cylinder source without caps, triangulates and saves an STL
file.

I have noticed that the cylinder resolution can be prescribed to any
number in the python script:

~~~
# create a new 'Cylinder'
cylinder1 = Cylinder()

# Properties modified on cylinder1 
cylinder1.Resolution = 10
~~~

And this number is reported by the print command as well

~~~
print(cylinder1.Resolution)
~~~

However, the actual resolution of the cylinder source never exceeds the
number 512. This I have figured out after manually inspecting the number
of triangles in the 'cylinder.stl' file generated by the attached script.

I have browsed the VTK code as well, but I could not find the point
where the maximal cylinder source resolution is restricted to 512.

My question is: can I somehow (in python, or in VTK) override the
resolution that is actually then applied to the cylinder? I am using
paraview version 4.4.0. Does it work in a newer paraview version?

Kind Regards,

Tomislav


 import the simple module from the paraview
from paraview.simple import *
 disable automatic camera reset on 'Show'
paraview.simple._DisableFirstRenderCameraReset()

# create a new 'Cylinder'
cylinder1 = Cylinder()

# Properties modified on cylinder1
cylinder1.Resolution = 10
cylinder1.Height = 0.1
cylinder1.Radius = 0.2 
cylinder1.Center = [0.0, 0.0, 0.0]
cylinder1.Capping = 0

# create a new 'Transform'
transform1 = Transform(Input=cylinder1)
transform1.Transform = 'Transform'

# Properties modified on transform1.Transform
transform1.Transform.Rotate = [90.0, 0.0, 0.0]

# create a new 'Transform'
transform2 = Transform(Input=transform1)
transform2.Transform = 'Transform'

# Properties modified on transform2.Transform
transform2.Transform.Translate = [0.5, 0.5, 0.05]

# create a new 'Triangulate'
triangulate1 = Triangulate(Input=cylinder1)

# save data
SaveData('./cylinder.stl', proxy=triangulate1, FileType='Ascii')
___
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


Re: [Paraview] Python Scripting

2017-05-29 Thread Shawn Waldon
Hi Richard,

Since you didn't specify the version you are using I'm using 5.4-RC3 for
this answer.  I loaded a dataset and ran the Python Trace (Tools -> Start
Trace) to find out what it is doing.  Here is the python script that was
generated from changing what the dataset was colored by.


# get active source.

canex2 = GetActiveSource()


# get active view

renderView1 = GetActiveViewOrCreate('RenderView')

# uncomment following to set a specific view size

# renderView1.ViewSize = [1330, 670]


# get display properties

canex2Display = GetDisplayProperties(canex2, view=renderView1)


# set scalar coloring

ColorBy(canex2Display, ('POINTS', 'VEL', 'Magnitude'))


# get color transfer function/color map for 'vtkBlockColors'

vtkBlockColorsLUT = GetColorTransferFunction('vtkBlockColors')


# Hide the scalar bar for this color map if no visible data is colored by it.

HideScalarBarIfNotNeeded(vtkBlockColorsLUT, renderView1)


# rescale color and/or opacity maps used to include current data range

canex2Display.RescaleTransferFunctionToDataRange(True, False)


# show color bar/color legend

canex2Display.SetScalarBarVisibility(renderView1, True)


# get color transfer function/color map for 'VEL'

vELLUT = GetColorTransferFunction('VEL')


It is hiding the scalar bar for vtkBlockColors since that is what the data
used to be colored by.  I think your problem will be solved by using the
GetDisplayProperties and ColorBy functions rather than setting
ColorArrayName.

HTH,
Shawn

On Sat, May 27, 2017 at 1:35 PM, Richard Kalhoefer <
kalhoe...@physik.uni-kiel.de> wrote:

> Hey,
>
> I have a python script that opens a Legacy VTK file that contains two
> scalar arrays of the same length (real and imaginary part of a wave
> function) and then adjusts the camera settings, representation and color.
> My transfer functions seem to be ignored and I just get full opacity and
> black color. Running the script inside the GUI's python shell gives the
> same result, but when I then change the array under Display->Coloring to
> the other one and back again. everything looks as expected. So my question
> is: What is this GUI element doing beyond "GetRepresentation(reader,
> view).ColorArrayName = ['POINTS', arrayname]" and how can I do the same
> within the python script?
>
> Kind regards
> Richard Kalhöfer
>
> ___
> 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
>
>
___
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


Re: [Paraview] RedHat6/mesa/Paraview5.3 problem

2017-05-29 Thread Patrick Begou

Hi Chuck

thanks for all these details. Finaly I had to install a dedicated version of 
mesa as the update to 11.0.7 from ELrepo was breaking one of our licensed 
software (ANSYS) and I had to roll back to 10.4.3.:-[
I've compiled mesa-17.0.4 (with llvm-4.0.0, libdrm-2.4.70, xcb-proto-1.12, 
pthread-stubs-0.3, libXau-1.0.8, libxcb-1.12, libxshmfence-1.2 prerequisites) 
and all seams running fine now with hardware rendering (?). In my VNC session:

$ glxinfo

direct rendering: Yes
...
OpenGL renderer string: Gallium 0.4 on llvmpipe (LLVM 4.0, 256 bits)
OpenGL version string: 3.0 Mesa 17.0.4


so am I using the GPU (direct rendering is set to yes) or the CPU (if llvmpipe 
is software rendering) ?


Patrick

Chuck Atkins wrote:

Hi Patrick,

On a RedHat 6 server, with AMD firepro W7000 GPU

...

I'm launching paraview via vncviewer on this node.


If you're running via VNC then unfortunately you won't be using the GPU 
(unless you get more creative with something like VirtualGL).  You're only 
going to be able to use the CPU based renderer in Mesa.


If you are using Mesa please make sure you have version 10.6.5 or later
and make sure your driver in Mesa supports OpenGL 3.2.


So, Mesa got OpenGL 3.2 support in 10.6.5, but not all of the drivers 
implemented it until much later.


OpenGL renderer string: Gallium 0.4 on llvmpipe (LLVM 3.6, 256 bits)


llvmpipe is Mesa's software renderer


OpenGL version string: 2.1 Mesa 11.0.7


Older versions of Mesa may have supported OpenGL 3.2 at it's core but the 
llvmpipe driver still took a while to catch up.



So which minimal mesa version is required for paraview 5.3 ?


It wasn't until Mesa 12 that OpenGL 3.2 was properly supported and reported by 
all Mesa drivers.  With some versions of 11, though, it works *enough* that 
you can fake it by exporting the environment variable GL_VERSION_OVERRIDE=3.2, 
so give that a try.  If you instead want to just use the linux binaries from 
paraview.org , we build those on EL6 and include a very 
recent copy of mesa with it that you can make paraview use with:


paraview --mesa-swr

That instructs ParaView to use it's own copy of Mesa and the OpenSWR parallel 
CPU rasterizer.


- Chuck




--
===
|  Equipe M.O.S.T. |  |
|  Patrick BEGOU   | mailto:patrick.be...@grenoble-inp.fr |
|  LEGI|  |
|  BP 53 X | Tel 04 76 82 51 35   |
|  38041 GRENOBLE CEDEX| Fax 04 76 82 52 71   |
===

___
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


Re: [Paraview] How to output forces over time?

2017-05-29 Thread HongchaoWang
I have solved the problem myself. I have chosen the wrong field association
when outputting the data.

 

Regards,

Wilson

From: HongchaoWang [mailto:hongchao.wang2...@gmail.com] 
Sent: Monday, 29 May 2017 4:13 PM
To: 'paraview@paraview.org' 
Subject: How to output forces over time?

 

Hi,

 

I am using paraview to postprocess the results from OpenFoam. I am able to
calculate the drag and lift forces on a fixed box by integrating pressure
over the box surface. Now I would like to output the time history of the of
the forces. How can I achieve that? What I have done is to select the row of
forces generated in the spread sheet view and then use "File->save data->
Write All Time Steps" . However, the output file only give me the results of
p, U, normals, etc. without the forces I want. 

 

Does anyone know the solution to this problem?

 

Many thanks,

Wilson

 

___
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


[Paraview] How to output forces over time?

2017-05-29 Thread HongchaoWang
Hi,

 

I am using paraview to postprocess the results from OpenFoam. I am able to
calculate the drag and lift forces on a fixed box by integrating pressure
over the box surface. Now I would like to output the time history of the of
the forces. How can I achieve that? What I have done is to select the row of
forces generated in the spread sheet view and then use "File->save data->
Write All Time Steps" . However, the output file only give me the results of
p, U, normals, etc. without the forces I want. 

 

Does anyone know the solution to this problem?

 

Many thanks,

Wilson

 

___
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