# Path: neurotools/plotting.py
# PILIMAGEUSE = check_dependency('PIL')
# def get_display(display):
# def progress_bar(progress):
# def pylab_params(fig_width_pt=246.0,
#                 ratio=(numpy.sqrt(5)-1.0)/2.0,# Aesthetic golden mean ratio by default
#                 text_fontsize=10, tick_labelsize=8, useTex=False):
# def set_axis_limits(subplot, xmin, xmax, ymin, ymax):
# def set_labels(subplot, xlabel, ylabel):
# def set_pylab_params(fig_width_pt=246.0,
#                     ratio=(numpy.sqrt(5)-1.0)/2.0,# Aesthetic golden mean ratio by default
#                     text_fontsize=10, tick_labelsize=8, useTex=False):
# def save_2D_image(mat, filename):
# def save_2D_movie(frame_list, filename, frame_duration):
#     def __init__(self, nrows, ncolumns, title="", xlabel=None, ylabel=None,
#                  scaling=('linear','linear')):
#     def finalise(self):
#     def save(self, filename):
#     def next_panel(self):
#     def panel(self, i):
#     def set_frame(self, ax, boollist, linewidth=2):
# class SimpleMultiplot(object):


import matplotlib
import unittest
import pylab
import os
        import time
        import numpy
        import numpy
from neurotools import plotting
    def runTest(self):

        a = plotting.get_display(True)
        assert a != None
        a = plotting.get_display(False)
        assert a == None
        a = plotting.get_display(1234)
        assert a == 1234



class ProgressBarTest(unittest.TestCase):

    def runTest(self):

        print '\nINFO: Testing progress bar...'
        for i in range(100):
            plotting.progress_bar(i/100.)
            time.sleep(.01)
        print '\n'



class Save2DImageTest(unittest.TestCase):

    def runTest(self):

        mat = numpy.random.random([50,50])
        filename = 'deleteme.png'
        if os.path.exists(filename): os.remove(filename)

# Path: neurotools/plotting.py
# PILIMAGEUSE = check_dependency('PIL')
# def get_display(display):
# def progress_bar(progress):
# def pylab_params(fig_width_pt=246.0,
#                 ratio=(numpy.sqrt(5)-1.0)/2.0,# Aesthetic golden mean ratio by default
#                 text_fontsize=10, tick_labelsize=8, useTex=False):
# def set_axis_limits(subplot, xmin, xmax, ymin, ymax):
# def set_labels(subplot, xlabel, ylabel):
# def set_pylab_params(fig_width_pt=246.0,
#                     ratio=(numpy.sqrt(5)-1.0)/2.0,# Aesthetic golden mean ratio by default
#                     text_fontsize=10, tick_labelsize=8, useTex=False):
# def save_2D_image(mat, filename):
# def save_2D_movie(frame_list, filename, frame_duration):
#     def __init__(self, nrows, ncolumns, title="", xlabel=None, ylabel=None,
#                  scaling=('linear','linear')):
#     def finalise(self):
#     def save(self, filename):
#     def next_panel(self):
#     def panel(self, i):
#     def set_frame(self, ax, boollist, linewidth=2):
# class SimpleMultiplot(object):


# Path: test/test_plotting.py
import matplotlib
import unittest
import pylab
import os
        import time
        import numpy
        import numpy
from neurotools import plotting

    def runTest(self):

        a = plotting.get_display(True)
        assert a != None
        a = plotting.get_display(False)
        assert a == None
        a = plotting.get_display(1234)
        assert a == 1234



class ProgressBarTest(unittest.TestCase):

    def runTest(self):

        print '\nINFO: Testing progress bar...'
        for i in range(100):
            plotting.progress_bar(i/100.)
            time.sleep(.01)
        print '\n'



class Save2DImageTest(unittest.TestCase):

    def runTest(self):

        mat = numpy.random.random([50,50])
        filename = 'deleteme.png'
        if os.path.exists(filename): os.remove(filename)

        plotting.save_2D_image(mat, filename)