From dd7a2438bdfafc5a2bbbb34a5e80336d12b5e86d Mon Sep 17 00:00:00 2001 From: epapoutsellis Date: Mon, 8 Apr 2019 14:12:14 +0100 Subject: profile gradient --- Wrappers/Python/wip/test_profile.py | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 Wrappers/Python/wip/test_profile.py diff --git a/Wrappers/Python/wip/test_profile.py b/Wrappers/Python/wip/test_profile.py new file mode 100644 index 0000000..7be19f9 --- /dev/null +++ b/Wrappers/Python/wip/test_profile.py @@ -0,0 +1,26 @@ +#!/usr/bin/env python3 +# -*- coding: utf-8 -*- +""" +Created on Mon Apr 8 13:57:46 2019 + +@author: evangelos +""" + +# profile direct, adjoint, gradient + +from ccpi.framework import ImageGeometry +from ccpi.optimisation.operators import Gradient + +N, M = 500, 500 + +ig = ImageGeometry(N, M) + +G = Gradient(ig) + +u = G.domain_geometry().allocate('random_int') +w = G.range_geometry().allocate('random_int') + +for i in range(500): + + res = G.adjoint(w) + \ No newline at end of file -- cgit v1.2.3