0.0.191
This commit is contained in:
parent
0500442f42
commit
ca2fd59f2b
@ -1,4 +1,4 @@
|
|||||||
# API Reference shows all functions in Guan package. The current version is guan-0.0.190, updated on December 09, 2023.
|
# API Reference shows all functions in Guan package. The current version is guan-0.0.191, updated on December 12, 2023.
|
||||||
|
|
||||||
import guan
|
import guan
|
||||||
|
|
||||||
@ -818,6 +818,9 @@ degenerate_k_array, degenerate_eigenvalue_array = guan.find_degenerate_points(k_
|
|||||||
# 选取一个种子生成固定的随机整数
|
# 选取一个种子生成固定的随机整数
|
||||||
rand_num = guan.generate_random_int_number_for_a_specific_seed(seed=0, x_min=0, x_max=10)
|
rand_num = guan.generate_random_int_number_for_a_specific_seed(seed=0, x_min=0, x_max=10)
|
||||||
|
|
||||||
|
# 统计中英文文本的字数
|
||||||
|
num_words = guan.count_words(text)
|
||||||
|
|
||||||
# 统计运行的日期和时间,写进文件
|
# 统计运行的日期和时间,写进文件
|
||||||
guan.statistics_with_day_and_time(content='', filename='a', file_format='.txt')
|
guan.statistics_with_day_and_time(content='', filename='a', file_format='.txt')
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
[metadata]
|
[metadata]
|
||||||
# replace with your username:
|
# replace with your username:
|
||||||
name = guan
|
name = guan
|
||||||
version = 0.0.190
|
version = 0.0.191
|
||||||
author = guanjihuan
|
author = guanjihuan
|
||||||
author_email = guanjihuan@163.com
|
author_email = guanjihuan@163.com
|
||||||
description = An open source python package
|
description = An open source python package
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
Metadata-Version: 2.1
|
Metadata-Version: 2.1
|
||||||
Name: guan
|
Name: guan
|
||||||
Version: 0.0.190
|
Version: 0.0.191
|
||||||
Summary: An open source python package
|
Summary: An open source python package
|
||||||
Home-page: https://py.guanjihuan.com
|
Home-page: https://py.guanjihuan.com
|
||||||
Author: guanjihuan
|
Author: guanjihuan
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
# Guan is an open-source python package developed and maintained by https://www.guanjihuan.com/about (Ji-Huan Guan, 关济寰). The primary location of this package is on website https://py.guanjihuan.com. GitHub link: https://github.com/guanjihuan/py.guanjihuan.com.
|
# Guan is an open-source python package developed and maintained by https://www.guanjihuan.com/about (Ji-Huan Guan, 关济寰). The primary location of this package is on website https://py.guanjihuan.com. GitHub link: https://github.com/guanjihuan/py.guanjihuan.com.
|
||||||
|
|
||||||
# The current version is guan-0.0.190, updated on December 09, 2023.
|
# The current version is guan-0.0.191, updated on December 12, 2023.
|
||||||
|
|
||||||
# Installation: pip install --upgrade guan
|
# Installation: pip install --upgrade guan
|
||||||
|
|
||||||
@ -3576,6 +3576,13 @@ def generate_random_int_number_for_a_specific_seed(seed=0, x_min=0, x_max=10):
|
|||||||
rand_num = np.random.randint(x_min, x_max) # 左闭右开[x_min, x_max)
|
rand_num = np.random.randint(x_min, x_max) # 左闭右开[x_min, x_max)
|
||||||
return rand_num
|
return rand_num
|
||||||
|
|
||||||
|
# 统计中英文文本的字数
|
||||||
|
def count_words(text):
|
||||||
|
import jieba
|
||||||
|
words = jieba.lcut(text)
|
||||||
|
num_words = len(words)
|
||||||
|
return num_words
|
||||||
|
|
||||||
# 统计运行的日期和时间,写进文件
|
# 统计运行的日期和时间,写进文件
|
||||||
def statistics_with_day_and_time(content='', filename='a', file_format='.txt'):
|
def statistics_with_day_and_time(content='', filename='a', file_format='.txt'):
|
||||||
import datetime
|
import datetime
|
||||||
|
Loading…
x
Reference in New Issue
Block a user