Hello,
It seems that "meep 0.9 + (output-dielectric) + h5tovtk" doesn't output
metals as very large negative values, but rather as "inf" values. mayavi
doesn't like that (see forwarded message below).
The simplest solution is to take "h5tovtk -a" output and simply replace
all "inf" values with some other value, by doing this for example:
sed -i s/inf/-1e20/g 2drods1-eps-000000.00.vtk
The disadvantage here is that you're forced to use ascii vtk output, and
as stated in the h5tovtk man page, this not as compact as binary output.
I'm a beginner at mayavi/vtk. Is there a better technique for viewing
metallo-dielectric structures than using IsoSurface modules in mayavi?
Kind Regards,
Matt
---------- Forwarded message ----------
Date: Sun, 27 Aug 2006 09:49:31 -0400
From: Prabhu Ramachandran <[EMAIL PROTECTED]>
To: Matt <[EMAIL PROTECTED]>
Cc: [email protected]
Subject: Re: [MayaVi-users] isosurface config hangs on "inf" dimension
"Matt" == Matt <[EMAIL PROTECTED]> writes:
Matt> When I try adding an IsoSurface module for the attached
Matt> structure, the IsoSurface config window opens (sans topmost
Matt> horizontal scroll bar) and mayavi hangs.
Matt> The data contains very large negative values. In the
Matt> configure panel, Iso-surface value is filled in with the
Matt> value inf, minimum contour 1.0, and maximum contour inf.
I would suggest you write out your data into ASCII VTK files before
you play with binary file formats. VTK will not handle inf and nan
values gracefully. When VTK reads your data file it thinks the
minimum value of the scalars is 1.0 and the maximum is inf. Clearly,
according to you, this is wrong.
Matt> It seems that mayavi only hangs with "inf" values present.
Matt> Is this a bug, or is there a workaround?
I would suggest that you remove "inf"s and nans from the data before
you use VTK/MayaVi.
cheers,
prabhu
_______________________________________________
meep-discuss mailing list
[email protected]
http://ab-initio.mit.edu/cgi-bin/mailman/listinfo/meep-discuss