From e3ccbc56788b59cae74ab59e30ae656dae18a07e Mon Sep 17 00:00:00 2001 From: Laura Murgatroyd <60604372+lauramurgatroyd@users.noreply.github.com> Date: Wed, 8 Mar 2023 10:54:44 +0000 Subject: [PATCH 01/12] Fix typos in the documentation (#1431) * Fix typos in the documentation * improve reader docstrings * docstring updates * update reader docstrings and FBP typos * minor Zeiss reader update * initialise variables in readers * Update tiff docstring and init * move nikon docstring out of init * Update change log [ci skip] * Update docs/source/processors.rst * Suggestions from code review * Add default roi if it is set to None * improve render for zeiss docstrings --------- Signed-off-by: Laura Murgatroyd <60604372+lauramurgatroyd@users.noreply.github.com> Co-authored-by: Edoardo Pasca --- CHANGELOG.md | 2 + Wrappers/Python/cil/io/NEXUSDataReader.py | 13 +- Wrappers/Python/cil/io/NEXUSDataWriter.py | 65 ++++----- Wrappers/Python/cil/io/NikonDataReader.py | 123 +++++++++--------- Wrappers/Python/cil/io/TIFF.py | 81 +++++++----- Wrappers/Python/cil/io/ZEISSDataReader.py | 95 +++++++++----- Wrappers/Python/cil/recon/FBP.py | 10 +- .../Python/test/test_NexusReaderWriter.py | 1 - .../Python/test/test_tiff_readerwriter.py | 2 +- docs/source/developer_guide.rst | 2 +- docs/source/framework.rst | 4 +- docs/source/index.rst | 2 +- docs/source/introduction.rst | 6 +- docs/source/io.rst | 19 ++- docs/source/optimisation.rst | 2 +- docs/source/processors.rst | 2 +- 16 files changed, 239 insertions(+), 190 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index fcc49598b..67ef7fc1c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,8 @@ * x.x.x - Partitioner is now able to create batches even if angle is not the outer dimension - Renamed `max_iteration_stop_cryterion` method in the Algorithm class to `max_iteration_stop_criterion` + - Improved and tidied up documentation for all readers and writers, including hiding special members. + - Use arguments instead of kwargs in all readers and writers with multiple kwargs, making documentation easier. * 22.2.0 - BlockGeometry is iterable diff --git a/Wrappers/Python/cil/io/NEXUSDataReader.py b/Wrappers/Python/cil/io/NEXUSDataReader.py index 4b871bfd0..9debfc958 100644 --- a/Wrappers/Python/cil/io/NEXUSDataReader.py +++ b/Wrappers/Python/cil/io/NEXUSDataReader.py @@ -32,14 +32,13 @@ class NEXUSDataReader(object): Parameters ---------- - **kwargs : dict, optional - Arguments to the constructor. One of these should be `file_name`. + file_name: str + the full path to the NeXus file to read. """ - def __init__(self, - **kwargs): - - self.file_name = kwargs.get('file_name', None) + def __init__(self, file_name=None): + + self.file_name = file_name if self.file_name is not None: self.set_up(file_name = self.file_name) @@ -284,7 +283,7 @@ def __read_as(self, dtype=np.float32): self.get_geometry() #allocate data container as requested type - output = self._geometry.allocate(None,dtype=dtype) + output = self._geometry.allocate(None, dtype=dtype) with h5py.File(self.file_name,'r') as dfile: diff --git a/Wrappers/Python/cil/io/NEXUSDataWriter.py b/Wrappers/Python/cil/io/NEXUSDataWriter.py index 77816ef36..c781300cc 100644 --- a/Wrappers/Python/cil/io/NEXUSDataWriter.py +++ b/Wrappers/Python/cil/io/NEXUSDataWriter.py @@ -29,28 +29,26 @@ class NEXUSDataWriter(object): + ''' Create a writer for NEXUS files. - def __init__(self, - **kwargs): - - ''' - Constructor - - :param data: The dataset to write to file - :type data: AcquisitionData, ImageData - :param file_name: file name to write - :type file_name: os.path or string, default None - :param compression: The lossy compression to apply, default 0 will not compress data. 8 or 16 will compress to 8 and 16 bit dtypes respectively. - :type compression: int, default 0 - ''' + Parameters + ---------- + data: AcquisitionData, ImageData, + The dataset to write to file + file_name: os.path or string, default None + The file name to write + compression: int, default 0 + The lossy compression to apply, default 0 will not compress data. + 8 or 16 will compress to 8 and 16 bit dtypes respectively. + ''' + + def __init__(self, data=None, file_name=None, compression=0): - self.data = kwargs.get('data', None) - self.file_name = kwargs.get('file_name', None) - self.compression = kwargs.get('compression', 0) + self.data = data + self.file_name = file_name - if ((self.data is not None) and (self.file_name is not None)): - self.set_up(data = self.data, - file_name = self.file_name, compression=self.compression) + if ((data is not None) and (file_name is not None)): + self.set_up(data = data, file_name = file_name, compression=compression) def set_up(self, data = None, @@ -58,17 +56,26 @@ def set_up(self, compression = 0): ''' - set up writer - - :param data: The dataset to write to file - :type data: AcquisitionData, ImageData - :param file_name: file name to write - :type file_name: os.path or string, default None - :param compression: The lossy compression to apply, default 0 will not compress data. 8 or 16 will compress to 8 and 16bit dtypes respectively. - :type compression: int, default 0 - ''' + Set up the writer + + data: AcquisitionData, ImageData, + The dataset to write to file + file_name: os.path or string, default None + The file name to write + compression: int, default 0 + The lossy compression to apply, default 0 will not compress data. + 8 or 16 will compress to 8 and 16 bit dtypes respectively. + ''' self.data = data - self.file_name = os.path.abspath(file_name) + self.file_name = file_name + + if self.file_name is None: + raise Exception('Path to write file is required.') + else: + self.file_name = os.path.abspath(file_name) + + if self.data is None: + raise Exception('Data to write is required.') if not self.file_name.endswith('nxs') and not self.file_name.endswith('nex'): self.file_name+='.nxs' diff --git a/Wrappers/Python/cil/io/NikonDataReader.py b/Wrappers/Python/cil/io/NikonDataReader.py index 7b6d7a734..1eefd417a 100644 --- a/Wrappers/Python/cil/io/NikonDataReader.py +++ b/Wrappers/Python/cil/io/NikonDataReader.py @@ -22,70 +22,72 @@ class NikonDataReader(object): + '''Basic reader for xtekct files - def __init__(self, - **kwargs): - '''Basic reader for xtekct files - - Parameters - ---------- + Parameters + ---------- - - file_name: str with full path to .xtekct file - - roi: dictionary with roi to load - {'angle': (start, end, step), - 'horizontal': (start, end, step), - 'vertical': (start, end, step)} - Files are stacked along axis_0. axis_1 and axis_2 correspond - to row and column dimensions, respectively. - Files are stacked in alphabetic order. - To skip projections or to change number of projections to load, - adjust 'angle'. For instance, 'angle': (100, 300) - will skip first 100 projections and will load 200 projections. - 'angle': -1 is a shortcut to load all elements along axis. - Start and end can be specified as None which is equivalent - to start = 0 and end = load everything to the end, respectively. - Start and end also can be negative. - - normalise: bool, normalises loaded projections by detector - white level (I_0). Default value is True - - fliplr: bool, default = False, flip projections in the left-right direction - (about vertical axis) - - mode: str, 'bin' (default) or 'slice'. In bin mode, 'step' number - of pixels is binned together, values of resulting binned - pixels are calculated as average. - In 'slice' mode 'step' defines standard numpy slicing. - Note: in general - output array size in bin mode != output array size in slice mode + file_name: str + full path to .xtekct file - Output - ------ + roi: dict, default=None + dictionary with roi to load: + {'angle': (start, end, step), + 'horizontal': (start, end, step), + 'vertical': (start, end, step)} - Acquisition data with corresponding geometry, arranged as ['angle', horizontal'] - if a single slice is loaded and ['vertical, 'angle', horizontal'] - if more than 1 slices are loaded. - - ''' + normalise: bool, default=True + normalises loaded projections by detector white level (I_0) + + fliplr: bool, default = False, + flip projections in the left-right direction (about vertical axis) + + mode: str: {'bin', 'slice'}, default='bin' + In bin mode, 'step' number of pixels is binned together, + values of resulting binned pixels are calculated as average. + In 'slice' mode 'step' defines standard numpy slicing. + Note: in general output array size in bin mode != output array size in slice mode + + + Notes + ----- + `roi` behaviour: + Files are stacked along axis_0. axis_1 and axis_2 correspond + to row and column dimensions, respectively. + + Files are stacked in alphabetic order. - self.file_name = kwargs.get('file_name', None) - self.roi = kwargs.get('roi', {'angle': -1, 'horizontal': -1, 'vertical': -1}) - self.normalise = kwargs.get('normalise', True) - self.mode = kwargs.get('mode', 'bin') - self.fliplr = kwargs.get('fliplr', False) + To skip projections or to change number of projections to load, + adjust 'angle'. For instance, 'angle': (100, 300) + will skip first 100 projections and will load 200 projections. - if self.file_name is not None: - self.set_up(file_name = self.file_name, - roi = self.roi, - normalise = self.normalise, - mode = self.mode, - fliplr = self.fliplr) + ``'angle': -1`` is a shortcut to load all elements along axis. + + ``start`` and ``end`` can be specified as ``None`` which is equivalent + to ``start = 0`` and ``end = load everything to the end``, respectively. + Start and end also can be negative. + + ''' + + def __init__(self, file_name = None, roi= None, + normalise=True, mode='bin', fliplr=False): + + self.file_name = file_name + self.roi = roi + self.normalise = normalise + self.mode = mode + self.fliplr = fliplr + + if file_name is not None: + self.set_up(file_name = file_name, + roi = roi, + normalise = normalise, + mode = mode, + fliplr = fliplr) def set_up(self, file_name = None, - roi = {'angle': -1, 'horizontal': -1, 'vertical': -1}, + roi = None, normalise = True, mode = 'bin', fliplr = False): @@ -96,7 +98,7 @@ def set_up(self, self.mode = mode self.fliplr = fliplr - if self.file_name == None: + if self.file_name is None: raise Exception('Path to xtekct file is required.') # check if xtekct file exists @@ -110,6 +112,9 @@ def set_up(self, for key in self.roi.keys(): if key not in ['angle', 'horizontal', 'vertical']: raise Exception("Wrong label. One of the following is expected: angle, horizontal, vertical") + + if self.roi is None: + self.roi= {'angle': -1, 'horizontal': -1, 'vertical': -1} roi = self.roi.copy() @@ -202,8 +207,6 @@ def set_up(self, self.tiff_directory_path = os.path.join(os.path.dirname(self.file_name), input_folder_name) - - self._roi_par = [[0, num_projections, 1] ,[0, pixel_num_v_0, 1], [0, pixel_num_h_0, 1]] for key in roi.keys(): @@ -341,7 +344,9 @@ def get_roi(self): def read(self): ''' - Reads projections and return AcquisitionData container + Reads projections and returns AcquisitionData with corresponding geometry, + arranged as ['angle', horizontal'] if a single slice is loaded + and ['vertical, 'angle', horizontal'] if more than 1 slice is loaded. ''' reader = TIFFStackReader() diff --git a/Wrappers/Python/cil/io/TIFF.py b/Wrappers/Python/cil/io/TIFF.py index e35e9e2d8..16f30c047 100644 --- a/Wrappers/Python/cil/io/TIFF.py +++ b/Wrappers/Python/cil/io/TIFF.py @@ -84,17 +84,13 @@ class TIFFWriter(object): ''' - def __init__(self, **kwargs): - - - self.data_container = kwargs.get('data', None) - self.file_name = kwargs.get('file_name', None) - counter_offset = kwargs.get('counter_offset', 0) - compression = kwargs.get('compression', None) + def __init__(self, data=None, file_name=None, counter_offset=0, compression=None): - if ((self.data_container is not None) and (self.file_name is not None)): - self.set_up(data = self.data_container, - file_name = self.file_name, + self.data_container = data + self.file_name = file_name + self.counter_offset = counter_offset + if ((data is not None) and (file_name is not None)): + self.set_up(data = data, file_name = file_name, counter_offset=counter_offset, compression=compression) @@ -193,8 +189,8 @@ def _zero_padding(self, number): class TIFFStackReader(object): ''' - Basic TIFF redaer which loops through all tiff files in a specific - folder and load them in alphabetic order + Basic TIFF reader which loops through all tiff files in a specific + folder and loads them in alphabetic order Parameters ---------- @@ -203,33 +199,49 @@ class TIFFStackReader(object): Path to folder with tiff files, list of paths of tiffs, or single tiff file roi : dictionary, default `None` - dictionary with roi to load + dictionary with roi to load: ``{'axis_0': (start, end, step), 'axis_1': (start, end, step), 'axis_2': (start, end, step)}`` - Files are stacked along axis_0. axis_1 and axis_2 correspond - to row and column dimensions, respectively. - Files are stacked in alphabetic order. - To skip files or to change number of files to load, - adjust axis_0. For instance, 'axis_0': (100, 300) - will skip first 100 files and will load 200 files. - 'axis_0': -1 is a shortcut to load all elements along axis. - Start and end can be specified as None which is equivalent - to start = 0 and end = load everything to the end, respectively. - Start and end also can be negative. - Notes: roi is specified for axes before transpose. + roi is specified for axes before transpose. transpose : bool, default False Whether to transpose loaded images - mode : str, default 'bin'. Accepted values 'bin', 'slice' - Referring to the 'step' defined in the roi parameter, in bin mode, 'step' number of pixels - are binned together, values of resulting binned pixels are calculated as average. - In 'slice' mode 'step' defines standard numpy slicing. + mode : str, {'bin', 'slice'}, default 'bin'. + Defines the 'step' in the roi parameter: + + In bin mode, 'step' number of pixels + are binned together, values of resulting binned pixels are calculated as average. + + In 'slice' mode 'step' defines standard numpy slicing. + Note: in general output array size in bin mode != output array size in slice mode dtype : numpy type, string, default np.float32 Requested type of the read image. If set to None it defaults to the type of the saved file. + + + Notes: + ------ + roi behaviour: + Files are stacked along ``axis_0``, in alphabetical order. + + ``axis_1`` and ``axis_2`` correspond + to row and column dimensions, respectively. + + To skip files or to change number of files to load, + adjust ``axis_0``. For instance, ``'axis_0': (100, 300)`` + will skip first 100 files and will load 200 files. + + ``'axis_0': -1`` is a shortcut to load all elements along axis 0. + + ``start`` and ``end`` can be specified as ``None`` which is equivalent + to ``start = 0`` and ``end = load everything to the end``, respectively. + + Start and end also can be negative. + + roi is specified for axes before transpose. Example: @@ -249,12 +261,8 @@ class TIFFStackReader(object): >>> about_original_data = reader.read_rescaled() ''' - def __init__(self, **kwargs): - self.file_name = kwargs.get('file_name', None) - roi = kwargs.get('roi', {'axis_0': -1, 'axis_1': -1, 'axis_2': -1}) - transpose = kwargs.get('transpose', False) - mode = kwargs.get('mode', 'bin') - dtype = kwargs.get('dtype', np.float32) + def __init__(self, file_name=None, roi=None, transpose=False, mode='bin', dtype=np.float32): + self.file_name = file_name if self.file_name is not None: self.set_up(file_name = self.file_name, @@ -264,7 +272,7 @@ def __init__(self, **kwargs): def set_up(self, file_name = None, - roi = {'axis_0': -1, 'axis_1': -1, 'axis_2': -1}, + roi = None, transpose = False, mode = 'bin', dtype = np.float32): @@ -312,6 +320,9 @@ def set_up(self, if file_name == None: raise ValueError('file_name to tiff files is required. Can be a tiff, a list of tiffs or a directory containing tiffs') + + if self.roi is None: + self.roi = {'axis_0': -1, 'axis_1': -1, 'axis_2': -1} # check that PIL library is installed if (pilAvailable == False): diff --git a/Wrappers/Python/cil/io/ZEISSDataReader.py b/Wrappers/Python/cil/io/ZEISSDataReader.py index 96710bf87..beb785ce9 100644 --- a/Wrappers/Python/cil/io/ZEISSDataReader.py +++ b/Wrappers/Python/cil/io/ZEISSDataReader.py @@ -19,6 +19,7 @@ # Andrew Sharits (UES,Inc.) # Edoardo Pasca (UKRI-STFC) # Gemma Fardell (UKRI-STFC) +# Laura Murgatroyd (UKRI-STFC) from cil.framework import AcquisitionData, AcquisitionGeometry, ImageData, ImageGeometry, DataOrder @@ -35,55 +36,81 @@ logger = logging.getLogger(__name__) class ZEISSDataReader(object): + + ''' + Create a reader for ZEISS files - def __init__(self, file_name=None, roi=None): - ''' - Constructor + Parameters + ---------- + file_name: str + file name to read + roi: dict, default None + dictionary with roi to load for each axis: + ``{'axis_labels_1': (start, end, step),'axis_labels_2': (start, end, step)}``. + ``axis_labels`` are defined by ImageGeometry and AcquisitionGeometry dimension labels. + + Notes + ----- + `roi` behaviour: + For ImageData to skip files or to change number of files to load, + adjust ``vertical``. E.g. ``'vertical': (100, 300)`` will skip first 100 files + and will load 200 files. - :param file_name: file name to read - :type file_name: os.path or string - :param roi: dictionary with roi to load for each axis. - {'axis_labels_1': (start, end, step), - 'axis_labels_2': (start, end, step)} - axis_labels are definied by ImageGeometry and AcquisitionGeometry dimension labels. - e.g. for ImageData to skip files or to change number of files to load, - adjust 'vertical'. For instance, 'vertical': (100, 300) - will skip first 100 files and will load 200 files. - 'axis_label': -1 is a shortcut to load all elements along axis. - Start and end can be specified as None which is equivalent - to start = 0 and end = load everything to the end, respectively. - Start and end also can be negative using numpy indexing. - :type roi: dictionary, default None + ``'axis_label': -1`` is a shortcut to load all elements along axis. + + ``start`` and ``end`` can be specified as ``None`` which is equivalent + to ``start = 0`` and ``end = load everything to the end``, respectively. + ''' + + def __init__(self, file_name=None, roi=None): + + self.file_name = file_name - ''' # Set logging level for dxchange reader.py logger_dxchange = logging.getLogger(name='dxchange.reader') if logger_dxchange is not None: logger_dxchange.setLevel(logging.ERROR) if file_name is not None: - self.set_up(file_name = file_name, roi = roi) + self.set_up(file_name, roi = roi) def set_up(self, file_name, roi = None): '''Set up the reader + - :param file_name: file name to read - :type file_name: os.path or string, default None - :param roi: dictionary with roi to load for each axis. - {'axis_labels_1': (start, end, step), - 'axis_labels_2': (start, end, step)} - axis_labels are definied by ImageGeometry and AcquisitionGeometry dimension labels. - e.g. for ImageData to skip files or to change number of files to load, - adjust 'vertical'. For instance, 'vertical': (100, 300) - will skip first 100 files and will load 200 files. - 'axis_label': -1 is a shortcut to load all elements along axis. - Start and end can be specified as None which is equivalent - to start = 0 and end = load everything to the end, respectively. - Start and end also can be negative using numpy indexing. - :type roi: dictionary, default None + Parameters + ---------- + file_name: str + file name to read + roi: dict, default None + dictionary with roi to load for each axis: + ``{'axis_labels_1': (start, end, step),'axis_labels_2': (start, end, step)}``. + ``axis_labels`` are defined by ImageGeometry and AcquisitionGeometry dimension labels. + + Notes + ----- + `roi` behaviour: + ``'axis_label': -1`` is a shortcut to load all elements along axis. + + ``start`` and ``end`` can be specified as ``None`` which is equivalent + to ``start = 0`` and ``end = load everything to the end``, respectively. + + **Acquisition Data** + + The axis labels in the `roi` dict for `AcquisitionData` will be: + ``{'angle':(...),'vertical':(...),'horizontal':(...)}`` + + **Image Data** + + The axis labels in the `roi` dict for `ImageData` will be: + ``{'angle':(...),'vertical':(...),'horizontal':(...)}`` + + To skip files or to change number of files to load, + adjust ``vertical``. E.g. ``'vertical': (100, 300)`` will skip first 100 files + and will load 200 files. ''' # check if file exists @@ -92,7 +119,7 @@ def set_up(self, raise FileNotFoundError('{}'.format(file_name)) file_type = os.path.basename(file_name).split('.')[-1].lower() - if file_type not in ['txrm','txm']: + if file_type not in ['txrm', 'txm']: raise TypeError('This reader can only process TXRM or TXM files. Got {}'.format(os.path.basename(file_name))) self.file_name = file_name diff --git a/Wrappers/Python/cil/recon/FBP.py b/Wrappers/Python/cil/recon/FBP.py index 85cf2493d..3ee188bc5 100644 --- a/Wrappers/Python/cil/recon/FBP.py +++ b/Wrappers/Python/cil/recon/FBP.py @@ -93,13 +93,13 @@ def set_filter_inplace(self, inplace=False): Parameters ---------- - inplace: boolian + inplace: boolean Sets the inplace filtering of projections """ if type(inplace) is bool: self._filter_inplace= inplace else: - raise TypeError("set_filter_inplace expected a boolian. Got {}".format(type(inplace))) + raise TypeError("set_filter_inplace expected a boolean. Got {}".format(type(inplace))) def _default_fft_order(self): @@ -372,7 +372,7 @@ def run(self, out=None, verbose=1): out : ImageData, optional Fills the referenced ImageData with the reconstructed volume and suppresses the return verbose : int, default=1 - Contols the verbosity of the reconstructor. 0: No output is logged, 1: Full configuration is logged + Controls the verbosity of the reconstructor. 0: No output is logged, 1: Full configuration is logged Returns ------- @@ -442,7 +442,7 @@ class FBP(GenericFilteredBackProjection): Notes ----- - The reconstructor can be futher customised using additional 'set' methods provided. + The reconstructor can be further customised using additional 'set' methods provided. """ supported_backends = ['tigre', 'astra'] @@ -528,7 +528,7 @@ def run(self, out=None, verbose=1): Fills the referenced ImageData with the reconstructed volume and suppresses the return verbose : int, default=1 - Contols the verbosity of the reconstructor. 0: No output is logged, 1: Full configuration is logged + Controls the verbosity of the reconstructor. 0: No output is logged, 1: Full configuration is logged Returns ------- diff --git a/Wrappers/Python/test/test_NexusReaderWriter.py b/Wrappers/Python/test/test_NexusReaderWriter.py index 414d8ce38..51a14456d 100644 --- a/Wrappers/Python/test/test_NexusReaderWriter.py +++ b/Wrappers/Python/test/test_NexusReaderWriter.py @@ -166,4 +166,3 @@ def readAcquisitionDataAndTest(self): assert ag3d == self.ag3d - diff --git a/Wrappers/Python/test/test_tiff_readerwriter.py b/Wrappers/Python/test/test_tiff_readerwriter.py index 0f41b5d58..7f0c8946a 100644 --- a/Wrappers/Python/test/test_tiff_readerwriter.py +++ b/Wrappers/Python/test/test_tiff_readerwriter.py @@ -134,4 +134,4 @@ class Fake(object): fake = Fake() fake.shape = (36,11,10) acq = reader.read_as_ImageData(fake) - + \ No newline at end of file diff --git a/docs/source/developer_guide.rst b/docs/source/developer_guide.rst index 16434fc0d..91b5b3504 100644 --- a/docs/source/developer_guide.rst +++ b/docs/source/developer_guide.rst @@ -22,7 +22,7 @@ Creator To create an instance of a class, the creator of a class should require the **essential** and **often-configured** parameters as named parameters. -It should not accept positional arguments `*args` or keyworded arguments `**kwargs` so that the user can clearly understand what parameters are necessary to +It should not accept positional arguments `*args` or key-worded arguments `**kwargs` so that the user can clearly understand what parameters are necessary to create the instance. Setter methods and properties diff --git a/docs/source/framework.rst b/docs/source/framework.rst index 2fb930695..a3c308178 100644 --- a/docs/source/framework.rst +++ b/docs/source/framework.rst @@ -2,7 +2,7 @@ Framework ********* -AcquisitonGeometry +AcquisitionGeometry ================== The :code:`AcquisitionGeometry` class holds the system acquisition parameters. @@ -73,7 +73,7 @@ BlockGeometry Data Containers =============== -:code:`AcquisiionData` and :code:`ImageData` inherit from the same parent :code:`DataContainer` class, +:code:`AcquisitionData` and :code:`ImageData` inherit from the same parent :code:`DataContainer` class, therefore they largely behave the same way. There are algebraic operations defined for both :code:`AcquisitionData` and :code:`ImageData`. diff --git a/docs/source/index.rst b/docs/source/index.rst index 6e277332a..e8f712bc2 100755 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -19,7 +19,7 @@ operators and functions as well a collection of useful example operators and functions. Both smooth and non-smooth functions can be used. Further, it provides a number of high-level generic implementations of -optimisation algorithms to solve genericlly formulated optimisation problems +optimisation algorithms to solve generically formulated optimisation problems constructed from operator and function objects. Demos and Examples diff --git a/docs/source/introduction.rst b/docs/source/introduction.rst index c4ffbbec6..3d859967e 100644 --- a/docs/source/introduction.rst +++ b/docs/source/introduction.rst @@ -9,7 +9,7 @@ The framework comprises: * :code:`cil.io` module which provides a number of loaders for real CT machines, e.g. Nikon. It also provides reader and writer to save to NeXuS file format. * :code:`cil.optimisation` module allows the user to create iterative methods to reconstruct acquisition data applying different types of regularisation, which better suit the data characteristics. * :code:`cil.plugins` module which allows CIL to use selected functionality from ASTRA, TIGRE, TomoPhantom and the Regularisation Toolkit -* :code:`cil.processors` module contains tools for data manipulation and common CT pre-processoing steps +* :code:`cil.processors` module contains tools for data manipulation and common CT pre-processing steps * :code:`cil.recon` module contains an optimised FDK/FBP reconstructors, making using the both CIL accelerated libraries and the Tigre/ASTRA back-projectors * :code:`cil.utilities` module contains a selection of display tools for 2D and 3D data, as well as real and simulated test datasets @@ -17,7 +17,7 @@ The framework comprises: CT Geometry ========== -Please refer to `this `_ notebook on the CIL-Demos +Please refer to `this `_ notebook on the CIL-Demos repository for full description. @@ -115,7 +115,7 @@ where, * :math:`\alpha` is the regularisation parameter * :math:`L` is a regularisation operator -The first term measures the fidelity of the solution to the data. The second term meausures the +The first term measures the fidelity of the solution to the data. The second term measures the fidelity to the prior knowledge we have imposed on the system, operator :math:`L`. This can be re-written equivalently in the block matrix form: diff --git a/docs/source/io.rst b/docs/source/io.rst index 2a7c83f68..5d6aafaa3 100644 --- a/docs/source/io.rst +++ b/docs/source/io.rst @@ -15,17 +15,17 @@ as NeXuS files. # initialise NEXUS Writer writer = NEXUSDataWriter() - writer.set_up(file_name='tmp_nexus.nxs', - data_container=my_data) + writer.set_up(data=my_data, + file_name='tmp_nexus.nxs') # write data - writer.write_file() + writer.write() # read data # initialize NEXUS reader reader = NEXUSDataReader() - reader.set_up(nexus_file='tmp_nexus.nxs') + reader.set_up(file_name='tmp_nexus.nxs') # load data - ad1 = reader.load_data() + ad1 = reader.read() # get AcquisitionGeometry ag1 = reader.get_geometry() @@ -34,21 +34,20 @@ as NeXuS files. :inherited-members: .. autoclass:: cil.io.NEXUSDataWriter :members: - :special-members: + :inherited-members: | Nikon ===== .. autoclass:: cil.io.NikonDataReader :members: - :special-members: + :inherited-members: ZEISS ===== - -.. autoclass:: cil.io.TXRMDataReader +.. autoclass:: cil.io.ZEISSDataReader :members: - :special-members: + :inherited-members: TIFF Reader/Writer ================== diff --git a/docs/source/optimisation.rst b/docs/source/optimisation.rst index fa5539d3b..a3b5c571d 100644 --- a/docs/source/optimisation.rst +++ b/docs/source/optimisation.rst @@ -380,7 +380,7 @@ where, * :math:`\alpha` is the regularisation parameter * :math:`L` is a regularisation operator -The first term measures the fidelity of the solution to the data. The second term meausures the +The first term measures the fidelity of the solution to the data. The second term measures the fidelity to the prior knowledge we have imposed on the system, operator :math:`L`. This can be re-written equivalently in the block matrix form: diff --git a/docs/source/processors.rst b/docs/source/processors.rst index 32fb5be4f..078e4d747 100644 --- a/docs/source/processors.rst +++ b/docs/source/processors.rst @@ -64,7 +64,7 @@ Centre Of Rotation Corrector ---------------------------- In the ideal alignment of a CT instrument, the projection of the axis of rotation onto the -detector coincides with the vertical midline of the detector. In prtactise this is hard to acheive +detector coincides with the vertical midline of the detector. In practice this is hard to achieve due to misalignments and/or kinematic errors in positioning of CT instrument components. A slight offset of the center of rotation with respect to the theoretical position will contribute to the loss of resolution; in more severe cases, it will cause severe artifacts in the reconstructed From 6049b62d74501181a25e8b552eff723b9ed16a46 Mon Sep 17 00:00:00 2001 From: Laura Murgatroyd <60604372+lauramurgatroyd@users.noreply.github.com> Date: Fri, 10 Mar 2023 15:56:10 +0000 Subject: [PATCH 02/12] Remove deprecated code and deprecate int compression (#1440) * removing deprecated code * deprecate use of integer compression in NEXUSDataWriter * remove axpby tests * Fix PowerMethod unit tests --- CHANGELOG.md | 3 + Wrappers/Python/cil/framework/framework.py | 15 --- Wrappers/Python/cil/io/NEXUSDataWriter.py | 10 +- .../cil/optimisation/algorithms/Algorithm.py | 29 ++--- .../cil/optimisation/algorithms/PDHG.py | 4 - .../cil/optimisation/algorithms/SPDHG.py | 9 +- .../cil/optimisation/operators/Operator.py | 2 +- Wrappers/Python/test/test_DataContainer.py | 110 ------------------ Wrappers/Python/test/test_Operator.py | 3 +- Wrappers/Python/test/test_io.py | 2 +- 10 files changed, 25 insertions(+), 162 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 67ef7fc1c..49405d437 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,9 @@ * x.x.x - Partitioner is now able to create batches even if angle is not the outer dimension - Renamed `max_iteration_stop_cryterion` method in the Algorithm class to `max_iteration_stop_criterion` + - Removed (previously deprecated) `very_verbose` parameter in `Algorithm`'s run method. + - Removed (previously deprecated) `axpby` method in DataContainer. + - Deprecate use of integer compression in NEXUSDataWriter. - Improved and tidied up documentation for all readers and writers, including hiding special members. - Use arguments instead of kwargs in all readers and writers with multiple kwargs, making documentation easier. diff --git a/Wrappers/Python/cil/framework/framework.py b/Wrappers/Python/cil/framework/framework.py index 42cb31957..9bcf86159 100644 --- a/Wrappers/Python/cil/framework/framework.py +++ b/Wrappers/Python/cil/framework/framework.py @@ -3123,14 +3123,6 @@ def sapyb(self, a, y, b, out=None, num_threads=NUM_THREADS): if ret_out: return out - - def axpby(self, a, b, y, out, dtype=numpy.float32, num_threads=NUM_THREADS): - '''Deprecated. Alias of _axpby''' - warnings.warn('The use of axpby is deprecated and will be removed in following version. Use sapyb instead', - DeprecationWarning) - self._axpby(a,b,y,out, dtype, num_threads) - - def _axpby(self, a, b, y, out, dtype=numpy.float32, num_threads=NUM_THREADS): '''performs axpby with cilacc C library, can be done in-place. @@ -3396,10 +3388,6 @@ def __init__(self, geometry=None, **kwargs): - if not kwargs.get('suppress_warning', False): - warnings.warn('Direct invocation is deprecated and will be removed in following version. Use allocate from ImageGeometry instead', - DeprecationWarning) - dtype = kwargs.get('dtype', numpy.float32) @@ -3570,9 +3558,6 @@ def __init__(self, deep_copy=True, geometry = None, **kwargs): - if not kwargs.get('suppress_warning', False): - warnings.warn('Direct invocation is deprecated and will be removed in following version. Use allocate from AcquisitionGeometry instead', - DeprecationWarning) dtype = kwargs.get('dtype', numpy.float32) diff --git a/Wrappers/Python/cil/io/NEXUSDataWriter.py b/Wrappers/Python/cil/io/NEXUSDataWriter.py index c781300cc..2b278ccb2 100644 --- a/Wrappers/Python/cil/io/NEXUSDataWriter.py +++ b/Wrappers/Python/cil/io/NEXUSDataWriter.py @@ -37,12 +37,12 @@ class NEXUSDataWriter(object): The dataset to write to file file_name: os.path or string, default None The file name to write - compression: int, default 0 - The lossy compression to apply, default 0 will not compress data. - 8 or 16 will compress to 8 and 16 bit dtypes respectively. + compression: str, {'uint8', 'uint16', None}, default None + The lossy compression to apply, default None will not compress data. + uint8 or unit16 will compress to 8 and 16 bit dtypes respectively. ''' - def __init__(self, data=None, file_name=None, compression=0): + def __init__(self, data=None, file_name=None, compression=None): self.data = data self.file_name = file_name @@ -53,7 +53,7 @@ def __init__(self, data=None, file_name=None, compression=0): def set_up(self, data = None, file_name = None, - compression = 0): + compression = None): ''' Set up the writer diff --git a/Wrappers/Python/cil/optimisation/algorithms/Algorithm.py b/Wrappers/Python/cil/optimisation/algorithms/Algorithm.py index ccde7faaf..07e173a39 100644 --- a/Wrappers/Python/cil/optimisation/algorithms/Algorithm.py +++ b/Wrappers/Python/cil/optimisation/algorithms/Algorithm.py @@ -44,7 +44,7 @@ def __init__(self, **kwargs): :param max_iteration: maximum number of iterations :type max_iteration: int, optional, default 0 - :param update_objectice_interval: the interval every which we would save the current\ + :param update_objective_interval: the interval every which we would save the current\ objective. 1 means every iteration, 2 every 2 iteration\ and so forth. This is by default 1 and should be increased\ when evaluating the objective is computationally expensive. @@ -75,7 +75,7 @@ def update(self): def should_stop(self): '''default stopping criterion: number of iterations - The user can change this in concrete implementatition of iterative algorithms.''' + The user can change this in concrete implementation of iterative algorithms.''' return self.max_iteration_stop_criterion() def __set_up_logger(self, fname): @@ -246,26 +246,21 @@ def run(self, iterations=None, verbose=1, callback=None, **kwargs): screen. Notice that printing will not evaluate the objective function and so the print might be out of sync wrt the calculation of the objective. In such cases nan will be printed. - :param very_verbose: deprecated bool, useful for algorithms with primal and dual objectives (PDHG), - prints to screen both primal and dual ''' print_interval = kwargs.get('print_interval', self.update_objective_interval) if print_interval > self.update_objective_interval: print_interval = self.update_objective_interval - if isinstance(verbose, bool): - very_verbose = kwargs.get('very_verbose', False) + if verbose == 0: + verbose = False + very_verbose = False + elif verbose == 1: + verbose = True + very_verbose = False + elif verbose == 2: + verbose = True + very_verbose = True else: - if verbose == 0: - verbose = False - very_verbose = False - elif verbose == 1: - verbose = True - very_verbose = False - elif verbose == 2: - verbose = True - very_verbose = True - else: - raise ValueError("verbose should be 0, 1 or 2. Got {}".format (verbose)) + raise ValueError("verbose should be 0, 1 or 2. Got {}".format (verbose)) if self.should_stop(): print ("Stop criterion has been reached.") if iterations is None : diff --git a/Wrappers/Python/cil/optimisation/algorithms/PDHG.py b/Wrappers/Python/cil/optimisation/algorithms/PDHG.py index d26b889ec..1c61bbf20 100644 --- a/Wrappers/Python/cil/optimisation/algorithms/PDHG.py +++ b/Wrappers/Python/cil/optimisation/algorithms/PDHG.py @@ -223,10 +223,6 @@ def __init__(self, f, g, operator, tau=None, sigma=None,initial=None, **kwargs): super(PDHG, self).__init__(**kwargs) - if kwargs.get('use_axpby', None) is not None: - warnings.warn('The use of the "use_axpby" parameter is deprecated and will not be used by this algorithm', - DeprecationWarning, stacklevel=4) - self._tau = None self._sigma = None diff --git a/Wrappers/Python/cil/optimisation/algorithms/SPDHG.py b/Wrappers/Python/cil/optimisation/algorithms/SPDHG.py index d724f7155..f04ed907d 100644 --- a/Wrappers/Python/cil/optimisation/algorithms/SPDHG.py +++ b/Wrappers/Python/cil/optimisation/algorithms/SPDHG.py @@ -60,7 +60,7 @@ class SPDHG(Algorithm): Note ---- - Convergence is guaranted provided that [2, eq. (12)]: + Convergence is guaranteed provided that [2, eq. (12)]: .. math:: @@ -70,7 +70,7 @@ class SPDHG(Algorithm): ---- Notation for primal and dual step-sizes are reversed with comparison - to PDGH.py + to PDHG.py Note ---- @@ -97,11 +97,6 @@ def __init__(self, f=None, g=None, operator=None, tau=None, sigma=None, super(SPDHG, self).__init__(**kwargs) - if kwargs.get('use_axpby', None) is not None: - warnings.warn('The use of the "use_axpby" parameter is deprecated and will not be used by this algorithm', - DeprecationWarning, stacklevel=4) - - if f is not None and operator is not None and g is not None: self.set_up(f=f, g=g, operator=operator, tau=tau, sigma=sigma, initial=initial, prob=prob, gamma=gamma, norms=kwargs.get('norms', None)) diff --git a/Wrappers/Python/cil/optimisation/operators/Operator.py b/Wrappers/Python/cil/optimisation/operators/Operator.py index dd24d4962..9da61280d 100644 --- a/Wrappers/Python/cil/optimisation/operators/Operator.py +++ b/Wrappers/Python/cil/optimisation/operators/Operator.py @@ -139,7 +139,7 @@ def adjoint(self,x, out=None): raise NotImplementedError @staticmethod - def PowerMethod(operator, max_iteration=10, initial=None, tolerance = 1e-5, return_all=False, **deprecated_args): + def PowerMethod(operator, max_iteration=10, initial=None, tolerance = 1e-5, return_all=False): r"""Power method or Power iteration algorithm diff --git a/Wrappers/Python/test/test_DataContainer.py b/Wrappers/Python/test/test_DataContainer.py index addd8941b..c73c0f2ee 100755 --- a/Wrappers/Python/test/test_DataContainer.py +++ b/Wrappers/Python/test/test_DataContainer.py @@ -804,116 +804,6 @@ def test_multiply_out(self): numpy.testing.assert_allclose(u.as_array(), c) - def test_axpby(self): - ig = ImageGeometry(10,10) - d1 = ig.allocate(1) - d2 = ig.allocate(2) - out = ig.allocate(None) - a = 2 - b = 1 - # equals to 2 * [1] + 1 * [2] = [4] - d1.axpby(a,b,d2,out) - res = numpy.ones_like(d1.as_array()) * 4. - numpy.testing.assert_allclose(res, out.as_array()) - - - def test_axpby2(self): - N = 100 - ig = ImageGeometry(N,2*N,N*10) - d1 = ig.allocate(1) - d2 = ig.allocate(2) - out = ig.allocate(None) - a = 2 - b = 1 - # equals to 2 * [1] + 1 * [2] = [4] - d1.axpby(a,b,d2,out, num_threads=4) - res = numpy.ones_like(d1.as_array()) * 4. - numpy.testing.assert_allclose(res, out.as_array()) - - - def test_axpby3(self): - #a vec, b float - ig = ImageGeometry(10,10) - d1 = ig.allocate(1) - d2 = ig.allocate(2) - a = ig.allocate(2) - b = 1 - out = ig.allocate(None) - # equals to 2 * [1] + 1 * [2] = [4] - d1.axpby(a,b,d2,out) - res = numpy.ones_like(d1.as_array()) * 4. - numpy.testing.assert_allclose(res, out.as_array()) - - - def test_axpby4(self): - #a float, b vec - ig = ImageGeometry(10,10) - d1 = ig.allocate(1) - d2 = ig.allocate(2) - a = 2 - b = ig.allocate(1) - out = ig.allocate(None) - # equals to 2 * [1] + 1 * [2] = [4] - d1.axpby(a,b,d2,out) - res = numpy.ones_like(d1.as_array()) * 4. - numpy.testing.assert_allclose(res, out.as_array()) - - - def test_axpby5(self): - #a vec, b vec - ig = ImageGeometry(10,10) - d1 = ig.allocate(1) - d2 = ig.allocate(2) - a = ig.allocate(2) - b = ig.allocate(1) - out = ig.allocate(None) - # equals to 2 * [1] + 1 * [2] = [4] - d1.axpby(a,b,d2,out) - res = numpy.ones_like(d1.as_array()) * 4. - numpy.testing.assert_allclose(res, out.as_array()) - - - def test_axpby6(self): - #a vec, b vec - ig = ImageGeometry(10,10) - d1 = ig.allocate() - d2 = ig.allocate() - a = ig.allocate() - b = ig.allocate() - - d1.fill(numpy.arange(1,101).reshape(10,10)) - d2.fill(numpy.arange(1,101).reshape(10,10)) - a.fill(1.0/d1.as_array()) - b.fill(-1.0/d2.as_array()) - - out = ig.allocate(None) - # equals to 1 + -1 = 0 - d1.axpby(a,b,d2,out) - res = numpy.zeros_like(d1.as_array()) - numpy.testing.assert_allclose(res, out.as_array()) - - - def test_axpby7(self): - #a vec, b vec - #daxpby - ig = ImageGeometry(10,10) - d1 = ig.allocate() - d2 = ig.allocate() - a = ig.allocate() - b = ig.allocate() - - d1.fill(numpy.arange(1,101).reshape(10,10)) - d2.fill(numpy.arange(1,101).reshape(10,10)) - a.fill(1.0/d1.as_array()) - b.fill(-1.0/d2.as_array()) - - out = ig.allocate(dtype=numpy.float64) - # equals to 1 + -1 = 0 - d1.axpby(a,b,d2,out, dtype=numpy.float64) - res = numpy.zeros_like(d1.as_array()) - numpy.testing.assert_allclose(res, out.as_array()) - - def test_sapyb_datacontainer_f(self): #a vec, b vec diff --git a/Wrappers/Python/test/test_Operator.py b/Wrappers/Python/test/test_Operator.py index 08f380f8e..16d56b8fd 100644 --- a/Wrappers/Python/test/test_Operator.py +++ b/Wrappers/Python/test/test_Operator.py @@ -479,7 +479,7 @@ def test_SymmetrisedGradientOperator2a(self): Grad2 = GradientOperator(self.ig2, correlation = 'Space', backend='numpy') E2 = SymmetrisedGradientOperator(Grad2.range_geometry()) - norm = LinearOperator.PowerMethod(E2, max_iterations=self.iterations) + norm = LinearOperator.PowerMethod(E2, max_iteration=self.iterations) numpy.testing.assert_almost_equal(norm, numpy.sqrt(8), decimal = self.decimal) @@ -994,4 +994,3 @@ def test_CompositionOperator_adjoint7(self): 2 * out2.as_array()) numpy.testing.assert_array_almost_equal(d_out.as_array(), 2 * out2.as_array()) - diff --git a/Wrappers/Python/test/test_io.py b/Wrappers/Python/test/test_io.py index c22fc6c34..463cc3ca5 100644 --- a/Wrappers/Python/test/test_io.py +++ b/Wrappers/Python/test/test_io.py @@ -518,4 +518,4 @@ def test_read_to(self): data_partial_by_hand[subset] = data_full.array[subset] HDF5_utilities.read_to(self.path, self.dset_path, data_partial, source_sel=subset, dest_sel=subset) - np.testing.assert_allclose(data_partial_by_hand,data_partial) \ No newline at end of file + np.testing.assert_allclose(data_partial_by_hand,data_partial) From 1f32510bc7f86a079fcd7f6f119c7b12a9b0fa87 Mon Sep 17 00:00:00 2001 From: Laura Murgatroyd <60604372+lauramurgatroyd@users.noreply.github.com> Date: Tue, 14 Mar 2023 09:34:48 +0000 Subject: [PATCH 03/12] Correct names of methods in acquisition geom docstring (#1449) Signed-off-by: Laura Murgatroyd <60604372+lauramurgatroyd@users.noreply.github.com> --- Wrappers/Python/cil/framework/framework.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Wrappers/Python/cil/framework/framework.py b/Wrappers/Python/cil/framework/framework.py index 9bcf86159..863751d38 100644 --- a/Wrappers/Python/cil/framework/framework.py +++ b/Wrappers/Python/cil/framework/framework.py @@ -2012,9 +2012,9 @@ class AcquisitionGeometry(object): `AcquisitionGeometry.create_Parallel2D()` - `AcquisitionGeometry.create_Cone3D()` + `AcquisitionGeometry.create_Cone2D()` - `AcquisitionGeometry.create_Parallel2D()` + `AcquisitionGeometry.create_Parallel3D()` `AcquisitionGeometry.create_Cone3D()` """ @@ -4067,4 +4067,4 @@ def check_order_for_engine(engine, geometry): - \ No newline at end of file + From 82c0f1671830b4706f0a178560021d1c94f7dd90 Mon Sep 17 00:00:00 2001 From: Edoardo Pasca Date: Tue, 14 Mar 2023 09:35:12 +0000 Subject: [PATCH 04/12] Update TIFF.py (#1451) * Update TIFF.py closes #1450 Signed-off-by: Edoardo Pasca * Update Wrappers/Python/cil/io/TIFF.py Signed-off-by: Laura Murgatroyd <60604372+lauramurgatroyd@users.noreply.github.com> --------- Signed-off-by: Edoardo Pasca Signed-off-by: Laura Murgatroyd <60604372+lauramurgatroyd@users.noreply.github.com> Co-authored-by: Laura Murgatroyd <60604372+lauramurgatroyd@users.noreply.github.com> --- Wrappers/Python/cil/io/TIFF.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Wrappers/Python/cil/io/TIFF.py b/Wrappers/Python/cil/io/TIFF.py index 16f30c047..c537a53c3 100644 --- a/Wrappers/Python/cil/io/TIFF.py +++ b/Wrappers/Python/cil/io/TIFF.py @@ -255,7 +255,7 @@ class TIFFStackReader(object): Alternatively, if TIFFWriter has been used to save data with lossy compression, then you can rescale the read data to approximately the original data with the following code: - >>> writer = TIFFWriter(file_name = '/path/to/folder', compression=8) + >>> writer = TIFFWriter(file_name = '/path/to/folder', compression='uint8') >>> writer.write(original_data) >>> reader = TIFFStackReader(file_name = '/path/to/folder') >>> about_original_data = reader.read_rescaled() From 0fa149a1c09cae1f5b6648a369b38117e83dd280 Mon Sep 17 00:00:00 2001 From: Gemma Fardell <47746591+gfardell@users.noreply.github.com> Date: Tue, 14 Mar 2023 17:02:33 +0000 Subject: [PATCH 05/12] New build variants Signed-off-by: Gemma Fardell <47746591+gfardell@users.noreply.github.com> --- recipe/conda_build_config.yaml | 26 +++++++++++++++++++------- recipe/meta.yaml | 13 +++++++------ 2 files changed, 26 insertions(+), 13 deletions(-) diff --git a/recipe/conda_build_config.yaml b/recipe/conda_build_config.yaml index 5a2373e1d..9be3cda5e 100644 --- a/recipe/conda_build_config.yaml +++ b/recipe/conda_build_config.yaml @@ -1,22 +1,34 @@ #creates pairs of versions using zip_keys, lists must be the same length python: - - 3.8 - - 3.8 - 3.8 - 3.9 + - 3.10 + - 3.8 - 3.9 + - 3.10 + - 3.8 - 3.9 - - 3.10 - 3.10 + # - 3.11 + # - 3.8 + # - 3.9 + # - 3.10 + # - 3.11 numpy: - - 1.20 - 1.21 - - 1.22 - - 1.20 - 1.21 - - 1.22 - 1.21 - 1.22 + - 1.22 + - 1.22 + - 1.23 + - 1.23 + - 1.23 + # - 1.23 + # - 1.24 + # - 1.24 + # - 1.24 + # - 1.24 zip_keys: - python - numpy diff --git a/recipe/meta.yaml b/recipe/meta.yaml index 111e64148..8f273c5ef 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -18,16 +18,16 @@ build: test: requires: - python-wget - - cvxpy # [ linux and not py36] + - cvxpy # [ linux ] - scikit-image - tomophantom=2.0.0 # [ linux ] - - tigre =2.2 # [ not osx ] + - tigre=2.4 # [ not osx ] - packaging - - ccpi-regulariser=21.0.0 # [ not osx ] + - ccpi-regulariser=22.0.0 # [ not osx ] - astra-toolbox>=1.9.9.dev5,<2.1 source_files: - - ./Wrappers/Python/test # [win] + - ./Wrappers/Python/test # [win] - ./Wrappers/Python/test # [not win] commands: @@ -39,6 +39,7 @@ requirements: build: - python - numpy {{ numpy }} + - pip - setuptools - cmake # [not osx] - cmake >=3.16 # [osx] @@ -77,8 +78,8 @@ requirements: run_constrained: - tomophantom=2.0.0 - astra-toolbox>=1.9.9.dev5,<2.1 - - tigre=2.2 - - ccpi-regulariser=21.0.0 + - tigre=2.4 + - ccpi-regulariser=22.0.0 - ipywidgets <8 about: From e1a7879adf897a14d7c0b8d8b18b626d69463ce6 Mon Sep 17 00:00:00 2001 From: Laura Murgatroyd <60604372+lauramurgatroyd@users.noreply.github.com> Date: Fri, 17 Mar 2023 13:03:36 +0000 Subject: [PATCH 06/12] Update CIL License Headers (#1453) * Licensing headers * update readme * header issues * Update change log [ci skip] * update cil-astra headers --- .github/workflows/conda_and_docs_build.yml | 19 +++++ CHANGELOG.md | 1 + CMakeLists.txt | 19 +++++ NOTICE.txt | 74 ++++++++++++++----- Wrappers/Python/CMake/parse_git_describe.py | 19 +++++ Wrappers/Python/CMake/setup.py.in | 32 ++++---- Wrappers/Python/CMake/sp_dir.py | 19 +++++ Wrappers/Python/CMake/version.py.in | 19 +++++ Wrappers/Python/CMakeLists.txt | 19 +++++ Wrappers/Python/cil/__init__.py | 32 ++++---- .../cil/framework/BlockDataContainer.py | 31 ++++---- .../Python/cil/framework/BlockGeometry.py | 32 ++++---- Wrappers/Python/cil/framework/__init__.py | 31 ++++---- Wrappers/Python/cil/framework/framework.py | 31 ++++---- Wrappers/Python/cil/io/NEXUSDataReader.py | 32 ++++---- Wrappers/Python/cil/io/NEXUSDataWriter.py | 31 ++++---- Wrappers/Python/cil/io/NikonDataReader.py | 31 ++++---- Wrappers/Python/cil/io/RAWFileWriter.py | 34 ++++----- Wrappers/Python/cil/io/TIFF.py | 32 ++++---- Wrappers/Python/cil/io/ZEISSDataReader.py | 39 +++++----- Wrappers/Python/cil/io/__init__.py | 31 ++++---- Wrappers/Python/cil/io/utilities.py | 33 +++++---- Wrappers/Python/cil/optimisation/__init__.py | 32 ++++---- .../cil/optimisation/algorithms/ADMM.py | 32 ++++---- .../cil/optimisation/algorithms/Algorithm.py | 32 ++++---- .../cil/optimisation/algorithms/CGLS.py | 32 ++++---- .../cil/optimisation/algorithms/FISTA.py | 32 ++++---- .../Python/cil/optimisation/algorithms/GD.py | 32 ++++---- .../cil/optimisation/algorithms/PDHG.py | 32 ++++---- .../cil/optimisation/algorithms/SIRT.py | 31 ++++---- .../cil/optimisation/algorithms/SPDHG.py | 32 ++++---- .../cil/optimisation/algorithms/__init__.py | 31 ++++---- .../optimisation/functions/BlockFunction.py | 32 ++++---- .../cil/optimisation/functions/Function.py | 32 ++++---- .../optimisation/functions/IndicatorBox.py | 37 +++++----- .../optimisation/functions/KullbackLeibler.py | 32 ++++---- .../cil/optimisation/functions/L1Norm.py | 32 ++++---- .../optimisation/functions/L2NormSquared.py | 32 ++++---- .../optimisation/functions/LeastSquares.py | 32 ++++---- .../optimisation/functions/MixedL21Norm.py | 32 ++++---- .../functions/OperatorCompositionFunction.py | 32 ++++---- .../cil/optimisation/functions/Rosenbrock.py | 32 ++++---- .../optimisation/functions/TotalVariation.py | 33 +++++---- .../cil/optimisation/functions/__init__.py | 32 ++++---- .../optimisation/operators/BlockOperator.py | 32 ++++---- .../operators/BlurringOperator.py | 32 ++++---- .../operators/ChannelwiseOperator.py | 32 ++++---- .../operators/DiagonalOperator.py | 32 ++++---- .../operators/FiniteDifferenceOperator.py | 41 +++++----- .../operators/GradientOperator.py | 32 ++++---- .../operators/IdentityOperator.py | 32 ++++---- .../optimisation/operators/MaskOperator.py | 32 ++++---- .../optimisation/operators/MatrixOperator.py | 32 ++++---- .../cil/optimisation/operators/Operator.py | 32 ++++---- .../optimisation/operators/ProjectionMap.py | 19 +++++ .../SparseFiniteDifferenceOperator.py | 32 ++++---- .../operators/SymmetrisedGradientOperator.py | 32 ++++---- .../optimisation/operators/ZeroOperator.py | 32 ++++---- .../cil/optimisation/operators/__init__.py | 32 ++++---- Wrappers/Python/cil/plugins/TomoPhantom.py | 32 ++++---- Wrappers/Python/cil/plugins/__init__.py | 32 ++++---- Wrappers/Python/cil/plugins/astra/__init__.py | 9 ++- .../astra/operators/AstraProjector2D.py | 7 +- .../astra/operators/AstraProjector3D.py | 7 +- .../astra/operators/ProjectionOperator.py | 7 +- .../cil/plugins/astra/operators/__init__.py | 7 +- .../astra/processors/AstraBackProjector2D.py | 7 +- .../astra/processors/AstraBackProjector3D.py | 7 +- .../processors/AstraForwardProjector2D.py | 7 +- .../processors/AstraForwardProjector3D.py | 7 +- .../cil/plugins/astra/processors/FBP.py | 7 +- .../plugins/astra/processors/FBP_Flexible.py | 7 +- .../plugins/astra/processors/FDK_Flexible.py | 7 +- .../cil/plugins/astra/processors/__init__.py | 7 +- .../cil/plugins/astra/utilities/__init__.py | 7 +- .../utilities/convert_geometry_to_astra.py | 7 +- .../convert_geometry_to_astra_vec_2D.py | 7 +- .../convert_geometry_to_astra_vec_3D.py | 7 +- .../plugins/ccpi_regularisation/__init__.py | 32 ++++---- .../ccpi_regularisation/functions/__init__.py | 32 ++++---- .../functions/regularisers.py | 32 ++++---- Wrappers/Python/cil/plugins/tigre/FBP.py | 7 +- Wrappers/Python/cil/plugins/tigre/Geometry.py | 7 +- .../cil/plugins/tigre/ProjectionOperator.py | 7 +- Wrappers/Python/cil/plugins/tigre/__init__.py | 32 ++++---- .../AbsorptionTransmissionConverter.py | 32 ++++---- Wrappers/Python/cil/processors/Binner.py | 32 ++++---- .../processors/CentreOfRotationCorrector.py | 32 ++++---- .../cil/processors/CofR_image_sharpness.py | 32 ++++---- .../cil/processors/CofR_xcorrelation.py | 32 ++++---- .../Python/cil/processors/MaskGenerator.py | 32 ++++---- Wrappers/Python/cil/processors/Masker.py | 32 ++++---- Wrappers/Python/cil/processors/Normaliser.py | 32 ++++---- Wrappers/Python/cil/processors/Padder.py | 32 ++++---- Wrappers/Python/cil/processors/RingRemover.py | 32 ++++---- Wrappers/Python/cil/processors/Slicer.py | 31 ++++---- .../TransmissionAbsorptionConverter.py | 32 ++++---- Wrappers/Python/cil/processors/__init__.py | 32 ++++---- .../Python/cil/processors/cilacc_binner.py | 19 +++++ Wrappers/Python/cil/recon/FBP.py | 31 ++++---- Wrappers/Python/cil/recon/Reconstructor.py | 32 ++++---- Wrappers/Python/cil/recon/__init__.py | 32 ++++---- Wrappers/Python/cil/utilities/__init__.py | 32 ++++---- Wrappers/Python/cil/utilities/dataexample.py | 32 ++++---- Wrappers/Python/cil/utilities/display.py | 33 +++++---- .../Python/cil/utilities/jupyter/__init__.py | 33 +++++---- .../Python/cil/utilities/multiprocessing.py | 32 ++++---- Wrappers/Python/cil/utilities/noise.py | 31 ++++---- .../Python/cil/utilities/quality_measures.py | 32 ++++---- Wrappers/Python/environment.yml | 18 +++++ Wrappers/Python/test/__init__.py | 9 ++- .../Python/test/test_AcquisitionGeometry.py | 7 +- .../Python/test/test_BlockDataContainer.py | 7 +- Wrappers/Python/test/test_BlockOperator.py | 7 +- Wrappers/Python/test/test_CIL_CVXPy.py | 7 +- Wrappers/Python/test/test_DataContainer.py | 7 +- Wrappers/Python/test/test_DataProcessor.py | 7 +- Wrappers/Python/test/test_Gradient.py | 7 +- Wrappers/Python/test/test_ISTA_algorithm.py | 32 ++++---- .../Python/test/test_NexusReaderWriter.py | 8 +- Wrappers/Python/test/test_Operator.py | 7 +- Wrappers/Python/test/test_PluginsAstra_CPU.py | 7 +- Wrappers/Python/test/test_PluginsAstra_FBP.py | 7 +- Wrappers/Python/test/test_PluginsAstra_GPU.py | 7 +- .../Python/test/test_PluginsAstra_Geometry.py | 7 +- .../test_PluginsAstra_ProjectorConsistency.py | 7 +- .../test/test_PluginsAstra_Projectors.py | 7 +- .../Python/test/test_PluginsRegularisation.py | 7 +- Wrappers/Python/test/test_PluginsTigre_FBP.py | 7 +- .../Python/test/test_PluginsTigre_General.py | 7 +- .../Python/test/test_PluginsTigre_Siddon.py | 7 +- .../test/test_PluginsTigre_interpolated.py | 7 +- .../Python/test/test_PluginsTomoPhantom.py | 7 +- Wrappers/Python/test/test_SIRF.py | 7 +- Wrappers/Python/test/test_SumFunction.py | 7 +- .../Python/test/test_TranslateFunction.py | 7 +- Wrappers/Python/test/test_algorithms.py | 7 +- Wrappers/Python/test/test_dataexample.py | 7 +- .../test/test_function_KullbackLeibler.py | 32 ++++---- Wrappers/Python/test/test_functions.py | 12 ++- Wrappers/Python/test/test_io.py | 7 +- Wrappers/Python/test/test_quality_measures.py | 7 +- Wrappers/Python/test/test_reconstructors.py | 7 +- Wrappers/Python/test/test_ring_processor.py | 7 +- Wrappers/Python/test/test_run_test.py | 7 +- Wrappers/Python/test/test_subset.py | 7 +- .../Python/test/test_tiff_readerwriter.py | 7 +- Wrappers/Python/test/test_version.py | 7 +- Wrappers/Python/test/testclass.py | 7 +- Wrappers/Python/test/utils.py | 7 +- Wrappers/Python/test/utils_projectors.py | 7 +- _config.yml | 18 +++++ docs/Makefile | 19 +++++ docs/docs_environment.yml | 19 +++++ docs/make.bat | 18 +++++ docs/source/conf.py | 20 ++++- docs/source/developer_guide.rst | 22 +++++- docs/source/framework.rst | 19 +++++ docs/source/index.rst | 20 +++++ docs/source/introduction.rst | 19 +++++ docs/source/io.rst | 20 +++++ docs/source/optimisation.rst | 19 +++++ docs/source/plugins.rst | 19 +++++ docs/source/processors.rst | 19 +++++ docs/source/recon.rst | 19 +++++ docs/source/refs.bib | 19 +++++ docs/source/utilities.rst | 19 +++++ recipe/bld.bat | 18 +++++ recipe/build.sh | 19 +++++ recipe/conda_build_config.yaml | 20 +++++ recipe/meta.yaml | 19 +++++ .../create_local_env_for_cil_development.sh | 18 +++++ ...ate_local_env_for_cil_development_tests.sh | 2 + scripts/requirements-test.yml | 18 +++++ src/Core/Binning.cpp | 20 ++++- src/Core/CMakeLists.txt | 18 +++++ src/Core/FBP_filtering.cpp | 19 +++++ src/Core/FiniteDifferenceLibrary.cpp | 21 ++++++ src/Core/axpby.cpp | 20 +++++ src/Core/include/Binning.h | 18 +++++ src/Core/include/FBP_filtering.h | 19 +++++ src/Core/include/FiniteDifferenceLibrary.h | 19 +++++ src/Core/include/axpby.h | 18 +++++ src/Core/include/dll_export.h | 19 +++++ src/Core/include/utilities.h | 18 +++++ src/Core/utilities.cpp | 19 +++++ 186 files changed, 2559 insertions(+), 1367 deletions(-) mode change 100755 => 100644 Wrappers/Python/cil/optimisation/functions/Rosenbrock.py mode change 100755 => 100644 Wrappers/Python/cil/optimisation/operators/__init__.py mode change 100755 => 100644 Wrappers/Python/cil/processors/__init__.py mode change 100755 => 100644 Wrappers/Python/test/test_BlockDataContainer.py mode change 100755 => 100644 Wrappers/Python/test/test_DataContainer.py mode change 100755 => 100644 Wrappers/Python/test/test_DataProcessor.py mode change 100755 => 100644 Wrappers/Python/test/test_Gradient.py mode change 100755 => 100644 Wrappers/Python/test/test_algorithms.py mode change 100755 => 100644 Wrappers/Python/test/test_dataexample.py mode change 100755 => 100644 Wrappers/Python/test/test_run_test.py mode change 100755 => 100644 Wrappers/Python/test/testclass.py mode change 100755 => 100644 docs/Makefile mode change 100755 => 100644 docs/make.bat mode change 100755 => 100644 docs/source/conf.py mode change 100755 => 100644 docs/source/index.rst diff --git a/.github/workflows/conda_and_docs_build.yml b/.github/workflows/conda_and_docs_build.yml index 23ce23e1e..1fe806f25 100644 --- a/.github/workflows/conda_and_docs_build.yml +++ b/.github/workflows/conda_and_docs_build.yml @@ -1,3 +1,22 @@ +# -*- coding: utf-8 -*- +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + name: conda_and_docs_build on: diff --git a/CHANGELOG.md b/CHANGELOG.md index 49405d437..52ca2fc2a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,7 @@ - Deprecate use of integer compression in NEXUSDataWriter. - Improved and tidied up documentation for all readers and writers, including hiding special members. - Use arguments instead of kwargs in all readers and writers with multiple kwargs, making documentation easier. + - Update Apache2 License Headers. * 22.2.0 - BlockGeometry is iterable diff --git a/CMakeLists.txt b/CMakeLists.txt index ea05455ec..a06e0450c 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,3 +1,22 @@ +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt +# Richard Brown (University College London) + if(APPLE) cmake_minimum_required(VERSION 3.16) else() diff --git a/NOTICE.txt b/NOTICE.txt index 9a94aeef1..b6ecc3033 100644 --- a/NOTICE.txt +++ b/NOTICE.txt @@ -1,28 +1,62 @@ CCPi Core Imaging Library (CIL). -Copyright 2017-2022 United Kingdom Research and Innovation -Copyright 2017-2022 University of Manchester +Copyright 2017 United Kingdom Research and Innovation +Copyright 2017 The University of Manchester + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. + This software product is developed for the Collaborative Computational Project in Tomographic Imaging CCPi (http://www.ccpi.ac.uk/) with substantial contributions by UKRI-STFC and The University of Manchester. and other contributing institutions. -Main contributors in alphabetical order: -Evelina Ametova (UoM) -Gemma Fardell (STFC) -Jakob Jorgensen (DTU) -Laura Murgatroyd (STFC) -Evangelos Papoutsellis (STFC) -Edoardo Pasca (STFC) -Kyle Pidgeon (STFC) - -Other contributors: -Claire Delplancke (UoB) -Daniil Kazantsev (Diamond Light Source) -Tomas Kulhanek (STFC) -Srikanth Nagella (STFC) -Andrew Sharits (UES Inc.) -Kris Thielemans (UCL) -Sam Tygier (STFC) -Ryan Warr (UoM) +Institutions Key: +1 - United Kingdom Research and Innovation - Science & Technology Facilities Council (UKRI-STFC) +2 - Technical University of Denmark (DTU) +3 - The University of Manchester +4 - Finden +5 - University College London (UCL) +6 - Karlsruhe Institute of Technology (KIT) +7 - University of Bath +8 - UES Inc. +9 - Swansea University +10 - University of Warwick + +CIL Developers in date order: +Edoardo Pasca (2017 – present) - 1 +Jakob Sauer Jørgensen (2017 - present) - 2, 3 +Evangelos Papoutsellis (2018 – 2020) - 3, (2020-2022) - 1, (2022-present) - 4 +Gemma Fardell (2019 - present) - 1 +Kris Thielemans (2020 - present) - 5 +Laura Murgatroyd (2021 - present) - 1 +Evelina Ametova (2018-2020) - 3, (2020-2021) - 6 + +CIL Contributors: +Srikanth Nagella (2017-2018) - 1 +Daniil Kazantsev (2018) - 3 +Ryan Warr (2019) - 3 +Tomas Kulhanek (2019) - 1 +Claire Delplancke (2019 - 2022) - 7 +Matthias Ehrhardt (2019 - 2023) - 7 +Richard Brown (2020-2021) - 5 +Sam Tygier (2022) - 1 +Andrew Sharits (2022) - 8 +Kyle Pidgeon (2023) - 1 +CIL Advisory Board: +Llion Evans - 9 +William Lionheart - 3 +Kris Thielemans - 5 +Martin Turner - 3 +Jay Warnett - 10 +Philip Withers - 3 diff --git a/Wrappers/Python/CMake/parse_git_describe.py b/Wrappers/Python/CMake/parse_git_describe.py index 98495e6e3..a647de885 100644 --- a/Wrappers/Python/CMake/parse_git_describe.py +++ b/Wrappers/Python/CMake/parse_git_describe.py @@ -1,3 +1,22 @@ +# -*- coding: utf-8 -*- +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + import re, subprocess, sys, os git_executable = os.path.abspath(sys.argv[1]) diff --git a/Wrappers/Python/CMake/setup.py.in b/Wrappers/Python/CMake/setup.py.in index 2f5adaad8..96cbea46b 100644 --- a/Wrappers/Python/CMake/setup.py.in +++ b/Wrappers/Python/CMake/setup.py.in @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from setuptools import setup import os diff --git a/Wrappers/Python/CMake/sp_dir.py b/Wrappers/Python/CMake/sp_dir.py index b2b5b14b2..efafdb527 100644 --- a/Wrappers/Python/CMake/sp_dir.py +++ b/Wrappers/Python/CMake/sp_dir.py @@ -1,2 +1,21 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + import os print (os.path.dirname(os.__file__)) diff --git a/Wrappers/Python/CMake/version.py.in b/Wrappers/Python/CMake/version.py.in index 10dc6a7cc..70d23119c 100644 --- a/Wrappers/Python/CMake/version.py.in +++ b/Wrappers/Python/CMake/version.py.in @@ -1,3 +1,22 @@ +# -*- coding: utf-8 -*- +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + version = '@CIL_VERSION_MAJOR@.@CIL_VERSION_MINOR@.@CIL_VERSION_PATCH@' major = '@CIL_VERSION_MAJOR@' minor = '@CIL_VERSION_MINOR@' diff --git a/Wrappers/Python/CMakeLists.txt b/Wrappers/Python/CMakeLists.txt index 7703f640d..4c284775f 100644 --- a/Wrappers/Python/CMakeLists.txt +++ b/Wrappers/Python/CMakeLists.txt @@ -1,3 +1,22 @@ +# -*- coding: utf-8 -*- +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + option (BUILD_PYTHON_WRAPPER "Build Python Wrapper" ON) if (BUILD_PYTHON_WRAPPER) diff --git a/Wrappers/Python/cil/__init__.py b/Wrappers/Python/cil/__init__.py index 50ae6868c..00b34d00b 100644 --- a/Wrappers/Python/cil/__init__.py +++ b/Wrappers/Python/cil/__init__.py @@ -1,18 +1,20 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from .version import version as __version__ \ No newline at end of file diff --git a/Wrappers/Python/cil/framework/BlockDataContainer.py b/Wrappers/Python/cil/framework/BlockDataContainer.py index 74de2af6e..35b94f84d 100644 --- a/Wrappers/Python/cil/framework/BlockDataContainer.py +++ b/Wrappers/Python/cil/framework/BlockDataContainer.py @@ -1,19 +1,22 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. import numpy from numbers import Number import functools diff --git a/Wrappers/Python/cil/framework/BlockGeometry.py b/Wrappers/Python/cil/framework/BlockGeometry.py index 885051760..b2a47a662 100644 --- a/Wrappers/Python/cil/framework/BlockGeometry.py +++ b/Wrappers/Python/cil/framework/BlockGeometry.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import functools from cil.framework.BlockDataContainer import BlockDataContainer diff --git a/Wrappers/Python/cil/framework/__init__.py b/Wrappers/Python/cil/framework/__init__.py index d36c6ab09..457144151 100644 --- a/Wrappers/Python/cil/framework/__init__.py +++ b/Wrappers/Python/cil/framework/__init__.py @@ -1,19 +1,22 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. import numpy import sys from datetime import timedelta, datetime diff --git a/Wrappers/Python/cil/framework/framework.py b/Wrappers/Python/cil/framework/framework.py index 863751d38..bd4615340 100644 --- a/Wrappers/Python/cil/framework/framework.py +++ b/Wrappers/Python/cil/framework/framework.py @@ -1,19 +1,22 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. import copy import numpy import warnings diff --git a/Wrappers/Python/cil/io/NEXUSDataReader.py b/Wrappers/Python/cil/io/NEXUSDataReader.py index 9debfc958..ace5f41a7 100644 --- a/Wrappers/Python/cil/io/NEXUSDataReader.py +++ b/Wrappers/Python/cil/io/NEXUSDataReader.py @@ -1,19 +1,23 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt +# Kyle Pidgeon (UKRI-STFC) -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. import numpy as np import os from cil.framework import AcquisitionData, AcquisitionGeometry, ImageData, ImageGeometry diff --git a/Wrappers/Python/cil/io/NEXUSDataWriter.py b/Wrappers/Python/cil/io/NEXUSDataWriter.py index 2b278ccb2..759a700d9 100644 --- a/Wrappers/Python/cil/io/NEXUSDataWriter.py +++ b/Wrappers/Python/cil/io/NEXUSDataWriter.py @@ -1,19 +1,22 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. import numpy as np import os from cil.framework import AcquisitionData, AcquisitionGeometry, ImageData, ImageGeometry diff --git a/Wrappers/Python/cil/io/NikonDataReader.py b/Wrappers/Python/cil/io/NikonDataReader.py index 1eefd417a..458c411b4 100644 --- a/Wrappers/Python/cil/io/NikonDataReader.py +++ b/Wrappers/Python/cil/io/NikonDataReader.py @@ -1,19 +1,22 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. from cil.framework import AcquisitionData, AcquisitionGeometry from cil.io.TIFF import TIFFStackReader import warnings diff --git a/Wrappers/Python/cil/io/RAWFileWriter.py b/Wrappers/Python/cil/io/RAWFileWriter.py index f2f78694e..7b1b90ad2 100644 --- a/Wrappers/Python/cil/io/RAWFileWriter.py +++ b/Wrappers/Python/cil/io/RAWFileWriter.py @@ -1,24 +1,24 @@ # -*- coding: utf-8 -*- -# Copyright 2023 United Kingdom Research and Innovation -# Copyright 2023 The University of Manchester - -# Author(s): Edoardo Pasca (UKRI) - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2023 United Kingdom Research and Innovation +# Copyright 2023 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import AcquisitionData, ImageData, DataContainer import os -from cil.framework import AcquisitionData, ImageData from cil.io import utilities import configparser diff --git a/Wrappers/Python/cil/io/TIFF.py b/Wrappers/Python/cil/io/TIFF.py index c537a53c3..4d1f388d9 100644 --- a/Wrappers/Python/cil/io/TIFF.py +++ b/Wrappers/Python/cil/io/TIFF.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License.import numpy as np +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import AcquisitionData, AcquisitionGeometry, ImageGeometry, ImageData import os, re diff --git a/Wrappers/Python/cil/io/ZEISSDataReader.py b/Wrappers/Python/cil/io/ZEISSDataReader.py index beb785ce9..06e05d5bd 100644 --- a/Wrappers/Python/cil/io/ZEISSDataReader.py +++ b/Wrappers/Python/cil/io/ZEISSDataReader.py @@ -1,25 +1,22 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# Authored by: Jakob S. Jørgensen (DTU) -# Andrew Sharits (UES,Inc.) -# Edoardo Pasca (UKRI-STFC) -# Gemma Fardell (UKRI-STFC) -# Laura Murgatroyd (UKRI-STFC) +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt +# Andrew Shartis (UES, Inc.) from cil.framework import AcquisitionData, AcquisitionGeometry, ImageData, ImageGeometry, DataOrder diff --git a/Wrappers/Python/cil/io/__init__.py b/Wrappers/Python/cil/io/__init__.py index 6df7b564e..56a4770b9 100644 --- a/Wrappers/Python/cil/io/__init__.py +++ b/Wrappers/Python/cil/io/__init__.py @@ -1,19 +1,22 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. from .NEXUSDataReader import NEXUSDataReader from .NEXUSDataWriter import NEXUSDataWriter from .NikonDataReader import NikonDataReader diff --git a/Wrappers/Python/cil/io/utilities.py b/Wrappers/Python/cil/io/utilities.py index 32477cc0e..a662ad066 100644 --- a/Wrappers/Python/cil/io/utilities.py +++ b/Wrappers/Python/cil/io/utilities.py @@ -1,19 +1,22 @@ -# Copyright 2022 United Kingdom Research and Innovation -# Copyright 2022 The University of Manchester +# -*- coding: utf-8 -*- +# Copyright 2023 United Kingdom Research and Innovation +# Copyright 2023 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt -# Author(s): Edoardo Pasca - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. import numpy as np import json import logging diff --git a/Wrappers/Python/cil/optimisation/__init__.py b/Wrappers/Python/cil/optimisation/__init__.py index f90064aab..89add0b5b 100644 --- a/Wrappers/Python/cil/optimisation/__init__.py +++ b/Wrappers/Python/cil/optimisation/__init__.py @@ -1,16 +1,18 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. \ No newline at end of file +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt \ No newline at end of file diff --git a/Wrappers/Python/cil/optimisation/algorithms/ADMM.py b/Wrappers/Python/cil/optimisation/algorithms/ADMM.py index b9d0282d1..5bfe5b1da 100644 --- a/Wrappers/Python/cil/optimisation/algorithms/ADMM.py +++ b/Wrappers/Python/cil/optimisation/algorithms/ADMM.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.algorithms import Algorithm import warnings diff --git a/Wrappers/Python/cil/optimisation/algorithms/Algorithm.py b/Wrappers/Python/cil/optimisation/algorithms/Algorithm.py index 07e173a39..632de0b85 100644 --- a/Wrappers/Python/cil/optimisation/algorithms/Algorithm.py +++ b/Wrappers/Python/cil/optimisation/algorithms/Algorithm.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import time, functools from numbers import Integral, Number diff --git a/Wrappers/Python/cil/optimisation/algorithms/CGLS.py b/Wrappers/Python/cil/optimisation/algorithms/CGLS.py index abb9e0967..29efe62b1 100644 --- a/Wrappers/Python/cil/optimisation/algorithms/CGLS.py +++ b/Wrappers/Python/cil/optimisation/algorithms/CGLS.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.algorithms import Algorithm import numpy diff --git a/Wrappers/Python/cil/optimisation/algorithms/FISTA.py b/Wrappers/Python/cil/optimisation/algorithms/FISTA.py index f7e8bc4c9..92a8f08a8 100644 --- a/Wrappers/Python/cil/optimisation/algorithms/FISTA.py +++ b/Wrappers/Python/cil/optimisation/algorithms/FISTA.py @@ -1,17 +1,21 @@ -# Copyright 2022 United Kingdom Research and Innovation -# Copyright 2022 The University of Manchester - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# -*- coding: utf-8 -*- +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.algorithms import Algorithm import numpy diff --git a/Wrappers/Python/cil/optimisation/algorithms/GD.py b/Wrappers/Python/cil/optimisation/algorithms/GD.py index 5e8a6edbf..6bea2d8fb 100644 --- a/Wrappers/Python/cil/optimisation/algorithms/GD.py +++ b/Wrappers/Python/cil/optimisation/algorithms/GD.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import numpy from cil.optimisation.algorithms import Algorithm diff --git a/Wrappers/Python/cil/optimisation/algorithms/PDHG.py b/Wrappers/Python/cil/optimisation/algorithms/PDHG.py index 1c61bbf20..64b4bfcf7 100644 --- a/Wrappers/Python/cil/optimisation/algorithms/PDHG.py +++ b/Wrappers/Python/cil/optimisation/algorithms/PDHG.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataContainer, BlockDataContainer from cil.optimisation.algorithms import Algorithm diff --git a/Wrappers/Python/cil/optimisation/algorithms/SIRT.py b/Wrappers/Python/cil/optimisation/algorithms/SIRT.py index c25dd592c..79227ccb4 100644 --- a/Wrappers/Python/cil/optimisation/algorithms/SIRT.py +++ b/Wrappers/Python/cil/optimisation/algorithms/SIRT.py @@ -1,19 +1,22 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. from cil.optimisation.algorithms import Algorithm from cil.optimisation.functions import IndicatorBox from numpy import inf diff --git a/Wrappers/Python/cil/optimisation/algorithms/SPDHG.py b/Wrappers/Python/cil/optimisation/algorithms/SPDHG.py index f04ed907d..37efd460b 100644 --- a/Wrappers/Python/cil/optimisation/algorithms/SPDHG.py +++ b/Wrappers/Python/cil/optimisation/algorithms/SPDHG.py @@ -1,19 +1,23 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt +# Claire Delplancke (University of Bath) -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. from cil.optimisation.algorithms import Algorithm import numpy as np import warnings diff --git a/Wrappers/Python/cil/optimisation/algorithms/__init__.py b/Wrappers/Python/cil/optimisation/algorithms/__init__.py index 536327e1d..b6b23bcb5 100644 --- a/Wrappers/Python/cil/optimisation/algorithms/__init__.py +++ b/Wrappers/Python/cil/optimisation/algorithms/__init__.py @@ -1,19 +1,22 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. from .Algorithm import Algorithm from .CGLS import CGLS from .SIRT import SIRT diff --git a/Wrappers/Python/cil/optimisation/functions/BlockFunction.py b/Wrappers/Python/cil/optimisation/functions/BlockFunction.py index 8caa7a83e..c1a9a9e65 100644 --- a/Wrappers/Python/cil/optimisation/functions/BlockFunction.py +++ b/Wrappers/Python/cil/optimisation/functions/BlockFunction.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.functions import Function from cil.framework import BlockDataContainer diff --git a/Wrappers/Python/cil/optimisation/functions/Function.py b/Wrappers/Python/cil/optimisation/functions/Function.py index e2ee72dcb..cfc4c1881 100644 --- a/Wrappers/Python/cil/optimisation/functions/Function.py +++ b/Wrappers/Python/cil/optimisation/functions/Function.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import warnings diff --git a/Wrappers/Python/cil/optimisation/functions/IndicatorBox.py b/Wrappers/Python/cil/optimisation/functions/IndicatorBox.py index a8f17c94f..77170e4d0 100644 --- a/Wrappers/Python/cil/optimisation/functions/IndicatorBox.py +++ b/Wrappers/Python/cil/optimisation/functions/IndicatorBox.py @@ -1,22 +1,21 @@ -# Copyright 2023 United Kingdom Research and Innovation -# Copyright 2023 The University of Manchester - -# Author(s): -# Evangelos Papoutsellis (UKRI) -# Edoardo Pasca (UKRI) -# Gemma Fardell (UKRI) - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# -*- coding: utf-8 -*- +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.functions import Function import numpy as np diff --git a/Wrappers/Python/cil/optimisation/functions/KullbackLeibler.py b/Wrappers/Python/cil/optimisation/functions/KullbackLeibler.py index 502e9961f..287c4756d 100644 --- a/Wrappers/Python/cil/optimisation/functions/KullbackLeibler.py +++ b/Wrappers/Python/cil/optimisation/functions/KullbackLeibler.py @@ -1,17 +1,21 @@ -# Copyright 2023 United Kingdom Research and Innovation -# Copyright 2023 The University of Manchester - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# -*- coding: utf-8 -*- +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import numpy from cil.optimisation.functions import Function diff --git a/Wrappers/Python/cil/optimisation/functions/L1Norm.py b/Wrappers/Python/cil/optimisation/functions/L1Norm.py index 3306dab35..6ef9dc404 100644 --- a/Wrappers/Python/cil/optimisation/functions/L1Norm.py +++ b/Wrappers/Python/cil/optimisation/functions/L1Norm.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.functions import Function from cil.framework import BlockDataContainer diff --git a/Wrappers/Python/cil/optimisation/functions/L2NormSquared.py b/Wrappers/Python/cil/optimisation/functions/L2NormSquared.py index f65e928cc..e7b2e84bf 100644 --- a/Wrappers/Python/cil/optimisation/functions/L2NormSquared.py +++ b/Wrappers/Python/cil/optimisation/functions/L2NormSquared.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.functions import Function from cil.framework import DataContainer diff --git a/Wrappers/Python/cil/optimisation/functions/LeastSquares.py b/Wrappers/Python/cil/optimisation/functions/LeastSquares.py index 757aefa78..f57057c1b 100644 --- a/Wrappers/Python/cil/optimisation/functions/LeastSquares.py +++ b/Wrappers/Python/cil/optimisation/functions/LeastSquares.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.operators import LinearOperator, DiagonalOperator from cil.optimisation.functions import Function diff --git a/Wrappers/Python/cil/optimisation/functions/MixedL21Norm.py b/Wrappers/Python/cil/optimisation/functions/MixedL21Norm.py index 44763a374..a96e68c1e 100644 --- a/Wrappers/Python/cil/optimisation/functions/MixedL21Norm.py +++ b/Wrappers/Python/cil/optimisation/functions/MixedL21Norm.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.functions import Function from cil.framework import BlockDataContainer diff --git a/Wrappers/Python/cil/optimisation/functions/OperatorCompositionFunction.py b/Wrappers/Python/cil/optimisation/functions/OperatorCompositionFunction.py index 3e2c4ae9b..f27e5142e 100644 --- a/Wrappers/Python/cil/optimisation/functions/OperatorCompositionFunction.py +++ b/Wrappers/Python/cil/optimisation/functions/OperatorCompositionFunction.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.functions import Function from cil.optimisation.operators import Operator, ScaledOperator diff --git a/Wrappers/Python/cil/optimisation/functions/Rosenbrock.py b/Wrappers/Python/cil/optimisation/functions/Rosenbrock.py old mode 100755 new mode 100644 index 7d3d97e3c..3e35dc4c0 --- a/Wrappers/Python/cil/optimisation/functions/Rosenbrock.py +++ b/Wrappers/Python/cil/optimisation/functions/Rosenbrock.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import numpy from cil.optimisation.functions import Function diff --git a/Wrappers/Python/cil/optimisation/functions/TotalVariation.py b/Wrappers/Python/cil/optimisation/functions/TotalVariation.py index 96fbc7bd8..0934e01b4 100644 --- a/Wrappers/Python/cil/optimisation/functions/TotalVariation.py +++ b/Wrappers/Python/cil/optimisation/functions/TotalVariation.py @@ -1,17 +1,22 @@ -# Copyright 2022 United Kingdom Research and Innovation -# Copyright 2022 The University of Manchester - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# -*- coding: utf-8 -*- +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt +# Claire Delplancke (University of Bath) from cil.optimisation.functions import Function, IndicatorBox, MixedL21Norm, MixedL11Norm from cil.optimisation.operators import GradientOperator diff --git a/Wrappers/Python/cil/optimisation/functions/__init__.py b/Wrappers/Python/cil/optimisation/functions/__init__.py index 0dcafcf24..2c97ad4cb 100644 --- a/Wrappers/Python/cil/optimisation/functions/__init__.py +++ b/Wrappers/Python/cil/optimisation/functions/__init__.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from .Function import Function from .Function import SumFunction diff --git a/Wrappers/Python/cil/optimisation/operators/BlockOperator.py b/Wrappers/Python/cil/optimisation/operators/BlockOperator.py index 4f694b903..79d485105 100644 --- a/Wrappers/Python/cil/optimisation/operators/BlockOperator.py +++ b/Wrappers/Python/cil/optimisation/operators/BlockOperator.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import numpy import functools diff --git a/Wrappers/Python/cil/optimisation/operators/BlurringOperator.py b/Wrappers/Python/cil/optimisation/operators/BlurringOperator.py index 5bd74fc43..4541ecd60 100644 --- a/Wrappers/Python/cil/optimisation/operators/BlurringOperator.py +++ b/Wrappers/Python/cil/optimisation/operators/BlurringOperator.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import numpy as np from cil.optimisation.operators import LinearOperator diff --git a/Wrappers/Python/cil/optimisation/operators/ChannelwiseOperator.py b/Wrappers/Python/cil/optimisation/operators/ChannelwiseOperator.py index 4dd73077f..c32db1f19 100644 --- a/Wrappers/Python/cil/optimisation/operators/ChannelwiseOperator.py +++ b/Wrappers/Python/cil/optimisation/operators/ChannelwiseOperator.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import numpy as np from cil.framework import ImageData diff --git a/Wrappers/Python/cil/optimisation/operators/DiagonalOperator.py b/Wrappers/Python/cil/optimisation/operators/DiagonalOperator.py index e5d4d190e..99de954bf 100644 --- a/Wrappers/Python/cil/optimisation/operators/DiagonalOperator.py +++ b/Wrappers/Python/cil/optimisation/operators/DiagonalOperator.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import numpy as np from cil.framework import ImageData diff --git a/Wrappers/Python/cil/optimisation/operators/FiniteDifferenceOperator.py b/Wrappers/Python/cil/optimisation/operators/FiniteDifferenceOperator.py index deaaa8d60..bb2a7dabc 100644 --- a/Wrappers/Python/cil/optimisation/operators/FiniteDifferenceOperator.py +++ b/Wrappers/Python/cil/optimisation/operators/FiniteDifferenceOperator.py @@ -1,32 +1,25 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import numpy as np from cil.optimisation.operators import LinearOperator - -############################################################################### -############################################################################### -############################################################################### -############################# New Finite Difference ########################### -############################################################################### -############################################################################### -############################################################################### - class FiniteDifferenceOperator(LinearOperator): diff --git a/Wrappers/Python/cil/optimisation/operators/GradientOperator.py b/Wrappers/Python/cil/optimisation/operators/GradientOperator.py index 005d164c2..b311ed01a 100644 --- a/Wrappers/Python/cil/optimisation/operators/GradientOperator.py +++ b/Wrappers/Python/cil/optimisation/operators/GradientOperator.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.operators import LinearOperator from cil.optimisation.operators import FiniteDifferenceOperator diff --git a/Wrappers/Python/cil/optimisation/operators/IdentityOperator.py b/Wrappers/Python/cil/optimisation/operators/IdentityOperator.py index dec576765..4ec534bba 100644 --- a/Wrappers/Python/cil/optimisation/operators/IdentityOperator.py +++ b/Wrappers/Python/cil/optimisation/operators/IdentityOperator.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.operators import LinearOperator import scipy.sparse as sp diff --git a/Wrappers/Python/cil/optimisation/operators/MaskOperator.py b/Wrappers/Python/cil/optimisation/operators/MaskOperator.py index cd81ea102..8f3d34749 100644 --- a/Wrappers/Python/cil/optimisation/operators/MaskOperator.py +++ b/Wrappers/Python/cil/optimisation/operators/MaskOperator.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import numpy as np diff --git a/Wrappers/Python/cil/optimisation/operators/MatrixOperator.py b/Wrappers/Python/cil/optimisation/operators/MatrixOperator.py index 26c97f51c..bb754f2fc 100644 --- a/Wrappers/Python/cil/optimisation/operators/MatrixOperator.py +++ b/Wrappers/Python/cil/optimisation/operators/MatrixOperator.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import numpy from scipy.sparse.linalg import svds diff --git a/Wrappers/Python/cil/optimisation/operators/Operator.py b/Wrappers/Python/cil/optimisation/operators/Operator.py index 9da61280d..764578d44 100644 --- a/Wrappers/Python/cil/optimisation/operators/Operator.py +++ b/Wrappers/Python/cil/optimisation/operators/Operator.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from numbers import Number import numpy diff --git a/Wrappers/Python/cil/optimisation/operators/ProjectionMap.py b/Wrappers/Python/cil/optimisation/operators/ProjectionMap.py index 1546408f9..92d904e90 100644 --- a/Wrappers/Python/cil/optimisation/operators/ProjectionMap.py +++ b/Wrappers/Python/cil/optimisation/operators/ProjectionMap.py @@ -1,3 +1,22 @@ +# -*- coding: utf-8 -*- +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + from cil.optimisation.operators import LinearOperator from cil.framework import BlockGeometry diff --git a/Wrappers/Python/cil/optimisation/operators/SparseFiniteDifferenceOperator.py b/Wrappers/Python/cil/optimisation/operators/SparseFiniteDifferenceOperator.py index a19f88b90..622d594f6 100644 --- a/Wrappers/Python/cil/optimisation/operators/SparseFiniteDifferenceOperator.py +++ b/Wrappers/Python/cil/optimisation/operators/SparseFiniteDifferenceOperator.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import scipy.sparse as sp import numpy as np diff --git a/Wrappers/Python/cil/optimisation/operators/SymmetrisedGradientOperator.py b/Wrappers/Python/cil/optimisation/operators/SymmetrisedGradientOperator.py index 3def140e0..562e9083b 100644 --- a/Wrappers/Python/cil/optimisation/operators/SymmetrisedGradientOperator.py +++ b/Wrappers/Python/cil/optimisation/operators/SymmetrisedGradientOperator.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.operators import LinearOperator from cil.framework import BlockGeometry, BlockDataContainer diff --git a/Wrappers/Python/cil/optimisation/operators/ZeroOperator.py b/Wrappers/Python/cil/optimisation/operators/ZeroOperator.py index cf68927dc..0a8ce4492 100644 --- a/Wrappers/Python/cil/optimisation/operators/ZeroOperator.py +++ b/Wrappers/Python/cil/optimisation/operators/ZeroOperator.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import numpy as np from cil.framework import ImageData diff --git a/Wrappers/Python/cil/optimisation/operators/__init__.py b/Wrappers/Python/cil/optimisation/operators/__init__.py old mode 100755 new mode 100644 index f109acc38..fe6a06856 --- a/Wrappers/Python/cil/optimisation/operators/__init__.py +++ b/Wrappers/Python/cil/optimisation/operators/__init__.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from .Operator import Operator, LinearOperator, ScaledOperator, SumOperator,\ CompositionOperator diff --git a/Wrappers/Python/cil/plugins/TomoPhantom.py b/Wrappers/Python/cil/plugins/TomoPhantom.py index c402a26fb..72c42de3c 100644 --- a/Wrappers/Python/cil/plugins/TomoPhantom.py +++ b/Wrappers/Python/cil/plugins/TomoPhantom.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import ImageGeometry, AcquisitionGeometry from cil.framework import ImageData, AcquisitionData, DataOrder diff --git a/Wrappers/Python/cil/plugins/__init__.py b/Wrappers/Python/cil/plugins/__init__.py index f90064aab..89add0b5b 100644 --- a/Wrappers/Python/cil/plugins/__init__.py +++ b/Wrappers/Python/cil/plugins/__init__.py @@ -1,16 +1,18 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. \ No newline at end of file +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt \ No newline at end of file diff --git a/Wrappers/Python/cil/plugins/astra/__init__.py b/Wrappers/Python/cil/plugins/astra/__init__.py index e99089d62..03ce8d840 100644 --- a/Wrappers/Python/cil/plugins/astra/__init__.py +++ b/Wrappers/Python/cil/plugins/astra/__init__.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from .operators import ProjectionOperator -from .processors import FBP +from .processors import FBP \ No newline at end of file diff --git a/Wrappers/Python/cil/plugins/astra/operators/AstraProjector2D.py b/Wrappers/Python/cil/plugins/astra/operators/AstraProjector2D.py index 20674a19c..5f7d973f0 100644 --- a/Wrappers/Python/cil/plugins/astra/operators/AstraProjector2D.py +++ b/Wrappers/Python/cil/plugins/astra/operators/AstraProjector2D.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2019 - 2022 United Kingdom Research and Innovation -# Copyright 2019 - 2022 The University of Manchester +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.operators import LinearOperator diff --git a/Wrappers/Python/cil/plugins/astra/operators/AstraProjector3D.py b/Wrappers/Python/cil/plugins/astra/operators/AstraProjector3D.py index bf3da67d1..9790bdbe2 100644 --- a/Wrappers/Python/cil/plugins/astra/operators/AstraProjector3D.py +++ b/Wrappers/Python/cil/plugins/astra/operators/AstraProjector3D.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2019 - 2022 United Kingdom Research and Innovation -# Copyright 2019 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.operators import LinearOperator diff --git a/Wrappers/Python/cil/plugins/astra/operators/ProjectionOperator.py b/Wrappers/Python/cil/plugins/astra/operators/ProjectionOperator.py index c1d69415f..2e921178f 100644 --- a/Wrappers/Python/cil/plugins/astra/operators/ProjectionOperator.py +++ b/Wrappers/Python/cil/plugins/astra/operators/ProjectionOperator.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2019 - 2022 United Kingdom Research and Innovation -# Copyright 2019 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataOrder from cil.optimisation.operators import LinearOperator, ChannelwiseOperator diff --git a/Wrappers/Python/cil/plugins/astra/operators/__init__.py b/Wrappers/Python/cil/plugins/astra/operators/__init__.py index 690d58bd7..e84d1b7bd 100644 --- a/Wrappers/Python/cil/plugins/astra/operators/__init__.py +++ b/Wrappers/Python/cil/plugins/astra/operators/__init__.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from .AstraProjector2D import AstraProjector2D diff --git a/Wrappers/Python/cil/plugins/astra/processors/AstraBackProjector2D.py b/Wrappers/Python/cil/plugins/astra/processors/AstraBackProjector2D.py index c8a12cb52..1e5724720 100644 --- a/Wrappers/Python/cil/plugins/astra/processors/AstraBackProjector2D.py +++ b/Wrappers/Python/cil/plugins/astra/processors/AstraBackProjector2D.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataProcessor, ImageData diff --git a/Wrappers/Python/cil/plugins/astra/processors/AstraBackProjector3D.py b/Wrappers/Python/cil/plugins/astra/processors/AstraBackProjector3D.py index 0dbab7845..6e69e9162 100644 --- a/Wrappers/Python/cil/plugins/astra/processors/AstraBackProjector3D.py +++ b/Wrappers/Python/cil/plugins/astra/processors/AstraBackProjector3D.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataProcessor, ImageData, DataOrder diff --git a/Wrappers/Python/cil/plugins/astra/processors/AstraForwardProjector2D.py b/Wrappers/Python/cil/plugins/astra/processors/AstraForwardProjector2D.py index e419c95f2..e36709430 100644 --- a/Wrappers/Python/cil/plugins/astra/processors/AstraForwardProjector2D.py +++ b/Wrappers/Python/cil/plugins/astra/processors/AstraForwardProjector2D.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataProcessor, AcquisitionData diff --git a/Wrappers/Python/cil/plugins/astra/processors/AstraForwardProjector3D.py b/Wrappers/Python/cil/plugins/astra/processors/AstraForwardProjector3D.py index c03315b21..48f7b3041 100644 --- a/Wrappers/Python/cil/plugins/astra/processors/AstraForwardProjector3D.py +++ b/Wrappers/Python/cil/plugins/astra/processors/AstraForwardProjector3D.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataProcessor, AcquisitionData, DataOrder diff --git a/Wrappers/Python/cil/plugins/astra/processors/FBP.py b/Wrappers/Python/cil/plugins/astra/processors/FBP.py index c5409d63c..e5dc50d4a 100644 --- a/Wrappers/Python/cil/plugins/astra/processors/FBP.py +++ b/Wrappers/Python/cil/plugins/astra/processors/FBP.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2019 - 2022 United Kingdom Research and Innovation -# Copyright 2019 - 2022 The University of Manchester +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataProcessor from cil.framework import DataOrder diff --git a/Wrappers/Python/cil/plugins/astra/processors/FBP_Flexible.py b/Wrappers/Python/cil/plugins/astra/processors/FBP_Flexible.py index 2537f8476..61af6d281 100644 --- a/Wrappers/Python/cil/plugins/astra/processors/FBP_Flexible.py +++ b/Wrappers/Python/cil/plugins/astra/processors/FBP_Flexible.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import AcquisitionGeometry, Processor, ImageData diff --git a/Wrappers/Python/cil/plugins/astra/processors/FDK_Flexible.py b/Wrappers/Python/cil/plugins/astra/processors/FDK_Flexible.py index 1525d6c57..a2a74588f 100644 --- a/Wrappers/Python/cil/plugins/astra/processors/FDK_Flexible.py +++ b/Wrappers/Python/cil/plugins/astra/processors/FDK_Flexible.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataProcessor, ImageData diff --git a/Wrappers/Python/cil/plugins/astra/processors/__init__.py b/Wrappers/Python/cil/plugins/astra/processors/__init__.py index 5b1ea746f..af8a43f68 100644 --- a/Wrappers/Python/cil/plugins/astra/processors/__init__.py +++ b/Wrappers/Python/cil/plugins/astra/processors/__init__.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from .AstraForwardProjector2D import AstraForwardProjector2D diff --git a/Wrappers/Python/cil/plugins/astra/utilities/__init__.py b/Wrappers/Python/cil/plugins/astra/utilities/__init__.py index 43d76e426..4e9f7182e 100644 --- a/Wrappers/Python/cil/plugins/astra/utilities/__init__.py +++ b/Wrappers/Python/cil/plugins/astra/utilities/__init__.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from .convert_geometry_to_astra import convert_geometry_to_astra diff --git a/Wrappers/Python/cil/plugins/astra/utilities/convert_geometry_to_astra.py b/Wrappers/Python/cil/plugins/astra/utilities/convert_geometry_to_astra.py index 2e407210f..777fe7ba7 100644 --- a/Wrappers/Python/cil/plugins/astra/utilities/convert_geometry_to_astra.py +++ b/Wrappers/Python/cil/plugins/astra/utilities/convert_geometry_to_astra.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import astra diff --git a/Wrappers/Python/cil/plugins/astra/utilities/convert_geometry_to_astra_vec_2D.py b/Wrappers/Python/cil/plugins/astra/utilities/convert_geometry_to_astra_vec_2D.py index 779a547ea..9f0c6995d 100644 --- a/Wrappers/Python/cil/plugins/astra/utilities/convert_geometry_to_astra_vec_2D.py +++ b/Wrappers/Python/cil/plugins/astra/utilities/convert_geometry_to_astra_vec_2D.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import astra diff --git a/Wrappers/Python/cil/plugins/astra/utilities/convert_geometry_to_astra_vec_3D.py b/Wrappers/Python/cil/plugins/astra/utilities/convert_geometry_to_astra_vec_3D.py index 1ea3b7699..0c8f0d607 100644 --- a/Wrappers/Python/cil/plugins/astra/utilities/convert_geometry_to_astra_vec_3D.py +++ b/Wrappers/Python/cil/plugins/astra/utilities/convert_geometry_to_astra_vec_3D.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import astra diff --git a/Wrappers/Python/cil/plugins/ccpi_regularisation/__init__.py b/Wrappers/Python/cil/plugins/ccpi_regularisation/__init__.py index f90064aab..5e91003ed 100644 --- a/Wrappers/Python/cil/plugins/ccpi_regularisation/__init__.py +++ b/Wrappers/Python/cil/plugins/ccpi_regularisation/__init__.py @@ -1,16 +1,18 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. \ No newline at end of file +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt \ No newline at end of file diff --git a/Wrappers/Python/cil/plugins/ccpi_regularisation/functions/__init__.py b/Wrappers/Python/cil/plugins/ccpi_regularisation/functions/__init__.py index 1b27aef58..83464d5d9 100644 --- a/Wrappers/Python/cil/plugins/ccpi_regularisation/functions/__init__.py +++ b/Wrappers/Python/cil/plugins/ccpi_regularisation/functions/__init__.py @@ -1,18 +1,20 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from .regularisers import FGP_TV, TGV, FGP_dTV, TNV diff --git a/Wrappers/Python/cil/plugins/ccpi_regularisation/functions/regularisers.py b/Wrappers/Python/cil/plugins/ccpi_regularisation/functions/regularisers.py index 7e824580c..789d95da1 100644 --- a/Wrappers/Python/cil/plugins/ccpi_regularisation/functions/regularisers.py +++ b/Wrappers/Python/cil/plugins/ccpi_regularisation/functions/regularisers.py @@ -1,17 +1,21 @@ -# Copyright 2022 United Kingdom Research and Innovation -# Copyright 2022 The University of Manchester - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# -*- coding: utf-8 -*- +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt try: from ccpi.filters import regularisers diff --git a/Wrappers/Python/cil/plugins/tigre/FBP.py b/Wrappers/Python/cil/plugins/tigre/FBP.py index 3513ce8d3..190bb7898 100644 --- a/Wrappers/Python/cil/plugins/tigre/FBP.py +++ b/Wrappers/Python/cil/plugins/tigre/FBP.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataProcessor, ImageData from cil.framework import DataOrder diff --git a/Wrappers/Python/cil/plugins/tigre/Geometry.py b/Wrappers/Python/cil/plugins/tigre/Geometry.py index e23c3e552..3d82793d1 100644 --- a/Wrappers/Python/cil/plugins/tigre/Geometry.py +++ b/Wrappers/Python/cil/plugins/tigre/Geometry.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import AcquisitionGeometry, ImageGeometry import numpy as np diff --git a/Wrappers/Python/cil/plugins/tigre/ProjectionOperator.py b/Wrappers/Python/cil/plugins/tigre/ProjectionOperator.py index ba4a8a02c..9840b0e0e 100644 --- a/Wrappers/Python/cil/plugins/tigre/ProjectionOperator.py +++ b/Wrappers/Python/cil/plugins/tigre/ProjectionOperator.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import ImageData, AcquisitionData, AcquisitionGeometry from cil.framework import DataOrder diff --git a/Wrappers/Python/cil/plugins/tigre/__init__.py b/Wrappers/Python/cil/plugins/tigre/__init__.py index 632d18dbd..3f23da8cd 100644 --- a/Wrappers/Python/cil/plugins/tigre/__init__.py +++ b/Wrappers/Python/cil/plugins/tigre/__init__.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from .Geometry import CIL2TIGREGeometry from .ProjectionOperator import ProjectionOperator diff --git a/Wrappers/Python/cil/processors/AbsorptionTransmissionConverter.py b/Wrappers/Python/cil/processors/AbsorptionTransmissionConverter.py index d38bcd8f8..64d6b10e1 100644 --- a/Wrappers/Python/cil/processors/AbsorptionTransmissionConverter.py +++ b/Wrappers/Python/cil/processors/AbsorptionTransmissionConverter.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataProcessor, AcquisitionData, ImageData, DataContainer, AcquisitionGeometry, ImageGeometry diff --git a/Wrappers/Python/cil/processors/Binner.py b/Wrappers/Python/cil/processors/Binner.py index f97d85ea6..2fb5de57e 100644 --- a/Wrappers/Python/cil/processors/Binner.py +++ b/Wrappers/Python/cil/processors/Binner.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.processors import Slicer import numpy as np diff --git a/Wrappers/Python/cil/processors/CentreOfRotationCorrector.py b/Wrappers/Python/cil/processors/CentreOfRotationCorrector.py index 77be07b92..ab1f8d58c 100644 --- a/Wrappers/Python/cil/processors/CentreOfRotationCorrector.py +++ b/Wrappers/Python/cil/processors/CentreOfRotationCorrector.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataProcessor from cil.processors.CofR_xcorrelation import CofR_xcorrelation diff --git a/Wrappers/Python/cil/processors/CofR_image_sharpness.py b/Wrappers/Python/cil/processors/CofR_image_sharpness.py index 053869c08..504d30fff 100644 --- a/Wrappers/Python/cil/processors/CofR_image_sharpness.py +++ b/Wrappers/Python/cil/processors/CofR_image_sharpness.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import Processor, AcquisitionData, DataOrder import matplotlib.pyplot as plt diff --git a/Wrappers/Python/cil/processors/CofR_xcorrelation.py b/Wrappers/Python/cil/processors/CofR_xcorrelation.py index c975a736f..976a1a7a0 100644 --- a/Wrappers/Python/cil/processors/CofR_xcorrelation.py +++ b/Wrappers/Python/cil/processors/CofR_xcorrelation.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import Processor, AcquisitionData import numpy as np diff --git a/Wrappers/Python/cil/processors/MaskGenerator.py b/Wrappers/Python/cil/processors/MaskGenerator.py index 74e76a282..020eddeee 100644 --- a/Wrappers/Python/cil/processors/MaskGenerator.py +++ b/Wrappers/Python/cil/processors/MaskGenerator.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataProcessor, AcquisitionData, ImageData, DataContainer, ImageGeometry import warnings diff --git a/Wrappers/Python/cil/processors/Masker.py b/Wrappers/Python/cil/processors/Masker.py index 46a5aa5b4..a94f67218 100644 --- a/Wrappers/Python/cil/processors/Masker.py +++ b/Wrappers/Python/cil/processors/Masker.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataProcessor, AcquisitionData, ImageData, ImageGeometry, DataContainer import warnings diff --git a/Wrappers/Python/cil/processors/Normaliser.py b/Wrappers/Python/cil/processors/Normaliser.py index afa970b6a..23a68044f 100644 --- a/Wrappers/Python/cil/processors/Normaliser.py +++ b/Wrappers/Python/cil/processors/Normaliser.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import Processor, DataContainer, AcquisitionData,\ AcquisitionGeometry, ImageGeometry, ImageData diff --git a/Wrappers/Python/cil/processors/Padder.py b/Wrappers/Python/cil/processors/Padder.py index 79b847f4b..879771db8 100644 --- a/Wrappers/Python/cil/processors/Padder.py +++ b/Wrappers/Python/cil/processors/Padder.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataProcessor, AcquisitionData, ImageData diff --git a/Wrappers/Python/cil/processors/RingRemover.py b/Wrappers/Python/cil/processors/RingRemover.py index 7cd9b9143..968115857 100644 --- a/Wrappers/Python/cil/processors/RingRemover.py +++ b/Wrappers/Python/cil/processors/RingRemover.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from scipy.fftpack import fftshift, ifftshift, fft, ifft import numpy as np diff --git a/Wrappers/Python/cil/processors/Slicer.py b/Wrappers/Python/cil/processors/Slicer.py index 4fb0685e3..4f8584b8c 100644 --- a/Wrappers/Python/cil/processors/Slicer.py +++ b/Wrappers/Python/cil/processors/Slicer.py @@ -1,19 +1,22 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. from cil.framework import DataProcessor, AcquisitionData, ImageData, DataContainer from cil.framework import AcquisitionGeometry, ImageGeometry, VectorGeometry import numpy as np diff --git a/Wrappers/Python/cil/processors/TransmissionAbsorptionConverter.py b/Wrappers/Python/cil/processors/TransmissionAbsorptionConverter.py index a8f27be41..f14e0c065 100644 --- a/Wrappers/Python/cil/processors/TransmissionAbsorptionConverter.py +++ b/Wrappers/Python/cil/processors/TransmissionAbsorptionConverter.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import DataProcessor, AcquisitionData, ImageData, DataContainer import warnings diff --git a/Wrappers/Python/cil/processors/__init__.py b/Wrappers/Python/cil/processors/__init__.py old mode 100755 new mode 100644 index efa759c4d..76eb0a3de --- a/Wrappers/Python/cil/processors/__init__.py +++ b/Wrappers/Python/cil/processors/__init__.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from .CentreOfRotationCorrector import CentreOfRotationCorrector from .Normaliser import Normaliser diff --git a/Wrappers/Python/cil/processors/cilacc_binner.py b/Wrappers/Python/cil/processors/cilacc_binner.py index b50c2419b..1dc2d33d4 100644 --- a/Wrappers/Python/cil/processors/cilacc_binner.py +++ b/Wrappers/Python/cil/processors/cilacc_binner.py @@ -1,3 +1,22 @@ +# -*- coding: utf-8 -*- +# Copyright 2023 United Kingdom Research and Innovation +# Copyright 2023 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + from cil.framework import cilacc import numpy as np diff --git a/Wrappers/Python/cil/recon/FBP.py b/Wrappers/Python/cil/recon/FBP.py index 3ee188bc5..ea02d648e 100644 --- a/Wrappers/Python/cil/recon/FBP.py +++ b/Wrappers/Python/cil/recon/FBP.py @@ -1,19 +1,22 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. from cil.framework import cilacc from cil.framework import AcquisitionGeometry from cil.recon import Reconstructor diff --git a/Wrappers/Python/cil/recon/Reconstructor.py b/Wrappers/Python/cil/recon/Reconstructor.py index 9f1eaced3..9bbda4cb8 100644 --- a/Wrappers/Python/cil/recon/Reconstructor.py +++ b/Wrappers/Python/cil/recon/Reconstructor.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import AcquisitionData, ImageGeometry, DataOrder import importlib diff --git a/Wrappers/Python/cil/recon/__init__.py b/Wrappers/Python/cil/recon/__init__.py index 854ae475c..5d02d057b 100644 --- a/Wrappers/Python/cil/recon/__init__.py +++ b/Wrappers/Python/cil/recon/__init__.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from .Reconstructor import Reconstructor from .FBP import FBP diff --git a/Wrappers/Python/cil/utilities/__init__.py b/Wrappers/Python/cil/utilities/__init__.py index bd1c8cfd9..ea811c542 100644 --- a/Wrappers/Python/cil/utilities/__init__.py +++ b/Wrappers/Python/cil/utilities/__init__.py @@ -1,16 +1,18 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt diff --git a/Wrappers/Python/cil/utilities/dataexample.py b/Wrappers/Python/cil/utilities/dataexample.py index 5b0b87303..b922332e1 100644 --- a/Wrappers/Python/cil/utilities/dataexample.py +++ b/Wrappers/Python/cil/utilities/dataexample.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.framework import ImageData, ImageGeometry, DataContainer import numpy diff --git a/Wrappers/Python/cil/utilities/display.py b/Wrappers/Python/cil/utilities/display.py index 9b08d2d94..42b21ed24 100644 --- a/Wrappers/Python/cil/utilities/display.py +++ b/Wrappers/Python/cil/utilities/display.py @@ -1,19 +1,22 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt +# Kyle Pidgeon (UKRI-STFC) #%% diff --git a/Wrappers/Python/cil/utilities/jupyter/__init__.py b/Wrappers/Python/cil/utilities/jupyter/__init__.py index b8554d6fe..22f6c618c 100644 --- a/Wrappers/Python/cil/utilities/jupyter/__init__.py +++ b/Wrappers/Python/cil/utilities/jupyter/__init__.py @@ -1,19 +1,22 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt +# Kyle Pidgeon (UKRI-STFC) try: from ipywidgets import interactive_output diff --git a/Wrappers/Python/cil/utilities/multiprocessing.py b/Wrappers/Python/cil/utilities/multiprocessing.py index 94cafb930..dba804e15 100644 --- a/Wrappers/Python/cil/utilities/multiprocessing.py +++ b/Wrappers/Python/cil/utilities/multiprocessing.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import multiprocessing NUM_THREADS = max(int(multiprocessing.cpu_count()/2),1) \ No newline at end of file diff --git a/Wrappers/Python/cil/utilities/noise.py b/Wrappers/Python/cil/utilities/noise.py index e1d219a50..89b8c69ad 100644 --- a/Wrappers/Python/cil/utilities/noise.py +++ b/Wrappers/Python/cil/utilities/noise.py @@ -1,19 +1,22 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. from cil.utilities.dataexample import TestData def gaussian(image, seed=None, clip=True, **kwargs): diff --git a/Wrappers/Python/cil/utilities/quality_measures.py b/Wrappers/Python/cil/utilities/quality_measures.py index 53e21530c..1ab30e8fa 100644 --- a/Wrappers/Python/cil/utilities/quality_measures.py +++ b/Wrappers/Python/cil/utilities/quality_measures.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.functions import L2NormSquared, L1Norm import numpy as np diff --git a/Wrappers/Python/environment.yml b/Wrappers/Python/environment.yml index 5cdd6fecf..93988c0ea 100644 --- a/Wrappers/Python/environment.yml +++ b/Wrappers/Python/environment.yml @@ -1,3 +1,21 @@ +# -*- coding: utf-8 -*- +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt name: test_new dependencies: - python=3.6.7=h8dc6b48_1004 diff --git a/Wrappers/Python/test/__init__.py b/Wrappers/Python/test/__init__.py index 22bd05b44..5e91003ed 100644 --- a/Wrappers/Python/test/__init__.py +++ b/Wrappers/Python/test/__init__.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -12,4 +12,7 @@ # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and -# limitations under the License. \ No newline at end of file +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt \ No newline at end of file diff --git a/Wrappers/Python/test/test_AcquisitionGeometry.py b/Wrappers/Python/test/test_AcquisitionGeometry.py index 2d064ba87..8b48dca84 100644 --- a/Wrappers/Python/test/test_AcquisitionGeometry.py +++ b/Wrappers/Python/test/test_AcquisitionGeometry.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_BlockDataContainer.py b/Wrappers/Python/test/test_BlockDataContainer.py old mode 100755 new mode 100644 index 652dcafd3..c608c7e5f --- a/Wrappers/Python/test/test_BlockDataContainer.py +++ b/Wrappers/Python/test/test_BlockDataContainer.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_BlockOperator.py b/Wrappers/Python/test/test_BlockOperator.py index b2225b452..3e81ab4ca 100644 --- a/Wrappers/Python/test/test_BlockOperator.py +++ b/Wrappers/Python/test/test_BlockOperator.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_CIL_CVXPy.py b/Wrappers/Python/test/test_CIL_CVXPy.py index c4b52e6e8..e47b6607f 100644 --- a/Wrappers/Python/test/test_CIL_CVXPy.py +++ b/Wrappers/Python/test/test_CIL_CVXPy.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_DataContainer.py b/Wrappers/Python/test/test_DataContainer.py old mode 100755 new mode 100644 index c73c0f2ee..f84e9bf36 --- a/Wrappers/Python/test/test_DataContainer.py +++ b/Wrappers/Python/test/test_DataContainer.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_DataProcessor.py b/Wrappers/Python/test/test_DataProcessor.py old mode 100755 new mode 100644 index b1eb9ff5b..eaae2d2be --- a/Wrappers/Python/test/test_DataProcessor.py +++ b/Wrappers/Python/test/test_DataProcessor.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest import numpy diff --git a/Wrappers/Python/test/test_Gradient.py b/Wrappers/Python/test/test_Gradient.py old mode 100755 new mode 100644 index a353c8af8..607e1eeb9 --- a/Wrappers/Python/test/test_Gradient.py +++ b/Wrappers/Python/test/test_Gradient.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_ISTA_algorithm.py b/Wrappers/Python/test/test_ISTA_algorithm.py index bfd3c3d24..bdb9a9028 100644 --- a/Wrappers/Python/test/test_ISTA_algorithm.py +++ b/Wrappers/Python/test/test_ISTA_algorithm.py @@ -1,19 +1,21 @@ # -*- coding: utf-8 -*- -# This work is part of the Core Imaging Library (CIL) developed by CCPi -# (Collaborative Computational Project in Tomographic Imaging), with -# substantial contributions by UKRI-STFC and University of Manchester. - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt from cil.optimisation.algorithms import ISTA diff --git a/Wrappers/Python/test/test_NexusReaderWriter.py b/Wrappers/Python/test/test_NexusReaderWriter.py index 51a14456d..4cbba1814 100644 --- a/Wrappers/Python/test/test_NexusReaderWriter.py +++ b/Wrappers/Python/test/test_NexusReaderWriter.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,7 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. - +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests import os diff --git a/Wrappers/Python/test/test_Operator.py b/Wrappers/Python/test/test_Operator.py index 16d56b8fd..01988899c 100644 --- a/Wrappers/Python/test/test_Operator.py +++ b/Wrappers/Python/test/test_Operator.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_PluginsAstra_CPU.py b/Wrappers/Python/test/test_PluginsAstra_CPU.py index 00c9b4a64..68ce36a12 100644 --- a/Wrappers/Python/test/test_PluginsAstra_CPU.py +++ b/Wrappers/Python/test/test_PluginsAstra_CPU.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils_projectors import TestCommon_ProjectionOperator_SIM diff --git a/Wrappers/Python/test/test_PluginsAstra_FBP.py b/Wrappers/Python/test/test_PluginsAstra_FBP.py index ab4efc8a7..6e762cfda 100644 --- a/Wrappers/Python/test/test_PluginsAstra_FBP.py +++ b/Wrappers/Python/test/test_PluginsAstra_FBP.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils_projectors import TestCommon_FBP_SIM diff --git a/Wrappers/Python/test/test_PluginsAstra_GPU.py b/Wrappers/Python/test/test_PluginsAstra_GPU.py index ec6050df9..8b6d67312 100644 --- a/Wrappers/Python/test/test_PluginsAstra_GPU.py +++ b/Wrappers/Python/test/test_PluginsAstra_GPU.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils_projectors import TestCommon_ProjectionOperator_SIM diff --git a/Wrappers/Python/test/test_PluginsAstra_Geometry.py b/Wrappers/Python/test/test_PluginsAstra_Geometry.py index 844eadd26..2161c8cd7 100644 --- a/Wrappers/Python/test/test_PluginsAstra_Geometry.py +++ b/Wrappers/Python/test/test_PluginsAstra_Geometry.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from cil.framework import AcquisitionGeometry diff --git a/Wrappers/Python/test/test_PluginsAstra_ProjectorConsistency.py b/Wrappers/Python/test/test_PluginsAstra_ProjectorConsistency.py index c497dc85c..6dce544ee 100644 --- a/Wrappers/Python/test/test_PluginsAstra_ProjectorConsistency.py +++ b/Wrappers/Python/test/test_PluginsAstra_ProjectorConsistency.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from cil.framework import AcquisitionGeometry diff --git a/Wrappers/Python/test/test_PluginsAstra_Projectors.py b/Wrappers/Python/test/test_PluginsAstra_Projectors.py index d91ec59ca..d759b9292 100644 --- a/Wrappers/Python/test/test_PluginsAstra_Projectors.py +++ b/Wrappers/Python/test/test_PluginsAstra_Projectors.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from cil.framework import AcquisitionGeometry diff --git a/Wrappers/Python/test/test_PluginsRegularisation.py b/Wrappers/Python/test/test_PluginsRegularisation.py index 57375a648..b7e07ebf8 100644 --- a/Wrappers/Python/test/test_PluginsRegularisation.py +++ b/Wrappers/Python/test/test_PluginsRegularisation.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest import numpy as np diff --git a/Wrappers/Python/test/test_PluginsTigre_FBP.py b/Wrappers/Python/test/test_PluginsTigre_FBP.py index 19b706e90..81b7f9ec1 100644 --- a/Wrappers/Python/test/test_PluginsTigre_FBP.py +++ b/Wrappers/Python/test/test_PluginsTigre_FBP.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils_projectors import TestCommon_FBP_SIM diff --git a/Wrappers/Python/test/test_PluginsTigre_General.py b/Wrappers/Python/test/test_PluginsTigre_General.py index 6596d1579..04b5d579d 100644 --- a/Wrappers/Python/test/test_PluginsTigre_General.py +++ b/Wrappers/Python/test/test_PluginsTigre_General.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from cil.framework import AcquisitionGeometry diff --git a/Wrappers/Python/test/test_PluginsTigre_Siddon.py b/Wrappers/Python/test/test_PluginsTigre_Siddon.py index cdfd6633a..e691d05ae 100644 --- a/Wrappers/Python/test/test_PluginsTigre_Siddon.py +++ b/Wrappers/Python/test/test_PluginsTigre_Siddon.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils_projectors import TestCommon_ProjectionOperator_SIM diff --git a/Wrappers/Python/test/test_PluginsTigre_interpolated.py b/Wrappers/Python/test/test_PluginsTigre_interpolated.py index 74dd7e02b..791cfa62b 100644 --- a/Wrappers/Python/test/test_PluginsTigre_interpolated.py +++ b/Wrappers/Python/test/test_PluginsTigre_interpolated.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils_projectors import TestCommon_ProjectionOperator_SIM diff --git a/Wrappers/Python/test/test_PluginsTomoPhantom.py b/Wrappers/Python/test/test_PluginsTomoPhantom.py index c657132fe..d8f2e18a2 100644 --- a/Wrappers/Python/test/test_PluginsTomoPhantom.py +++ b/Wrappers/Python/test/test_PluginsTomoPhantom.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from cil.framework import ImageGeometry, AcquisitionGeometry diff --git a/Wrappers/Python/test/test_SIRF.py b/Wrappers/Python/test/test_SIRF.py index 592b594cf..eaece897e 100644 --- a/Wrappers/Python/test/test_SIRF.py +++ b/Wrappers/Python/test/test_SIRF.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_SumFunction.py b/Wrappers/Python/test/test_SumFunction.py index dc5beeb83..ecb9f1406 100644 --- a/Wrappers/Python/test/test_SumFunction.py +++ b/Wrappers/Python/test/test_SumFunction.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_TranslateFunction.py b/Wrappers/Python/test/test_TranslateFunction.py index 6cf79f65a..8198f9dac 100644 --- a/Wrappers/Python/test/test_TranslateFunction.py +++ b/Wrappers/Python/test/test_TranslateFunction.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_algorithms.py b/Wrappers/Python/test/test_algorithms.py old mode 100755 new mode 100644 index 53069404e..8c2a2a318 --- a/Wrappers/Python/test/test_algorithms.py +++ b/Wrappers/Python/test/test_algorithms.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_dataexample.py b/Wrappers/Python/test/test_dataexample.py old mode 100755 new mode 100644 index 3692dc9e9..850b37a83 --- a/Wrappers/Python/test/test_dataexample.py +++ b/Wrappers/Python/test/test_dataexample.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_function_KullbackLeibler.py b/Wrappers/Python/test/test_function_KullbackLeibler.py index be479467a..1a7472830 100644 --- a/Wrappers/Python/test/test_function_KullbackLeibler.py +++ b/Wrappers/Python/test/test_function_KullbackLeibler.py @@ -1,17 +1,21 @@ -# Copyright 2022 United Kingdom Research and Innovation -# Copyright 2022 The University of Manchester - -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at - -# http://www.apache.org/licenses/LICENSE-2.0 - -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. +# -*- coding: utf-8 -*- +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from cil.optimisation.functions import KullbackLeibler diff --git a/Wrappers/Python/test/test_functions.py b/Wrappers/Python/test/test_functions.py index f22b26c5a..3f7da34a3 100644 --- a/Wrappers/Python/test/test_functions.py +++ b/Wrappers/Python/test/test_functions.py @@ -1,11 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2023 United Kingdom Research and Innovation -# Copyright 2023 The University of Manchester -# -# Author(s): -# Evangelos Papoutsellis (UKRI) -# Edoardo Pasca (UKRI) -# Gemma Fardell (UKRI) +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -18,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest diff --git a/Wrappers/Python/test/test_io.py b/Wrappers/Python/test/test_io.py index 463cc3ca5..b352f6e35 100644 --- a/Wrappers/Python/test/test_io.py +++ b/Wrappers/Python/test/test_io.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from unittest.mock import patch diff --git a/Wrappers/Python/test/test_quality_measures.py b/Wrappers/Python/test/test_quality_measures.py index 3f9ad8f95..0fb27fcae 100644 --- a/Wrappers/Python/test/test_quality_measures.py +++ b/Wrappers/Python/test/test_quality_measures.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_reconstructors.py b/Wrappers/Python/test/test_reconstructors.py index 8f1ba50b5..d8b0320fa 100644 --- a/Wrappers/Python/test/test_reconstructors.py +++ b/Wrappers/Python/test/test_reconstructors.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from cil.framework import AcquisitionGeometry diff --git a/Wrappers/Python/test/test_ring_processor.py b/Wrappers/Python/test/test_ring_processor.py index d5d1a9ae3..5e63e44d6 100644 --- a/Wrappers/Python/test/test_ring_processor.py +++ b/Wrappers/Python/test/test_ring_processor.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from cil.processors import RingRemover diff --git a/Wrappers/Python/test/test_run_test.py b/Wrappers/Python/test/test_run_test.py old mode 100755 new mode 100644 index 34464ab15..46bbb815c --- a/Wrappers/Python/test/test_run_test.py +++ b/Wrappers/Python/test/test_run_test.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest import numpy diff --git a/Wrappers/Python/test/test_subset.py b/Wrappers/Python/test/test_subset.py index 7a18afe0c..6ff93657f 100644 --- a/Wrappers/Python/test/test_subset.py +++ b/Wrappers/Python/test/test_subset.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_tiff_readerwriter.py b/Wrappers/Python/test/test_tiff_readerwriter.py index 7f0c8946a..3ee589915 100644 --- a/Wrappers/Python/test/test_tiff_readerwriter.py +++ b/Wrappers/Python/test/test_tiff_readerwriter.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/test_version.py b/Wrappers/Python/test/test_version.py index 914893b16..322e4b743 100644 --- a/Wrappers/Python/test/test_version.py +++ b/Wrappers/Python/test/test_version.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from utils import initialise_tests diff --git a/Wrappers/Python/test/testclass.py b/Wrappers/Python/test/testclass.py old mode 100755 new mode 100644 index e06a587c7..6b8906d1b --- a/Wrappers/Python/test/testclass.py +++ b/Wrappers/Python/test/testclass.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import unittest from cil.framework import DataContainer diff --git a/Wrappers/Python/test/utils.py b/Wrappers/Python/test/utils.py index b59cd16d6..d6044d6a4 100644 --- a/Wrappers/Python/test/utils.py +++ b/Wrappers/Python/test/utils.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import os import subprocess diff --git a/Wrappers/Python/test/utils_projectors.py b/Wrappers/Python/test/utils_projectors.py index d34cf0417..5a2d36ad4 100644 --- a/Wrappers/Python/test/utils_projectors.py +++ b/Wrappers/Python/test/utils_projectors.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -# Copyright 2018 - 2022 United Kingdom Research and Innovation -# Copyright 2018 - 2022 The University of Manchester +# Copyright 2022 United Kingdom Research and Innovation +# Copyright 2022 The University of Manchester # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -13,6 +13,9 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt import numpy as np from cil.optimisation.operators import LinearOperator diff --git a/_config.yml b/_config.yml index c74188174..057c91070 100644 --- a/_config.yml +++ b/_config.yml @@ -1 +1,19 @@ +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + theme: jekyll-theme-slate \ No newline at end of file diff --git a/docs/Makefile b/docs/Makefile old mode 100755 new mode 100644 index 69fe55ecf..fef05dccf --- a/docs/Makefile +++ b/docs/Makefile @@ -1,3 +1,22 @@ +## -*- coding: utf-8 -*- +## Copyright 2019 United Kingdom Research and Innovation +## Copyright 2019 The University of Manchester +## +## Licensed under the Apache License, Version 2.0 (the "License"); +## you may not use this file except in compliance with the License. +## You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, software +## distributed under the License is distributed on an "AS IS" BASIS, +## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +## See the License for the specific language governing permissions and +## limitations under the License. +## +## Authors: +## CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + # Minimal makefile for Sphinx documentation # diff --git a/docs/docs_environment.yml b/docs/docs_environment.yml index aae8fc662..f7c4fd502 100644 --- a/docs/docs_environment.yml +++ b/docs/docs_environment.yml @@ -1,3 +1,22 @@ +# -*- coding: utf-8 -*- +# Copyright 2021 United Kingdom Research and Innovation +# Copyright 2021 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + name: docs channels: - conda-forge diff --git a/docs/make.bat b/docs/make.bat old mode 100755 new mode 100644 index 543c6b13b..5c18ceb9f --- a/docs/make.bat +++ b/docs/make.bat @@ -1,3 +1,21 @@ +REM -*- coding: utf-8 -*- +REM Copyright 2019 United Kingdom Research and Innovation +REM Copyright 2019 The University of Manchester +REM +REM Licensed under the Apache License, Version 2.0 (the "License"); +REM you may not use this file except in compliance with the License. +REM You may obtain a copy of the License at +REM +REM http://www.apache.org/licenses/LICENSE-2.0 +REM +REM Unless required by applicable law or agreed to in writing, software +REM distributed under the License is distributed on an "AS IS" BASIS, +REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +REM See the License for the specific language governing permissions and +REM limitations under the License. +REM +REM Authors: +REM CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt @ECHO OFF pushd %~dp0 diff --git a/docs/source/conf.py b/docs/source/conf.py old mode 100755 new mode 100644 index 92db0ecfe..0f76fcdcb --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -1,5 +1,23 @@ # -*- coding: utf-8 -*- -# +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + + # Configuration file for the Sphinx documentation builder. # # This file does only contain a selection of the most common options. For a diff --git a/docs/source/developer_guide.rst b/docs/source/developer_guide.rst index 91b5b3504..d9e298842 100644 --- a/docs/source/developer_guide.rst +++ b/docs/source/developer_guide.rst @@ -1,4 +1,24 @@ -Developer's guide +.. -*- coding: utf-8 -*- + Copyright 2020 United Kingdom Research and Innovation + Copyright 2020 The University of Manchester + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Authors: + CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + Kyle Pidgeon (UKRI-STFC) + +Developers' Guide ***************** CIL is an Object Orientated software. It has evolved during the years and it currently does not fully adheres to the following conventions. New additions must comply with diff --git a/docs/source/framework.rst b/docs/source/framework.rst index a3c308178..d62772bbe 100644 --- a/docs/source/framework.rst +++ b/docs/source/framework.rst @@ -1,3 +1,22 @@ +.. -*- coding: utf-8 -*- + Copyright 2019 United Kingdom Research and Innovation + Copyright 2019 The University of Manchester + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Authors: + CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + Framework ********* diff --git a/docs/source/index.rst b/docs/source/index.rst old mode 100755 new mode 100644 index e8f712bc2..ecc527622 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -1,3 +1,23 @@ +.. -*- coding: utf-8 -*- + Copyright 2019 United Kingdom Research and Innovation + Copyright 2019 The University of Manchester + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Authors: + CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + + .. CCPi-Framework documentation master file, created by sphinx-quickstart on Tue Mar 19 15:12:44 2019. You can adapt this file completely to your liking, but it should at least diff --git a/docs/source/introduction.rst b/docs/source/introduction.rst index 3d859967e..19fa04185 100644 --- a/docs/source/introduction.rst +++ b/docs/source/introduction.rst @@ -1,3 +1,22 @@ +.. -*- coding: utf-8 -*- + Copyright 2022 United Kingdom Research and Innovation + Copyright 2022 The University of Manchester + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Authors: + CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + Introduction ************ diff --git a/docs/source/io.rst b/docs/source/io.rst index 5d6aafaa3..ca17e93ff 100644 --- a/docs/source/io.rst +++ b/docs/source/io.rst @@ -1,3 +1,23 @@ +.. -*- coding: utf-8 -*- + Copyright 2019 United Kingdom Research and Innovation + Copyright 2019 The University of Manchester + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Authors: + CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + Kyle Pidgeon (UKRI-STFC) + Read/ write AcquisitionData and ImageData ***************************************** diff --git a/docs/source/optimisation.rst b/docs/source/optimisation.rst index a3b5c571d..9409d4fb9 100644 --- a/docs/source/optimisation.rst +++ b/docs/source/optimisation.rst @@ -1,3 +1,22 @@ +.. -*- coding: utf-8 -*- + Copyright 2019 United Kingdom Research and Innovation + Copyright 2019 The University of Manchester + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Authors: + CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + Optimisation framework ********************** This package allows rapid prototyping of optimisation-based reconstruction problems, i.e. defining and solving different optimization problems to enforce different properties on the reconstructed image. diff --git a/docs/source/plugins.rst b/docs/source/plugins.rst index 1b06a15f4..d4f80ca0f 100644 --- a/docs/source/plugins.rst +++ b/docs/source/plugins.rst @@ -1,3 +1,22 @@ +.. -*- coding: utf-8 -*- + Copyright 2019 United Kingdom Research and Innovation + Copyright 2019 The University of Manchester + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Authors: + CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + CIL Plugins ************ diff --git a/docs/source/processors.rst b/docs/source/processors.rst index 078e4d747..e237a0441 100644 --- a/docs/source/processors.rst +++ b/docs/source/processors.rst @@ -1,3 +1,22 @@ +.. -*- coding: utf-8 -*- + Copyright 2021 United Kingdom Research and Innovation + Copyright 2021 The University of Manchester + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Authors: + CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + Processors ********** diff --git a/docs/source/recon.rst b/docs/source/recon.rst index 756d43caf..a2cbee721 100644 --- a/docs/source/recon.rst +++ b/docs/source/recon.rst @@ -1,3 +1,22 @@ +.. -*- coding: utf-8 -*- + Copyright 2021 United Kingdom Research and Innovation + Copyright 2021 The University of Manchester + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Authors: + CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + Recon ***** diff --git a/docs/source/refs.bib b/docs/source/refs.bib index 974a597f2..376bb7e11 100644 --- a/docs/source/refs.bib +++ b/docs/source/refs.bib @@ -1,3 +1,22 @@ +.. -*- coding: utf-8 -*- + Copyright 2021 United Kingdom Research and Innovation + Copyright 2021 The University of Manchester + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Authors: + CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + @Article{CP2011, author={Chambolle, Antonin and Pock, Thomas}, diff --git a/docs/source/utilities.rst b/docs/source/utilities.rst index ccba32ffd..afdd491a1 100644 --- a/docs/source/utilities.rst +++ b/docs/source/utilities.rst @@ -1,3 +1,22 @@ +.. -*- coding: utf-8 -*- + Copyright 2021 United Kingdom Research and Innovation + Copyright 2021 The University of Manchester + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + Authors: + CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + Utilities ********* diff --git a/recipe/bld.bat b/recipe/bld.bat index 735498142..21e2eacde 100644 --- a/recipe/bld.bat +++ b/recipe/bld.bat @@ -1,3 +1,21 @@ +REM -*- coding: utf-8 -*- +REM Copyright 2019 United Kingdom Research and Innovation +REM Copyright 2019 The University of Manchester + +REM Licensed under the Apache License, Version 2.0 (the "License"); +REM you may not use this file except in compliance with the License. +REM You may obtain a copy of the License at + +REM http://www.apache.org/licenses/LICENSE-2.0 + +REM Unless required by applicable law or agreed to in writing, software +REM distributed under the License is distributed on an "AS IS" BASIS, +REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +REM See the License for the specific language governing permissions and +REM limitations under the License. + +REM Authors: +REM CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt ROBOCOPY /E "%RECIPE_DIR%\.." "%SRC_DIR%" /XD .git /XD Wrappers\Python\build diff --git a/recipe/build.sh b/recipe/build.sh index 8f54fb082..2e83de237 100644 --- a/recipe/build.sh +++ b/recipe/build.sh @@ -1,3 +1,22 @@ +# -*- coding: utf-8 -*- +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + if [ `python -c "from __future__ import print_function; import platform; print (platform.system())"` == "Darwin" ] ; then echo "Darwin"; diff --git a/recipe/conda_build_config.yaml b/recipe/conda_build_config.yaml index 9be3cda5e..cd7d480ce 100644 --- a/recipe/conda_build_config.yaml +++ b/recipe/conda_build_config.yaml @@ -1,3 +1,23 @@ +# -*- coding: utf-8 -*- +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt +# Tomas Kulhanek (STFC) + #creates pairs of versions using zip_keys, lists must be the same length python: - 3.8 diff --git a/recipe/meta.yaml b/recipe/meta.yaml index 8f273c5ef..689d36f7b 100644 --- a/recipe/meta.yaml +++ b/recipe/meta.yaml @@ -1,3 +1,22 @@ +# -*- coding: utf-8 -*- +# Copyright 2018 United Kingdom Research and Innovation +# Copyright 2018 The University of Manchester + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt +# Kyle Pidgeon (UKRI-STFC) package: name: cil # use the latest stable release version diff --git a/scripts/create_local_env_for_cil_development.sh b/scripts/create_local_env_for_cil_development.sh index 3445e2df6..0efe88ba0 100644 --- a/scripts/create_local_env_for_cil_development.sh +++ b/scripts/create_local_env_for_cil_development.sh @@ -1,3 +1,21 @@ +# -*- coding: utf-8 -*- +# Copyright 2020 United Kingdom Research and Innovation +# Copyright 2020 The University of Manchester + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt #! /bin/bash while getopts hn:p:e: option diff --git a/scripts/create_local_env_for_cil_development_tests.sh b/scripts/create_local_env_for_cil_development_tests.sh index 7762726ad..6086d342c 100644 --- a/scripts/create_local_env_for_cil_development_tests.sh +++ b/scripts/create_local_env_for_cil_development_tests.sh @@ -1,3 +1,5 @@ + + #! /bin/bash diff --git a/scripts/requirements-test.yml b/scripts/requirements-test.yml index 0e200e30a..7677e3985 100644 --- a/scripts/requirements-test.yml +++ b/scripts/requirements-test.yml @@ -1,3 +1,21 @@ +# -*- coding: utf-8 -*- +# Copyright 2023 United Kingdom Research and Innovation +# Copyright 2023 The University of Manchester + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt name: cil_dev channels: - conda-forge diff --git a/src/Core/Binning.cpp b/src/Core/Binning.cpp index c613c45c9..030b4e8c7 100644 --- a/src/Core/Binning.cpp +++ b/src/Core/Binning.cpp @@ -1,5 +1,23 @@ -#include "Binning.h" +// -*- coding: utf-8 -*- +// Copyright 2023 United Kingdom Research and Innovation +// Copyright 2023 The University of Manchester +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// Authors: +// CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt +#include "Binning.h" #include #include #include diff --git a/src/Core/CMakeLists.txt b/src/Core/CMakeLists.txt index f1f323383..2a27183d3 100644 --- a/src/Core/CMakeLists.txt +++ b/src/Core/CMakeLists.txt @@ -1,3 +1,21 @@ +# Copyright 2019 United Kingdom Research and Innovation +# Copyright 2019 The University of Manchester +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# Authors: +# CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt +# Richard Brown (UCL) set (CMAKE_CXX_STANDARD 11) set (CMAKE_CXX_STANDARD_REQUIRED ON) diff --git a/src/Core/FBP_filtering.cpp b/src/Core/FBP_filtering.cpp index 68f9fa311..9857fbfa1 100644 --- a/src/Core/FBP_filtering.cpp +++ b/src/Core/FBP_filtering.cpp @@ -1,3 +1,22 @@ +// -*- coding: utf-8 -*- +// Copyright 2021 United Kingdom Research and Innovation +// Copyright 2021 The University of Manchester +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// Authors: +// CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + #include "FBP_filtering.h" int filter_projections_avh(float * data, const float * filter, const float* weights, int order, long num_proj, long pix_y, long pix_x) diff --git a/src/Core/FiniteDifferenceLibrary.cpp b/src/Core/FiniteDifferenceLibrary.cpp index b19add331..be2feeda6 100644 --- a/src/Core/FiniteDifferenceLibrary.cpp +++ b/src/Core/FiniteDifferenceLibrary.cpp @@ -1,3 +1,24 @@ +// -*- coding: utf-8 -*- +// Copyright 2019 United Kingdom Research and Innovation +// Copyright 2019 The University of Manchester +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// Authors: +// CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt +// Sam Tygier (UKRI-STFC) + + #include "FiniteDifferenceLibrary.h" DLL_EXPORT int openMPtest(int nThreads) diff --git a/src/Core/axpby.cpp b/src/Core/axpby.cpp index 0fc2ee948..ec09ccd36 100644 --- a/src/Core/axpby.cpp +++ b/src/Core/axpby.cpp @@ -1,3 +1,23 @@ +// -*- coding: utf-8 -*- +// Copyright 2019 United Kingdom Research and Innovation +// Copyright 2019 The University of Manchester +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// Authors: +// CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + + #include "axpby.h" diff --git a/src/Core/include/Binning.h b/src/Core/include/Binning.h index e16384f6b..83586dbbc 100644 --- a/src/Core/include/Binning.h +++ b/src/Core/include/Binning.h @@ -1,3 +1,21 @@ +// -*- coding: utf-8 -*- +// Copyright 2023 United Kingdom Research and Innovation +// Copyright 2023 The University of Manchester +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// Authors: +// CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt #ifndef _BINNER_H_ #define _BINNER_H_ diff --git a/src/Core/include/FBP_filtering.h b/src/Core/include/FBP_filtering.h index c60508d3a..a0aba6002 100644 --- a/src/Core/include/FBP_filtering.h +++ b/src/Core/include/FBP_filtering.h @@ -1,3 +1,22 @@ +// -*- coding: utf-8 -*- +// Copyright 2021 United Kingdom Research and Innovation +// Copyright 2021 The University of Manchester +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// Authors: +// CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + #include #include #include diff --git a/src/Core/include/FiniteDifferenceLibrary.h b/src/Core/include/FiniteDifferenceLibrary.h index e61a13585..cb1293d53 100644 --- a/src/Core/include/FiniteDifferenceLibrary.h +++ b/src/Core/include/FiniteDifferenceLibrary.h @@ -1,3 +1,22 @@ +// -*- coding: utf-8 -*- +// Copyright 2019 United Kingdom Research and Innovation +// Copyright 2019 The University of Manchester +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// Authors: +// CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + #include #include #include diff --git a/src/Core/include/axpby.h b/src/Core/include/axpby.h index 0599e35d2..5711b17ed 100644 --- a/src/Core/include/axpby.h +++ b/src/Core/include/axpby.h @@ -1,3 +1,21 @@ +// -*- coding: utf-8 -*- +// Copyright 2019 United Kingdom Research and Innovation +// Copyright 2019 The University of Manchester +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// Authors: +// CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt #include #include #include diff --git a/src/Core/include/dll_export.h b/src/Core/include/dll_export.h index 20763eab8..37f1615d0 100644 --- a/src/Core/include/dll_export.h +++ b/src/Core/include/dll_export.h @@ -1,3 +1,22 @@ +// -*- coding: utf-8 -*- +// Copyright 2019 United Kingdom Research and Innovation +// Copyright 2019 The University of Manchester +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// Authors: +// CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + #pragma once #ifndef DLLEXPORT_H #define DLLEXPORT_H diff --git a/src/Core/include/utilities.h b/src/Core/include/utilities.h index c3003d696..32ef8344f 100644 --- a/src/Core/include/utilities.h +++ b/src/Core/include/utilities.h @@ -1,3 +1,21 @@ +// -*- coding: utf-8 -*- +// Copyright 2020 United Kingdom Research and Innovation +// Copyright 2020 The University of Manchester +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// Authors: +// CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt #include "omp.h" void threads_setup(int nThreads_requested, int *nThreads_current); \ No newline at end of file diff --git a/src/Core/utilities.cpp b/src/Core/utilities.cpp index 86b23e85a..4aad36ae5 100644 --- a/src/Core/utilities.cpp +++ b/src/Core/utilities.cpp @@ -1,3 +1,22 @@ +// -*- coding: utf-8 -*- +// Copyright 2020 United Kingdom Research and Innovation +// Copyright 2020 The University of Manchester +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// +// Authors: +// CIL Developers, listed at: https://github.com/TomographicImaging/CIL/blob/master/NOTICE.txt + #include "utilities.h" From e37dd956e76bddc2d7024da094f9b12148beb041 Mon Sep 17 00:00:00 2001 From: Gemma Fardell <47746591+gfardell@users.noreply.github.com> Date: Fri, 17 Mar 2023 13:50:11 +0000 Subject: [PATCH 07/12] Update version number (#1454) --- CHANGELOG.md | 2 +- README.md | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 52ca2fc2a..157957909 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,4 @@ -* x.x.x +* 23.0.0 - Partitioner is now able to create batches even if angle is not the outer dimension - Renamed `max_iteration_stop_cryterion` method in the Algorithm class to `max_iteration_stop_criterion` - Removed (previously deprecated) `very_verbose` parameter in `Algorithm`'s run method. diff --git a/README.md b/README.md index 8ca26ae48..9116baa07 100644 --- a/README.md +++ b/README.md @@ -19,13 +19,13 @@ The documentation for CIL can be accessed [here](https://tomographicimaging.gith Binary installation of CIL can be done with `conda`. Install a new environment using: ```bash -conda create --name cil -c conda-forge -c intel -c ccpi cil=22.2.0 +conda create --name cil -c conda-forge -c intel -c ccpi cil=23.0.0 ``` To install CIL and the additional packages and plugins needed to run the [CIL demos](https://github.com/TomographicImaging/CIL-Demos) install the environment with: ```bash -conda create --name cil -c conda-forge -c intel -c astra-toolbox -c ccpi cil=22.2.0 astra-toolbox tigre ccpi-regulariser tomophantom "ipywidgets<8" +conda create --name cil -c conda-forge -c intel -c astra-toolbox -c ccpi cil=23.0.0 astra-toolbox tigre ccpi-regulariser tomophantom "ipywidgets<8" ``` where, @@ -38,7 +38,7 @@ where, ```tomophantom``` [Tomophantom](https://github.com/dkazanc/TomoPhantom) will allow you to generate phantoms to use as test data. -```cudatoolkit``` If you have GPU drivers compatible with more recent CUDA versions you can modify this package selector (installing tigre via conda requires 9.2). +```cudatoolkit``` If you have GPU drivers compatible with more recent CUDA versions you can modify this package selector (installing tigre via conda requires 10.2). ## Dependency From a1fa617a2adabff79bdc51b6c3e53c0739772649 Mon Sep 17 00:00:00 2001 From: Gemma Fardell <47746591+gfardell@users.noreply.github.com> Date: Tue, 21 Mar 2023 10:25:19 +0000 Subject: [PATCH 08/12] Update README.md Signed-off-by: Gemma Fardell <47746591+gfardell@users.noreply.github.com> --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index 9116baa07..2ed62e22b 100644 --- a/README.md +++ b/README.md @@ -27,7 +27,6 @@ To install CIL and the additional packages and plugins needed to run the [CIL de ```bash conda create --name cil -c conda-forge -c intel -c astra-toolbox -c ccpi cil=23.0.0 astra-toolbox tigre ccpi-regulariser tomophantom "ipywidgets<8" ``` - where, ```astra-toolbox``` will allow you to use CIL with the [ASTRA toolbox](http://www.astra-toolbox.com/) projectors (GPLv3 license). From 5e4924f43b95a40c702d413ea2d9ef278b51218b Mon Sep 17 00:00:00 2001 From: Gemma Fardell <47746591+gfardell@users.noreply.github.com> Date: Tue, 21 Mar 2023 10:29:30 +0000 Subject: [PATCH 09/12] Update optimisation.rst Signed-off-by: Gemma Fardell <47746591+gfardell@users.noreply.github.com> --- docs/source/optimisation.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/source/optimisation.rst b/docs/source/optimisation.rst index 9409d4fb9..8b92feb66 100644 --- a/docs/source/optimisation.rst +++ b/docs/source/optimisation.rst @@ -27,7 +27,7 @@ Further, it provides a number of high-level generic implementations of optimisat The fundamental components are: -+ :code:`Operator`: A class specifying a (currently linear) operator ++ :code:`Operator`: A class specifying a (currently linear) operator. + :code:`Function`: A class specifying mathematical functions such as a least squares data fidelity. + :code:`Algorithm`: Implementation of an iterative optimisation algorithm to solve a particular generic optimisation problem. Algorithms are iterable Python object which can be run in a for loop. Can be stopped and warm restarted. From 01f0fee7fd0825b148764aae2dffaf71ee002637 Mon Sep 17 00:00:00 2001 From: Gemma Fardell <47746591+gfardell@users.noreply.github.com> Date: Tue, 21 Mar 2023 11:58:39 +0000 Subject: [PATCH 10/12] Update docs_environment.yml Signed-off-by: Gemma Fardell <47746591+gfardell@users.noreply.github.com> --- docs/docs_environment.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/docs_environment.yml b/docs/docs_environment.yml index f7c4fd502..07adaa742 100644 --- a/docs/docs_environment.yml +++ b/docs/docs_environment.yml @@ -30,7 +30,7 @@ dependencies: - scikit-image - packaging - numba - - tigre=2.2 + - tigre=2.4 - sphinx_rtd_theme - sphinxcontrib-bibtex - pydata-sphinx-theme<0.9 @@ -41,7 +41,7 @@ dependencies: - sphinx-click=2.7 - sphinx-copybutton=0.3 - astra-toolbox>=1.9.9.dev5,<2.1 - - ccpi-regulariser=21.0.0 + - ccpi-regulariser=22.0.0 - tomophantom=2.0.0 - ipywidgets - tqdm From bc5608d9fcaf6d28e69c5e2d36c012f8cb45bc60 Mon Sep 17 00:00:00 2001 From: Laura Murgatroyd <60604372+lauramurgatroyd@users.noreply.github.com> Date: Mon, 27 Mar 2023 14:31:53 +0100 Subject: [PATCH 11/12] Fix bug in NikonReader when ROI is not set (#1457) * fix bug when ROI is None Signed-off-by: Laura Murgatroyd <60604372+lauramurgatroyd@users.noreply.github.com> * update change log * basic unit tests * Exception types --------- Signed-off-by: Laura Murgatroyd <60604372+lauramurgatroyd@users.noreply.github.com> Co-authored-by: gfardell --- CHANGELOG.md | 3 ++ Wrappers/Python/cil/io/NikonDataReader.py | 12 ++++---- Wrappers/Python/test/test_io.py | 36 ++++++++++++++++++++++- 3 files changed, 44 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 157957909..cc918a856 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,6 @@ +* 23.0.1 + - Fix bug with NikonReader requiring ROI to be set in constructor. + * 23.0.0 - Partitioner is now able to create batches even if angle is not the outer dimension - Renamed `max_iteration_stop_cryterion` method in the Algorithm class to `max_iteration_stop_criterion` diff --git a/Wrappers/Python/cil/io/NikonDataReader.py b/Wrappers/Python/cil/io/NikonDataReader.py index 458c411b4..94b8aaa37 100644 --- a/Wrappers/Python/cil/io/NikonDataReader.py +++ b/Wrappers/Python/cil/io/NikonDataReader.py @@ -102,22 +102,22 @@ def set_up(self, self.fliplr = fliplr if self.file_name is None: - raise Exception('Path to xtekct file is required.') + raise ValueError('Path to xtekct file is required.') # check if xtekct file exists if not(os.path.isfile(self.file_name)): - raise Exception('File\n {}\n does not exist.'.format(self.file_name)) + raise FileNotFoundError('File\n {}\n does not exist.'.format(self.file_name)) if os.path.basename(self.file_name).split('.')[-1].lower() != 'xtekct': raise TypeError('This reader can only process xtekct files. Got {}'.format(os.path.basename(self.file_name))) + + if self.roi is None: + self.roi= {'angle': -1, 'horizontal': -1, 'vertical': -1} # check labels for key in self.roi.keys(): if key not in ['angle', 'horizontal', 'vertical']: - raise Exception("Wrong label. One of the following is expected: angle, horizontal, vertical") - - if self.roi is None: - self.roi= {'angle': -1, 'horizontal': -1, 'vertical': -1} + raise ValueError("Wrong label. One of the following is expected: angle, horizontal, vertical") roi = self.roi.copy() diff --git a/Wrappers/Python/test/test_io.py b/Wrappers/Python/test/test_io.py index b352f6e35..41c89e8c1 100644 --- a/Wrappers/Python/test/test_io.py +++ b/Wrappers/Python/test/test_io.py @@ -24,7 +24,7 @@ import numpy as np import os from cil.framework import ImageGeometry -from cil.io import TXRMDataReader, NEXUSDataReader +from cil.io import TXRMDataReader, NEXUSDataReader, NikonDataReader, ZEISSDataReader from cil.io import TIFFWriter, TIFFStackReader from cil.io.utilities import HDF5_utilities from cil.processors import Slicer @@ -522,3 +522,37 @@ def test_read_to(self): HDF5_utilities.read_to(self.path, self.dset_path, data_partial, source_sel=subset, dest_sel=subset) np.testing.assert_allclose(data_partial_by_hand,data_partial) + + +class TestNikonReader(unittest.TestCase): + + def test_setup(self): + + reader = NikonDataReader() + self.assertEqual(reader.file_name, None) + self.assertEqual(reader.roi, None) + self.assertTrue(reader.normalise) + self.assertEqual(reader.mode, 'bin') + self.assertFalse(reader.fliplr) + + roi = {'vertical':(1,-1),'horizontal':(1,-1),'angle':(1,-1)} + reader = NikonDataReader(file_name=None, roi=roi, normalise=False, mode='slice', fliplr=True) + self.assertEqual(reader.file_name, None) + self.assertEqual(reader.roi, roi) + self.assertFalse(reader.normalise) + self.assertEqual(reader.mode, 'slice') + self.assertTrue(reader.fliplr) + + with self.assertRaises(FileNotFoundError): + reader = NikonDataReader(file_name='no-file') + + +class TestZeissReader(unittest.TestCase): + + def test_setup(self): + + reader = ZEISSDataReader() + self.assertEqual(reader.file_name, None) + + with self.assertRaises(FileNotFoundError): + reader = ZEISSDataReader(file_name='no-file') From 45e0b235ac79efc03dc5cb46b8ddda9d16f6331b Mon Sep 17 00:00:00 2001 From: Gemma Fardell <47746591+gfardell@users.noreply.github.com> Date: Tue, 28 Mar 2023 10:06:15 +0100 Subject: [PATCH 12/12] Update README.md (#1458) removed astra-toolbox channel as all versions available on conda-forge Signed-off-by: Gemma Fardell <47746591+gfardell@users.noreply.github.com> --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 2ed62e22b..a3ed88f8c 100644 --- a/README.md +++ b/README.md @@ -19,13 +19,13 @@ The documentation for CIL can be accessed [here](https://tomographicimaging.gith Binary installation of CIL can be done with `conda`. Install a new environment using: ```bash -conda create --name cil -c conda-forge -c intel -c ccpi cil=23.0.0 +conda create --name cil -c conda-forge -c intel -c ccpi cil=23.0.1 ``` To install CIL and the additional packages and plugins needed to run the [CIL demos](https://github.com/TomographicImaging/CIL-Demos) install the environment with: ```bash -conda create --name cil -c conda-forge -c intel -c astra-toolbox -c ccpi cil=23.0.0 astra-toolbox tigre ccpi-regulariser tomophantom "ipywidgets<8" +conda create --name cil -c conda-forge -c intel -c ccpi cil=23.0.1 astra-toolbox tigre ccpi-regulariser tomophantom "ipywidgets<8" ``` where,