Skip to content

IceVision


Quick Fact :

  • https://airctic.com/0.12.0/install/
  • It wraps up fastai, pytorch lightning
  • Its unified API allow to choose libraries → their models → their backbones

    # e.g. lib = mmdet, model = retinanet, backbone = resnet50_fpn_1x
    model_type = models.mmdet.retinanet
    backbone = model_type.backbones.resnet50_fpn_1x(pretrained=True)
    

Prerequisite Knowledge :

Basic knowledge of

  • Fastai / Pytorch Lightning
  • YOLO

Frequent Issue :

  • Issue - Icevision is suck on dependencies, the functional env so far :

    # packages
    python==3.7.13
    icevision[all]==0.11.0
    yolov5-icevision==6.0.0
    "opencv-python-headless<4.3"
    setuptools==61.2.0
    
  • issue - how to do inference with the exported model ?

    • i.e. how to load trained checkpoints
    • option 1 - official inference method model_from_checkpoint

      • weird, need to install mmcv-full even if you use yolo5:

        pip install mmcv-full -f https://download.openmmlab.com/mmcv/dist/cpu/torch1.10.0/index.html
        #mmcv-full-1.5.3.tar.gz
        
    • option 2 - use fastai / torch to load them manually

  • issue - training or data loader hanged locally (CPU)

  • issue - images / plot not showing

  • issue - about “image truncated”, below code can solve it

    from PIL import ImageFile
    ImageFile.LOAD_TRUNCATED_IMAGES = True
    

Comments