From 970e82c7ee5fedab771480f42293963fdc32d17b Mon Sep 17 00:00:00 2001 From: dkazanc Date: Mon, 9 Dec 2019 14:08:21 +0000 Subject: fixes gpu issues with pdtv --- demos/demo_cpu_regularisers.py | 8 +++----- demos/demo_cpu_regularisers3D.py | 6 ++---- demos/demo_cpu_vs_gpu_regularisers.py | 12 ++++-------- demos/demo_gpu_regularisers.py | 6 ++---- demos/demo_gpu_regularisers3D.py | 6 ++---- 5 files changed, 13 insertions(+), 25 deletions(-) (limited to 'demos') diff --git a/demos/demo_cpu_regularisers.py b/demos/demo_cpu_regularisers.py index 7d66b7f..50a5065 100644 --- a/demos/demo_cpu_regularisers.py +++ b/demos/demo_cpu_regularisers.py @@ -176,11 +176,10 @@ pars = {'algorithm' : PD_TV, \ 'input' : u0,\ 'regularisation_parameter':0.02, \ 'number_of_iterations' :1500 ,\ - 'tolerance_constant':1e-08,\ + 'tolerance_constant':1e-06,\ 'methodTV': 0 ,\ 'nonneg': 1, - 'lipschitz_const' : 8, - 'tau' : 0.0025} + 'lipschitz_const' : 8} print ("#############PD TV CPU####################") start_time = timeit.default_timer() @@ -190,8 +189,7 @@ start_time = timeit.default_timer() pars['tolerance_constant'], pars['methodTV'], pars['nonneg'], - pars['lipschitz_const'], - pars['tau'],'cpu') + pars['lipschitz_const'],'cpu') Qtools = QualityTools(Im, pd_cpu) pars['rmse'] = Qtools.rmse() diff --git a/demos/demo_cpu_regularisers3D.py b/demos/demo_cpu_regularisers3D.py index cfdd2d4..0e7e9be 100644 --- a/demos/demo_cpu_regularisers3D.py +++ b/demos/demo_cpu_regularisers3D.py @@ -188,8 +188,7 @@ pars = {'algorithm' : PD_TV, \ 'tolerance_constant':1e-06,\ 'methodTV': 0 ,\ 'nonneg': 0, - 'lipschitz_const' : 8, - 'tau' : 0.0025} + 'lipschitz_const' : 8} print ("#############FGP TV GPU####################") start_time = timeit.default_timer() @@ -199,8 +198,7 @@ start_time = timeit.default_timer() pars['tolerance_constant'], pars['methodTV'], pars['nonneg'], - pars['lipschitz_const'], - pars['tau'],'cpu') + pars['lipschitz_const'],'cpu') Qtools = QualityTools(idealVol, pd_cpu3D) pars['rmse'] = Qtools.rmse() diff --git a/demos/demo_cpu_vs_gpu_regularisers.py b/demos/demo_cpu_vs_gpu_regularisers.py index 015dfc6..a34bc19 100644 --- a/demos/demo_cpu_vs_gpu_regularisers.py +++ b/demos/demo_cpu_vs_gpu_regularisers.py @@ -241,8 +241,7 @@ pars = {'algorithm' : PD_TV, \ 'tolerance_constant':0.0,\ 'methodTV': 0 ,\ 'nonneg': 0, - 'lipschitz_const' : 8, - 'tau' : 0.0025} + 'lipschitz_const' : 8} print ("#############PD TV CPU####################") start_time = timeit.default_timer() @@ -252,8 +251,7 @@ start_time = timeit.default_timer() pars['tolerance_constant'], pars['methodTV'], pars['nonneg'], - pars['lipschitz_const'], - pars['tau'],'cpu') + pars['lipschitz_const'],'cpu') Qtools = QualityTools(Im, pd_cpu) pars['rmse'] = Qtools.rmse() @@ -279,8 +277,7 @@ pars = {'algorithm' : PD_TV, \ 'tolerance_constant':0.0,\ 'methodTV': 0 ,\ 'nonneg': 0, - 'lipschitz_const' : 8, - 'tau' : 0.0025} + 'lipschitz_const' : 8} print ("#############PD TV CPU####################") start_time = timeit.default_timer() @@ -290,8 +287,7 @@ start_time = timeit.default_timer() pars['tolerance_constant'], pars['methodTV'], pars['nonneg'], - pars['lipschitz_const'], - pars['tau'],'gpu') + pars['lipschitz_const'],'gpu') Qtools = QualityTools(Im, pd_gpu) pars['rmse'] = Qtools.rmse() diff --git a/demos/demo_gpu_regularisers.py b/demos/demo_gpu_regularisers.py index 5131847..c6114db 100644 --- a/demos/demo_gpu_regularisers.py +++ b/demos/demo_gpu_regularisers.py @@ -176,8 +176,7 @@ pars = {'algorithm' : PD_TV, \ 'tolerance_constant':1e-06,\ 'methodTV': 0 ,\ 'nonneg': 1, - 'lipschitz_const' : 8, - 'tau' : 0.0025} + 'lipschitz_const' : 8} print ("#############PD TV CPU####################") start_time = timeit.default_timer() @@ -187,8 +186,7 @@ start_time = timeit.default_timer() pars['tolerance_constant'], pars['methodTV'], pars['nonneg'], - pars['lipschitz_const'], - pars['tau'],'gpu') + pars['lipschitz_const'],'gpu') Qtools = QualityTools(Im, pd_gpu) pars['rmse'] = Qtools.rmse() diff --git a/demos/demo_gpu_regularisers3D.py b/demos/demo_gpu_regularisers3D.py index 2c25d01..18d97e5 100644 --- a/demos/demo_gpu_regularisers3D.py +++ b/demos/demo_gpu_regularisers3D.py @@ -192,8 +192,7 @@ pars = {'algorithm' : PD_TV, \ 'tolerance_constant':1e-06,\ 'methodTV': 0 ,\ 'nonneg': 0, - 'lipschitz_const' : 8, - 'tau' : 0.0025} + 'lipschitz_const' : 8} print ("#############PD TV GPU####################") start_time = timeit.default_timer() @@ -203,8 +202,7 @@ start_time = timeit.default_timer() pars['tolerance_constant'], pars['methodTV'], pars['nonneg'], - pars['lipschitz_const'], - pars['tau'],'gpu') + pars['lipschitz_const'],'gpu') Qtools = QualityTools(idealVol, pd_gpu3D) pars['rmse'] = Qtools.rmse() -- cgit v1.2.3