2

I tried importing Lasagne in my code which is as follows:

from __future__ import print_function
import sys
import os
import time
import string
import random
import pickle
import numpy as np
import theano
import theano.tensor as T
import lasagne

But on running the file I keep getting the following error:

  File "main_cifar_100_theano.py", line 12, in <module>
    import lasagne
  File "/usr/local/lib/python3.7/dist-packages/lasagne/__init__.py", line 19, in <module>
    from . import layers
  File "/usr/local/lib/python3.7/dist-packages/lasagne/layers/__init__.py", line 5, in <module>
    from .noise import *
  File "/usr/local/lib/python3.7/dist-packages/lasagne/layers/noise.py", line 6, in <module>
    from theano.sandbox.rng_mrg import MRG_RandomStreams as RandomStreams
ImportError: cannot import name 'MRG_RandomStreams' from 'theano.sandbox.rng_mrg' (/usr/local/lib/python3.7/dist-packages/theano/sandbox/rng_mrg.py)

Please help me resolve this issue.

Dr. Snoopy
  • 55,122
  • 7
  • 121
  • 140

0 Answers0