### Install PopSift with demo apps via vcpkg Source: https://popsift.readthedocs.io/en/latest/install/install.html Installs PopSift including the demo applications. Add the 'apps' feature to include sample programs. ```shell vcpkg install popsift[apps] --triplet ``` -------------------------------- ### Install PopSift with vcpkg Source: https://popsift.readthedocs.io/en/latest/install/install.html Installs the PopSift library via vcpkg. Replace with the target architecture, e.g., x64-windows or x64-linux-dynamic. ```shell vcpkg install popsift --triplet ``` -------------------------------- ### Install dependencies with vcpkg Source: https://popsift.readthedocs.io/en/latest/install/install.html Installs all required dependencies for PopSift on Windows using vcpkg. Add the --triplet flag to specify architecture and version, e.g., --triplet x64-windows for dynamic Windows 64-bit builds. ```shell vcpkg install cuda devil boost-system boost-program-options boost-thread boost-filesystem ``` -------------------------------- ### Install dependencies on Ubuntu/Debian Source: https://popsift.readthedocs.io/en/latest/install/install.html Installs required dependencies on Ubuntu/Debian using the package manager. ```shell sudo apt-get install g++ git-all libboost-all-dev libdevil-dev ``` -------------------------------- ### Install dependencies on macOS with Homebrew Source: https://popsift.readthedocs.io/en/latest/install/install.html Installs required dependencies on macOS using Homebrew. ```shell brew install git boost devil ``` -------------------------------- ### Install dependencies on CentOS Source: https://popsift.readthedocs.io/en/latest/install/install.html Installs required dependencies on CentOS using the package manager. ```shell sudo yum install gcc-c++ git boost-devel devil ``` -------------------------------- ### Run PopSift Docker image Source: https://popsift.readthedocs.io/en/latest/install/install.html Run the PopSift Docker image in interactive mode. Requires nvidia-docker to be installed. ```bash docker run -it --runtime=nvidia alicevision/popsift:cuda8.0-ubuntu18.04 ``` -------------------------------- ### popsift::FeaturesHost *get() Source: https://popsift.readthedocs.io/en/latest/api/api.html Deprecated. See also getHost(). ```APIDOC ## popsift::FeaturesHost *get() ### Description Deprecated. See also getHost(). ``` -------------------------------- ### Config::getSiftMode() const Source: https://popsift.readthedocs.io/en/latest/api/api.html Gets the SIFT mode for more detailed sub-modes. ```APIDOC ## Config::getSiftMode() const ### Description Gets the SIFT mode for more detailed sub-modes. ### Method N/A (C++ method) ### Endpoint N/A ### Parameters None ### Request Example N/A ### Response #### Success Response - **SiftMode** - The SiftMode. #### Response Example N/A ``` -------------------------------- ### CMake find_package and link PopSift Source: https://popsift.readthedocs.io/en/latest/install/install.html Add PopSift as a dependency in your CMake project. The find_package call locates PopSiftConfig.cmake installed in /lib/cmake/PopSift/ and exposes the target PopSift::PopSift for compiling and linking. ```cmake find_package(PopSift CONFIG REQUIRED) ... add_executable(popsiftTest yourfile.cpp) target_link_libraries(popsiftTest PUBLIC PopSift::PopSift) ``` -------------------------------- ### getGaussModeDefault Source: https://popsift.readthedocs.io/en/latest/api/api.html Static function to get the default GaussMode. Call this from the constructor. ```APIDOC ## getGaussModeDefault ### Description Call this from the constructor. ### Method static GaussMode getGaussModeDefault() ### Returns GaussMode - The default GaussMode. ``` -------------------------------- ### getGaussModeUsage Source: https://popsift.readthedocs.io/en/latest/api/api.html Static function to get a message with the strings to use for setting the values of GaussMode. ```APIDOC ## getGaussModeUsage ### Description Get a message with the strings to use for setting the values of `GaussMode`. ### Method static const char *getGaussModeUsage() ### Returns const char* - A message with the list of strings. ``` -------------------------------- ### void uninit() Source: https://popsift.readthedocs.io/en/latest/api/api.html Release the resources. ```APIDOC ## void uninit() ### Description Release the resources. ``` -------------------------------- ### bool configure(const popsift::Config &config, bool force = false) Source: https://popsift.readthedocs.io/en/latest/api/api.html Provide the configuration if you used the PopSift default constructor. ```APIDOC ## bool configure(const popsift::Config &config, bool force = false) ### Description Provide the configuration if you used the PopSift default constructor. ### Parameters - **config** (const popsift::Config&) - configuration - **force** (bool) - force reconfiguration, default false ``` -------------------------------- ### inline void uninit(int) Source: https://popsift.readthedocs.io/en/latest/api/api.html Deprecated. ```APIDOC ## inline void uninit(int) ### Description Deprecated. ``` -------------------------------- ### Configure and build with CMake Source: https://popsift.readthedocs.io/en/latest/install/install.html Configures and builds PopSift from the root folder. On Windows, add -G "Visual Studio 16 2019" -A x64 to generate the Visual Studio solution. If using vcpkg dependencies, pass -DCMAKE_TOOLCHAIN_FILE=path/to/vcpkg/scripts/buildsystems/vcpkg.cmake at the cmake step. ```shell mkdir build && cd build cmake .. make -j `nproc` ``` -------------------------------- ### inline bool init(int, int w, int h) Source: https://popsift.readthedocs.io/en/latest/api/api.html Deprecated. ```APIDOC ## inline bool init(int, int w, int h) ### Description Deprecated. ``` -------------------------------- ### Build PopSift Docker image Source: https://popsift.readthedocs.io/en/latest/install/install.html Build the PopSift image using the Ubuntu-based Dockerfile after building the dependency image. ```bash docker build --tag alicevision/popsift:cuda8.0-ubuntu18.04 . ``` -------------------------------- ### popsift::FeaturesHost *getHost() Source: https://popsift.readthedocs.io/en/latest/api/api.html Returns the features host. ```APIDOC ## popsift::FeaturesHost *getHost() ### Description Returns the features host. ``` -------------------------------- ### Config::getUpscaleFactor() const Source: https://popsift.readthedocs.io/en/latest/api/api.html Returns the upscale factor for the input image. ```APIDOC ## Config::getUpscaleFactor() const ### Description Returns the upscale factor for the input image. ### Method N/A (C++ method) ### Endpoint N/A ### Parameters None ### Request Example N/A ### Response #### Success Response - **float** - The upscale factor. #### Response Example N/A ``` -------------------------------- ### explicit PopSift(ImageMode imode = ByteImages, int device = 0) Source: https://popsift.readthedocs.io/en/latest/api/api.html Constructor for PopSift with default configuration. ```APIDOC ## explicit PopSift(ImageMode imode = ByteImages, int device = 0) ### Description We support more than 1 streams, but we support only one sigma and one level parameters. ### Parameters - **imode** (ImageMode) - image mode, default ByteImages - **device** (int) - CUDA device, default 0 ``` -------------------------------- ### void setFeatures(popsift::FeaturesBase *f) Source: https://popsift.readthedocs.io/en/latest/api/api.html Fulfill the promise. ```APIDOC ## void setFeatures(popsift::FeaturesBase *f) ### Description Fulfill the promise. ### Parameters - **f** (popsift::FeaturesBase*) - the features to set ``` -------------------------------- ### Config::setVerbose(bool on = true) Source: https://popsift.readthedocs.io/en/latest/api/api.html Enables or disables verbose mode. ```APIDOC ## Config::setVerbose(bool on = true) ### Description Enables or disables verbose mode. ### Method N/A (C++ method) ### Endpoint N/A ### Parameters - **on** (bool) - [in] Whether to display additional information. ### Request Example N/A ### Response #### Success Response No return value. #### Response Example N/A ``` -------------------------------- ### ~PopSift() Source: https://popsift.readthedocs.io/en/latest/api/api.html Release all the resources. ```APIDOC ## ~PopSift() ### Description Release all the resources. ``` -------------------------------- ### Build PopSift dependency Docker image Source: https://popsift.readthedocs.io/en/latest/install/install.html Build the dependency image (Dockerfile_deps) with a specific CUDA and Ubuntu version. CUDA_TAG and OS_TAG build arguments select the versions; defaults are CUDA_TAG=10.2 and OS_TAG=18.04. ```bash docker build --build-arg CUDA_TAG=8.0 --tag alicevision/popsift-deps:cuda8.0-ubuntu18.04 -f Dockerfile_deps . ``` -------------------------------- ### Config::getLogMode() const Source: https://popsift.readthedocs.io/en/latest/api/api.html Finds out if we should print logging info or not. ```APIDOC ## Config::getLogMode() const ### Description Finds out if we should print logging info or not. ### Method N/A (C++ method) ### Endpoint N/A ### Parameters None ### Request Example N/A ### Response #### Success Response - **LogMode** - The current LogMode. #### Response Example N/A ``` -------------------------------- ### std::string testTextureFitErrorString(AllocTest err, int w, int h) Source: https://popsift.readthedocs.io/en/latest/api/api.html Create a warning string for an AllocTest error code. ```APIDOC ## std::string testTextureFitErrorString(AllocTest err, int w, int h) ### Description Create a warning string for an AllocTest error code. ### Parameters - **err** (AllocTest) - error code - **w** (int) - width - **h** (int) - height ``` -------------------------------- ### explicit PopSift(const popsift::Config &config, popsift::Config::ProcessingMode mode = popsift::Config::ExtractingMode, ImageMode imode = ByteImages, int device = 0) Source: https://popsift.readthedocs.io/en/latest/api/api.html Constructor with configuration. ```APIDOC ## explicit PopSift(const popsift::Config &config, popsift::Config::ProcessingMode mode = popsift::Config::ExtractingMode, ImageMode imode = ByteImages, int device = 0) ### Description Constructor with configuration. ### Parameters - **config** (const popsift::Config&) - configuration - **mode** (popsift::Config::ProcessingMode) - processing mode, default ExtractingMode - **imode** (ImageMode) - image mode, default ByteImages - **device** (int) - CUDA device, default 0 ``` -------------------------------- ### AllocTest testTextureFit(int width, int height) Source: https://popsift.readthedocs.io/en/latest/api/api.html Check whether the current CUDA device can support the image resolution (width,height) with the current configuration based on the card’s texture engine. ```APIDOC ## AllocTest testTextureFit(int width, int height) ### Description Check whether the current CUDA device can support the image resolution (width,height) with the current configuration based on the card’s texture engine. The function does not check if there is sufficient available memory. ### Parameters - **width** (int) - [in] The width of the input image - **height** (int) - [in] The height of the input image ### Returns AllocTest::Ok if the image dimensions are supported by this device’s CUDA texture engine, AllocTest::ImageExceedsLinearTextureLimit if the input image size exceeds the dimensions of the CUDA Texture used for loading. The input image must be scaled. AllocTest::ImageExceedsLayeredSurfaceLimit if the scaled input image exceeds the dimensions of the CUDA Surface used for the image pyramid. The scaling factor must be changes to fit in. ``` -------------------------------- ### Config::DEPRECATED(void setUseRootSift(bool on)) Source: https://popsift.readthedocs.io/en/latest/api/api.html Deprecated method to set the normalization mode. ```APIDOC ## Config::DEPRECATED(void setUseRootSift(bool on)) ### Description Deprecated method to set the normalization mode. ### Method N/A (C++ method) ### Endpoint N/A ### Parameters - **on** (bool) - [in] Use RootSift (`true`) or the L2-norm (`false`). ### Request Example N/A ### Response #### Success Response No return value. #### Response Example N/A ``` -------------------------------- ### SiftJob(int w, int h, const float *imageData) Source: https://popsift.readthedocs.io/en/latest/api/api.html Constructor for float images, value range [0..1[. ```APIDOC ## SiftJob(int w, int h, const float *imageData) ### Description Constructor for float images, value range [0..1[. ### Parameters - **w** (int) - [in] the width in pixel of the image - **h** (int) - [in] the height in pixel of the image - **imageData** (const float*) - [in] the image buffer ``` -------------------------------- ### Config::setLogMode(LogMode mode = All) Source: https://popsift.readthedocs.io/en/latest/api/api.html Sets the log mode. ```APIDOC ## Config::setLogMode(LogMode mode = All) ### Description Sets the log mode. ### Method N/A (C++ method) ### Endpoint N/A ### Parameters - **mode** (LogMode) - The log mode. ### Request Example N/A ### Response #### Success Response No return value. #### Response Example N/A ``` -------------------------------- ### CMake configure with PopSift_DIR Source: https://popsift.readthedocs.io/en/latest/install/install.html Pass the location of PopSiftConfig.cmake to CMake from the command line when building your project. ```bash cmake .. -DPopSift_DIR=/lib/cmake/PopSift/ ``` -------------------------------- ### ~SiftJob() Source: https://popsift.readthedocs.io/en/latest/api/api.html Destructor releases all the resources. ```APIDOC ## ~SiftJob() ### Description Destructor releases all the resources. ``` -------------------------------- ### Clone PopSift repository Source: https://popsift.readthedocs.io/en/latest/install/install.html Clones the PopSift repository from GitHub. ```shell git clone https://github.com/alicevision/PopSift.git ``` -------------------------------- ### SiftJob(int w, int h, const unsigned char *imageData) Source: https://popsift.readthedocs.io/en/latest/api/api.html Constructor for byte images, value range 0..255. ```APIDOC ## SiftJob(int w, int h, const unsigned char *imageData) ### Description Constructor for byte images, value range 0..255. ### Parameters - **w** (int) - [in] the width in pixel of the image - **h** (int) - [in] the height in pixel of the image - **imageData** (const unsigned char*) - [in] the image buffer ``` -------------------------------- ### getDescMode Source: https://popsift.readthedocs.io/en/latest/api/api.html Returns the descriptor extraction mode. ```APIDOC ## getDescMode ### Description Get the descriptor extraction mode. ### Method inline DescMode getDescMode() const ### Returns DescMode - The descriptor extraction mode. ``` -------------------------------- ### Config::setDescMode(DescMode mode = Loop) Source: https://popsift.readthedocs.io/en/latest/api/api.html Sets the descriptor mode. ```APIDOC ## Config::setDescMode(DescMode mode = Loop) ### Description Sets the descriptor mode. ### Method N/A (C++ method) ### Endpoint N/A ### Parameters - **mode** (DescMode) - [in] The descriptor mode. ### Request Example N/A ### Response #### Success Response No return value. #### Response Example N/A ``` -------------------------------- ### Config::ifPrintGaussTables() const Source: https://popsift.readthedocs.io/en/latest/api/api.html Prints Gauss spans and tables? ```APIDOC ## Config::ifPrintGaussTables() const ### Description Prints Gauss spans and tables? ### Method N/A (C++ method) ### Endpoint N/A ### Parameters None ### Request Example N/A ### Response #### Success Response - **bool** - Whether to print Gauss spans and tables. #### Response Example N/A ``` -------------------------------- ### Config::setMode(SiftMode m) Source: https://popsift.readthedocs.io/en/latest/api/api.html Sets the Sift mode. ```APIDOC ## Config::setMode(SiftMode m) ### Description Sets the Sift mode. ### Method N/A (C++ method) ### Endpoint N/A ### Parameters - **m** (SiftMode) - [in] The Sift mode ### Request Example N/A ### Response #### Success Response No return value. #### Response Example N/A ``` -------------------------------- ### SiftJob *enqueue(int w, int h, const unsigned char *imageData) Source: https://popsift.readthedocs.io/en/latest/api/api.html Enqueue a byte image, value range [0,255]. ```APIDOC ## SiftJob *enqueue(int w, int h, const unsigned char *imageData) ### Description Enqueue a byte image, value range [0,255]. ### Parameters - **w** (int) - [in] the width of the image. - **h** (int) - [in] the height of the image. - **imageData** (const unsigned char*) - [in] the image buffer. ### Returns the associated job ``` -------------------------------- ### Config::getNormalizationMultiplier() const Source: https://popsift.readthedocs.io/en/latest/api/api.html Returns the normalization multiplier (power of 2). ```APIDOC ## Config::getNormalizationMultiplier() const ### Description Returns the normalization multiplier (power of 2). ### Method N/A (C++ method) ### Endpoint N/A ### Parameters None ### Request Example N/A ### Response #### Success Response - **int** - The normalization multiplier. #### Response Example N/A ``` -------------------------------- ### Config::getPeakThreshold() const Source: https://popsift.readthedocs.io/en/latest/api/api.html Computes the actual peak threshold depending on the threshold parameter and the non-augmented number of levels. ```APIDOC ## Config::getPeakThreshold() const ### Description Computes the actual peak threshold depending on the threshold parameter and the non-augmented number of levels. ### Method N/A (C++ method) ### Endpoint N/A ### Parameters None ### Request Example N/A ### Response #### Success Response - **float** - The peak threshold value. #### Response Example N/A ``` -------------------------------- ### SiftJob *enqueue(int w, int h, const float *imageData) Source: https://popsift.readthedocs.io/en/latest/api/api.html Enqueue a float image, value range [0,1]. ```APIDOC ## SiftJob *enqueue(int w, int h, const float *imageData) ### Description Enqueue a float image, value range [0,1]. ### Parameters - **w** (int) - [in] the width of the image. - **h** (int) - [in] the height of the image. - **imageData** (const float*) - [in] the image buffer. ### Returns the associated job ``` -------------------------------- ### octaves Source: https://popsift.readthedocs.io/en/latest/api/api.html Public member variable specifying the number of octaves. If not specified, it is computed as log_2(min(x,y)) - 3 - start_sampling. ```APIDOC ## octaves ### Description The number of octaves is chosen freely. If not specified, it is: log_2( min(x,y) ) - 3 - start_sampling ### Type int ``` -------------------------------- ### execute Source: https://popsift.readthedocs.io/en/latest/api/api.html Deprecated function to execute the SIFT extraction algorithm on an image. ```APIDOC ## execute ### Description Deprecated function to execute the SIFT extraction algorithm on an image. ### Method N/A (C++ function) ### Endpoint N/A ### Parameters - **int** - Input parameter (unspecified) - **const unsigned char *imageData** - Pointer to image data ### Request Example N/A ### Response #### Success Response - **popsift::FeaturesBase*** - Pointer to extracted features #### Response Example N/A ``` -------------------------------- ### Config::setDescMode(const std::string &byname) Source: https://popsift.readthedocs.io/en/latest/api/api.html Sets the descriptor mode by string. ```APIDOC ## Config::setDescMode(const std::string &byname) ### Description Sets the descriptor mode by string. ### Method N/A (C++ method) ### Endpoint N/A ### Parameters - **byname** (const std::string&) - [in] The string containing the descriptor mode. ### Request Example N/A ### Response #### Success Response No return value. #### Response Example N/A ``` -------------------------------- ### Config::setNormMode(NormMode m) Source: https://popsift.readthedocs.io/en/latest/api/api.html Sets the normalization mode (L2-like or RootSift). ```APIDOC ## Config::setNormMode(NormMode m) ### Description Sets the normalization mode (L2-like or RootSift). ### Method N/A (C++ method) ### Endpoint N/A ### Parameters - **m** (NormMode) - The normalization mode. ### Request Example N/A ### Response #### Success Response No return value. #### Response Example N/A ``` -------------------------------- ### levels Source: https://popsift.readthedocs.io/en/latest/api/api.html Public member variable specifying the number of levels per octave. This is the number of inner DoG levels where feature points can be searched. ```APIDOC ## levels ### Description The number of levels per octave. This is actually the number of inner DoG levels where we can search for feature points. The number of ... This is the non-augmented number of levels, meaning this is not the number of gauss-filtered picture layers (which is levels+3), but the number of DoG layers in which we can search for extrema. ### Type int ``` -------------------------------- ### Config::setGaussMode(GaussMode m) Source: https://popsift.readthedocs.io/en/latest/api/api.html Sets the Gaussian mode. ```APIDOC ## Config::setGaussMode(GaussMode m) ### Description Sets the Gaussian mode. ### Method N/A (C++ method) ### Endpoint N/A ### Parameters - **m** (GaussMode) - [in] The Gaussian mode to use. ### Request Example N/A ### Response #### Success Response No return value. #### Response Example N/A ``` -------------------------------- ### Cite PopSift with BibTeX entry Source: https://popsift.readthedocs.io/en/latest/about/about.html BibTeX entry for citing the PopSift paper in publications. Use this citation format when referencing the work in academic papers or bibliographies. ```bibtex @inproceedings{Griwodz2018Popsift, author = {Griwodz, Carsten and Calvet, Lilian and Halvorsen, P{\aa}l}, title = {Popsift: A Faithful SIFT Implementation for Real-time Applications}, booktitle = {Proceedings of the 9th {ACM} Multimedia Systems Conference}, series = {MMSys '18}, year = {2018}, isbn = {978-1-4503-5192-8}, location = {Amsterdam, Netherlands}, pages = {415--420}, numpages = {6}, doi = {10.1145/3204949.3208136}, acmid = {3208136}, publisher = {ACM}, address = {New York, NY, USA}, } ``` -------------------------------- ### getScalingMode Source: https://popsift.readthedocs.io/en/latest/api/api.html Returns the scaling mode used for descriptor extraction. ```APIDOC ## getScalingMode ### Description Get the scaling mode. ### Method inline ScalingMode getScalingMode() const ### Returns ScalingMode - The descriptor extraction mode. ``` -------------------------------- ### _edge_limit Source: https://popsift.readthedocs.io/en/latest/api/api.html Public member variable specifying the edge limit. Default is 16.0f from Celebrandil, default edge_limit 10.0f from Bemap. ```APIDOC ## _edge_limit ### Description default edge_limit 16.0f from Celebrandil default edge_limit 10.0f from Bemap ### Type float ``` -------------------------------- ### Config::getGaussMode() const Source: https://popsift.readthedocs.io/en/latest/api/api.html Returns the Gauss filter scan mode. ```APIDOC ## Config::getGaussMode() const ### Description Returns the Gauss filter scan mode. ### Method N/A (C++ method) ### Endpoint N/A ### Parameters None ### Request Example N/A ### Response #### Success Response - **GaussMode** - The current GaussMode. #### Response Example N/A ``` -------------------------------- ### Config::setGaussMode(const std::string &m) Source: https://popsift.readthedocs.io/en/latest/api/api.html Sets the Gaussian mode from a string representation. ```APIDOC ## Config::setGaussMode(const std::string &m) ### Description Sets the Gaussian mode from a string representation. ### Method N/A (C++ method) ### Endpoint N/A ### Parameters - **m** (const std::string&) - [in] The string version of the GaussMode ### Request Example N/A ### Response #### Success Response No return value. #### Response Example N/A ``` -------------------------------- ### getFilterGridSize Source: https://popsift.readthedocs.io/en/latest/api/api.html Returns the grid size used for filtering. The image is split into gridSize x gridSize tiles to distribute extrema evenly. ```APIDOC ## getFilterGridSize ### Description Get the grid size for filtering. To avoid that grid filtering happens only in a tiny piece of an image, the image is split into getFilterGridSize() X getFilterGridSize() tiles and we allow getFilterMaxExtrema() / getFilterGridSize() extrema in each tile. ### Method inline int getFilterGridSize() const ### Returns int - The grid size. ``` -------------------------------- ### getFilterMaxExtrema Source: https://popsift.readthedocs.io/en/latest/api/api.html Returns the approximate number of extrema whose orientation and descriptor should be computed. Default is -1, which sets a hard limit based on octaves and max extrema. ```APIDOC ## getFilterMaxExtrema ### Description Set the approximate number of extrema whose orientation and descriptor should be computed. Default is -1, which sets the hard limit defined by "number of octaves * getMaxExtrema()". ### Method inline int getFilterMaxExtrema() const ### Returns int - The approximate number of extrema. ``` -------------------------------- ### getCanFilterExtrema Source: https://popsift.readthedocs.io/en/latest/api/api.html Checks whether filtering of extrema is enabled. This is a compile-time decision based on whether Thrust is used. ```APIDOC ## getCanFilterExtrema ### Description Have we enabled filtering? This is a compile time decision. The reason is that we use Thrust, which increases compile considerably and can be deactivated at the CMake level when you work on something else. ### Method bool getCanFilterExtrema() const ### Returns bool - Whether filtering is enabled. ``` -------------------------------- ### getFilterSorting Source: https://popsift.readthedocs.io/en/latest/api/api.html Returns the filtering mode, which determines how extrema are sorted during filtering. ```APIDOC ## getFilterSorting ### Description Get the filtering mode. ### Method inline GridFilterMode getFilterSorting() const ### Returns GridFilterMode - The filtering mode. ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.