tensortrade.core.base module¶
Responsible for the basic classes in the project.
- tensortrade.core.base.global_clock¶
A clock that provides a global reference for all objects that share a timeline.
- Type:
Clock
- class tensortrade.core.base.Identifiable[source]¶
Bases:
object
Identifiable mixin for adding a unique id property to instances of a class.
- class tensortrade.core.base.Observable[source]¶
Bases:
object
An object with some value that can be observed.
An object to which a listener can be attached to and be alerted about on an event happening.
- listeners¶
A list of listeners that the object will alert on events occurring.
- Type:
list of listeners
- attach(listener) Observable [source]¶
Adds a listener to receive alerts.
- Parameters:
listener (a listener object)
- Returns:
Observable – The observable being called.
- detach(listener) Observable [source]¶
Removes a listener from receiving alerts.
- Parameters:
listener (a listener object)
- Returns:
Observable – The observable being called.
- class tensortrade.core.base.TimeIndexed[source]¶
Bases:
object
A class for objects that are indexed by time.
- class tensortrade.core.base.TimedIdentifiable[source]¶
Bases:
Identifiable
,TimeIndexed
A class an identifiable object embedded in a time process.
- created_at¶
The time at which this object was created according to its associated clock.
- Type:
datetime.datetime