Show
Ignore:
Timestamp:
11/12/08 19:49:46 (4 years ago)
Author:
LaurentPerrinet
Message:

wiki:examples : reflect changes in the wiki:parameters API / polishing figures to give usable examples

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/examples/retina/benchmark_noise.py

    • Property svn:keywords set to Id
    r172 r326  
    2525import progressbar # see http://projects.scipy.org/pipermail/scipy-dev/2008-January/008200.html 
    2626 
    27 N, N_exp_noise = 100, 22 
    28 p = ParameterSet({}) 
    29 p.noise_std = ParameterRange(list(10.**(numpy.linspace(-.50,1.,N_exp_noise)))) 
     27N, N_exp_noise = 1000, 22 
     28 
     29p =  ParameterSpace({'noise_std' : ParameterRange(list(10.**(numpy.linspace(-.50,1.,N_exp_noise))))}) 
    3030 
    3131import retina as model 
    32  
    33  
    3432retina = model.Retina(N)  
    3533retina.params['snr'] = 0 # no input 
     
    8785pylab.xlabel('Noise amplitude') 
    8886 
    89 pylab.savefig('results/fig-' + name + '.pdf') 
    90 pylab.savefig('results/fig-' + name + '.png', dpi = 300) 
    9187 
     88if 0: 
     89    pylab.show() 
     90else: 
     91    pylab.savefig('results/fig-' + name + '.pdf') 
     92    pylab.savefig('results/fig-' + name + '.png', dpi = 300) 
     93 
     94 
     95#TODO: make a plot showing that spontaneous activity is a point process with a known histogram