Пример #1
0
    def __init__(self):
        period = 1;

        # initialize base class
        _updater.__init__(self);

        # create the c++ mirror class
        if not hoomd.context.current.device.cpp_exec_conf.isCUDAEnabled():
            self.cpp_updater = _md.Enforce2DUpdater(hoomd.context.current.system_definition);
        else:
            self.cpp_updater = _md.Enforce2DUpdaterGPU(hoomd.context.current.system_definition);
        self.setupUpdater(period);
Пример #2
0
    def __init__(self):
        hoomd.util.print_status_line()
        period = 1

        # initialize base class
        _updater.__init__(self)

        # create the c++ mirror class
        if not hoomd.context.exec_conf.isCUDAEnabled():
            self.cpp_updater = _md.Enforce2DUpdater(
                hoomd.context.current.system_definition)
        else:
            self.cpp_updater = _md.Enforce2DUpdaterGPU(
                hoomd.context.current.system_definition)
        self.setupUpdater(period)