Skip to content

[Bug]: [FATAL] This fastdup version is deprecated, please reinstall from pypi using pip install fastdup #351

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
prashant-dn opened this issue Nov 27, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@prashant-dn
Copy link

What happened?

I re-installed fastdup using

!pip install -U pip
!pip uninstall fastdup -y
!pip install fastdup
import fastdup as f
f.__version__

and found the version 2.1 installed.

Now, when I run

import fastdup as f
fd = fastdup.create(input_dir="/dnhq-filer1/archived_vids/prashant/dnca-dataset/cart_classifier/frames/batch15_batches/batch_1")
fd.run()

I get error

Warning: fastdup create() without work_dir argument, output is stored in a folder named work_dir in your current working path.
FastDup Software, (C) copyright 2022 Dr. Amir Alush and Dr. Danny Bickson.
2024-11-27 10:44:27 [FATAL] This fastdup version is deprecated, please reinstall from pypi using `pip install fastdup`
---------------------------------------------------------------------------
RuntimeError                              Traceback (most recent call last)
Cell In[17], line 3
      1 import fastdup as f
      2 fd = fastdup.create(input_dir="/dnhq-filer1/archived_vids/prashant/dnca-dataset/cart_classifier/frames/batch15_batches/batch_1")
----> 3 fd.run()

File /algo/users/sujit/softwares/MiniConda/envs/fastdup/lib/python3.8/site-packages/fastdup/engine.py:157, in Fastdup.run(self, input_dir, annotations, embeddings, subset, data_type, overwrite, model_path, distance, nearest_neighbors_k, threshold, outlier_percentile, num_threads, num_images, verbose, license, high_accuracy, cc_threshold, **kwargs)
    154     fastdup_func_params['model_path'] = model_path
    155 fastdup_func_params.update(kwargs)
--> 157 return super().run(annotations=annotations, input_dir=input_dir, subset=subset, data_type=data_type,
    158             overwrite=overwrite, embeddings=embeddings, **fastdup_func_params)

File /algo/users/sujit/softwares/MiniConda/envs/fastdup/lib/python3.8/site-packages/fastdup/sentry.py:144, in v1_sentry_handler.<locals>.inner_function(*args, **kwargs)
    142     else:
    143         fastdup_capture_exception(f"V1:{func.__name__}", ex)
--> 144     raise ex
    146 except Exception as ex:
    147     fastdup_capture_exception(f"V1:{func.__name__}", ex)

File /algo/users/sujit/softwares/MiniConda/envs/fastdup/lib/python3.8/site-packages/fastdup/sentry.py:135, in v1_sentry_handler.<locals>.inner_function(*args, **kwargs)
    133 try:
    134     start_time = time.time()
--> 135     ret = func(*args, **kwargs)
    136     fastdup_performance_capture(f"V1:{func.__name__}", start_time)
    137     return ret

File /algo/users/sujit/softwares/MiniConda/envs/fastdup/lib/python3.8/site-packages/fastdup/fastdup_controller.py:595, in FastdupController.run(self, input_dir, annotations, subset, embeddings, data_type, overwrite, print_summary, print_vl_datasets_ref, **fastdup_kwargs)
    593 # run fastdup - create embeddings
    594 if fastdup.run(self._set_fastdup_input(), work_dir=str(self._work_dir), **fastdup_kwargs) != 0:
--> 595     raise RuntimeError('Fastdup execution failed')
    597 #fastdup_convert_to_relpath(self._work_dir, self._filename_prefix)
    598 
    599 # post process - map fastdup-id to image (for bbox this is done in self._set_fastdup_input)
    600 if self._dtype == FD.IMG or self._run_mode == FD.MODE_CROP:

RuntimeError: Fastdup execution failed

What did you expect to see?

I expected the fd.run() to run normally

What version of fastdup were you runnning on?

2.1

What version of Python were you running on?

Python 3.8

Operating System

Ubuntu 20.04.4 LTS

Reproduction steps

Get an env just mine (above) and install fastdup using pip.

Relevant log output

No response

Attach a screenshot [Optional]

No response

Contact Details [Optional]

No response

@prashant-dn prashant-dn added the bug Something isn't working label Nov 27, 2024
@prashant-dn
Copy link
Author

Even the docker container faces the same issue :>
It had 1.2 and said

>>> import fastdup as f
"/dnhq-filer1/archived_vids/prashant/dnca-dataset/cart_classifier/frames/batch15_batches/batch_1")
fd.run()Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python3.8/dist-packages/fastdup/__init__.py", line 52, in <module>
    raise RuntimeError(f"fastdup detected your are running an old version {__version__} (10 versions or more vs. the latest) please upgrade fastdup")
RuntimeError: fastdup detected your are running an old version 1.25 (10 versions or more vs. the latest) please upgrade fastdup

On upgrading it via pip install fastdup --upgrade, It still give above error

>>> import fastdup
>>> fd = fastdup.create(input_dir="/dnhq-filer1/archived_vids/prashant/dnca-dataset/cart_classifier/frames/batch15_batches/batch_1")
Warning: fastdup create() without work_dir argument, output is stored in a folder named work_dir in your current working path.
>>> fd.run()
FastDup Software, (C) copyright 2022 Dr. Amir Alush and Dr. Danny Bickson.
2024-11-27 07:14:46 [FATAL] This fastdup version is deprecated, please reinstall from pypi using `pip install fastdup`
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python3.8/dist-packages/fastdup/engine.py", line 157, in run
    return super().run(annotations=annotations, input_dir=input_dir, subset=subset, data_type=data_type,
  File "/usr/local/lib/python3.8/dist-packages/fastdup/sentry.py", line 144, in inner_function
    raise ex
  File "/usr/local/lib/python3.8/dist-packages/fastdup/sentry.py", line 135, in inner_function
    ret = func(*args, **kwargs)
  File "/usr/local/lib/python3.8/dist-packages/fastdup/fastdup_controller.py", line 595, in run
    raise RuntimeError('Fastdup execution failed')
RuntimeError: Fastdup execution failed

@dbickson
Copy link
Collaborator

dbickson commented Nov 27, 2024

Hi, You need to upgrade this version is not supported anymore.
In addition python3.8 is no longer supported, you need python3.9 and up

@prashant-dn
Copy link
Author

Hey,
It seems to work with python3.9 -m pip install -U fastdup --force-reinstall and then running through python3.9.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants