Changeset 101 for trunk/examples/retina/benchmark_noise.py
- Timestamp:
- 01/15/08 17:44:22 (4 years ago)
- Files:
-
- 1 modified
-
trunk/examples/retina/benchmark_noise.py (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/examples/retina/benchmark_noise.py
r97 r101 35 35 noise_std, CRF = numpy.zeros(len(experiments)), numpy.zeros(len(experiments)) 36 36 for count, experiment in enumerate(experiments): 37 out_ON_DATA = benchmark.get('out',experiment)['out_ON_DATA'] #.as_list_id_list_time()37 out_ON_DATA = benchmark.get('out',experiment)['out_ON_DATA'] 38 38 noise_std[count] = benchmark.get('experiments')[experiment]['noise_std'] 39 CRF[count] = out_ON_DATA.mean_rate() #[0]) / N / N / simtime * 1000.039 CRF[count] = out_ON_DATA.mean_rate() 40 40 41 41 … … 48 48 #pylab.axes([Lmargin, dmargin , 1.0 - Rmargin- Lmargin,1.0-umargin-dmargin]) # [left, bottom, width, height] 49 49 50 #pylab.subplot(111)51 50 idx_ = numpy.argsort(noise_std) # extract lines 52 51 pylab.plot(noise_std[idx_],CRF[idx_],'go-', label='line 1', linewidth=2) … … 65 64 # create a Retina Model object that contains a method to init, to run, ... 66 65 ret = model.Retina(10) 67 ret.params['simtime'] = 4000*0.168 66 69 tag = '07-02-21' 70 tag = '07-03-08' # worked fine for D25 71 tag = '07-04-12' 72 tag = '07-04-08' # new with multiple seeds for CNS07 73 tag = '07-05-14' # no 74 tag = '07-05-16' # going OO 75 tag = 'test' # going OO 67 tag = 'test' 76 68 77 69 name = 'results/' + tag + '_benchmark_noise' 78 70 79 71 # create the list of experiments as all possibilities accross parameter vectors 80 run = benchmark.get_experiment_dict({'noise_std':numpy.linspace(.10,10.0,20), 'snr' : [ 0.0 ]}) 72 span, N_exp = 5, 2*7+1 73 #range = 10.**(numpy.linspace(-span,span,N_exp)) 74 range = numpy.linspace(1/span,span,N_exp) 75 run = benchmark.get_experiment_dict({'noise_std': ret.params['noise_std']* range, 'snr' : [ 0.0 ]}) 81 76 82 77 # create benchmark (or open it if it exists) … … 86 81 87 82 show(B) 88 83 #B.reset_all() # erase experimental data
