OverviewFilesCommitsIssuesDocsReleasesPeers

opencog-sensory / opencog / cython-v0 / sensory_v0.pyx

25 lines · pyx ref:
#
# This file reads files that are generated by the OPENCOG_ADD_ATOM_TYPES
# macro so they can be imported using:
#
# from sensory import *
#
# This imports all the python wrappers for atom creation.
#
import warnings

from opencog.atomspace import types
from opencog.atomspace import regenerate_types
from opencog.utilities import add_node, add_link

# Step one: force the C++ shared lib ctor to run and report
# the new Atom type to the atomspace nameserver.
sensory_v0_types_init()

# Step two: Ask python to rebuild the list of Atom Types that it knows
# about.  This adds new attributes to the python .types class.
regenerate_types()

# Step three: declare some wrappers to make python easier to use.
include "opencog/sensory-v0/types/sensory_v0_types.pyx"