<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html; charset=ISO-8859-1"
 http-equiv="Content-Type">
</head>
<body bgcolor="#ffff99" text="#000000">
Hello,<br>
<br>
it doesn't fix the problem for me, but perhaps it is because I don't
use version 4.6 of Qt...<br>
<br>
But if I set the locale in the python script before writing the vtk
file in ASCII, it works fine.<br>
<br>
Thank you !<br>
<br>
J&eacute;r&ocirc;me<br>
<br>
Le 04/06/2010 16:15, Utkarsh Ayachit a &eacute;crit&nbsp;:
<blockquote
 cite="mid:AANLkTilV_kxNnNDj61KoQUMgpTK0alCQPGvr0CLhzx2w@mail.gmail.com"
 type="cite">
  <pre wrap="">I've committed a fix. Attached is the patch for the same.

commit 3f4904f94224ef3a6c03989a012c4484a759a607
Author: Utkarsh Ayachit <a class="moz-txt-link-rfc2396E" href="mailto:utkarsh.ayachit@kitware.com">&lt;utkarsh.ayachit@kitware.com&gt;</a>
Date:   Fri Jun 4 10:14:30 2010 -0400

    setlocale to avoid locale related numeric issues.

    Refer to <a class="moz-txt-link-freetext" href="http://www.paraview.org/pipermail/paraview/2009-August/013278.html">http://www.paraview.org/pipermail/paraview/2009-August/013278.html</a>
    thread for details.


Utkarsh

On Fri, Jun 4, 2010 at 9:50 AM, Berk Geveci <a class="moz-txt-link-rfc2396E" href="mailto:berk.geveci@kitware.com">&lt;berk.geveci@kitware.com&gt;</a> wrote:
  </pre>
  <blockquote type="cite">
    <pre wrap="">Thanks Takuya. We'll take care of it.

2010/6/4 Takuya OSHIMA <a class="moz-txt-link-rfc2396E" href="mailto:oshima@eng.niigata-u.ac.jp">&lt;oshima@eng.niigata-u.ac.jp&gt;</a>:
    </pre>
    <blockquote type="cite">
      <pre wrap="">Hi,

      </pre>
      <blockquote type="cite">
        <pre wrap="">This seems to be related to the way the LOCALE is set on your system. It is
probably set to French in one case and English in the other. Does anybody know
if we can force LOCALE to English in the ParaView application or the reader?
        </pre>
      </blockquote>
      <pre wrap="">
Indeed, forcing the locale where the PV application runs under to C
was what I proposed a while ago, which failed to draw attention:
<a class="moz-txt-link-freetext" href="http://www.paraview.org/pipermail/paraview/2009-August/013278.html">http://www.paraview.org/pipermail/paraview/2009-August/013278.html</a>

I'd really appreciate if the PV developers reconsider this.

Takuya

Takuya OSHIMA, Ph.D.
Faculty of Engineering, Niigata University
8050 Ikarashi-Ninocho, Nishi-ku, Niigata, 950-2181, JAPAN


From: Berk Geveci <a class="moz-txt-link-rfc2396E" href="mailto:berk.geveci@kitware.com">&lt;berk.geveci@kitware.com&gt;</a>
Subject: Re: [Paraview] Write and read a vtk file (in python)
Date: Fri, 4 Jun 2010 09:25:02 -0400

      </pre>
      <blockquote type="cite">
        <blockquote type="cite">
          <pre wrap="">1) reading :
------------

from a vtkStructuredGrid object, I use a vtkStructuredGridWriter to create a
vtk file, and I have the following problem :
when I launch the script in Paraview, the format of floating points is not
good (I obtain for example 33,1632 instead of 33.1632). So, the file created
is not readable by Paraview. If I launch the script directly in a terminal,
it works fine. Perhaps because the version of vtk module is not the same ?
If I use the binary format I have not this problem.
          </pre>
        </blockquote>
        <pre wrap="">
This seems to be related to the way the LOCALE is set on your system. It is
probably set to French in one case and English in the other. Does anybody know
if we can force LOCALE to English in the ParaView application or the reader?

        </pre>
        <blockquote type="cite">
          <pre wrap="">2) writing :
------------

&nbsp;I would like to read my vtk files from the python shell, with
OpenDataFile(), but It didn't succeed and I have the following message (with
a file which can be read in paraview using menu open of course :-) :
          </pre>
        </blockquote>
        <pre wrap="">
