code: def test_logloss_clipping(self):
      y = turicreate.SArray([0, 1, 2, 0])
      yhat = turicreate.SArray(
          [
              [0.9, 0.0, 0.1],
              [0.8, 0.1, 0.1],
              [0.1, 0.1, 0.8],
              [0.1, 0.1, 0.8],
          ]
      )
      log_loss = turicreate.toolkits.evaluation.log_loss(y, yhat)
      self.assertTrue(log_loss != inf)
  
      y = turicreate.SArray([0, 1, 2, 0])
      yhat = turicreate.SArray(
          [
              [1.0, 0.0, 0.0],
              [0.8, 0.1, 0.1],
              [0.1, 0.1, 0.8],
              [0.1, 0.1, 0.8],
          ]
      )
  
      log_loss = turicreate.toolkits.evaluation.log_loss(y, yhat)
      self.assertTrue(log_loss != inf)
  
      y = turicreate.SArray([0, 1, 0, 0])
      yhat = turicreate.SArray([0.0, 0.9, 0.1, 0.1])
      log_loss = turicreate.toolkits.evaluation.log_loss(y, yhat)
      self.assertTrue(log_loss != inf)
  
      y = turicreate.SArray([0, 1, 0, 0])
      yhat = turicreate.SArray([0.1, 1.0, 0.1, 0.1])
      log_loss = turicreate.toolkits.evaluation.log_loss(y, yhat)
      self.assertTrue(log_loss != inf)
  
imports: from __future__ import print_function
  from __future__ import division
  from __future__ import absolute_import
  import unittest
  import turicreate
  from turicreate.toolkits._main import ToolkitError
  import math
  from numpy import inf
  import numpy
label_desc: Use image node_id 3 for calling the MetricsTest obj's underlying member method code with example usage: obj.test_logloss_clipping() without return types