Skip to main content
  • Home
  • Development
  • Documentation
  • Donate
  • Operational login
  • Browse the archive

swh logo
SoftwareHeritage
Software
Heritage
Archive
Features
  • Search

  • Downloads

  • Save code now

  • Add forge now

  • Help

  • f99a844
  • /
  • lib
  • /
  • OxImageCalculatorT1.h
Raw File Download
Permalinks

To reference or cite the objects present in the Software Heritage archive, permalinks based on SoftWare Hash IDentifiers (SWHIDs) must be used.
Select below a type of object currently browsed in order to display its associated SWHID and permalink.

  • content
  • directory
content badge Iframe embedding
swh:1:cnt:417b0f824842e39d428838721b0dff69b2d8d26c
directory badge Iframe embedding
swh:1:dir:7f21c9a4b7dfafd29925be862d8bd559b684364d
Citations

This interface enables to generate software citations, provided that the root directory of browsed objects contains a citation.cff or codemeta.json file.
Select below a type of object currently browsed in order to generate citations for them.

  • content
  • directory
Generate software citation in BibTex format (requires biblatex-software package)
Generating citation ...
Generate software citation in BibTex format (requires biblatex-software package)
Generating citation ...
OxImageCalculatorT1.h
/*!
 * \file OxImageCalculator.h
 * \author Konrad Werys
 * \date 2018/08/07
 */

#ifndef Tomato_OXIMAGECALCULATORT1_H
#define Tomato_OXIMAGECALCULATORT1_H

#include "CmakeConfigForTomato.h"
#ifndef CXX_STANDARD_98
#include <thread>
#endif

#include "OxCalculatorT1.h"

namespace Ox {

    template<typename MeasureType>
    class ImageCalculatorT1 {
    public:

        ImageCalculatorT1();
        virtual ~ImageCalculatorT1(){};

        void setUseThreads(bool _useThreads);
        void setNCols(int _nCols);
        void setNRows(int _nRows);
        void setNSamples(int _nSamples);
        void setInvTimes(MeasureType *_invTimes);
        void setImageMag(MeasureType *_imageMag);
        void setImagePha(MeasureType *_imagePha);
        void setImageResults(MeasureType *_imageResults);
        void setCalculatorT1(CalculatorT1<MeasureType> *_calculatorT1);

        MeasureType *getImageResults() const;

        virtual int calculate();
        virtual int calculateOneThread(int posStart, int posStop);

    protected:
        bool _useThreads;
        int _nCols;
        int _nRows;
        int _nSamples;
        MeasureType* _invTimes; // nSamples
        MeasureType* _imageMag; // nCols * nRows * nSamples, address [iCol][iRow][iSam] iSample * (nCols*nRows) + iRow * nCols + iCol
        MeasureType* _imagePha; // nCols * nRows * nSamples, address [iCol][iRow][iSam] iSample * (nCols*nRows) + iRow * nCols + iCol
        MeasureType* _imageResults; // nCols * nRows * nDims, address [iCol][iRow][iDim] iDim * (nCols*nRows) + iRow * nCols + iCol

        CalculatorT1<MeasureType> *_calculatorT1;
    };

} // namespace Ox

#include "OxImageCalculatorT1.hxx"

#endif //Tomato_OXIMAGECALCULATORT1_H

Software Heritage — Copyright (C) 2015–2025, The Software Heritage developers. License: GNU AGPLv3+.
The source code of Software Heritage itself is available on our development forge.
The source code files archived by Software Heritage are available under their own copyright and licenses.
Terms of use: Archive access, API— Contact— JavaScript license information— Web API

back to top