nineml.abstraction_layer.component.EventPort

class nineml.abstraction_layer.component.EventPort(name, mode='send', reduce_op=None)

EventPort

An EventPort is a port that can transmit and receive discrete events at points in time. For example, an integrate-and-fire could ‘send’ events to notify other components that it had fired; or synapses could receive events to notify them to provide current to a post-synaptic neuron.

__init__(name, mode='send', reduce_op=None)

Methods

__init__(name[, mode, reduce_op])
accept_visitor(visitor, **kwargs) link to something about visitation.
is_incoming() Returns True if the port’s mode is ‘recv’ or ‘reduce’
is_outgoing() Returns True if the port’s mode is ‘send’

Attributes

mode The mode of the port.
name The name of the port, local to the current component
reduce_op The reduce operation of the port, if it is a ‘reduce’ port
accept_visitor(visitor, **kwargs)

link to something about visitation.

is_incoming()

Returns True if the port’s mode is ‘recv’ or ‘reduce’

is_outgoing()

Returns True if the port’s mode is ‘send’

mode

The mode of the port. [‘send’,’recv’ or ‘reduce’]

name

The name of the port, local to the current component

reduce_op

The reduce operation of the port, if it is a ‘reduce’ port