Skip to main content

easy-use tool for record running time

Project description

TimeNotes Readme

an easy-use tool for time researching

安装

pip install timenotes

引用

import timenotes

声明一个笔记本

timenote = timenotes.Timenote(words=None, intimeshow=False)

words参数为自定义输出形式,不填时默认为"阶段[{}]:{}时间花费 {} 秒"

例如,需要输入这种形式的字符串:words="区块{}:{}时间 {} 喵"

intimeshow参数为True时,每结束一个时间段的记录(具体为end)就会自动输出

为False时,不输出,需要在结尾专门输出,同时这种输出可以保持格式的对齐

默认为False

使用

timenote.start("示例一")
......
timenote.note("示例二")
......
timenote.pause()
......
timenote.start()
......
timenote.end()
......
timenote.show()
timenote.sleep(1)

timenote.start()可以输入一个字符串类型的参数并作为这个阶段的名称

如果无输入参数则自动以当前阶段的序数为名称

timenote.end()用于结束一个阶段的记录

timenote.note()和同时执行end和start的效果相同

timenote.show()用于输出记录,这里建议名字长度不同时使用纯中文`

timenote.sleep()用于使程序休眠一定时间,单位为秒

Project details


Release history Release notifications | RSS feed

This version

1.0

Download files

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

Source Distribution

timenotes-1.0.tar.gz (2.8 kB view details)

Uploaded Source

Built Distribution

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

timenotes-1.0-py3-none-any.whl (3.5 kB view details)

Uploaded Python 3

File details

Details for the file timenotes-1.0.tar.gz.

File metadata

  • Download URL: timenotes-1.0.tar.gz
  • Upload date:
  • Size: 2.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.8.1

File hashes

Hashes for timenotes-1.0.tar.gz
Algorithm Hash digest
SHA256 0557a289367874c710c342aca84d512b9bcdc3b77ada44cd9a7ef5b36aaa27c2
MD5 bd5e9882d0e7afe9a464823e403d9e88
BLAKE2b-256 305f9bb43d06bb32f9d399fbd0782c13589b883a8f7c6b3cbba5c4b917d63c84

See more details on using hashes here.

File details

Details for the file timenotes-1.0-py3-none-any.whl.

File metadata

  • Download URL: timenotes-1.0-py3-none-any.whl
  • Upload date:
  • Size: 3.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.8.1

File hashes

Hashes for timenotes-1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e873c67753957e3d2b872650f5607197af5fbd0be01fc11d96948bf995e43f96
MD5 5c5f0a5a85b52fa4ca390934a1e24c5e
BLAKE2b-256 253612696322ea6c65a8f0e33b083bc926b790f63556f6571c2154377eba6278

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