code: def compute_roc_tuned(x_train, y_train, x_test, y_test):
      # define objective function
      @optunity.cross_validated(
          x=x_train, y=y_train, num_iter=2, num_folds=5
      )
      def inner_cv(x_train, y_train, x_test, y_test, C, gamma):
          model = sklearn.svm.SVC(C=C, gamma=gamma).fit(
              x_train, y_train
          )
          decision_values = model.decision_function(x_test)
          return optunity.metrics.roc_auc(y_test, decision_values)
  
      # optimize parameters
      optimal_pars, _, _ = optunity.maximize(
          inner_cv, 150, C=[0, 10], gamma=[0, 0.1], pmap=optunity.pmap
      )
      # if you are running this in IPython, optunity.pmap will not work
      # more info at: https://github.com/claesenm/optunity/issues/8
      # comment out the above line and replace by the one below:
      # optimal_pars, _, _ = optunity.maximize(inner_cv, 200, C=[0, 10], gamma=[0, 0.1])
  
      tuned_model = sklearn.svm.SVC(**optimal_pars).fit(
          x_train, y_train
      )
      decision_values = tuned_model.decision_function(x_test)
      auc = optunity.metrics.roc_auc(y_test, decision_values)
      return auc
  
file_path: optunity/bin/examples/python/sklearn/svc.py
imports: import optunity
  import optunity.metrics
  import sklearn.svm
  import numpy
  import time
  from sklearn.datasets import load_digits
label_desc: Use image node_id 2 for calling a global function with example usage: compute_roc_tuned(x_train, y_train, x_test, y_test) and returns: auc, optunity