anomalib icon indicating copy to clipboard operation
anomalib copied to clipboard

[Bug]: Colab notebook anomalib install -v doesn't work

Open krupeshp opened this issue 1 year ago • 4 comments

Describe the bug

To use other subcommand using anomalib install Could not find anomalib. To use this feature, ensure that you have anomalib installed. Could not find openvino. To use this feature, ensure that you have openvino installed. To use comet logger install it using pip install comet-ml To use any logger install it using anomalib install -v /usr/local/lib/python3.10/dist-packages/anomalib/cli/install.py:63: UserWarning: Torch Version will be selected as 2.2.0. torch_install_args = get_torch_install_args(torch_requirement) /usr/local/lib/python3.10/dist-packages/anomalib/cli/utils/installation.py:271: UserWarning: Installed CUDA version is v12.2. v11.8 <= Supported CUDA version <= v12.1. This script will use CUDA v12.1. However, this may not be safe, and you are advised to install the correct version of CUDA. For more details, refer to https://pytorch.org/get-started/locally/ cuda_version = update_cuda_version_with_available_torch_cuda_build(cuda_version, torch_version) ⠋ Installing packages... This may take a few minutes.

[11:21:44] Installation list: ['gitpython', 'anomalib', 'tox', 'timm<=1.0.7,>=1.0.7',

This issue occurring in the google colab. It shows these logs and shell completes running. In both scenarios using pip and from source. %anomalib doesn't work as I use !anomalib install -v. Still having same problem. @samet-akcay

Dataset

N/A

Model

N/A

Steps to reproduce the behavior

NA

OS information

Google Colab

Expected behavior

It should install every dependencies which works fine with workstation installation. Colab installation doesn't work it is not installing dependencies which it should get installed with !anomalib install -v

Screenshots

No response

Pip/GitHub

pip

What version/branch did you use?

No response

Configuration YAML

NA

Logs

NA

Code of Conduct

  • [X] I agree to follow this project's Code of Conduct

krupeshp avatar Jul 29 '24 12:07 krupeshp

This also happens to me today. It seems like this happens only at Colab.

papago2355 avatar Jul 31 '24 02:07 papago2355

@krupeshp @papago2355 Thank you for reporting the issue.

I've checked and this only happens with colab. It doesn't install properly and the output also freezes and says it's done, but it doesn't install properly.

It's hard to tell if this is a problem with anomalib or colab, but there are alternatives.

!pip install anomalib[full]

In my colab environment (python 3.10), the above command works fine. Until we find the cause of this issue, recommend the above approach.

harimkang avatar Jul 31 '24 05:07 harimkang

@krupeshp @papago2355 Thank you for reporting the issue.

I've checked and this only happens with colab. It doesn't install properly and the output also freezes and says it's done, but it doesn't install properly.

It's hard to tell if this is a problem with anomalib or colab, but there are alternatives.

!pip install anomalib[full]

In my colab environment (python 3.10), the above command works fine. Until we find the cause of this issue, recommend the above approach.

@harimkang Thank you! This solves the issue. I highly doubt this is something from Colab since every other online editors and python notebook services are working 100% fine.

papago2355 avatar Jul 31 '24 05:07 papago2355

@harimkang Thank you! This solves the issue. I highly doubt this is something from Colab since every other online editors and python notebook services are working 100% fine.

Good to know! Colab is not sending any error output at the moment with anomalib install, so it might take a while to find the exact cause..

harimkang avatar Jul 31 '24 05:07 harimkang

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Jun 29 '25 05:06 github-actions[bot]

This issue was closed because it has been stalled for 14 days with no activity.

github-actions[bot] avatar Jul 14 '25 05:07 github-actions[bot]