Skip to content

Commit

Permalink
fail nicely when mosek is not available in so mc example
Browse files Browse the repository at this point in the history
  • Loading branch information
Soeren Sonnenburg committed Jul 3, 2012
1 parent 06d9542 commit 239e0c4
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions examples/undocumented/python_modular/so_multiclass.py
Expand Up @@ -2,9 +2,14 @@

import numpy as np

from shogun.Features import RealFeatures
from shogun.Loss import HingeLoss
from shogun.Structure import MulticlassModel, MulticlassSOLabels, PrimalMosekSOSVM, RealNumber
try:
from shogun.Features import RealFeatures
from shogun.Loss import HingeLoss
from shogun.Structure import MulticlassModel, MulticlassSOLabels, PrimalMosekSOSVM, RealNumber
except ImportError:
print "Mosek not available"
import sys
sys.exit(0)

def gen_data():
np.random.seed(0)
Expand Down

0 comments on commit 239e0c4

Please sign in to comment.