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


Python Magics.__init__方法代码示例

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


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

示例1: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
 def __init__(self, shell=None):
     Configurable.__init__(self, config=shell.config)
     self._generate_script_magics()
     Magics.__init__(self, shell=shell)
     self.job_manager = BackgroundJobManager()
     self.bg_processes = []
     atexit.register(self.kill_bg_processes)
开发者ID:pykomke,项目名称:Kurz_Python_KE,代码行数:9,代码来源:script.py

示例2: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
	def __init__(self, shell):
		Configurable.__init__(self, config=shell.config)
		Magics.__init__(self, shell=shell)

		# Add ourself to the list of module configurable via %config
		self.shell.configurables.append(self)

		self.rewriter = Rewriter()
开发者ID:miguel-branco,项目名称:ipython-raw-magic,代码行数:10,代码来源:magic.py

示例3: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
 def __init__(self, shell):
     Magics.__init__(self, shell)
     ip = get_ipython()
     self.csd = {}
     ip.user_ns["__csd"] = self.csd
     self.orc = {}
     ip.user_ns["__orc"] = self.orc
     self.sco = {}
     ip.user_ns["__sco"] = self.sco
开发者ID:fggp,项目名称:ctcsound,代码行数:11,代码来源:csoundmagics.py

示例4: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
 def __init__(self, shell):
     """Initialize sql_magic as a magic function; and add shell to configurables
     Create connection object."""
     self.shell = shell
     self.caller = None
     self.shell.configurables.append(self)
     Configurable.__init__(self, config=shell.config)
     Magics.__init__(self, shell=shell)
     self.conn = Connection(shell, available_connection_types, no_return_result_exceptions)
开发者ID:CedricArtigue,项目名称:sql_magic,代码行数:11,代码来源:sql_magic.py

示例5: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
        def __init__(self, shell):
            Configurable.__init__(self, config=shell.config)
            Magics.__init__(self, shell=shell)

            MyriaRelation.DefaultConnection = MyriaConnection(
                rest_url=self.rest_url,
                execution_url=self.execution_url,
                timeout=self.timeout)

            self.shell.configurables.append(self)
开发者ID:uwescience,项目名称:myria-python,代码行数:12,代码来源:extension.py

示例6: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
 def __init__(self, shell):
     Configurable.__init__(self, config=shell.config)
     Magics.__init__(self, shell=shell)
     self.shell.configurables.append(self)
     if self.autorestore:
         restore_data(self.shell)
开发者ID:AlfiyaZi,项目名称:ipython,代码行数:8,代码来源:storemagic.py

示例7: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
    def __init__(self, *a, **k):
        Magics.__init__(self, *a, **k)

        self.modules = {}
开发者ID:jaredly,项目名称:itreed,代码行数:6,代码来源:magic.py

示例8: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
 def __init__(self, robot_shell):
     Magics.__init__(self, robot_shell.shell)
     self.robot_shell = robot_shell
开发者ID:userzimmermann,项目名称:robotframework-tools,代码行数:5,代码来源:__init__.py

示例9: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
 def __init__(self, shell=None):
     Magics.__init__(self, shell)
     Configurable.__init__(self, config=shell.config)
开发者ID:jfear,项目名称:ipycache,代码行数:5,代码来源:ipycache.py

示例10: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
 def __init__(self, shell):
     Configurable.__init__(self, config=shell.config)
     Magics.__init__(self, shell=shell)
     # Add ourself to the list of module configurable via %config
     self.shell.configurables.append(self)
     self._legal_cypher_identifier = re.compile(r'^[A-Za-z0-9#_$]+')
开发者ID:robcast,项目名称:ipython-cypher,代码行数:8,代码来源:magic.py

示例11: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
 def __init__(self, shell):
     Magics.__init__(self, shell)
     self.process = None
     self.entities = {}
开发者ID:vitaut,项目名称:iampl,代码行数:6,代码来源:__init__.py

示例12: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
 def __init__(self, shell):
     Magics.__init__(self, shell)
     self.J_sessions = dict()
开发者ID:Synthetica9,项目名称:JMagic,代码行数:5,代码来源:__init__.py

示例13: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
 def __init__(self, shell=None):
     Configurable.__init__(self, config=shell.config)
     self._generate_script_magics()
     Magics.__init__(self, shell=shell)
     self.job_manager = BackgroundJobManager()
开发者ID:kbrooks,项目名称:ipython,代码行数:7,代码来源:script.py

示例14: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
 def __init__(self, shell):
     Configurable.__init__(self, parent=shell)
     Magics.__init__(self, shell)
     # this adds me to the `%config` list:
     shell.configurables.append(self)
开发者ID:Mondego,项目名称:pyreco,代码行数:7,代码来源:allPythonContent.py

示例15: __init__

# 需要导入模块: from IPython.core.magic import Magics [as 别名]
# 或者: from IPython.core.magic.Magics import __init__ [as 别名]
 def __init__(self, shell):
     Configurable.__init__(self, config=shell.config)
     Magics.__init__(self, shell=shell)
     self.shell.configurables.append(self)
开发者ID:Bloodevil,项目名称:ipython_mongo,代码行数:6,代码来源:imongo.py


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