Search code examples
pythonpython-3.xcrf

ImportError: cannot import name 'SubgradientStructuredSVM'


I am using jupyter notebook, and installed pystruct using pip install pystruct

from pystruct.learners import SubgradientStructuredSVM

ImportError: cannot import name 'SubgradientStructuredSVM'


Solution

  • Can you try:

    from pystruct.learners import SubgradientSSVM
    

    Please refer to the documentation for more information given in the link https://pystruct.github.io/generated/pystruct.learners.SubgradientSSVM.html.