class_docstr: This is just speed opt. Not for stability.
class_docstr_tok: ["This","is","just","speed","opt",".","Not","for","stability","."]
code: def c_code_contiguous_disabled(self, node, name, inp, out, sub):
      (x,) = inp
      (z,) = out
      if (
          not theano.config.lib.amdlibm
          or node.inputs[0].dtype != node.outputs[0].dtype
      ):
          raise theano.gof.utils.MethodNotDefined()
      dtype = node.inputs[0].dtype
      if dtype == "float32" and self.amd_float32 is not None:
          dtype = "float"
          fct = "amd_vrsa_expf"
      elif dtype == "float64" and self.amd_float64 is not None:
          dtype = "double"
          fct = "amd_vrda_exp"
      else:
          raise theano.gof.utils.MethodNotDefined()
      return (
          """
          npy_intp n = PyArray_SIZE(%(z)s);
          %(dtype)s * x = (%(dtype)s*) PyArray_DATA(%(x)s);
          %(dtype)s * z = (%(dtype)s*) PyArray_DATA(%(z)s);
          // We block to keep the data in l1
          // normal l1 size = 32k: 32k/2(input + output)/8(nb bytes of double)=2k
          // We stay bellow the 2k limit to let space for
          // This is faster than the not blocking version
          for(int i=0;i<n;i+=2048){
              npy_intp nb = (n-i<2048)?n-i:2048;
              for(int j=0;j<nb;j++){
                  z[i+j] = -x[i+j];
              }
              %(fct)s(nb, z+i, z+i);
              for(int j=0;j<nb;j++){
                  z[i+j] = 1.0 /(1.0+z[i+j]);
              }
          }
          """
          % locals()
      )
      raise theano.gof.utils.MethodNotDefined()
  
imports: from __future__ import absolute_import, print_function, division
  import warnings
  import numpy
  import theano
  from theano import config, gof, printing, scalar
  from theano.compat import imap
  from theano.printing import pprint
  from theano.tensor import basic
  from theano.tensor import elemwise, opt, NotScalarConstantError
  from theano.tensor.type import values_eq_approx_remove_inf
  from theano.gof.opt import copy_stack_trace
label_desc: Use image node_id 6 for calling the ScalarSigmoid obj's underlying member method code with example usage: obj.c_code_contiguous_disabled(node, name, inp, out, sub) and returns: unknown