pymvpa2-exec(1)


NAME

   pymvpa2-exec  -   evaluate  arbitrary  Python expressions for tests and
   assertions

SYNOPSIS

   pymvpa2 exec [--version] [-h] [-i [DATASET [DATASET ...]]] -e EXPR  [-s
   NAME [NAME ...]] [-o OUTPUT] [--hdf5-compression TYPE]

DESCRIPTION

   Execute arbitrary Python expressions (on datasets)

   This  command  can  be  used  to execute arbitrary Python scripts while
   avoiding unnecessary  boilerplate  code  to  load  datasets  and  store
   results.  This  command  is  also  useful for testing functionality and
   results via the  commandline  interface  and  for  asserting  arbitrary
   conditions in scripts.

   First,  optional  dataset(s)  are  loaded  from  one  or  more sources.
   Afterwards any number of given expressions (see --exec)  are  executed.
   An  expression  can  be  given as an argument on the command line, read
   from a file, or from STDIN. The return value of any given expression is
   ignored  (not  evaluated anyhow), only exceptions are treated as errors
   and cause the command  to  exit  with  a  non-zero  return  value.   To
   implement  tests and assertions it is best to utilize a Python unittest
   framework such as 'nose'.

   In the namespace in which  all  expressions  are  evaluated  the  NumPy
   module  is  available  via the alias 'np', and the nose.tools under the
   alias 'nt' (if installed). Any loaded datasets are available as a  list
   named  ``dss``.  The  first  dataset in that list (if any) is available
   under the name ``ds``.

OPTIONS

   --version
          show program's version and license information and exit

   -h, --help, --help-np
          show this help message and exit. --help-np  forcefully  disables
          the use of a pager for displaying the help.

   -i [DATASET [DATASET ...]], --input [DATASET [DATASET ...]]
          path(s)  to  one or more PyMVPA dataset files. All datasets will
          be  merged  into  a  single  dataset  (vstack'ed)  in  order  of
          specification.  In  some  cases  this  option  may  need  to  be
          specified more  than  once  if  multiple,  but  separate,  input
          datasets are required.

   -e EXPR, --exec EXPR
          Python  expression,  or  filename  of a Python script, or '-' to
          read expressions from STDIN.

   Output options:
   -s NAME [NAME ...], --store NAME [NAME ...]
          One or more names of variables or objects to  extract  from  the
          local  name space after all expressions have been executed. They
          will  be  stored  in  a  dictionary  in  HDF5  format  (requires
          --output).

   -o OUTPUT, --output OUTPUT
          output  filename  ('.hdf5'  extension  is added automatically if
          necessary).  NOTE:  The  output  format  is  suitable  for  data
          exchange  between  PyMVPA  commands,  but is not recommended for
          long-term storage or exchange as its specific content  may  vary
          depending  on  the  actual  software  environment. For long-term
          storage consider conversion into other data formats (see  'dump'
          command).

   --hdf5-compression TYPE
          compression  type  for  HDF5 storage. Available values depend on
          the specific HDF5  installation.  Typical  values  are:  'gzip',
          'lzf',   'szip',  or  integers  from  1  to  9  indicating  gzip
          compression levels.

EXAMPLES

   Assert some condition

          $ pymvpa2 exec -e 'assert(4==4)'

   Check for the presence of a particular sample attribute in a dataset

          $ pymvpa2 exec -e 'dss[0].sa.subj3' -i mydata.hdf5

   Extract and store results

          $ pymvpa2 exec -e 'a=5' -e 'print a' --store a -o mylittlea.hdf5

AUTHOR

   Written by Michael Hanke  &  Yaroslav  Halchenko,  and  numerous  other
   contributors.

COPYRIGHT

   Copyright  2006-2016 PyMVPA developers

   Permission is hereby granted, free of charge, to any person obtaining a
   copy  of  this  software  and  associated  documentation   files   (the
   "Software"),  to  deal  in  the Software without restriction, including
   without limitation the rights to use,  copy,  modify,  merge,  publish,
   distribute,  sublicense,  and/or  sell  copies  of the Software, and to
   permit persons to whom the Software is furnished to do so,  subject  to
   the following conditions:

   The above copyright notice and this permission notice shall be included
   in all copies or substantial portions of the Software.

   THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
   OR   IMPLIED,   INCLUDING   BUT   NOT  LIMITED  TO  THE  WARRANTIES  OF
   MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND  NONINFRINGEMENT.
   IN  NO  EVENT  SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
   CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN  ACTION  OF  CONTRACT,
   TORT  OR  OTHERWISE,  ARISING  FROM,  OUT  OF OR IN CONNECTION WITH THE
   SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.





Opportunity


Personal Opportunity - Free software gives you access to billions of dollars of software at no cost. Use this software for your business, personal use or to develop a profitable skill. Access to source code provides access to a level of capabilities/information that companies protect though copyrights. Open source is a core component of the Internet and it is available to you. Leverage the billions of dollars in resources and capabilities to build a career, establish a business or change the world. The potential is endless for those who understand the opportunity.

Business Opportunity - Goldman Sachs, IBM and countless large corporations are leveraging open source to reduce costs, develop products and increase their bottom lines. Learn what these companies know about open source and how open source can give you the advantage.





Free Software


Free Software provides computer programs and capabilities at no cost but more importantly, it provides the freedom to run, edit, contribute to, and share the software. The importance of free software is a matter of access, not price. Software at no cost is a benefit but ownership rights to the software and source code is far more significant.


Free Office Software - The Libre Office suite provides top desktop productivity tools for free. This includes, a word processor, spreadsheet, presentation engine, drawing and flowcharting, database and math applications. Libre Office is available for Linux or Windows.





Free Books


The Free Books Library is a collection of thousands of the most popular public domain books in an online readable format. The collection includes great classical literature and more recent works where the U.S. copyright has expired. These books are yours to read and use without restrictions.


Source Code - Want to change a program or know how it works? Open Source provides the source code for its programs so that anyone can use, modify or learn how to write those programs themselves. Visit the GNU source code repositories to download the source.





Education


Study at Harvard, Stanford or MIT - Open edX provides free online courses from Harvard, MIT, Columbia, UC Berkeley and other top Universities. Hundreds of courses for almost all major subjects and course levels. Open edx also offers some paid courses and selected certifications.


Linux Manual Pages - A man or manual page is a form of software documentation found on Linux/Unix operating systems. Topics covered include computer programs (including library and system calls), formal standards and conventions, and even abstract concepts.