ilds 2.2.0__tar.gz → 2.2.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (37) hide show
  1. {ilds-2.2.0 → ilds-2.2.2}/PKG-INFO +1 -1
  2. {ilds-2.2.0 → ilds-2.2.2}/ilds/excel_xlsx.py +3 -3
  3. {ilds-2.2.0 → ilds-2.2.2}/ilds/pd.py +14 -2
  4. {ilds-2.2.0 → ilds-2.2.2}/ilds/versions.py +1 -1
  5. {ilds-2.2.0 → ilds-2.2.2}/ilds.egg-info/PKG-INFO +1 -1
  6. {ilds-2.2.0 → ilds-2.2.2}/README.rst +0 -0
  7. {ilds-2.2.0 → ilds-2.2.2}/ilds/__init__.py +0 -0
  8. {ilds-2.2.0 → ilds-2.2.2}/ilds/cmd.py +0 -0
  9. {ilds-2.2.0 → ilds-2.2.2}/ilds/django/__init__.py +0 -0
  10. {ilds-2.2.0 → ilds-2.2.2}/ilds/django/admin.py +0 -0
  11. {ilds-2.2.0 → ilds-2.2.2}/ilds/django/import_export.py +0 -0
  12. {ilds-2.2.0 → ilds-2.2.2}/ilds/django/model.py +0 -0
  13. {ilds-2.2.0 → ilds-2.2.2}/ilds/django/user.py +0 -0
  14. {ilds-2.2.0 → ilds-2.2.2}/ilds/django/util.py +0 -0
  15. {ilds-2.2.0 → ilds-2.2.2}/ilds/everything.py +0 -0
  16. {ilds-2.2.0 → ilds-2.2.2}/ilds/excel_xlrd.py +0 -0
  17. {ilds-2.2.0 → ilds-2.2.2}/ilds/file.py +0 -0
  18. {ilds-2.2.0 → ilds-2.2.2}/ilds/lib/__init__.py +0 -0
  19. {ilds-2.2.0 → ilds-2.2.2}/ilds/lib/browsercookie.py +0 -0
  20. {ilds-2.2.0 → ilds-2.2.2}/ilds/lib/configobj/__init__.py +0 -0
  21. {ilds-2.2.0 → ilds-2.2.2}/ilds/lib/configobj/_version.py +0 -0
  22. {ilds-2.2.0 → ilds-2.2.2}/ilds/lib/configobj/validate.py +0 -0
  23. {ilds-2.2.0 → ilds-2.2.2}/ilds/lib/hexdump.py +0 -0
  24. {ilds-2.2.0 → ilds-2.2.2}/ilds/match_data.py +0 -0
  25. {ilds-2.2.0 → ilds-2.2.2}/ilds/md.py +0 -0
  26. {ilds-2.2.0 → ilds-2.2.2}/ilds/md5summer.py +0 -0
  27. {ilds-2.2.0 → ilds-2.2.2}/ilds/mycsv.py +0 -0
  28. {ilds-2.2.0 → ilds-2.2.2}/ilds/net.py +0 -0
  29. {ilds-2.2.0 → ilds-2.2.2}/ilds/spider.py +0 -0
  30. {ilds-2.2.0 → ilds-2.2.2}/ilds/time.py +0 -0
  31. {ilds-2.2.0 → ilds-2.2.2}/ilds/util.py +0 -0
  32. {ilds-2.2.0 → ilds-2.2.2}/ilds.egg-info/SOURCES.txt +0 -0
  33. {ilds-2.2.0 → ilds-2.2.2}/ilds.egg-info/dependency_links.txt +0 -0
  34. {ilds-2.2.0 → ilds-2.2.2}/ilds.egg-info/requires.txt +0 -0
  35. {ilds-2.2.0 → ilds-2.2.2}/ilds.egg-info/top_level.txt +0 -0
  36. {ilds-2.2.0 → ilds-2.2.2}/setup.cfg +0 -0
  37. {ilds-2.2.0 → ilds-2.2.2}/setup.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 1.1
2
2
  Name: ilds
3
- Version: 2.2.0
3
+ Version: 2.2.2
4
4
  Summary: 常用模块的集合,为了多平台,多电脑调用方便!
5
5
  Home-page: https://github.com/ldsxp/ilds
6
6
  Author: lds
@@ -2,9 +2,9 @@
2
2
  #
3
3
  # ---------------------------------------
4
4
  # 程序:excel_xlsx.py
5
- # 版本:0.5
5
+ # 版本:0.6
6
6
  # 作者:lds
7
- # 日期:2023-05-16
7
+ # 日期:2024-08-29
8
8
  # 语言:Python 3.X
9
9
  # 说明:读取excel文件内容
10
10
  # ---------------------------------------
@@ -310,7 +310,7 @@ def save_dir_excel_specified_rows(file_dir, dst_dir=None, num_rows=10):
310
310
  dst_dir.mkdir()
311
311
 
312
312
  for file in get_dir_files(file_dir, ext='.xlsx'):
313
- save_excel_specified_rows(input_file=file, output_file=dst_dir / f'测试 {os.path.basename(file)}', start_row=1, end_row=num_rows + 1)
313
+ save_excel_specified_rows(input_file=file, output_file=dst_dir / f'{os.path.basename(file)} {num_rows}行.xlsx', start_row=1, end_row=num_rows + 1)
314
314
 
315
315
 
316
316
  def doc():
@@ -2,9 +2,9 @@
2
2
  #
3
3
  # ---------------------------------------
4
4
  # 程序:pd.py
5
- # 版本:0.8
5
+ # 版本:0.9
6
6
  # 作者:lds
7
- # 日期:2024-08-21
7
+ # 日期:2024-09-12
8
8
  # 语言:Python 3.X
9
9
  # 说明:pandas 常用的函数集合,TODO 添加一些小抄在这里!
10
10
  # ---------------------------------------
@@ -273,6 +273,18 @@ def writer_excel(obj, path, index=False, use_zip64=False):
273
273
  writer.book.use_zip64()
274
274
 
275
275
 
276
+ def to_parquet(df, save_file):
277
+ """
278
+ 保存为parquet数据函数,是为了记录使用方法
279
+ """
280
+ # https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.read_parquet.html
281
+ # https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.to_parquet.html
282
+ # 我们可以保存pyarrow数据,读取文件以后保存到当前文件夹的_d_文件夹中
283
+ # df = pd.read_excel(file, dtype_backend='pyarrow')
284
+ df.to_parquet(save_file)
285
+ # restored_df = pd.read_parquet('data.parquet')
286
+
287
+
276
288
  def add_sorted_sequence_number(df, sort_column, ascending=False, sort_name='排序序号'):
277
289
  """
278
290
  根据指定列的值生成排序序号,并将序号合并回原始DataFrame中
@@ -1,4 +1,4 @@
1
- version = '2.2.0'
1
+ version = '2.2.2'
2
2
 
3
3
  # 因为日期格式问题,所以下面的版本号不能使用
4
4
  # 主版本号 (Major Version): 较大的功能变化或结构调整
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 1.1
2
2
  Name: ilds
3
- Version: 2.2.0
3
+ Version: 2.2.2
4
4
  Summary: 常用模块的集合,为了多平台,多电脑调用方便!
5
5
  Home-page: https://github.com/ldsxp/ilds
6
6
  Author: lds
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes