diff --git a/src/MATLAB/+HIP/@Cuda/Closure.m b/src/MATLAB/+HIP/@Cuda/Closure.m index de14b6d2663369f5471e7eefaa1706cb737dbca5..7c40dbb3824ccf17d1cfd84705c550373b39903d 100644 --- a/src/MATLAB/+HIP/@Cuda/Closure.m +++ b/src/MATLAB/+HIP/@Cuda/Closure.m @@ -1,5 +1,5 @@ -% Closure - This kernel will dilate follow by an erosion. -% arrayOut = HIP.Cuda.Closure(arrayIn,kernel,[numIterations],[device]) +% Closure - This kernel will apply a dilation followed by an erosion. +% [imageOut] = HIP.Cuda.Closure(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,6 +17,6 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = Closure(arrayIn,kernel,numIterations,device) - [arrayOut] = HIP.Cuda.Mex('Closure',arrayIn,kernel,numIterations,device); +function [imageOut] = Closure(imageIn,kernel,numIterations,device) + [imageOut] = HIP.Cuda.Mex('Closure',imageIn,kernel,numIterations,device); end diff --git a/src/MATLAB/+HIP/@Cuda/Cuda.m b/src/MATLAB/+HIP/@Cuda/Cuda.m index 6d01261b3811d9d8e0c752cb9c1bde4d76a6ad26..b947a013950a8be27fb5504382161f5410a5bf0f 100644 --- a/src/MATLAB/+HIP/@Cuda/Cuda.m +++ b/src/MATLAB/+HIP/@Cuda/Cuda.m @@ -1,27 +1,27 @@ classdef (Abstract,Sealed) Cuda methods (Static) - commandInfo = Info() + [imageOut] = Closure(imageIn,kernel,numIterations,device) + [imageOut] = HighPassFilter(imageIn,sigmas,device) + [numCudaDevices,memStats] = DeviceCount() Help(command) - [numCudaDevices,memoryStats] = DeviceCount() - deviceStatsArray = DeviceStats() - arrayOut = Closure(arrayIn,kernel,numIterations,device) - arrayOut = ElementWiseDifference(array1In,array2In,device) - arrayOut = EntropyFilter(arrayIn,kernel,device) - arrayOut = Gaussian(arrayIn,sigmas,numIterations,device) - [minValue,maxValue] = GetMinMax(arrayIn,device) - arrayOut = HighPassFilter(arrayIn,sigmas,device) - arrayOut = IdentityFilter(arrayIn,device) - arrayOut = LoG(arrayIn,sigmas,device) - arrayOut = MaxFilter(arrayIn,kernel,numIterations,device) - arrayOut = MeanFilter(arrayIn,kernel,numIterations,device) - arrayOut = MedianFilter(arrayIn,kernel,numIterations,device) - arrayOut = MinFilter(arrayIn,kernel,numIterations,device) - arrayOut = MultiplySum(arrayIn,kernel,numIterations,device) - arrayOut = Opener(arrayIn,kernel,numIterations,device) - arrayOut = StdFilter(arrayIn,kernel,numIterations,device) - valueOut = Sum(arrayIn,device) - arrayOut = VarFilter(arrayIn,kernel,numIterations,device) - arrayOut = WienerFilter(arrayIn,kernel,noiseVariance,device) + [minVal,maxVal] = GetMinMax(imageIn,device) + [cmdInfo] = Info() + [imageOut] = Gaussian(imageIn,sigmas,numIterations,device) + [imageOut] = MeanFilter(imageIn,kernel,numIterations,device) + [deviceStatsArray] = DeviceStats() + [imageOut] = ElementWiseDifference(image1In,image2In,device) + [imageOut] = MultiplySum(imageIn,kernel,numIterations,device) + [imageOut] = EntropyFilter(imageIn,kernel,device) + [imageOut] = StdFilter(imageIn,kernel,numIterations,device) + [imageOut] = IdentityFilter(imageIn,device) + [imageOut] = LoG(imageIn,sigmas,device) + [imageOut] = MedianFilter(imageIn,kernel,numIterations,device) + [imageOut] = MinFilter(imageIn,kernel,numIterations,device) + [imageOut] = MaxFilter(imageIn,kernel,numIterations,device) + [imageOut] = Opener(imageIn,kernel,numIterations,device) + [imageOut] = Sum(imageIn,device) + [imageOut] = VarFilter(imageIn,kernel,numIterations,device) + [imageOut] = WienerFilter(imageIn,kernel,noiseVariance,device) end methods (Static, Access = private) varargout = Mex(command, varargin) diff --git a/src/MATLAB/+HIP/@Cuda/DeviceCount.m b/src/MATLAB/+HIP/@Cuda/DeviceCount.m index e98fcdda17e5c21eb3ac016a6b7a61260b6075b0..26b0ace7837047c34f5481e9c96df3bd3bce3234 100644 --- a/src/MATLAB/+HIP/@Cuda/DeviceCount.m +++ b/src/MATLAB/+HIP/@Cuda/DeviceCount.m @@ -1,8 +1,9 @@ % DeviceCount - This will return the number of Cuda devices available, and their memory. -% [numCudaDevices,memoryStats] = HIP.Cuda.DeviceCount() +% [numCudaDevices,memStats] = HIP.Cuda.DeviceCount() % NumCudaDevices -- this is the number of Cuda devices available. % MemoryStats -- this is an array of structures where each entry corresponds to a Cuda device. % The memory structure contains the total memory on the device and the memory available for a Cuda call. -function [numCudaDevices,memoryStats] = DeviceCount() - [numCudaDevices,memoryStats] = HIP.Cuda.Mex('DeviceCount'); +% +function [numCudaDevices,memStats] = DeviceCount() + [numCudaDevices,memStats] = HIP.Cuda.Mex('DeviceCount'); end diff --git a/src/MATLAB/+HIP/@Cuda/DeviceStats.m b/src/MATLAB/+HIP/@Cuda/DeviceStats.m index 72369ad9358f9d710a37045db66bac6bcdbdcc59..62710ca62b0f4e3eb1bf15a57c1fe3bddcd63165 100644 --- a/src/MATLAB/+HIP/@Cuda/DeviceStats.m +++ b/src/MATLAB/+HIP/@Cuda/DeviceStats.m @@ -1,7 +1,7 @@ % DeviceStats - This will return the statistics of each Cuda capable device installed. -% deviceStatsArray = HIP.Cuda.DeviceStats() +% [deviceStatsArray] = HIP.Cuda.DeviceStats() % DeviceStatsArray -- this is an array of structs, one struct per device. % The struct has these fields: name, major, minor, constMem, sharedMem, totalMem, tccDriver, mpCount, threadsPerMP, warpSize, maxThreads. -function deviceStatsArray = DeviceStats() +function [deviceStatsArray] = DeviceStats() [deviceStatsArray] = HIP.Cuda.Mex('DeviceStats'); end diff --git a/src/MATLAB/+HIP/@Cuda/ElementWiseDifference.m b/src/MATLAB/+HIP/@Cuda/ElementWiseDifference.m index 3a79d97b6ef012238f28de4cf565dbcbc8557df3..52bbcb81d84254a7ef20ae488aa147583fe522f2 100644 --- a/src/MATLAB/+HIP/@Cuda/ElementWiseDifference.m +++ b/src/MATLAB/+HIP/@Cuda/ElementWiseDifference.m @@ -1,5 +1,5 @@ % ElementWiseDifference - This subtracts the second array from the first, element by element (A-B). -% arrayOut = HIP.Cuda.ElementWiseDifference(array1In,array2In,[device]) +% [imageOut] = HIP.Cuda.ElementWiseDifference(image1In,image2In,[device]) % image1In = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -13,6 +13,6 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = ElementWiseDifference(array1In,array2In,device) - [arrayOut] = HIP.Cuda.Mex('ElementWiseDifference',array1In,array2In,device); +function [imageOut] = ElementWiseDifference(image1In,image2In,device) + [imageOut] = HIP.Cuda.Mex('ElementWiseDifference',image1In,image2In,device); end diff --git a/src/MATLAB/+HIP/@Cuda/EntropyFilter.m b/src/MATLAB/+HIP/@Cuda/EntropyFilter.m index 8e3ccda8c2ec174769e264b5cc77734eed73cd8d..e3d31ecb37f89b2132655ad11a8569557a93ab88 100644 --- a/src/MATLAB/+HIP/@Cuda/EntropyFilter.m +++ b/src/MATLAB/+HIP/@Cuda/EntropyFilter.m @@ -1,5 +1,5 @@ % EntropyFilter - This calculates the entropy within the neighborhood given by the kernel. -% arrayOut = HIP.Cuda.EntropyFilter(arrayIn,kernel,[device]) +% [imageOut] = HIP.Cuda.EntropyFilter(imageIn,kernel,[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -13,6 +13,7 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = EntropyFilter(arrayIn,kernel,device) - [arrayOut] = HIP.Cuda.Mex('EntropyFilter',arrayIn,kernel,device); +% +function [imageOut] = EntropyFilter(imageIn,kernel,device) + [imageOut] = HIP.Cuda.Mex('EntropyFilter',imageIn,kernel,device); end diff --git a/src/MATLAB/+HIP/@Cuda/Gaussian.m b/src/MATLAB/+HIP/@Cuda/Gaussian.m index e4cb71f50a7f134f24b9d6c1be0935a5231cce91..92e6fa345fc973e5270531a41ae4c515f638e656 100644 --- a/src/MATLAB/+HIP/@Cuda/Gaussian.m +++ b/src/MATLAB/+HIP/@Cuda/Gaussian.m @@ -1,5 +1,5 @@ % Gaussian - Gaussian smoothing. -% arrayOut = HIP.Cuda.Gaussian(arrayIn,sigmas,[numIterations],[device]) +% [imageOut] = HIP.Cuda.Gaussian(imageIn,sigmas,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -16,6 +16,7 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = Gaussian(arrayIn,sigmas,numIterations,device) - [arrayOut] = HIP.Cuda.Mex('Gaussian',arrayIn,sigmas,numIterations,device); +% +function [imageOut] = Gaussian(imageIn,sigmas,numIterations,device) + [imageOut] = HIP.Cuda.Mex('Gaussian',imageIn,sigmas,numIterations,device); end diff --git a/src/MATLAB/+HIP/@Cuda/GetMinMax.m b/src/MATLAB/+HIP/@Cuda/GetMinMax.m index c5c12c440f9a29153b6ede5f211a9520d51b6675..b06dd63e9335b523b9de610e630c0496feb844c6 100644 --- a/src/MATLAB/+HIP/@Cuda/GetMinMax.m +++ b/src/MATLAB/+HIP/@Cuda/GetMinMax.m @@ -1,5 +1,5 @@ % GetMinMax - This function finds the lowest and highest value in the array that is passed in. -% [minValue,maxValue] = HIP.Cuda.GetMinMax(arrayIn,[device]) +% [minVal,maxVal] = HIP.Cuda.GetMinMax(imageIn,[device]) % imageIn = This is a one to five dimensional array. % % device (optional) = Use this if you have multiple devices and want to select one explicitly. @@ -8,6 +8,7 @@ % % minValue = This is the lowest value found in the array. % maxValue = This is the highest value found in the array. -function [minValue,maxValue] = GetMinMax(arrayIn,device) - [minValue,maxValue] = HIP.Cuda.Mex('GetMinMax',arrayIn,device); +% +function [minVal,maxVal] = GetMinMax(imageIn,device) + [minVal,maxVal] = HIP.Cuda.Mex('GetMinMax',imageIn,device); end diff --git a/src/MATLAB/+HIP/@Cuda/Help.m b/src/MATLAB/+HIP/@Cuda/Help.m index a446a6fcbd5fc086a23788a4fe2d317d6063e58f..2daacbdbdf7078392a015621393baa66c35b8ad1 100644 --- a/src/MATLAB/+HIP/@Cuda/Help.m +++ b/src/MATLAB/+HIP/@Cuda/Help.m @@ -1,6 +1,5 @@ -% Help - Help on a specified command. -% HIP.Cuda.Help(command) -% Print detailed usage information for the specified command. +% Help - Print detailed usage information for the specified command. +% HIP.Cuda.Help([command]) function Help(command) HIP.Cuda.Mex('Help',command); end diff --git a/src/MATLAB/+HIP/@Cuda/HighPassFilter.m b/src/MATLAB/+HIP/@Cuda/HighPassFilter.m index cb5b62e58693b1853777d1f1dfb9a34c37179b0d..e795bae55cf5da9c69650d235e6969ada24e9665 100644 --- a/src/MATLAB/+HIP/@Cuda/HighPassFilter.m +++ b/src/MATLAB/+HIP/@Cuda/HighPassFilter.m @@ -1,5 +1,5 @@ % HighPassFilter - Filters out low frequency by subtracting a Gaussian blurred version of the input based on the sigmas provided. -% arrayOut = HIP.Cuda.HighPassFilter(arrayIn,sigmas,[device]) +% [imageOut] = HIP.Cuda.HighPassFilter(imageIn,sigmas,[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -12,6 +12,7 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = HighPassFilter(arrayIn,sigmas,device) - [arrayOut] = HIP.Cuda.Mex('HighPassFilter',arrayIn,sigmas,device); +% +function [imageOut] = HighPassFilter(imageIn,sigmas,device) + [imageOut] = HIP.Cuda.Mex('HighPassFilter',imageIn,sigmas,device); end diff --git a/src/MATLAB/+HIP/@Cuda/IdentityFilter.m b/src/MATLAB/+HIP/@Cuda/IdentityFilter.m index 0ad9bcf24efa76e94592c3dff8684e60fa403c82..79955722436954c0a0f445429df263dc5be9c858 100644 --- a/src/MATLAB/+HIP/@Cuda/IdentityFilter.m +++ b/src/MATLAB/+HIP/@Cuda/IdentityFilter.m @@ -1,5 +1,5 @@ -% IdentityFilter - Identity Filter for testing. Copies image data to GPU memory and back into output image -% arrayOut = HIP.Cuda.IdentityFilter(arrayIn,[device]) +% IdentityFilter - Identity Filter for testing. Copies image data to GPU memory and back into output image. +% [imageOut] = HIP.Cuda.IdentityFilter(imageIn,[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -9,6 +9,7 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = IdentityFilter(arrayIn,device) - [arrayOut] = HIP.Cuda.Mex('IdentityFilter',arrayIn,device); +% +function [imageOut] = IdentityFilter(imageIn,device) + [imageOut] = HIP.Cuda.Mex('IdentityFilter',imageIn,device); end diff --git a/src/MATLAB/+HIP/@Cuda/Info.m b/src/MATLAB/+HIP/@Cuda/Info.m index 1ab3948bbdca2f523b54660213c490121102dd3b..a59edcf51c2f1e0a19c44679bb331fbe3b46d1b2 100644 --- a/src/MATLAB/+HIP/@Cuda/Info.m +++ b/src/MATLAB/+HIP/@Cuda/Info.m @@ -1,10 +1,11 @@ % Info - Get information on all available mex commands. -% commandInfo = HIP.Cuda.Info() +% [cmdInfo] = HIP.Cuda.Info() % Returns commandInfo structure array containing information on all mex commands. % commandInfo.command - Command string -% commandInfo.outArgs - Cell array of output arguments -% commandInfo.inArgs - Cell array of input arguments -% commandInfo.helpLines - Cell array of input arguments -function commandInfo = Info() - [commandInfo] = HIP.Cuda.Mex('Info'); +% commandInfo.outArgs - Comma-delimited string list of output arguments +% commandInfo.inArgs - Comma-delimited string list of input arguments +% commandInfo.helpLines - Help string +% +function [cmdInfo] = Info() + [cmdInfo] = HIP.Cuda.Mex('Info'); end diff --git a/src/MATLAB/+HIP/@Cuda/LoG.m b/src/MATLAB/+HIP/@Cuda/LoG.m index e6d5bb440bd4261e7b783e916aa4fe481d46c684..e0dff78fc6ad990db400b2dd06ae3af6657914f3 100644 --- a/src/MATLAB/+HIP/@Cuda/LoG.m +++ b/src/MATLAB/+HIP/@Cuda/LoG.m @@ -1,5 +1,5 @@ % LoG - Apply a Lapplacian of Gaussian filter with the given sigmas. -% arrayOut = HIP.Cuda.LoG(arrayIn,sigmas,[device]) +% [imageOut] = HIP.Cuda.LoG(imageIn,sigmas,[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -12,6 +12,7 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = LoG(arrayIn,sigmas,device) - [arrayOut] = HIP.Cuda.Mex('LoG',arrayIn,sigmas,device); +% +function [imageOut] = LoG(imageIn,sigmas,device) + [imageOut] = HIP.Cuda.Mex('LoG',imageIn,sigmas,device); end diff --git a/src/MATLAB/+HIP/@Cuda/MaxFilter.m b/src/MATLAB/+HIP/@Cuda/MaxFilter.m index 2715cc59ad78fe94495cb59bf44eb8e840ea4ddf..077a6c3b65c89d96d2ec5a39842af7edf7290373 100644 --- a/src/MATLAB/+HIP/@Cuda/MaxFilter.m +++ b/src/MATLAB/+HIP/@Cuda/MaxFilter.m @@ -1,5 +1,5 @@ % MaxFilter - This will set each pixel/voxel to the max value of the neighborhood defined by the given kernel. -% arrayOut = HIP.Cuda.MaxFilter(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.Cuda.MaxFilter(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,6 +17,7 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = MaxFilter(arrayIn,kernel,numIterations,device) - [arrayOut] = HIP.Cuda.Mex('MaxFilter',arrayIn,kernel,numIterations,device); +% +function [imageOut] = MaxFilter(imageIn,kernel,numIterations,device) + [imageOut] = HIP.Cuda.Mex('MaxFilter',imageIn,kernel,numIterations,device); end diff --git a/src/MATLAB/+HIP/@Cuda/MeanFilter.m b/src/MATLAB/+HIP/@Cuda/MeanFilter.m index 95ce167a0330379bca8ca8bb151b86efb172513b..a3a00ee58aaa4d71cb038d869aabcb33cdbea5bb 100644 --- a/src/MATLAB/+HIP/@Cuda/MeanFilter.m +++ b/src/MATLAB/+HIP/@Cuda/MeanFilter.m @@ -1,5 +1,5 @@ % MeanFilter - This will take the mean of the given neighborhood. -% arrayOut = HIP.Cuda.MeanFilter(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.Cuda.MeanFilter(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,6 +17,7 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = MeanFilter(arrayIn,kernel,numIterations,device) - [arrayOut] = HIP.Cuda.Mex('MeanFilter',arrayIn,kernel,numIterations,device); +% +function [imageOut] = MeanFilter(imageIn,kernel,numIterations,device) + [imageOut] = HIP.Cuda.Mex('MeanFilter',imageIn,kernel,numIterations,device); end diff --git a/src/MATLAB/+HIP/@Cuda/MedianFilter.m b/src/MATLAB/+HIP/@Cuda/MedianFilter.m index 28cbc93b4c0f5c92178c5213b710f4308e0fd0ec..e7436d1762d93f4d95be8cf0598baa5facf536ee 100644 --- a/src/MATLAB/+HIP/@Cuda/MedianFilter.m +++ b/src/MATLAB/+HIP/@Cuda/MedianFilter.m @@ -1,5 +1,5 @@ % MedianFilter - This will calculate the median for each neighborhood defined by the kernel. -% arrayOut = HIP.Cuda.MedianFilter(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.Cuda.MedianFilter(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,6 +17,7 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = MedianFilter(arrayIn,kernel,numIterations,device) - [arrayOut] = HIP.Cuda.Mex('MedianFilter',arrayIn,kernel,numIterations,device); +% +function [imageOut] = MedianFilter(imageIn,kernel,numIterations,device) + [imageOut] = HIP.Cuda.Mex('MedianFilter',imageIn,kernel,numIterations,device); end diff --git a/src/MATLAB/+HIP/@Cuda/Mex.mexw64 b/src/MATLAB/+HIP/@Cuda/Mex.mexw64 index d3e56d371e00aaa8f959d62c54fccec7085f1836..638de2db857e849c13b35fd852722f6031267911 100644 --- a/src/MATLAB/+HIP/@Cuda/Mex.mexw64 +++ b/src/MATLAB/+HIP/@Cuda/Mex.mexw64 @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:313b7d637667ffad14fae537d42918629d5a53bbd2d240114c55a5e43b95c3f6 -size 10465792 +oid sha256:771f4ef3470bc0354a1afe7d82f2e7775f317afec9c9ace353c4d18279087b01 +size 9447424 diff --git a/src/MATLAB/+HIP/@Cuda/MinFilter.m b/src/MATLAB/+HIP/@Cuda/MinFilter.m index 9513b840d47a9cda9812220fd87f2367f4fd3fb0..5f35fb68b1f2313166ea57baf13672de29defc0a 100644 --- a/src/MATLAB/+HIP/@Cuda/MinFilter.m +++ b/src/MATLAB/+HIP/@Cuda/MinFilter.m @@ -1,5 +1,5 @@ % MinFilter - This will set each pixel/voxel to the max value of the neighborhood defined by the given kernel. -% arrayOut = HIP.Cuda.MinFilter(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.Cuda.MinFilter(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,6 +17,7 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = MinFilter(arrayIn,kernel,numIterations,device) - [arrayOut] = HIP.Cuda.Mex('MinFilter',arrayIn,kernel,numIterations,device); +% +function [imageOut] = MinFilter(imageIn,kernel,numIterations,device) + [imageOut] = HIP.Cuda.Mex('MinFilter',imageIn,kernel,numIterations,device); end diff --git a/src/MATLAB/+HIP/@Cuda/MultiplySum.m b/src/MATLAB/+HIP/@Cuda/MultiplySum.m index 3499c3b5e0f5d54d3d438ae6f7560954026f1f1f..2d0bc1d07e06ef99ad5516deed8b40d1fcb9f59b 100644 --- a/src/MATLAB/+HIP/@Cuda/MultiplySum.m +++ b/src/MATLAB/+HIP/@Cuda/MultiplySum.m @@ -1,5 +1,5 @@ % MultiplySum - Multiplies the kernel with the neighboring values and sums these new values. -% arrayOut = HIP.Cuda.MultiplySum(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.Cuda.MultiplySum(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,6 +17,7 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = MultiplySum(arrayIn,kernel,numIterations,device) - [arrayOut] = HIP.Cuda.Mex('MultiplySum',arrayIn,kernel,numIterations,device); +% +function [imageOut] = MultiplySum(imageIn,kernel,numIterations,device) + [imageOut] = HIP.Cuda.Mex('MultiplySum',imageIn,kernel,numIterations,device); end diff --git a/src/MATLAB/+HIP/@Cuda/Opener.m b/src/MATLAB/+HIP/@Cuda/Opener.m index 7f53f8e84abde678255cd7e95e0baafa944bdc18..b4baee782100e4dc2f555f8c2a3d821c16659dd3 100644 --- a/src/MATLAB/+HIP/@Cuda/Opener.m +++ b/src/MATLAB/+HIP/@Cuda/Opener.m @@ -1,5 +1,5 @@ % Opener - This kernel will erode follow by a dilation. -% arrayOut = HIP.Cuda.Opener(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.Cuda.Opener(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,6 +17,7 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = Opener(arrayIn,kernel,numIterations,device) - [arrayOut] = HIP.Cuda.Mex('Opener',arrayIn,kernel,numIterations,device); +% +function [imageOut] = Opener(imageIn,kernel,numIterations,device) + [imageOut] = HIP.Cuda.Mex('Opener',imageIn,kernel,numIterations,device); end diff --git a/src/MATLAB/+HIP/@Cuda/StdFilter.m b/src/MATLAB/+HIP/@Cuda/StdFilter.m index ba66eec8535699afebf24b7c01eb71754acd792b..27f358a1716f6529a13ea97b5bb9640d352f8afb 100644 --- a/src/MATLAB/+HIP/@Cuda/StdFilter.m +++ b/src/MATLAB/+HIP/@Cuda/StdFilter.m @@ -1,5 +1,5 @@ % StdFilter - This will take the standard deviation of the given neighborhood. -% arrayOut = HIP.Cuda.StdFilter(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.Cuda.StdFilter(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,6 +17,7 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = StdFilter(arrayIn,kernel,numIterations,device) - [arrayOut] = HIP.Cuda.Mex('StdFilter',arrayIn,kernel,numIterations,device); +% +function [imageOut] = StdFilter(imageIn,kernel,numIterations,device) + [imageOut] = HIP.Cuda.Mex('StdFilter',imageIn,kernel,numIterations,device); end diff --git a/src/MATLAB/+HIP/@Cuda/Sum.m b/src/MATLAB/+HIP/@Cuda/Sum.m index 36d0e4607fa8938e8f93a4c72be9e243168dfe3b..12a272ce26e37b5f747a6c56c47fa34eea7b14ca 100644 --- a/src/MATLAB/+HIP/@Cuda/Sum.m +++ b/src/MATLAB/+HIP/@Cuda/Sum.m @@ -1,5 +1,5 @@ % Sum - This sums up the entire array in. -% valueOut = HIP.Cuda.Sum(arrayIn,[device]) +% [imageOut] = HIP.Cuda.Sum(imageIn,[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -9,6 +9,7 @@ % the data across multiple devices. % % valueOut = This is the summation of the entire array. -function valueOut = Sum(arrayIn,device) - [valueOut] = HIP.Cuda.Mex('Sum',arrayIn,device); +% +function [imageOut] = Sum(imageIn,device) + [imageOut] = HIP.Cuda.Mex('Sum',imageIn,device); end diff --git a/src/MATLAB/+HIP/@Cuda/VarFilter.m b/src/MATLAB/+HIP/@Cuda/VarFilter.m index 758d61d9ea780f912617a23795a74a38b2152254..638197b0a6fe8691ba8866cee8bd954cfab89921 100644 --- a/src/MATLAB/+HIP/@Cuda/VarFilter.m +++ b/src/MATLAB/+HIP/@Cuda/VarFilter.m @@ -1,5 +1,5 @@ % VarFilter - This will take the variance deviation of the given neighborhood. -% arrayOut = HIP.Cuda.VarFilter(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.Cuda.VarFilter(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,6 +17,7 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = VarFilter(arrayIn,kernel,numIterations,device) - [arrayOut] = HIP.Cuda.Mex('VarFilter',arrayIn,kernel,numIterations,device); +% +function [imageOut] = VarFilter(imageIn,kernel,numIterations,device) + [imageOut] = HIP.Cuda.Mex('VarFilter',imageIn,kernel,numIterations,device); end diff --git a/src/MATLAB/+HIP/@Cuda/WienerFilter.m b/src/MATLAB/+HIP/@Cuda/WienerFilter.m index bc8ccd078eec8bd84a7cff6438e186bd4b75b78f..1a43af9630e9065cbc06a99c368f3a7b2f6ea4f6 100644 --- a/src/MATLAB/+HIP/@Cuda/WienerFilter.m +++ b/src/MATLAB/+HIP/@Cuda/WienerFilter.m @@ -1,5 +1,5 @@ % WienerFilter - A Wiener filter aims to denoise an image in a linear fashion. -% arrayOut = HIP.Cuda.WienerFilter(arrayIn,[kernel],[noiseVariance],[device]) +% [imageOut] = HIP.Cuda.WienerFilter(imageIn,kernel,[noiseVariance],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,6 +17,7 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = WienerFilter(arrayIn,kernel,noiseVariance,device) - [arrayOut] = HIP.Cuda.Mex('WienerFilter',arrayIn,kernel,noiseVariance,device); +% +function [imageOut] = WienerFilter(imageIn,kernel,noiseVariance,device) + [imageOut] = HIP.Cuda.Mex('WienerFilter',imageIn,kernel,noiseVariance,device); end diff --git a/src/MATLAB/+HIP/Closure.m b/src/MATLAB/+HIP/Closure.m index fe80d7b8fd176cdc70a78e65f8d2793290d52c3f..9e1121b75521e8c2d7cfb24391b45898486e12df 100644 --- a/src/MATLAB/+HIP/Closure.m +++ b/src/MATLAB/+HIP/Closure.m @@ -1,5 +1,5 @@ -% Closure - This kernel will dilate follow by an erosion. -% arrayOut = HIP.Closure(arrayIn,kernel,[numIterations],[device]) +% Closure - This kernel will apply a dilation followed by an erosion. +% [imageOut] = HIP.Closure(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -18,11 +18,11 @@ % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = Closure(arrayIn,kernel,numIterations,device) +function [imageOut] = Closure(imageIn,kernel,numIterations,device) try - arrayOut = HIP.Cuda.Closure(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Cuda.Closure(imageIn,kernel,numIterations,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.Closure(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Local.Closure(imageIn,kernel,numIterations,device); end end diff --git a/src/MATLAB/+HIP/ElementWiseDifference.m b/src/MATLAB/+HIP/ElementWiseDifference.m index d8ed3e060b1bffac1e11978e74f24f8fbbbbfefc..b09b6696d94a90f7dd4673a7d05e769cd32b6d07 100644 --- a/src/MATLAB/+HIP/ElementWiseDifference.m +++ b/src/MATLAB/+HIP/ElementWiseDifference.m @@ -1,5 +1,5 @@ % ElementWiseDifference - This subtracts the second array from the first, element by element (A-B). -% arrayOut = HIP.ElementWiseDifference(array1In,array2In,[device]) +% [imageOut] = HIP.ElementWiseDifference(image1In,image2In,[device]) % image1In = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -14,11 +14,11 @@ % % imageOut = This will be an array of the same type and shape as the input array. -function arrayOut = ElementWiseDifference(array1In,array2In,device) +function [imageOut] = ElementWiseDifference(image1In,image2In,device) try - arrayOut = HIP.Cuda.ElementWiseDifference(array1In,array2In,device); + [imageOut] = HIP.Cuda.ElementWiseDifference(image1In,image2In,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.ElementWiseDifference(array1In,array2In,device); + [imageOut] = HIP.Local.ElementWiseDifference(image1In,image2In,device); end end diff --git a/src/MATLAB/+HIP/EntropyFilter.m b/src/MATLAB/+HIP/EntropyFilter.m index 600fc33e2b6adbaa38bcbdc2ec1831df70ecefc9..22834ce8008a1ade113dcc92f23d709e61ae2deb 100644 --- a/src/MATLAB/+HIP/EntropyFilter.m +++ b/src/MATLAB/+HIP/EntropyFilter.m @@ -1,5 +1,5 @@ % EntropyFilter - This calculates the entropy within the neighborhood given by the kernel. -% arrayOut = HIP.EntropyFilter(arrayIn,kernel,[device]) +% [imageOut] = HIP.EntropyFilter(imageIn,kernel,[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -13,12 +13,13 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. +% -function arrayOut = EntropyFilter(arrayIn,kernel,device) +function [imageOut] = EntropyFilter(imageIn,kernel,device) try - arrayOut = HIP.Cuda.EntropyFilter(arrayIn,kernel,device); + [imageOut] = HIP.Cuda.EntropyFilter(imageIn,kernel,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.EntropyFilter(arrayIn,kernel,device); + [imageOut] = HIP.Local.EntropyFilter(imageIn,kernel,device); end end diff --git a/src/MATLAB/+HIP/Gaussian.m b/src/MATLAB/+HIP/Gaussian.m index 86cef7bb488b25c00653f88d842c558b22ddbf64..9bfc841a6c92c88af1ca469bb66726e849e61a03 100644 --- a/src/MATLAB/+HIP/Gaussian.m +++ b/src/MATLAB/+HIP/Gaussian.m @@ -1,5 +1,5 @@ % Gaussian - Gaussian smoothing. -% arrayOut = HIP.Gaussian(arrayIn,sigmas,[numIterations],[device]) +% [imageOut] = HIP.Gaussian(imageIn,sigmas,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -16,12 +16,13 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. +% -function arrayOut = Gaussian(arrayIn,sigmas,numIterations,device) +function [imageOut] = Gaussian(imageIn,sigmas,numIterations,device) try - arrayOut = HIP.Cuda.Gaussian(arrayIn,sigmas,numIterations,device); + [imageOut] = HIP.Cuda.Gaussian(imageIn,sigmas,numIterations,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.Gaussian(arrayIn,sigmas,numIterations,device); + [imageOut] = HIP.Local.Gaussian(imageIn,sigmas,numIterations,device); end end diff --git a/src/MATLAB/+HIP/GetMinMax.m b/src/MATLAB/+HIP/GetMinMax.m index b50e4d9500deabb5acaa6484417d728d60001f46..3aa37bd53626af32c16b0d9ce3792d98677f35ad 100644 --- a/src/MATLAB/+HIP/GetMinMax.m +++ b/src/MATLAB/+HIP/GetMinMax.m @@ -1,5 +1,5 @@ % GetMinMax - This function finds the lowest and highest value in the array that is passed in. -% [minValue,maxValue] = HIP.GetMinMax(arrayIn,[device]) +% [minVal,maxVal] = HIP.GetMinMax(imageIn,[device]) % imageIn = This is a one to five dimensional array. % % device (optional) = Use this if you have multiple devices and want to select one explicitly. @@ -8,12 +8,13 @@ % % minValue = This is the lowest value found in the array. % maxValue = This is the highest value found in the array. +% -function [minValue,maxValue] = GetMinMax(arrayIn,device) +function [minVal,maxVal] = GetMinMax(imageIn,device) try - [minValue,maxValue] = HIP.Cuda.GetMinMax(arrayIn,device); + [minVal,maxVal] = HIP.Cuda.GetMinMax(imageIn,device); catch errMsg warning(errMsg.message); - [minValue,maxValue] = HIP.Local.GetMinMax(arrayIn,device); + [minVal,maxVal] = HIP.Local.GetMinMax(imageIn,device); end end diff --git a/src/MATLAB/+HIP/Help.m b/src/MATLAB/+HIP/Help.m index b2aeb1c6b850a686d407591a8b2c8d63ae95d28f..cf717d33694ffeab3a41e4e67a293153bc30a7ac 100644 --- a/src/MATLAB/+HIP/Help.m +++ b/src/MATLAB/+HIP/Help.m @@ -1,5 +1,4 @@ -% Help - Help on a specified command. -% HIP.Help(command) -% Print detailed usage information for the specified command. +% Help - Print detailed usage information for the specified command. +% HIP.Help([command]) function Help(command) end diff --git a/src/MATLAB/+HIP/HighPassFilter.m b/src/MATLAB/+HIP/HighPassFilter.m index f34c3fb9518da73fa898d0d3720b0af9272cf17b..a90189ed02d51f8b40e6930f2c99595dad825465 100644 --- a/src/MATLAB/+HIP/HighPassFilter.m +++ b/src/MATLAB/+HIP/HighPassFilter.m @@ -1,5 +1,5 @@ % HighPassFilter - Filters out low frequency by subtracting a Gaussian blurred version of the input based on the sigmas provided. -% arrayOut = HIP.HighPassFilter(arrayIn,sigmas,[device]) +% [imageOut] = HIP.HighPassFilter(imageIn,sigmas,[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -12,12 +12,13 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. +% -function arrayOut = HighPassFilter(arrayIn,sigmas,device) +function [imageOut] = HighPassFilter(imageIn,sigmas,device) try - arrayOut = HIP.Cuda.HighPassFilter(arrayIn,sigmas,device); + [imageOut] = HIP.Cuda.HighPassFilter(imageIn,sigmas,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.HighPassFilter(arrayIn,sigmas,device); + [imageOut] = HIP.Local.HighPassFilter(imageIn,sigmas,device); end end diff --git a/src/MATLAB/+HIP/IdentityFilter.m b/src/MATLAB/+HIP/IdentityFilter.m index 1a47270229c16029a8f6116c1416ee4e37624f59..12fefae6586fc76467fe115cc484109f778d1ce0 100644 --- a/src/MATLAB/+HIP/IdentityFilter.m +++ b/src/MATLAB/+HIP/IdentityFilter.m @@ -1,5 +1,5 @@ -% IdentityFilter - Identity Filter for testing. Copies image data to GPU memory and back into output image -% arrayOut = HIP.IdentityFilter(arrayIn,[device]) +% IdentityFilter - Identity Filter for testing. Copies image data to GPU memory and back into output image. +% [imageOut] = HIP.IdentityFilter(imageIn,[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -9,12 +9,13 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. +% -function arrayOut = IdentityFilter(arrayIn,device) +function [imageOut] = IdentityFilter(imageIn,device) try - arrayOut = HIP.Cuda.IdentityFilter(arrayIn,device); + [imageOut] = HIP.Cuda.IdentityFilter(imageIn,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.IdentityFilter(arrayIn,device); + [imageOut] = HIP.Local.IdentityFilter(imageIn,device); end end diff --git a/src/MATLAB/+HIP/Info.m b/src/MATLAB/+HIP/Info.m index c73ddaad0225a2fab1fcf4f6a4b086fb804a8da7..8c867debca80ad4cf759a6652d8217e58326215f 100644 --- a/src/MATLAB/+HIP/Info.m +++ b/src/MATLAB/+HIP/Info.m @@ -1,16 +1,17 @@ % Info - Get information on all available mex commands. -% commandInfo = HIP.Info() +% [cmdInfo] = HIP.Info() % Returns commandInfo structure array containing information on all mex commands. % commandInfo.command - Command string -% commandInfo.outArgs - Cell array of output arguments -% commandInfo.inArgs - Cell array of input arguments -% commandInfo.helpLines - Cell array of input arguments +% commandInfo.outArgs - Comma-delimited string list of output arguments +% commandInfo.inArgs - Comma-delimited string list of input arguments +% commandInfo.helpLines - Help string +% -function commandInfo = Info() +function [cmdInfo] = Info() try - commandInfo = HIP.Cuda.Info(); + [cmdInfo] = HIP.Cuda.Info(); catch errMsg warning(errMsg.message); - commandInfo = HIP.Local.Info(); + [cmdInfo] = HIP.Local.Info(); end end diff --git a/src/MATLAB/+HIP/LoG.m b/src/MATLAB/+HIP/LoG.m index b67f335a8c4dc22f27a212d8510bb4856261bc5a..6cb94a63c44bc1793ffffaa7faf00d9708626ad9 100644 --- a/src/MATLAB/+HIP/LoG.m +++ b/src/MATLAB/+HIP/LoG.m @@ -1,5 +1,5 @@ % LoG - Apply a Lapplacian of Gaussian filter with the given sigmas. -% arrayOut = HIP.LoG(arrayIn,sigmas,[device]) +% [imageOut] = HIP.LoG(imageIn,sigmas,[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -12,12 +12,13 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. +% -function arrayOut = LoG(arrayIn,sigmas,device) +function [imageOut] = LoG(imageIn,sigmas,device) try - arrayOut = HIP.Cuda.LoG(arrayIn,sigmas,device); + [imageOut] = HIP.Cuda.LoG(imageIn,sigmas,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.LoG(arrayIn,sigmas,device); + [imageOut] = HIP.Local.LoG(imageIn,sigmas,device); end end diff --git a/src/MATLAB/+HIP/MaxFilter.m b/src/MATLAB/+HIP/MaxFilter.m index 6c4a71b8be91af797f8d008d45a0c284d564de78..320a3022af3b17e1d3cf2d0c052296e8537ea4e4 100644 --- a/src/MATLAB/+HIP/MaxFilter.m +++ b/src/MATLAB/+HIP/MaxFilter.m @@ -1,5 +1,5 @@ % MaxFilter - This will set each pixel/voxel to the max value of the neighborhood defined by the given kernel. -% arrayOut = HIP.MaxFilter(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.MaxFilter(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,12 +17,13 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. +% -function arrayOut = MaxFilter(arrayIn,kernel,numIterations,device) +function [imageOut] = MaxFilter(imageIn,kernel,numIterations,device) try - arrayOut = HIP.Cuda.MaxFilter(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Cuda.MaxFilter(imageIn,kernel,numIterations,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.MaxFilter(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Local.MaxFilter(imageIn,kernel,numIterations,device); end end diff --git a/src/MATLAB/+HIP/MeanFilter.m b/src/MATLAB/+HIP/MeanFilter.m index ffb7569f76b6ff53cd4fd1fd54fbde3985a43fec..8b681294101a19d995bebc7dbde9958a40ce90c9 100644 --- a/src/MATLAB/+HIP/MeanFilter.m +++ b/src/MATLAB/+HIP/MeanFilter.m @@ -1,5 +1,5 @@ % MeanFilter - This will take the mean of the given neighborhood. -% arrayOut = HIP.MeanFilter(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.MeanFilter(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,12 +17,13 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. +% -function arrayOut = MeanFilter(arrayIn,kernel,numIterations,device) +function [imageOut] = MeanFilter(imageIn,kernel,numIterations,device) try - arrayOut = HIP.Cuda.MeanFilter(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Cuda.MeanFilter(imageIn,kernel,numIterations,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.MeanFilter(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Local.MeanFilter(imageIn,kernel,numIterations,device); end end diff --git a/src/MATLAB/+HIP/MedianFilter.m b/src/MATLAB/+HIP/MedianFilter.m index 73209ee3fc1c73cf941b54ed4824b770632be19b..0a12d4c2b0d7ddde73cce6018ef0ebecc7ad370e 100644 --- a/src/MATLAB/+HIP/MedianFilter.m +++ b/src/MATLAB/+HIP/MedianFilter.m @@ -1,5 +1,5 @@ % MedianFilter - This will calculate the median for each neighborhood defined by the kernel. -% arrayOut = HIP.MedianFilter(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.MedianFilter(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,12 +17,13 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. +% -function arrayOut = MedianFilter(arrayIn,kernel,numIterations,device) +function [imageOut] = MedianFilter(imageIn,kernel,numIterations,device) try - arrayOut = HIP.Cuda.MedianFilter(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Cuda.MedianFilter(imageIn,kernel,numIterations,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.MedianFilter(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Local.MedianFilter(imageIn,kernel,numIterations,device); end end diff --git a/src/MATLAB/+HIP/MinFilter.m b/src/MATLAB/+HIP/MinFilter.m index 6d720660e65a986bd40957fb3ee0350a20f9948e..48b3ffbd8a07ad1b9b6b597f2cf756dae71a2fb3 100644 --- a/src/MATLAB/+HIP/MinFilter.m +++ b/src/MATLAB/+HIP/MinFilter.m @@ -1,5 +1,5 @@ % MinFilter - This will set each pixel/voxel to the max value of the neighborhood defined by the given kernel. -% arrayOut = HIP.MinFilter(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.MinFilter(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,12 +17,13 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. +% -function arrayOut = MinFilter(arrayIn,kernel,numIterations,device) +function [imageOut] = MinFilter(imageIn,kernel,numIterations,device) try - arrayOut = HIP.Cuda.MinFilter(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Cuda.MinFilter(imageIn,kernel,numIterations,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.MinFilter(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Local.MinFilter(imageIn,kernel,numIterations,device); end end diff --git a/src/MATLAB/+HIP/MultiplySum.m b/src/MATLAB/+HIP/MultiplySum.m index caa315510d390ee656f00fd73c298e9ac33d075a..ab6f06ea6359bf48f9c6e2a46d2610dd3e7fb8f6 100644 --- a/src/MATLAB/+HIP/MultiplySum.m +++ b/src/MATLAB/+HIP/MultiplySum.m @@ -1,5 +1,5 @@ % MultiplySum - Multiplies the kernel with the neighboring values and sums these new values. -% arrayOut = HIP.MultiplySum(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.MultiplySum(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,12 +17,13 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. +% -function arrayOut = MultiplySum(arrayIn,kernel,numIterations,device) +function [imageOut] = MultiplySum(imageIn,kernel,numIterations,device) try - arrayOut = HIP.Cuda.MultiplySum(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Cuda.MultiplySum(imageIn,kernel,numIterations,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.MultiplySum(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Local.MultiplySum(imageIn,kernel,numIterations,device); end end diff --git a/src/MATLAB/+HIP/Opener.m b/src/MATLAB/+HIP/Opener.m index 2246b8a3aa7800cb93e790fce77784abf9d79767..21f6a5bcb2568fd6e6c9f4c4ab8b251bcca7037a 100644 --- a/src/MATLAB/+HIP/Opener.m +++ b/src/MATLAB/+HIP/Opener.m @@ -1,5 +1,5 @@ % Opener - This kernel will erode follow by a dilation. -% arrayOut = HIP.Opener(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.Opener(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,12 +17,13 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. +% -function arrayOut = Opener(arrayIn,kernel,numIterations,device) +function [imageOut] = Opener(imageIn,kernel,numIterations,device) try - arrayOut = HIP.Cuda.Opener(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Cuda.Opener(imageIn,kernel,numIterations,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.Opener(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Local.Opener(imageIn,kernel,numIterations,device); end end diff --git a/src/MATLAB/+HIP/StdFilter.m b/src/MATLAB/+HIP/StdFilter.m index 46360e6acf2f6c2ca3e622ba4f18305e4a4f6ff0..2fe520c1b9993faf20112483f74236291006f5ed 100644 --- a/src/MATLAB/+HIP/StdFilter.m +++ b/src/MATLAB/+HIP/StdFilter.m @@ -1,5 +1,5 @@ % StdFilter - This will take the standard deviation of the given neighborhood. -% arrayOut = HIP.StdFilter(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.StdFilter(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,12 +17,13 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. +% -function arrayOut = StdFilter(arrayIn,kernel,numIterations,device) +function [imageOut] = StdFilter(imageIn,kernel,numIterations,device) try - arrayOut = HIP.Cuda.StdFilter(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Cuda.StdFilter(imageIn,kernel,numIterations,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.StdFilter(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Local.StdFilter(imageIn,kernel,numIterations,device); end end diff --git a/src/MATLAB/+HIP/Sum.m b/src/MATLAB/+HIP/Sum.m index 35296914936c9d01c61cea9a8f1db68daf07d53b..68eab89b43caf566748e2c8ad82c13fe1dca2e3f 100644 --- a/src/MATLAB/+HIP/Sum.m +++ b/src/MATLAB/+HIP/Sum.m @@ -1,5 +1,5 @@ % Sum - This sums up the entire array in. -% valueOut = HIP.Sum(arrayIn,[device]) +% [imageOut] = HIP.Sum(imageIn,[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -9,12 +9,13 @@ % the data across multiple devices. % % valueOut = This is the summation of the entire array. +% -function valueOut = Sum(arrayIn,device) +function [imageOut] = Sum(imageIn,device) try - valueOut = HIP.Cuda.Sum(arrayIn,device); + [imageOut] = HIP.Cuda.Sum(imageIn,device); catch errMsg warning(errMsg.message); - valueOut = HIP.Local.Sum(arrayIn,device); + [imageOut] = HIP.Local.Sum(imageIn,device); end end diff --git a/src/MATLAB/+HIP/VarFilter.m b/src/MATLAB/+HIP/VarFilter.m index 738cdbceaad4662b30cb2791e4d0b9164dcd4349..1e3d642e3495b3363dc293646b1b1231444ee1ef 100644 --- a/src/MATLAB/+HIP/VarFilter.m +++ b/src/MATLAB/+HIP/VarFilter.m @@ -1,5 +1,5 @@ % VarFilter - This will take the variance deviation of the given neighborhood. -% arrayOut = HIP.VarFilter(arrayIn,kernel,[numIterations],[device]) +% [imageOut] = HIP.VarFilter(imageIn,kernel,[numIterations],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,12 +17,13 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. +% -function arrayOut = VarFilter(arrayIn,kernel,numIterations,device) +function [imageOut] = VarFilter(imageIn,kernel,numIterations,device) try - arrayOut = HIP.Cuda.VarFilter(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Cuda.VarFilter(imageIn,kernel,numIterations,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.VarFilter(arrayIn,kernel,numIterations,device); + [imageOut] = HIP.Local.VarFilter(imageIn,kernel,numIterations,device); end end diff --git a/src/MATLAB/+HIP/WienerFilter.m b/src/MATLAB/+HIP/WienerFilter.m index da0a60727b221d891d629830c613a606326293e6..398311f9678fe758d582bdb44b56ffcd99ce6115 100644 --- a/src/MATLAB/+HIP/WienerFilter.m +++ b/src/MATLAB/+HIP/WienerFilter.m @@ -1,5 +1,5 @@ % WienerFilter - A Wiener filter aims to denoise an image in a linear fashion. -% arrayOut = HIP.WienerFilter(arrayIn,[kernel],[noiseVariance],[device]) +% [imageOut] = HIP.WienerFilter(imageIn,kernel,[noiseVariance],[device]) % imageIn = This is a one to five dimensional array. The first three dimensions are treated as spatial. % The spatial dimensions will have the kernel applied. The last two dimensions will determine % how to stride or jump to the next spatial block. @@ -17,12 +17,13 @@ % the data across multiple devices. % % imageOut = This will be an array of the same type and shape as the input array. +% -function arrayOut = WienerFilter(arrayIn,kernel,noiseVariance,device) +function [imageOut] = WienerFilter(imageIn,kernel,noiseVariance,device) try - arrayOut = HIP.Cuda.WienerFilter(arrayIn,kernel,noiseVariance,device); + [imageOut] = HIP.Cuda.WienerFilter(imageIn,kernel,noiseVariance,device); catch errMsg warning(errMsg.message); - arrayOut = HIP.Local.WienerFilter(arrayIn,kernel,noiseVariance,device); + [imageOut] = HIP.Local.WienerFilter(imageIn,kernel,noiseVariance,device); end end