从Jupyter服务器下载数据 [英] Download data from a jupyter server

查看:264
本文介绍了从Jupyter服务器下载数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在通过连接到服务器
来使用ipython笔记本,我不知道如何以编程方式将事物(例如数据框,.csv文件...)下载到本地计算机。因为我无法具体声明像C:// user //这样的路径,所以它将下载到他们的计算机上而不是我的

I'm using ipython notebook by connecting to a server I don't know how to download a thing (data frame, .csv file,... for example) programatically to my local computer. Because I can't specific declare the path like C://user//... It will be downloaded to their machine not mine

推荐答案

在其中一本笔记本的单独单元中运行它:

Run this in separate cell in one of the notebooks:

!tar cvfz zipname.tar.gz *

要覆盖树上更多的文件夹,请在目录的每一步之前在*之前写上../。 / p>

To cover more folders up the tree, write ../ before the * for every step up the directory.

tar cvfz zipname.tar.gz ../../*

zipname.tar.gz文件将与笔记本保存在同一文件夹中。

The file zipname.tar.gz will be saved in the same folder as your notebook.

如果文件太大,请在同一笔记本块中执行以下操作

Also if files size is too large execute the following in same notebook block

!split -b 200m allfiles.tar.gz allfiles.tar.gz.part

或者,您可以使用此扩展名 https://github.com/data-8/nbzip

Alternatively you can use this extension https://github.com/data-8/nbzip

这篇关于从Jupyter服务器下载数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