Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit cbd3399

Browse files
authored
Fixing issue for CUDA feautre extraction (#117)
Using THROW_CHECK_EQ(options_.max_image_size, sift_gpu->GetMaxDimension()); causes issues for me when using CUDA as I don't seem to be able to set the parameter right. It seems wrong to me to expect that max_image_size is set to GetMaxDimension, as the latter will be device-dependent. Using THROW_CHECK_LE seems more appropriate.
1 parent d251596 commit cbd3399

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

sift.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ class Sift {
9999
#ifdef CUDA_ENABLED
100100
template <typename dtype>
101101
sift_output_t ExtractGPU(const pyimage_t<dtype>& image /* [h, w] */) {
102-
THROW_CHECK_EQ(options_.max_image_size, sift_gpu->GetMaxDimension());
102+
THROW_CHECK_LE(options_.max_image_size, sift_gpu->GetMaxDimension());
103103
THROW_CHECK(!options_.estimate_affine_shape);
104104
THROW_CHECK(!options_.domain_size_pooling);
105105

0 commit comments

Comments
 (0)