0

When I am trying to import ConvexHull from scipy I am getting an error.

from  scipy.spatial import ConvexHull
**Traceback (most recent call last):
  File "<input>", line 1, in <module>
ImportError: cannot import name ConvexHull**

Here what I am doing wrong?

I am using scipy0.12.0 version.But when I am importing scipy and scipy.spatial I am not getting any error.

StackExchange
  • 432
  • 2
  • 8
  • 22

1 Answers1

0

I think this is what you are looking for

from scipy import spatial

spatial.qhull?
Type:       module
Base Class: <type 'module'>
String Form:<module 'scipy.spatial.qhull' from '/usr/lib/python2.7/dist-packages/scipy/spatial/qhull.so'>
Namespace:  Interactive
File:       /usr/lib/python2.7/dist-packages/scipy/spatial/qhull.so
Docstring:
Wrappers for Qhull triangulation, plus some additional N-D geometry utilities

.. versionadded:: 0.9

But it is true, you should be able to import the ConvexHull directly from version 0.12.0 on.

New in version 0.12.0.

I'm using 0.9 so that is why I have to use the Qhull library.

LarsVegas
  • 6,522
  • 10
  • 43
  • 67