Show
Ignore:
Timestamp:
11/14/08 19:17:05 (3 years ago)
Author:
LaurentPerrinet
Message:

some polishing of the wiki:examples, the retina needs a bit more work...

Files:
1 modified

Legend:

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

    r333 r340  
    1919import os, sys, numpy, shelve 
    2020 
    21 retina.params['snr'] = 0 # no input 
    22  
     21N, N_exp_noise = 1000, 22 
     22from NeuroTools.parameters import * 
     23p =  ParameterSpace({'noise_std' : ParameterRange(list(10.**(numpy.linspace(-.50,1.,N_exp_noise))))}) 
    2324 
    2425name = sys.argv[0].split('.')[0] # name of the current script withpout the '.py' part 
     
    2728    CRF = results['CRF'] 
    2829except: 
    29          
    30     from NeuroTools.parameters import * 
    31  
    3230    # this is not mandatory but just a "easy_install progressbar" away 
    3331    # else remove all corresponding lines in this code... 
    3432    import progressbar # see http://projects.scipy.org/pipermail/scipy-dev/2008-January/008200.html 
    35  
    36     N, N_exp_noise = 1000, 22 
    37  
    38     p =  ParameterSpace({'noise_std' : ParameterRange(list(10.**(numpy.linspace(-.50,1.,N_exp_noise))))}) 
    39  
    4033    import retina as model 
    4134    retina = model.Retina(N)  
     35    retina.params['snr'] = 0 # no input 
     36     
    4237    # calculates the dimension of the parameter space 
    4338    results_dim, results_label = p.parameter_space_dimension_labels() 
     
    7570""" 
    7671 
    77 N, simtime = retina.params['N'], retina.params['simtime'] 
    78  
    7972import pylab 
    8073