[Nipy-devel] attributes vs. traits
Jonathan Taylor
jonathan.taylor at stanford.edu
Sun May 28 11:32:17 CDT 2006
Jarrod Millman wrote:
>
> For example, I think it is the case that most scientific programmers
> are using
> matplotlib as opposed to enthought's chaco. The enthought team has
> certainly
> done some impressive work developing traits, but it would be good to know
> if there are any scientific projects using it. I went through the
> google hits for
> "python traits" and they all seemed to be enthought generated content.
good point about matplotlib vs. chaco. though chaco's goals are
different then matplotlib's. chaco is aiming for interactivity, i.e.
application building whereas matplotlib is aimed at publication quality
graphics.
re: numpy/scipy not using traits: it makes sense for to not pollute the
numpy and scipy code with traits because they are not aimed at being
applications, but libraries. on the other hand, we clearly want to build
applications.
as i understand it from reading the enthought-dev list and having heard
talk of it at scipy, enthought has plans to officially release envisage.
currently, the code is available but not officially released.
if i recall correctly, john hunter has been talking to the enthought
guys about being able to use matplotlib into an envisage plugin -- there
is even a copy of the enthought.traits source tree in matplotlib's svn
repository.
what would be very helpful is a "hello chaco" example in envisage,
and/or a "hello pylab".
i have been working on putting together some "decent" trait_views with
some "actions" for the FIAC example ($NIPY/examples/FIAC/traits). the
file "ui_view_action.py" is a VERY lightweight application that would
allow you to plot the design (if i could drop matplotlib into
enthought), and run a single run analysis. i'm not claiming that this is
a pretty interface, but it is very easy to generalize/reuse -- i suppose
it is a disposable gui application. i started with the VET tool, looked
at its output, read some source and that's about it. from looking at the
examples, i think that this code is the kind of thing that can be
dropped into an envisage plugin (i think everything is based on pyface
somewhere underneath).
my feeling is that there is something to be gained from using traits and
continuing to think about envisage. if i can make the foundations of a
lightweight gui application on a flight and a train trip, then i think
there is something there. i have briefly looked at other things like
glade and quickly became lost. one of the really nice things is that the
code that generates the gui(which is based on the code generated by VET)
is very easy to read. i am so dense with gui code, i can't even read the
arrayview.py in our visualization package.
instead of poring through google result to see how many people reference
traits, etc. i propose that we:
i) send an email to enthought-dev asking for some help on a "hello
chaco" example (i would prefer "hello pylab" but that is more
complicated right now)
ii) see if we can get some simple visualization tool working
one of the best motto (mantra?) that i heard repeated numerous times at
scipy was
"functioning code wins all arguments"
(as opposed to "google search results win all arguments" :) )
i agree with the former and think we should try as a group to get a
"functioning" envisage example. in the process, we might build the first
non-enthought envisage application (with lots of documentation of course
:)). this would also be a good faith effort to encourage envisage to
officially release envisage.
best,
jonathan
--
------------------------------------------------------------------------
I'm part of the Team in Training: please support our efforts for the
Leukemia and Lymphoma Society!
http://www.active.com/donate/tntsvmb/tntsvmbJTaylor
GO TEAM !!!
------------------------------------------------------------------------
Jonathan Taylor Tel: 650.723.9230
Dept. of Statistics Fax: 650.725.8977
Sequoia Hall, 137 www-stat.stanford.edu/~jtaylo
390 Serra Mall
Stanford, CA 94305
More information about the Nipy-devel
mailing list