ohmeow / ohmeow_website

Apache License 2.0
24 stars 21 forks source link

BLURR not defined #22

Closed nadyadevani3112 closed 3 years ago

nadyadevani3112 commented 3 years ago

Hi, I got this error : NameError: name 'BLURR' is not defined

when running this cell pretrained_model_name = "facebook/bart-large-cnn" hf_arch, hf_config, hf_tokenizer, hf_model = BLURR.get_hf_objects(pretrained_model_name, model_cls=BartForConditionalGeneration)

may i know what BLURR is?

ohmeow commented 3 years ago

Make sure you are using the latest by doing a pip install ohmeow-blurr --upgrade

nazhimkalam commented 1 year ago

The issue is not yet resolved

nazhimkalam commented 1 year ago

The solution which worked for me is as follows

from fastai.text.all import *

from blurr.text.data.all import from blurr.text.modeling.all import

Since u import using a '*' meaning that you import all, you dont need to make use of the key BLURR to import any functions, instead you can call out the function name with out BLURR itself which solved the problem for me

devanshiatlumiq commented 1 year ago

from blurr.text.utils import BlurrText

BLURR = BlurrText()

BLURR.get_hf_object()