Camil Ziane
init space
fcf0cff
raw
history blame
465 Bytes
from transformers import AutoModel, AutoImageProcessor
from . import register_vision_tower
from .base import VisionTower
@register_vision_tower('aimv2')
class AIMv2Tower(VisionTower):
def __init__(self, cfg):
super().__init__(cfg)
self._vision_tower = AutoModel.from_pretrained(cfg.model_name_or_path, config = cfg, trust_remote_code=True)
self._image_processor = AutoImageProcessor.from_pretrained(cfg.model_name_or_path)