How to Set Up the Post Processing Package

Create a directory in your home directory or elsewhere that shall contain all the python related code that is required for you to experiment For our example, I will call this directory "my_python_modules". I will create this directory in my HOME directory which is "/users/tejasvi"


  $ cd
	
  $ pwd
  /users/tejasvi
	
  $ mkdir my_python_modules

  $ ls
  my_python_modules  mail  README  images

Now unpack the tar that contains the python code into the directory created. Say that the python tar file is named "postprocess.tar.gz"


   $ cd my_python_modules

   $ pwd
   /users/tejasvi/my_python_modules

   $ tar xvzf postprocess.tar.gz

Notice that this will extract all the post-processing code into a directory called postprocess. The other required modules for the post-process filters to work are the filter configuration file parsing module and the namespace file parser modules. These shall be present in the top level directory that you created. In the example shown above, it was "my_python_modules"

Since the python wrappers for libxml2 werent present in some/all of the linux at Eaton, the libxml2 python module has also been included in the package. The files corresponding to the libxml2 package shall also be present in the top-level directory that you extracted the tar file in.

   $ pwd
   /users/tejasvi/my_python_modules

   $ ls 
   advanced_namespace_parser.py  filter_config_parser.py  libxml2mod.la  
   libxml2.py                    postprocess              README
   drv_libxml2.py                libxml2mod.a             libxml2mod.so  
   namespace_parser.py 

Now, set your PYTHONPATH environment variable to point to the directory that you created at the start. In the example shown above, this directory would be "/users/tejasvi/my_python_modules"


    $ echo $SHELL

If you are using bash , use
    $ export PYTHONPATH=$PYTHONPATH:/users/tejasvi/my_python_modules
If you are using tcsh, use
    $ setenv PYTHONPATH ${PYTHONPATH}:/users/tejasvi/my_python_modules

You can now test the post processing examples that are present in the "postprocess/examples" directory.