Skip to main content

Manage your variable in jupyter

Project description

var-io模块介绍

v0.2.8

var-io是希望在使用jupyter环境时更方便的查看并管理变量

Manage your variable in jupyter

安装

pip install var-io

功能

  1. 跟踪并查看变量
  2. 保存或载入变量
  3. 删除已有变量
  4. 更多功能...

工作模式

filter:默认跟踪所有变量

choose:默认不跟踪变量

参数解释

method:工作方式,filter或choose

strict:是否跟踪模块或callable的变量

exclude_unsupported:是否屏蔽不支持的变量类型

示例

filter模式

from var_io import VarHome
vh = VarHome(method = 'filter')    #filter模式初始化

vh.vars()         #查看当前追踪的变量

a = {"a":3,'b':4}           #创建测试变量
b = np.random.randn(200,20)
c = pd.Series([1,2,3])

vh.vars()         #查看变量
is_supported type size memory usage
a TRUE dict 2 240
b TRUE numpy.ndarray (200, 20) 32112
c TRUE Series (3,) 128

choose模式

from var_io import VarHome
vh = VarHome(method = 'choose')    #filter模式初始化

vh.vars()         #查看当前追踪的变量

a = {"a":3,'b':4}           #创建测试变量
b = np.random.randn(200,20)
c = pd.Series([1,2,3])
vh.vars()     #当前没有跟踪的变量

变量管理

vh.save_data('./test.ipynbdata')    #保存目前跟踪的变量
vh.load_data('./test.ipynbdata')    #将保存的变量加载到当前命名空间中
vh.del_var('a')           #将变量a从当前命名空间中删除
vh.reset_all()                #重置
vh.clear_list()           #清空当前跟踪的变量列表,只跟踪之后定义的变量
vh.choose_var('a')        #跟踪变量a
vh.exclude_var('a')       #屏蔽变量a

Project details


Download files

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

Source Distribution

var-io-0.2.8.tar.gz (8.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

var_io-0.2.8-py3-none-any.whl (9.8 kB view details)

Uploaded Python 3

File details

Details for the file var-io-0.2.8.tar.gz.

File metadata

  • Download URL: var-io-0.2.8.tar.gz
  • Upload date:
  • Size: 8.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.2.0.post20200210 requests-toolbelt/0.9.1 tqdm/4.42.1 CPython/3.7.6

File hashes

Hashes for var-io-0.2.8.tar.gz
Algorithm Hash digest
SHA256 64e2a5124ebec25f9a14ea55da2848b6809ca15e1e6eff0c37b9b6eb0e7039aa
MD5 b4411e9041f51ecdcbd33859f6f8d6c2
BLAKE2b-256 28c23f613defcb24c5f10acf8cb693f9c6e4441ad6069616b96c4a5a9163f206

See more details on using hashes here.

File details

Details for the file var_io-0.2.8-py3-none-any.whl.

File metadata

  • Download URL: var_io-0.2.8-py3-none-any.whl
  • Upload date:
  • Size: 9.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.2.0.post20200210 requests-toolbelt/0.9.1 tqdm/4.42.1 CPython/3.7.6

File hashes

Hashes for var_io-0.2.8-py3-none-any.whl
Algorithm Hash digest
SHA256 137b38e5a946eb8e74bac6de4a2e1783b685172cfcde4fbedbf1da604f3480e0
MD5 f971cca35850ca5c01da6bd3968eec2c
BLAKE2b-256 2e0c9d276f947d4a03324a2004bb00b521cc558b6e5a89368801ad820a206d9c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page