[Insight-users] [Insight-developers] csv file reader
Tom Vercauteren
tom.vercauteren at m4x.org
Wed Oct 20 03:24:38 EDT 2010
Hey Brian,
This would be a valuable addition. CSV is not completely
straightforward though. You'll have to take care of character
encoding, field and line separators, decimal separators (change your
locale for testing it), escaping some characters such as quotes, etc.:
http://en.wikipedia.org/wiki/Comma-separated_values#Specification
Making a decent CSV writer is fairly easy but making a generic CSV
reader might be more problematic if you want to try and automatically
detect the parameters (not sure if it's even possible).
Tom
On Tue, Oct 19, 2010 at 21:36, brian avants <stnava at gmail.com> wrote:
> Hi Everyone
>
> I'd like the ability to read generic csv files into some standard itk format.
> Has anyone already implemented or heard of a csv file reader for itk?
>
> Saw this for paraview :
>
> http://www.itk.org/Wiki/Data_formats#CSV_.28Comma_Separated_Variable.29_files
>
> but not much in the itk world.
>
> My first thoughts are to have the reader output a list of vectors where each
> vector has a string name (from the header of the csv file) and each vector
> is of either type string or double.
>
> Any feedback welcome.
>
> Brian
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Kitware offers ITK Training Courses, for more information visit:
> http://kitware.com/products/protraining.html
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-developers
>
More information about the Insight-users
mailing list