Getting AttributeError: 'module' object (scipy) has no attribute 'misc' in Python. How to solve this?

0 votes

Python module I have written suddenly no longer works with the error message that the module scipy does not have the attribute 'misc'.  I am still using python 2.7 after the update. 

I just updated Ubuntu to its latest stable version and that's about it.

Here is where the code crashes

import scipy
scipy.misc.imsave(slice,dat)

Any ideas on how to fix this? Appreciate some help!

Dec 24, 2018 in Python by Anirudh
• 2,080 points
1,904 views

1 answer to this question.

0 votes
>>> import scipy
>>> scipy.misc
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'module' object has no attribute 'misc'
>>> 
>>> 
>>> import scipy.misc
>>> scipy.misc.imsave
<function imsave at 0x19cfa28>
>>>

This is very common with scipy. Cheers!

answered Dec 24, 2018 by Nymeria
• 3,540 points

Related Questions In Python

0 votes
1 answer

Python error "AttributeError: '_Screen' object has no attribute 'mainloop'" python module turtle

Hey @Nagya, replace  wn.mainlopp() with turtle.mainloop() a ...READ MORE

answered Jun 19, 2019 in Python by Faiza
545 views
0 votes
1 answer

Python Pandas error: AttributeError: 'DataFrame' object has no attribute 'rows'

There is no attribute called “rows”. The ...READ MORE

answered Mar 28, 2019 in Python by Shri
15,147 views
0 votes
1 answer
+1 vote
2 answers

how can i count the items in a list?

Syntax :            list. count(value) Code: colors = ['red', 'green', ...READ MORE

answered Jul 6, 2019 in Python by Neha
• 330 points

edited Jul 8, 2019 by Kalgi 668 views
0 votes
0 answers
+4 votes
6 answers
0 votes
1 answer

How to convert a Pandas GroupBy object to DataFrame in Python

g1 here is a DataFrame. It has a hierarchical index, ...READ MORE

answered Nov 12, 2018 in Python by Nymeria
• 3,540 points
12,376 views
0 votes
1 answer

How to fix this? ValueError: invalid literal for int() with base 10 error in Python

The following are totally acceptable in python: passing ...READ MORE

answered Nov 16, 2018 in Python by Nymeria
• 3,540 points
41,806 views