示例#1
0
文件: test.py 项目: wolever/pprintpp
 def test_pp_pprint(self):
     pp.pprint("stuff")
     self.assertStdout("'stuff'")
示例#2
0
        candidates = []
        for i in range(num_cands):
            candidates.append([100+i,20+i])
            
        parameters = sim_vars.keys()
        
        print('Using %s & %s'%(parameters, candidates))
        
        cont.num_parallel_evaluations = num_cands
        
        traces = cont.run(candidates,parameters)
        
        
    else:

        t, v = cont.run_individual(sim_vars, show=(not nogui))
        
        from pyelectro import analysis
        
        analysis_var={'peak_delta':0,'baseline':0,'dvdt_threshold':0, 'peak_threshold':0}
        
        data_analysis=analysis.NetworkAnalysis(v,
                                               t,
                                               analysis_var,
                                               start_analysis=0,
                                               end_analysis=sim_time)
                                                   
        analysed = data_analysis.analyse()     
        
        pp.pprint(analysed)
示例#3
0
文件: test.py 项目: ahawker/pprintpp
import pp

pp(["hello", "world"])

pp.pprint("stuff")

print pp.pformat("asdf")

print pp.fmt("stuff")

print dir(pp)

print repr(pp)
示例#4
0
 def test_pp_pprint(self):
     pp.pprint("stuff")
     self.assertStdout("'stuff'")
示例#5
0
        parameters = sim_vars.keys()

        print('Using %s & %s' % (parameters, candidates))

        cont.num_parallel_evaluations = num_cands

        traces = cont.run(candidates, parameters)

    else:

        t, v = cont.run_individual(sim_vars, show=(not nogui))

        from pyelectro import analysis

        analysis_var = {
            'peak_delta': 0,
            'baseline': 0,
            'dvdt_threshold': 0,
            'peak_threshold': 0
        }

        data_analysis = analysis.NetworkAnalysis(v,
                                                 t,
                                                 analysis_var,
                                                 start_analysis=0,
                                                 end_analysis=sim_time)

        analysed = data_analysis.analyse()

        pp.pprint(analysed)