Skip to main content

IPython file upload widget

Project description

Latest Version Downloads

An IPython notebook widget to upload files, using FileReader.


Install using pip:

pip install -U fileupload


import io
from IPython.display import display
import fileupload

# Install Javascript

def _upload():

    _upload_widget = fileupload.FileUploadWidget()

    def _cb(change):
        decoded = io.StringIO(change['owner'].data.decode('utf-8'))
        filename = change['owner'].filename
        print('Uploaded `{}` ({:.2f} kB)'.format(
            filename, len( / 2 **10))

    _upload_widget.observe(_cb, names='data')


Base64 data is synced to the data_base64 member, decoded data can be obtained from data. The name of the uploaded file is stored in filename.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Built Distribution

fileupload-0.1.1-py2.py3-none-any.whl (4.1 kB view hashes)

Uploaded py2 py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page