deepy/core/graph.py
def shared(self, value, name=None):
        """
        Create a shared theano scalar value.
        """
        if type(value) == int:
            final_value = np.array(value, dtype="int32")
        elif type(value) == float:
            final_value = np.array(value, dtype=env.FLOATX)
        else:
            final_value = value

        return theano.shared(final_value, name=name)
def shared(self, value, name=None):
        if type(value) == int:
            final_value = np.array(value, dtype="int32")
        elif type(value) == float:
            final_value = np.array(value, dtype=env.FLOATX)
        else:
            final_value = value

        return theano.shared(final_value, name=name)
def shared ( self , value , name = None ) : if type ( value ) == int : final_value = np . array ( value , dtype = "int32" ) elif type ( value ) == float : final_value = np . array ( value , dtype = env . FLOATX ) else : final_value = value return theano . shared ( final_value , name = name )
Create a shared theano scalar value.
Create a shared theano scalar value .