当前位置: 首页>>代码示例>>Python>>正文


Python Component._init方法代码示例

本文整理汇总了Python中pyre.components.Component.Component._init方法的典型用法代码示例。如果您正苦于以下问题:Python Component._init方法的具体用法?Python Component._init怎么用?Python Component._init使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在pyre.components.Component.Component的用法示例。


在下文中一共展示了Component._init方法的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: _init

# 需要导入模块: from pyre.components.Component import Component [as 别名]
# 或者: from pyre.components.Component.Component import _init [as 别名]
    def _init(self):
        Component._init(self)
        self.weaver = self.inventory.weaver

        renderer = self.getCurator().codecs['pml'].renderer
        self.weaver.renderer = renderer

        return
开发者ID:geodynamics,项目名称:pythia,代码行数:10,代码来源:Application.py

示例2: _init

# 需要导入模块: from pyre.components.Component import Component [as 别名]
# 或者: from pyre.components.Component.Component import _init [as 别名]
    def _init(self):
        Component._init(self)
        
        self._alphabet = list(self.inventory.alphabet)
        self._base = len(self._alphabet)
        self._hashtable = self._hash(self._alphabet)

        return
开发者ID:Alex-Song,项目名称:vmaf,代码行数:10,代码来源:RecordLocator.py

示例3: _init

# 需要导入模块: from pyre.components.Component import Component [as 别名]
# 或者: from pyre.components.Component.Component import _init [as 别名]
    def _init(self):
        import journal
        theJournal = journal.journal()

        device = self.inventory.device.device
        theJournal.device = device

        Component._init(self)

        return
开发者ID:Alex-Song,项目名称:vmaf,代码行数:12,代码来源:Journal.py

示例4: _init

# 需要导入模块: from pyre.components.Component import Component [as 别名]
# 或者: from pyre.components.Component.Component import _init [as 别名]
    def _init(self):
        Component._init(self)

        # locate the user database
        import os
        self.passwd = os.path.join(self.home, self.inventory.passwd)
        self._info.log("user database in '%s'" % self.passwd)

        # configure the weaver
        self.weaver = self.inventory.weaver
        self.weaver.language = "python"

        return
开发者ID:Alex-Song,项目名称:vmaf,代码行数:15,代码来源:UserManager.py

示例5: _init

# 需要导入模块: from pyre.components.Component import Component [as 别名]
# 或者: from pyre.components.Component.Component import _init [as 别名]
    def _init(self):
        Component._init(self)

        thickness = self.thickness
        width = self.width
        height = self.height
        darkAngle = self.darkAngle

        from sampleassembly.predefined.VanadiumPlate import VanadiumPlate
        
        self._sample = VanadiumPlate(  self.name, width, height, thickness, darkAngle )
        
        return
开发者ID:danse-inelastic,项目名称:sampleassembly,代码行数:15,代码来源:VanadiumPlate.py

示例6: _init

# 需要导入模块: from pyre.components.Component import Component [as 别名]
# 或者: from pyre.components.Component.Component import _init [as 别名]
 def _init(self):
     """ 
         Initialization of the underlying model 
     """
     Component._init(self)
     
     # Set the parameters of the underlying model
     for name in model.params: 
         if hasattr(self, name):
             self.set(name, getattr(self, name))
         else:
             raise ValueError, "%s not an attribute" % name
     
     return
开发者ID:mcvine,项目名称:sansmodels,代码行数:16,代码来源:ScatteringIntensityFactory.py

示例7: _init

# 需要导入模块: from pyre.components.Component import Component [as 别名]
# 或者: from pyre.components.Component.Component import _init [as 别名]
    def _init(self):
        Component._init(self)

        import sys
        if len(self.logfile) == 0:
            logstream = sys.stdout
        else:
            logstream = open( self.logfile, 'w' )
        self.logstream = logstream

        if self.errlogfile == self.logfile:
            if len (self.errlogfile) == 0:
                errlogstream = sys.stderr
            else:
                errlogstream = self.logstream
        else:
            errlogstream = open(self.errlogfile, 'w')
        self.errlogstream = errlogstream
        
        return
开发者ID:danse-inelastic,项目名称:pyregui,代码行数:22,代码来源:Launcher.py

示例8: _init

# 需要导入模块: from pyre.components.Component import Component [as 别名]
# 或者: from pyre.components.Component.Component import _init [as 别名]
    def _init(self):
        Component._init(self)

        # install the ipc support
        import pyre.ipc
        self.selector = self._createSelector()
        self.monitor = self._createPortMonitor()

        # create the command dispatcher
        self.evaluator = self._createEvaluator()

        # initialize the port monitor
        self.monitor.install(self.inventory.port)

        # register our callbacks
        self.selector.notifyWhenIdle(self.onTimeout)
        self.selector.notifyOnInterrupt(self.onInterrupt)
        self.selector.notifyOnReadReady(self.monitor, self.onConnectionAttempt)

	# register the signal handlers
        self.registerSignalHandlers()

        return
开发者ID:Alex-Song,项目名称:vmaf,代码行数:25,代码来源:Service.py

示例9: _init

# 需要导入模块: from pyre.components.Component import Component [as 别名]
# 或者: from pyre.components.Component.Component import _init [as 别名]
 def _init(self):
     Component._init(self)
     self.deepcopy = DeepCopier( self )
     return
开发者ID:danse-inelastic,项目名称:inelastic-svn,代码行数:6,代码来源:Clerk.py

示例10: _init

# 需要导入模块: from pyre.components.Component import Component [as 别名]
# 或者: from pyre.components.Component.Component import _init [as 别名]
 def _init(self):
     Component._init(self)
     return
开发者ID:danse-inelastic,项目名称:molDynamics,代码行数:5,代码来源:LennardJonesForcefield.py

示例11: _init

# 需要导入模块: from pyre.components.Component import Component [as 别名]
# 或者: from pyre.components.Component.Component import _init [as 别名]
 def _init(self):
     base._init(self)
开发者ID:danse-inelastic,项目名称:AbInitio,代码行数:4,代码来源:DistributedDataStorage.py

示例12: _init

# 需要导入模块: from pyre.components.Component import Component [as 别名]
# 或者: from pyre.components.Component.Component import _init [as 别名]
 def _init(self):
     Component._init(self)
     self.initialize()
     return
开发者ID:bmi-forum,项目名称:bmi-pyre,代码行数:6,代码来源:Exponential.py

示例13: _init

# 需要导入模块: from pyre.components.Component import Component [as 别名]
# 或者: from pyre.components.Component.Component import _init [as 别名]
 def _init(self):
     Component._init(self)
     if self.inventory.dump: self._dump()
     return
开发者ID:McStasMcXtrace,项目名称:MCViNE,代码行数:6,代码来源:Geometer.py


注:本文中的pyre.components.Component.Component._init方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。