Commit cc079555 authored by alexander.dornheim's avatar alexander.dornheim
Browse files

Added more testing for tasse AP

parent 829ca38b
......@@ -83,7 +83,7 @@ class AP(Algorithm):
Relerrs = change.copy()
tmp1 = prox2.work(u);
while iters < maxiter and change[iters] >= tol:
iters += 1;
......@@ -119,7 +119,7 @@ class AP(Algorithm):
change[iters] = sqrt(tmp_change);
gap[iters] = sqrt(tmp_gap);
u = tmp_u.copy();
u = tmp_u;
tmp = prox1.work(u);
tmp2 = prox2.work(u);
......
......@@ -70,7 +70,7 @@ new_config = {
# able to control (without too much damage)'''
# Algorithm:
'algorithm' : 'RAAR', #'Accelerated_AP_product_space';
'algorithm' : 'AP', #'Accelerated_AP_product_space';
'numruns' : 1, # the only time this parameter will
# be different than 1 is when we are
# benchmarking...not something a normal user
......@@ -88,7 +88,7 @@ new_config = {
#maximum number of iterations and tolerances
'MAXIT' : 500,
'MAXIT' : 1,
'TOL' : 1e-8,
# relaxaton parameters in RAAR, HPR and HAAR
......
......@@ -241,13 +241,17 @@ class Phase(Problem):
print(self.config['proxoperators'])
if self.config['experiment'] == 'JWST':
if self.config['MAXIT'] == 1:
f = h5py.File('Phase_test_data/u1_1.mat')
elif self.config['MAXIT'] == 500 :
f = h5py.File('Phase_test_data/u1_500.mat')
else:
print("No file available to compare to.")
return
if self.config['algorithm'] == 'RAAR':
if self.config['MAXIT'] == 1:
f = h5py.File('Phase_test_data/u1_1.mat')
elif self.config['MAXIT'] == 500 :
f = h5py.File('Phase_test_data/u1_500.mat')
else:
print("No file available to compare to.")
return
elif self.config['algorithm'] == 'AP':
f = h5py.File('Phase_test_data/JWST_u1_ap_' + str(self.config['MAXIT']) + '.mat')
u1 = f['u1'].value.view(np.complex)
else:
if self.config['algorithm'] == 'RAAR':
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment