Repository: stable-diffusion-webui
Issue: [Bug]: RuntimeError: cannot import name '_compare_version' from 'torchmetrics.utilities.imports'
Labels: bug-report

### Is there an existing issue for this?

- [X] I have searched the existing issues and checked the recent builds/commits

### What happened?

Use Google Colab and run into problems:
cannot import name '_compare_version' from 'torchmetrics.utilities.imports'

### Steps to reproduce the problem

1. Use Google Colab
2. Clone the repo using git clone https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
3. run %pip install torch==1.13.1+cu117 torchvision==0.14.1+cu117 torchtext==0.14.1 torchaudio==0.13.1 torchdata==0.5.1 --extra-index-url https://download.pytorch.org/whl/cu117
4. run !git checkout 11d432d
5. Start the webui-user.bat

### What should have happened?

The Web-UI should have launched without any errors.

### Version or Commit where the problem happens

11d432d

### What Python version are you running on ?

None

### What platforms do you use to access the UI ?

Windows

### What device are you running WebUI on?

_No response_

### Cross attention optimization

Automatic

### What browsers do you use to access the UI ?

Google Chrome

### Command Line Arguments

```Shell
--share --gradio-debug --disable-safe-unpickle --reinstall-xformers --enable-insecure-extension-access --opt-channelslast
```


### List of extensions

No

### Console logs

```Shell
Traceback (most recent call last):
  File "/content/test1/launch.py", line 295, in <module>
    start()
  File "/content/test1/launch.py", line 286, in start
    import webui
  File "/content/test1/webui.py", line 15, in <module>
    from modules import shared, devices, sd_samplers, upscaler, extensions, localization, ui_tempdir
  File "/content/test1/modules/sd_samplers.py", line 12, in <module>
    from modules import prompt_parser, devices, processing, images, sd_vae_approx
  File "/content/test1/modules/processing.py", line 15, in <module>
    import modules.sd_hijack
  File "/content/test1/modules/sd_hijack.py", line 4, in <module>
    import modules.textual_inversion.textual_inversion
  File "/content/test1/modules/textual_inversion/textual_inversion.py", line 13, in <module>
    from modules import shared, devices, sd_hijack, processing, sd_models, images, sd_samplers
  File "/content/test1/modules/sd_models.py", line 18, in <module>
    from modules.sd_hijack_inpainting import do_inpainting_hijack, should_hijack_inpainting
  File "/content/test1/modules/sd_hijack_inpainting.py", line 7, in <module>
    import ldm.models.diffusion.ddpm
  File "/content/test1/repositories/stable-diffusion-stability-ai/ldm/models/diffusion/ddpm.py", line 12, in <module>
    import pytorch_lightning as pl
  File "/usr/local/lib/python3.10/dist-packages/pytorch_lightning/__init__.py", line 34, in <module>
    from pytorch_lightning.callbacks import Callback  # noqa: E402
  File "/usr/local/lib/python3.10/dist-packages/pytorch_lightning/callbacks/__init__.py", line 25, in <module>
    from pytorch_lightning.callbacks.progress import ProgressBarBase, RichProgressBar, TQDMProgressBar
  File "/usr/local/lib/python3.10/dist-packages/pytorch_lightning/callbacks/progress/__init__.py", line 22, in <module>
    from pytorch_lightning.callbacks.progress.rich_progress import RichProgressBar  # noqa: F401
  File "/usr/local/lib/python3.10/dist-packages/pytorch_lightning/callbacks/progress/rich_progress.py", line 20, in <module>
    from torchmetrics.utilities.imports import _compare_version
ImportError: cannot import name '_compare_version' from 'torchmetrics.utilities.imports' (/usr/local/lib/python3.10/dist-packages/torchmetrics/utilities/imports.py)
```


### Additional information

I don't know programming so don't know how to try to fix.
I would like to keep using 11d432d if I could.