How to use nbdev - 5 common examples

To help you get started, we’ve selected a few nbdev examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github fastai / fast_template / _action_files / nb2post.py View on Github external
# Modify the naming process such that destination files get named properly for Jekyll _posts
def _nb2htmlfname(nb_path, dest=None): 
    fname = rename_for_jekyll(nb_path)
    if dest is None: dest = Config().doc_path
    return Path(dest)/fname


for original, new in warnings:
    print(f'{original} has been renamed to {new} to be complaint with Jekyll naming conventions.\n')

# TODO: Open a GitHub Issue When there are any warnings
    
## apply monkey patch
export2html._nb2htmlfname = _nb2htmlfname

export2html.notebook2html(fname='_notebooks/*.ipynb', dest='_posts/')
github fastai / fast_template / _action_files / nb2post.py View on Github external
# Modify the naming process such that destination files get named properly for Jekyll _posts
def _nb2htmlfname(nb_path, dest=None): 
    fname = rename_for_jekyll(nb_path)
    if dest is None: dest = Config().doc_path
    return Path(dest)/fname


for original, new in warnings:
    print(f'{original} has been renamed to {new} to be complaint with Jekyll naming conventions.\n')

# TODO: Open a GitHub Issue When there are any warnings
    
## apply monkey patch
export2html._nb2htmlfname = _nb2htmlfname

export2html.notebook2html(fname='_notebooks/*.ipynb', dest='_posts/')
github asvcode / Vision_UI / vision_ui2.py View on Github external
import psutil
    import torchvision
    try:
        import fastai2; fastver = fastai2.__version__
    except ImportError:
        fastver = 'fastai not found'
    try:
        import fastprogress; fastprog = fastprogress.__version__
    except ImportError:
        fastprog = 'fastprogress not found'
    try:
        import fastpages; fastp = fastpages.__version__
    except ImportError:
        fastp = 'fastpages not found'
    try:
        import nbdev; nbd = nbdev.__version__
    except ImportError:
        nbd = 'nbdev not found'

    print (BOLD +  RED + '>> Vision_UI Update: 03/17/2020')
    style = {'description_width': 'initial'}

    button = widgets.Button(description='System', button_style='success')
    ex_button = widgets.Button(description='Explore', button_style='success')
    display(button)

    out = widgets.Output()
    display(out)

    def on_button_clicked_info(b):
        with out:
            clear_output()
github fastai / fast_template / _action_files / nb2post.py View on Github external
def _nb2htmlfname(nb_path, dest=None): 
    fname = rename_for_jekyll(nb_path)
    if dest is None: dest = Config().doc_path
    return Path(dest)/fname
github fastai / fast_template / _action_files / nb2post.py View on Github external
def _nb2htmlfname(nb_path, dest=None): 
    fname = rename_for_jekyll(nb_path)
    if dest is None: dest = Config().doc_path
    return Path(dest)/fname

nbdev

Create delightful software with Jupyter Notebooks

Apache-2.0
Latest version published 18 days ago

Package Health Score

81 / 100
Full package analysis

Similar packages