Unless I am mistaken, you give the filename directly to OpenDataFile(),
without FileName=.

-berk

        </pre>
        <blockquote type="cite">
          <pre wrap="">

/home/plumecoq/tmp/ParaView/flow_1_0075.vtk
Traceback (most recent call last):
&nbsp;File "&lt;string&gt;", line 1, in &lt;module&gt;
&nbsp;File "/home/plumecoq/EHPOC/plugins/ElsaMenu/elsa.py", line 91, in &lt;module&gt;
&nbsp; &nbsp;main()
&nbsp;File "/home/plumecoq/EHPOC/plugins/ElsaMenu/elsa.py", line 73, in main
&nbsp; &nbsp;reader_vtk = OpenDataFile(file_name_vtk)
&nbsp;File
"/home/plumecoq/Paraview/ParaView-3.8.0-bin/Utilities/VTKPythonWrapping/paraview/simple.py",
line 115, in OpenDataFile
&nbsp; &nbsp;reader = globals()[xml_name](FileName=filename, **extraArgs)
&nbsp;File
"/home/plumecoq/Paraview/ParaView-3.8.0-bin/Utilities/VTKPythonWrapping/paraview/simple.py",
line 542, in CreateObject
&nbsp; &nbsp;setattr(px, param, params[param])
&nbsp;File
"/home/plumecoq/Paraview/ParaView-3.8.0-bin/Utilities/VTKPythonWrapping/paraview/servermanager.py",
line 201, in __setattr__
&nbsp; &nbsp;"to add this attribute.")
AttributeError: Attribute FileName does not exist. &nbsp;This class does not
allow addition of new attributes to avoid mistakes due to typos. Use
add_attribute() if you really want to add this attribute.


any ideas ? I try to use LegacyVTKFileReader instead, but I have also some
problems.

I use a re-compile version of Paraview 3.8, under Linux (Fedora 10 - 64
bits)

thanks for your help.

J&eacute;r&ocirc;me

_______________________________________________
Powered by <a class="moz-txt-link-abbreviated" href="http://www.kitware.com">www.kitware.com</a>

Visit other Kitware open-source projects at
<a class="moz-txt-link-freetext" href="http://www.kitware.com/opensource/opensource.html">http://www.kitware.com/opensource/opensource.html</a>

Please keep messages on-topic and check the ParaView Wiki at:
<a class="moz-txt-link-freetext" href="http://paraview.org/Wiki/ParaView">http://paraview.org/Wiki/ParaView</a>

Follow this link to subscribe/unsubscribe:
<a class="moz-txt-link-freetext" href="http://www.paraview.org/mailman/listinfo/paraview">http://www.paraview.org/mailman/listinfo/paraview</a>
          </pre>
        </blockquote>
      </blockquote>
      <pre wrap="">
      </pre>
    </blockquote>
    <pre wrap="">_______________________________________________
Powered by <a class="moz-txt-link-abbreviated" href="http://www.kitware.com">www.kitware.com</a>

Visit other Kitware open-source projects at <a class="moz-txt-link-freetext" href="http://www.kitware.com/opensource/opensource.html">http://www.kitware.com/opensource/opensource.html</a>

Please keep messages on-topic and check the ParaView Wiki at: <a class="moz-txt-link-freetext" href="http://paraview.org/Wiki/ParaView">http://paraview.org/Wiki/ParaView</a>

Follow this link to subscribe/unsubscribe:
<a class="moz-txt-link-freetext" href="http://www.paraview.org/mailman/listinfo/paraview">http://www.paraview.org/mailman/listinfo/paraview</a>

    </pre>
    <pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Powered by <a class="moz-txt-link-abbreviated" href="http://www.kitware.com">www.kitware.com</a>

Visit other Kitware open-source projects at <a class="moz-txt-link-freetext" href="http://www.kitware.com/opensource/opensource.html">http://www.kitware.com/opensource/opensource.html</a>

Please keep messages on-topic and check the ParaView Wiki at: <a class="moz-txt-link-freetext" href="http://paraview.org/Wiki/ParaView">http://paraview.org/Wiki/ParaView</a>

Follow this link to subscribe/unsubscribe:
<a class="moz-txt-link-freetext" href="http://www.paraview.org/mailman/listinfo/paraview">http://www.paraview.org/mailman/listinfo/paraview</a>
    </pre>
  </blockquote>
</blockquote>
<br>
</body>
</html>