%%capture
!pip install condacolab
Requirement already satisfied: condacolab in /usr/local/lib/python3.7/dist-packages (0.1.3)
import condacolab
condacolab.install()
⏬ Downloading https://github.com/jaimergp/miniforge/releases/latest/download/Mambaforge-colab-Linux-x86_64.sh...
📦 Installing...
📌 Adjusting configuration...
🩹 Patching environment...
⏲ Done in 0:00:39
🔁 Restarting kernel...
!conda create -n pyannote python=3.8.5
!conda activate pyannote

!conda install numpy cffi
!conda install libsndfile=1.0.28 -c conda-forge

!pip install https://github.com/pyannote/pyannote-audio/archive/develop.zip
%%capture
!wget https://podcast.rasset.ie/podcasts/audio/2021/0626/20210626_rteraidion-bailiuchanbhairbre-bailichnbh_c21974765_21975131_232_.mp3
%%capture
!ffmpeg -i /content/20210626_rteraidion-bailiuchanbhairbre-bailichnbh_c21974765_21975131_232_.mp3 -acodec pcm_s16le -ac 1 -ar 16000 /content/20210626_rteraidion-bailiuchanbhairbre-bailichnbh_c21974765_21975131_232_.wav
from pyannote.audio.pipelines import VoiceActivityDetection
pipeline = VoiceActivityDetection(segmentation="pyannote/segmentation")
HYPER_PARAMETERS = {
  # onset/offset activation thresholds
  "onset": 0.5, "offset": 0.5,
  # remove speech regions shorter than that many seconds.
  "min_duration_on": 0.0,
  # fill non-speech regions shorter than that many seconds.
  "min_duration_off": 0.0
}
pipeline.instantiate(HYPER_PARAMETERS)
vad = pipeline("/content/20210626_rteraidion-bailiuchanbhairbre-bailichnbh_c21974765_21975131_232_.wav")
---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
<ipython-input-5-e82545d3d9d2> in <module>()
----> 1 from pyannote.audio.pipelines import VoiceActivityDetection
      2 pipeline = VoiceActivityDetection(segmentation="pyannote/segmentation")
      3 HYPER_PARAMETERS = {
      4   # onset/offset activation thresholds
      5   "onset": 0.5, "offset": 0.5,

/usr/local/lib/python3.7/site-packages/pyannote/audio/__init__.py in <module>()
     27 
     28 
---> 29 from .core.inference import Inference
     30 from .core.io import Audio
     31 from .core.model import Model

/usr/local/lib/python3.7/site-packages/pyannote/audio/core/inference.py in <module>()
     28 import torch
     29 from einops import rearrange
---> 30 from pytorch_lightning.utilities.memory import is_oom_error
     31 
     32 from pyannote.audio.core.io import AudioFile

/usr/local/lib/python3.7/site-packages/pytorch_lightning/__init__.py in <module>()
     18 _PROJECT_ROOT = os.path.dirname(_PACKAGE_ROOT)
     19 
---> 20 from pytorch_lightning import metrics  # noqa: E402
     21 from pytorch_lightning.callbacks import Callback  # noqa: E402
     22 from pytorch_lightning.core import LightningDataModule, LightningModule  # noqa: E402

/usr/local/lib/python3.7/site-packages/pytorch_lightning/metrics/__init__.py in <module>()
     13 # limitations under the License.
     14 
---> 15 from pytorch_lightning.metrics.classification import (  # noqa: F401
     16     Accuracy,
     17     AUC,

/usr/local/lib/python3.7/site-packages/pytorch_lightning/metrics/classification/__init__.py in <module>()
     12 # See the License for the specific language governing permissions and
     13 # limitations under the License.
---> 14 from pytorch_lightning.metrics.classification.accuracy import Accuracy  # noqa: F401
     15 from pytorch_lightning.metrics.classification.auc import AUC  # noqa: F401
     16 from pytorch_lightning.metrics.classification.auroc import AUROC  # noqa: F401

/usr/local/lib/python3.7/site-packages/pytorch_lightning/metrics/classification/accuracy.py in <module>()
     16 from torchmetrics import Accuracy as _Accuracy
     17 
---> 18 from pytorch_lightning.metrics.utils import deprecated_metrics, void
     19 
     20 

/usr/local/lib/python3.7/site-packages/pytorch_lightning/metrics/utils.py in <module>()
     27 from torchmetrics.utilities.distributed import reduce as _reduce
     28 
---> 29 from pytorch_lightning.utilities import rank_zero_deprecation
     30 from pytorch_lightning.utilities.imports import _TORCHMETRICS_GREATER_EQUAL_0_3, _TORCHMETRICS_LOWER_THAN_0_3
     31 

/usr/local/lib/python3.7/site-packages/pytorch_lightning/utilities/__init__.py in <module>()
     16 import numpy
     17 
---> 18 from pytorch_lightning.utilities.apply_func import move_data_to_device  # noqa: F401
     19 from pytorch_lightning.utilities.distributed import AllGatherGrad, rank_zero_info, rank_zero_only  # noqa: F401
     20 from pytorch_lightning.utilities.enums import (  # noqa: F401

/usr/local/lib/python3.7/site-packages/pytorch_lightning/utilities/apply_func.py in <module>()
     28 
     29 if _TORCHTEXT_AVAILABLE:
---> 30     if _compare_version("torchtext", operator.ge, "0.9.0"):
     31         from torchtext.legacy.data import Batch
     32     else:

/usr/local/lib/python3.7/site-packages/pytorch_lightning/utilities/imports.py in _compare_version(package, op, version)
     52     """
     53     try:
---> 54         pkg = importlib.import_module(package)
     55     except (ModuleNotFoundError, DistributionNotFound):
     56         return False

/usr/lib/python3.7/importlib/__init__.py in import_module(name, package)
    125                 break
    126             level += 1
--> 127     return _bootstrap._gcd_import(name[level:], package, level)
    128 
    129 

/usr/local/lib/python3.7/dist-packages/torchtext/__init__.py in <module>()
      3 from . import datasets
      4 from . import utils
----> 5 from . import vocab
      6 from . import legacy
      7 

/usr/local/lib/python3.7/dist-packages/torchtext/vocab.py in <module>()
     11 from typing import Dict, List, Optional, Iterable
     12 from collections import Counter, OrderedDict
---> 13 from torchtext._torchtext import (
     14     Vocab as VocabPybind,
     15 )

ImportError: /usr/local/lib/python3.7/dist-packages/torchtext/_torchtext.so: undefined symbol: _ZN2at6detail10noopDeleteEPv

---------------------------------------------------------------------------
NOTE: If your import is failing due to a missing package, you can
manually install dependencies using either !pip or !apt.

To view examples of installing some common dependencies, click the
"Open Examples" button below.
---------------------------------------------------------------------------