From 896841a1f3755f2d1864618bd4461f97d36ce569 Mon Sep 17 00:00:00 2001 From: Daniel Danciu Date: Wed, 28 Apr 2021 13:44:42 +0200 Subject: [PATCH] Replace deprecated time.clock() with time.perf_counter() --- src/gen-scref.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gen-scref.py b/src/gen-scref.py index 1719933..9034b49 100644 --- a/src/gen-scref.py +++ b/src/gen-scref.py @@ -289,7 +289,7 @@ def simulate_sc(source, n_snv, n_sc, sc, snv_loc=None, out='', ts_tv_p=0.71, ts_ for loc in snv_loc} # loop through single cells - start_time = time.clock() # start timer + start_time = time.perf_counter() # start timer sc_fnames = [] r = 1 for c in range(len(sc)): @@ -320,7 +320,7 @@ def simulate_sc(source, n_snv, n_sc, sc, snv_loc=None, out='', ts_tv_p=0.71, ts_ outname = out+'%d'%(c+1) write_sc(sc_obj = sc_gtypes, seq_type = 'alt_gtype', out = 'prototype' + outname) # write sequence before WGA - sim_time = time.clock() - start_time # store simulation time for display + sim_time = time.perf_counter() - start_time # store simulation time for display logger.info('All done! Simulated %d SNVs in %d prototypes and %d single cells in %.2f seconds.'%(n_snv,len(sc),n_sc,sim_time)) # pack experiment results