File size: 404 Bytes
3bd5293
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
from multilingual_clip.legacy_multilingual_clip import MultilingualClip

model_path = 'M-CLIP/Swedish-500k'
tok_path = 'M-CLIP/Swedish-500k'
head_weight_path = 'data/weights/Swe-CLIP Linear Weights.pkl'

sweclip_args = {'model_name': model_path,
                'tokenizer_name': tok_path,
                'head_path': head_weight_path}

sweclip = MultilingualClip(**sweclip_args)

print(sweclip('test'))