module ipythonhelper.magic_scratch

Inheritance diagram of code_beatrix.ipythonhelper.magic_scratch

Short summary

module code_beatrix.ipythonhelper.magic_scratch

Magic command to handle files

source on GitHub

Classes

class

truncated documentation

MagicScratch

Defines magic commands to list the content of a folder

Functions

function

truncated documentation

register_scratch_magics

register magics function, can be called from a notebook

Properties

property

truncated documentation

Context

return the context or None

cross_validation_lock

A contextmanager for running a block with our cross validation lock set to True. At the end of the block, …

Static Methods

staticmethod

truncated documentation

snap_parser

defines the way to parse the magic command %snap

Methods

method

truncated documentation

snap

Defines %snap which inserts a snap window inside a notebook.

Documentation

Magic command to handle files

source on GitHub

class code_beatrix.ipythonhelper.magic_scratch.MagicScratch(**kwargs: Any)

Bases : MagicClassWithHelpers

Defines magic commands to list the content of a folder

Nouveau dans la version 1.1.

source on GitHub

Create a configurable given a config config.

Parameters

configConfig

If this is empty, default values are used. If config is a Config instance, it will be used to configure the instance.

parentConfigurable instance, optional

The parent Configurable instance of this object.

Notes

Subclasses of Configurable must call the __init__() method of Configurable before doing anything else and using super():

class MyConfigurable(Configurable):
    def __init__(self, config=None):
        super(MyConfigurable, self).__init__(config=config)
        # Then any other code you need to finish initialization.

This ensures that instances will be configured properly.

_all_trait_default_generators: Dict[str, Any] = {'config': <bound method TraitType.default of <traitlets.traitlets.Instance object>>, 'parent': <bound method TraitType.default of <traitlets.traitlets.Instance object>>}
_cross_validation_lock: bool
_descriptors = [<traitlets.traitlets.ObserveHandler object>, <traitlets.traitlets.Instance object>, <traitlets.traitlets.Instance object>]
_instance_inits = [<bound method ObserveHandler.instance_init of <traitlets.traitlets.ObserveHandler object>>, <bound method Instance.instance_init of <traitlets.traitlets.Instance object>>, <bound method Instance.instance_init of <traitlets.traitlets.Instance object>>]
_static_immutable_initial_values: Dict[str, Any] = {'parent': None}
_trait_default_generators = {}
_trait_notifiers: Dict[str, Any]
_trait_validators: Dict[str, Any]
_trait_values: Dict[str, Any]
_traits: Dict[str, Any] = {'config': <traitlets.traitlets.Instance object>, 'parent': <traitlets.traitlets.Instance object>}
snap(line)

Defines %snap which inserts a snap window inside a notebook.

source on GitHub

static snap_parser()

defines the way to parse the magic command %snap

source on GitHub

code_beatrix.ipythonhelper.magic_scratch.register_scratch_magics(ip)

register magics function, can be called from a notebook

Paramètres:

ip – ip

source on GitHub