i got a problem wir importing diffenrent libraries in codebook like "textblob" or "transformers". th

case# 14665399

Client facing the below issue . kindly check and assist

i got a problem wir importing diffenrent libraries in codebook like "textblob" or "transformers". the error "UnboundLocalError: local variable 'module_or_package' referenced before assignment" is shown after trying to import one of the packages.Are there any restrictions in codebook to use them? I found many examples in the official lseg developer community or on your github where the import is shown but can´t figure out why it is not working in codebook.
Just trying to start a project and import the librariesyou can see the code in the first 6 rows of the screenshotDo you have any idear?

Answers

  • Client provided the below information.
    Maybe the package is not installed in my codebook but I am not allowed to try to install it.I am getting the following massage if I try to install it 

    servlet.FileDownload?file=00PKY000005KI6v

    Maybe this information helps aswell…

  • Jirapongse
    Jirapongse ✭✭✭✭✭
    edited April 17

    @pavithra_suresh_17

    Yes, the client is not allowed to install additional Python libraries on CodeBook.

    The client needs to use the preinstalled libraries that are available on CodeBook.

    image.png image.png

    Otherwise, the client needs to setup the local jupyter environment to run the code.