FaustDerLegende commited on
Commit
e2cff35
·
verified ·
1 Parent(s): 404e61f

Upload folder using huggingface_hub (part 36)

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. .gitattributes +20 -0
  2. .venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/INSTALLER +1 -0
  3. .venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/METADATA +1600 -0
  4. .venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/RECORD +73 -0
  5. .venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/REQUESTED +0 -0
  6. .venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/WHEEL +5 -0
  7. .venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/entry_points.txt +2 -0
  8. .venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/licenses/LICENCE +49 -0
  9. .venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/top_level.txt +1 -0
  10. .venv/lib/python3.12/site-packages/tqdm/auto.py +40 -0
  11. .venv/lib/python3.12/site-packages/tqdm/autonotebook.py +38 -0
  12. .venv/lib/python3.12/site-packages/tqdm/cli.py +324 -0
  13. .venv/lib/python3.12/site-packages/tqdm/completion.sh +19 -0
  14. .venv/lib/python3.12/site-packages/tqdm/contrib/__init__.py +91 -0
  15. .venv/lib/python3.12/site-packages/tqdm/contrib/bells.py +28 -0
  16. .venv/lib/python3.12/site-packages/tqdm/contrib/concurrent.py +259 -0
  17. .venv/lib/python3.12/site-packages/tqdm/contrib/discord.py +155 -0
  18. .venv/lib/python3.12/site-packages/tqdm/contrib/itertools.py +92 -0
  19. .venv/lib/python3.12/site-packages/tqdm/contrib/logging.py +128 -0
  20. .venv/lib/python3.12/site-packages/tqdm/contrib/slack.py +119 -0
  21. .venv/lib/python3.12/site-packages/tqdm/contrib/telegram.py +152 -0
  22. .venv/lib/python3.12/site-packages/tqdm/contrib/utils_worker.py +38 -0
  23. .venv/lib/python3.12/site-packages/tqdm/dask.py +44 -0
  24. .venv/lib/python3.12/site-packages/tqdm/gui.py +179 -0
  25. .venv/lib/python3.12/site-packages/tqdm/keras.py +123 -0
  26. .venv/lib/python3.12/site-packages/tqdm/notebook.py +317 -0
  27. .venv/lib/python3.12/site-packages/tqdm/rich.py +154 -0
  28. .venv/lib/python3.12/site-packages/tqdm/std.py +1532 -0
  29. .venv/lib/python3.12/site-packages/tqdm/tk.py +196 -0
  30. .venv/lib/python3.12/site-packages/tqdm/tqdm.1 +241 -0
  31. .venv/lib/python3.12/site-packages/tqdm/utils.py +328 -0
  32. .venv/lib/python3.12/site-packages/tqdm/version.py +7 -0
  33. .venv/lib/python3.12/site-packages/typing_extensions-4.16.0.dist-info/INSTALLER +1 -0
  34. .venv/lib/python3.12/site-packages/typing_extensions-4.16.0.dist-info/METADATA +73 -0
  35. .venv/lib/python3.12/site-packages/typing_extensions-4.16.0.dist-info/RECORD +7 -0
  36. .venv/lib/python3.12/site-packages/typing_extensions-4.16.0.dist-info/WHEEL +4 -0
  37. .venv/lib/python3.12/site-packages/typing_extensions-4.16.0.dist-info/licenses/LICENSE +279 -0
  38. .venv/lib/python3.12/site-packages/typing_extensions.py +0 -0
  39. .venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/INSTALLER +1 -0
  40. .venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/METADATA +432 -0
  41. .venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/RECORD +624 -0
  42. .venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/REQUESTED +0 -0
  43. .venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/WHEEL +5 -0
  44. .venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/entry_points.txt +3 -0
  45. .venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/licenses/LICENSE +661 -0
  46. .venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/top_level.txt +1 -0
  47. .venv/lib/python3.12/site-packages/ultralytics/__init__.py +56 -0
  48. .venv/lib/python3.12/site-packages/ultralytics/__pycache__/__init__.cpython-312.pyc +0 -0
  49. .venv/lib/python3.12/site-packages/ultralytics/assets/bus.jpg +3 -0
  50. .venv/lib/python3.12/site-packages/ultralytics/assets/zidane.jpg +3 -0
.gitattributes CHANGED
@@ -736,3 +736,23 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
736
  .venv/lib/python3.12/site-packages/torchvision.libs/libpng16.fdd68bd0.so.16 filter=lfs diff=lfs merge=lfs -text
737
  .venv/lib/python3.12/site-packages/torchvision.libs/libwebp.14e109ad.so.7 filter=lfs diff=lfs merge=lfs -text
738
  .venv/lib/python3.12/site-packages/torchvision.libs/libz.1140de3a.so.1 filter=lfs diff=lfs merge=lfs -text
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
736
  .venv/lib/python3.12/site-packages/torchvision.libs/libpng16.fdd68bd0.so.16 filter=lfs diff=lfs merge=lfs -text
737
  .venv/lib/python3.12/site-packages/torchvision.libs/libwebp.14e109ad.so.7 filter=lfs diff=lfs merge=lfs -text
738
  .venv/lib/python3.12/site-packages/torchvision.libs/libz.1140de3a.so.1 filter=lfs diff=lfs merge=lfs -text
739
+ .venv/lib/python3.12/site-packages/ultralytics/data/__pycache__/augment.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
740
+ .venv/lib/python3.12/site-packages/ultralytics/engine/__pycache__/exporter.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
741
+ .venv/lib/python3.12/site-packages/ultralytics/models/sam/__pycache__/predict.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
742
+ .venv/lib/python3.12/site-packages/ultralytics/nn/__pycache__/tasks.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
743
+ .venv/lib/python3.12/site-packages/ultralytics/nn/modules/__pycache__/block.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
744
+ .venv/lib/python3.12/site-packages/ultralytics/nn/modules/__pycache__/head.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
745
+ .venv/lib/python3.12/site-packages/ultralytics/utils/__pycache__/metrics.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
746
+ .venv/lib/python3.12/site-packages/wcwidth/table_grapheme_overrides/__pycache__/_known_058c7585.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
747
+ .venv/lib/python3.12/site-packages/wcwidth/table_grapheme_overrides/__pycache__/_known_336a71a1.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
748
+ .venv/lib/python3.12/site-packages/wcwidth/table_grapheme_overrides/__pycache__/_known_59180a0d.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
749
+ .venv/lib/python3.12/site-packages/wcwidth/table_grapheme_overrides/__pycache__/_known_65c6beb5.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
750
+ .venv/lib/python3.12/site-packages/wcwidth/table_grapheme_overrides/__pycache__/_known_8c2ae14d.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
751
+ .venv/lib/python3.12/site-packages/wcwidth/table_grapheme_overrides/__pycache__/_known_97904ece.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
752
+ .venv/lib/python3.12/site-packages/wcwidth/table_grapheme_overrides/__pycache__/_known_a5880eeb.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
753
+ .venv/lib/python3.12/site-packages/wcwidth/table_grapheme_overrides/__pycache__/_known_b6d33cf4.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
754
+ .venv/lib/python3.12/site-packages/wcwidth/table_grapheme_overrides/__pycache__/_known_c57c295b.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
755
+ .venv/lib/python3.12/site-packages/wcwidth/table_grapheme_overrides/__pycache__/_known_e18ac6a7.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
756
+ .venv/lib/python3.12/site-packages/wcwidth/table_grapheme_overrides/__pycache__/_known_fb5fd79b.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
757
+ .venv/lib/python3.12/site-packages/wcwidth/table_grapheme_overrides/__pycache__/_known_fdc99132.cpython-312.pyc filter=lfs diff=lfs merge=lfs -text
758
+ .venv/lib/python3.12/site-packages/yaml/_yaml.cpython-312-x86_64-linux-gnu.so filter=lfs diff=lfs merge=lfs -text
.venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/INSTALLER ADDED
@@ -0,0 +1 @@
 
 
1
+ pip
.venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/METADATA ADDED
@@ -0,0 +1,1600 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Metadata-Version: 2.4
2
+ Name: tqdm
3
+ Version: 4.70.1
4
+ Summary: Fast, Extensible Progress Meter
5
+ Maintainer-email: tqdm developers <devs@tqdm.ml>
6
+ License: MPL-2.0 AND MIT
7
+ Project-URL: homepage, https://tqdm.github.io
8
+ Project-URL: repository, https://github.com/tqdm/tqdm
9
+ Project-URL: changelog, https://tqdm.github.io/releases
10
+ Project-URL: wiki, https://github.com/tqdm/tqdm/wiki
11
+ Keywords: progressbar,progressmeter,progress,bar,meter,rate,eta,console,terminal,time
12
+ Classifier: Development Status :: 5 - Production/Stable
13
+ Classifier: Environment :: Console
14
+ Classifier: Environment :: MacOS X
15
+ Classifier: Environment :: Other Environment
16
+ Classifier: Environment :: Win32 (MS Windows)
17
+ Classifier: Environment :: X11 Applications
18
+ Classifier: Framework :: IPython
19
+ Classifier: Framework :: Jupyter
20
+ Classifier: Intended Audience :: Developers
21
+ Classifier: Intended Audience :: Education
22
+ Classifier: Intended Audience :: End Users/Desktop
23
+ Classifier: Intended Audience :: Other Audience
24
+ Classifier: Intended Audience :: System Administrators
25
+ Classifier: Operating System :: MacOS
26
+ Classifier: Operating System :: MacOS :: MacOS X
27
+ Classifier: Operating System :: Microsoft
28
+ Classifier: Operating System :: Microsoft :: MS-DOS
29
+ Classifier: Operating System :: Microsoft :: Windows
30
+ Classifier: Operating System :: POSIX
31
+ Classifier: Operating System :: POSIX :: BSD
32
+ Classifier: Operating System :: POSIX :: BSD :: FreeBSD
33
+ Classifier: Operating System :: POSIX :: Linux
34
+ Classifier: Operating System :: POSIX :: SunOS/Solaris
35
+ Classifier: Operating System :: Unix
36
+ Classifier: Programming Language :: Python
37
+ Classifier: Programming Language :: Python :: 3
38
+ Classifier: Programming Language :: Python :: 3.8
39
+ Classifier: Programming Language :: Python :: 3.9
40
+ Classifier: Programming Language :: Python :: 3.10
41
+ Classifier: Programming Language :: Python :: 3.11
42
+ Classifier: Programming Language :: Python :: 3.12
43
+ Classifier: Programming Language :: Python :: 3.13
44
+ Classifier: Programming Language :: Python :: 3.14
45
+ Classifier: Programming Language :: Python :: 3 :: Only
46
+ Classifier: Programming Language :: Python :: Implementation
47
+ Classifier: Programming Language :: Python :: Implementation :: IronPython
48
+ Classifier: Programming Language :: Python :: Implementation :: PyPy
49
+ Classifier: Programming Language :: Unix Shell
50
+ Classifier: Topic :: Desktop Environment
51
+ Classifier: Topic :: Education :: Computer Aided Instruction (CAI)
52
+ Classifier: Topic :: Education :: Testing
53
+ Classifier: Topic :: Office/Business
54
+ Classifier: Topic :: Other/Nonlisted Topic
55
+ Classifier: Topic :: Software Development :: Build Tools
56
+ Classifier: Topic :: Software Development :: Libraries
57
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
58
+ Classifier: Topic :: Software Development :: Pre-processors
59
+ Classifier: Topic :: Software Development :: User Interfaces
60
+ Classifier: Topic :: System :: Installation/Setup
61
+ Classifier: Topic :: System :: Logging
62
+ Classifier: Topic :: System :: Monitoring
63
+ Classifier: Topic :: System :: Shells
64
+ Classifier: Topic :: Terminals
65
+ Classifier: Topic :: Utilities
66
+ Requires-Python: >=3.8
67
+ Description-Content-Type: text/x-rst
68
+ License-File: LICENCE
69
+ Requires-Dist: colorama; platform_system == "Windows"
70
+ Provides-Extra: discord
71
+ Requires-Dist: requests; extra == "discord"
72
+ Requires-Dist: envwrap; extra == "discord"
73
+ Provides-Extra: slack
74
+ Requires-Dist: slack-sdk; extra == "slack"
75
+ Requires-Dist: envwrap; extra == "slack"
76
+ Provides-Extra: telegram
77
+ Requires-Dist: requests; extra == "telegram"
78
+ Requires-Dist: envwrap; extra == "telegram"
79
+ Provides-Extra: notebook
80
+ Requires-Dist: ipywidgets>=6; extra == "notebook"
81
+ Dynamic: license-file
82
+
83
+ |Logo|
84
+
85
+ tqdm
86
+ ====
87
+
88
+ |Py-Versions| |Versions| |Conda-Forge-Status| |Docker| |Snapcraft|
89
+
90
+ |Build-Status| |Coverage-Status| |Branch-Coverage-Status| |Codacy-Grade| |Libraries-Rank| |PyPI-Downloads|
91
+
92
+ |LICENCE| |OpenHub-Status| |colab-demo| |binder-demo| |awesome-python|
93
+
94
+ ``tqdm`` derives from the Arabic word *taqaddum* (تقدّم) which can mean "progress,"
95
+ and is an abbreviation for "I love you so much" in Spanish (*te quiero demasiado*).
96
+
97
+ Instantly make your loops show a smart progress meter - just wrap any
98
+ iterable with ``tqdm(iterable)``, and you're done!
99
+
100
+ .. code:: python
101
+
102
+ from tqdm import tqdm
103
+ for i in tqdm(range(10000)):
104
+ ...
105
+
106
+ ``76%|████████████████████████        | 7568/10000 [00:33<00:10, 229.00it/s]``
107
+
108
+ ``trange(N)`` can also be used as a convenient shortcut for
109
+ ``tqdm(range(N))``.
110
+
111
+ |Screenshot|
112
+ |Video| |Slides| |Merch|
113
+
114
+ It can also be executed as a module with pipes:
115
+
116
+ .. code:: sh
117
+
118
+ $ seq 9999999 | tqdm --bytes | wc -l
119
+ 75.2MB [00:00, 217MB/s]
120
+ 9999999
121
+
122
+ $ tar -zcf - docs/ | tqdm --bytes --total `du -sb docs/ | cut -f1` \
123
+ > backup.tgz
124
+ 32%|██████████▍ | 8.89G/27.9G [00:42<01:31, 223MB/s]
125
+
126
+ Overhead is low -- about 60ns per iteration (80ns with ``tqdm.gui``), and is
127
+ unit tested against performance regression.
128
+ By comparison, the well-established
129
+ `ProgressBar <https://github.com/niltonvolpato/python-progressbar>`__ has
130
+ an 800ns/iter overhead.
131
+
132
+ In addition to its low overhead, ``tqdm`` uses smart algorithms to predict
133
+ the remaining time and to skip unnecessary iteration displays, which allows
134
+ for a negligible overhead in most cases.
135
+
136
+ ``tqdm`` works on any platform
137
+ (Linux, Windows, Mac, FreeBSD, NetBSD, Solaris/SunOS),
138
+ in any console or in a GUI, and is also friendly with IPython/Jupyter notebooks.
139
+
140
+ ``tqdm`` does not require any dependencies (not even ``curses``!), just
141
+ Python and an environment supporting ``carriage return \r`` and
142
+ ``line feed \n`` control characters.
143
+
144
+ **Featured Sponsors**
145
+
146
+ ======== ================================================
147
+ |OpenAI| Your Logo Here
148
+ ======== ================================================
149
+ OpenAI `Sponsors <https://github.com/sponsors/tqdm>`__
150
+ ======== ================================================
151
+
152
+ .. |OpenAI| image:: https://avatars.githubusercontent.com/u/14957082?s=96
153
+ :target: https://openai.com
154
+
155
+ ------------------------------------------
156
+
157
+ .. contents:: Table of contents
158
+ :backlinks: top
159
+ :local:
160
+
161
+
162
+ Installation
163
+ ------------
164
+
165
+ Latest PyPI stable release
166
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~
167
+
168
+ |Versions| |PyPI-Downloads| |Libraries-Dependents|
169
+
170
+ .. code:: sh
171
+
172
+ pip install tqdm
173
+
174
+ Latest development release on GitHub
175
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
176
+
177
+ |GitHub-Status| |GitHub-Stars| |GitHub-Commits| |GitHub-Forks| |GitHub-Updated|
178
+
179
+ Pull and install pre-release ``devel`` branch:
180
+
181
+ .. code:: sh
182
+
183
+ pip install "git+https://github.com/tqdm/tqdm.git@devel#egg=tqdm"
184
+
185
+ Latest Conda release
186
+ ~~~~~~~~~~~~~~~~~~~~
187
+
188
+ |Conda-Forge-Status|
189
+
190
+ .. code:: sh
191
+
192
+ conda install -c conda-forge tqdm
193
+
194
+ Latest Snapcraft release
195
+ ~~~~~~~~~~~~~~~~~~~~~~~~
196
+
197
+ |Snapcraft|
198
+
199
+ There are 3 channels to choose from:
200
+
201
+ .. code:: sh
202
+
203
+ snap install tqdm # implies --stable, i.e. latest tagged release
204
+ snap install tqdm --candidate # master branch
205
+ snap install tqdm --edge # devel branch
206
+
207
+ Note that ``snap`` binaries are purely for CLI use (not ``import``-able), and
208
+ automatically set up ``bash`` tab-completion.
209
+
210
+ Latest Docker release
211
+ ~~~~~~~~~~~~~~~~~~~~~
212
+
213
+ |Docker|
214
+
215
+ .. code:: sh
216
+
217
+ docker pull tqdm/tqdm
218
+ docker run -i --rm tqdm/tqdm --help
219
+
220
+ Other
221
+ ~~~~~
222
+
223
+ There are other (unofficial) places where ``tqdm`` may be downloaded, particularly for CLI use:
224
+
225
+ |Repology|
226
+
227
+ .. |Repology| image:: https://repology.org/badge/tiny-repos/python:tqdm.svg
228
+ :target: https://repology.org/project/python:tqdm/versions
229
+
230
+ Changelog
231
+ ---------
232
+
233
+ The list of all changes is available either on GitHub's Releases:
234
+ |GitHub-Status|, on the
235
+ `wiki <https://github.com/tqdm/tqdm/wiki/Releases>`__, or on the
236
+ `website <https://tqdm.github.io/releases>`__.
237
+
238
+
239
+ Usage
240
+ -----
241
+
242
+ ``tqdm`` is very versatile and can be used in a number of ways.
243
+ The three main ones are given below.
244
+
245
+ Iterable-based
246
+ ~~~~~~~~~~~~~~
247
+
248
+ Wrap ``tqdm()`` around any iterable:
249
+
250
+ .. code:: python
251
+
252
+ from tqdm import tqdm
253
+ from time import sleep
254
+
255
+ text = ""
256
+ for char in tqdm(["a", "b", "c", "d"]):
257
+ sleep(0.25)
258
+ text = text + char
259
+
260
+ ``trange(i)`` is a special optimised instance of ``tqdm(range(i))``:
261
+
262
+ .. code:: python
263
+
264
+ from tqdm import trange
265
+
266
+ for i in trange(100):
267
+ sleep(0.01)
268
+
269
+ Instantiation outside of the loop allows for manual control over ``tqdm()``:
270
+
271
+ .. code:: python
272
+
273
+ pbar = tqdm(["a", "b", "c", "d"])
274
+ for char in pbar:
275
+ sleep(0.25)
276
+ pbar.set_description("Processing %s" % char)
277
+
278
+ Manual
279
+ ~~~~~~
280
+
281
+ Manual control of ``tqdm()`` updates using a ``with`` statement:
282
+
283
+ .. code:: python
284
+
285
+ with tqdm(total=100) as pbar:
286
+ for i in range(10):
287
+ sleep(0.1)
288
+ pbar.update(10)
289
+
290
+ If the optional variable ``total`` (or an iterable with ``len()``) is
291
+ provided, predictive stats are displayed.
292
+
293
+ ``with`` is also optional (you can just assign ``tqdm()`` to a variable,
294
+ but in this case don't forget to ``del`` or ``close()`` at the end:
295
+
296
+ .. code:: python
297
+
298
+ pbar = tqdm(total=100)
299
+ for i in range(10):
300
+ sleep(0.1)
301
+ pbar.update(10)
302
+ pbar.close()
303
+
304
+ Module
305
+ ~~~~~~
306
+
307
+ Perhaps the most wonderful use of ``tqdm`` is in a script or on the command
308
+ line. Simply inserting ``tqdm`` (or ``python -m tqdm``) between pipes will pass
309
+ through all ``stdin`` to ``stdout`` while printing progress to ``stderr``.
310
+
311
+ The example below demonstrate counting the number of lines in all Python files
312
+ in the current directory, with timing information included.
313
+
314
+ .. code:: sh
315
+
316
+ $ time find . -name '*.py' -type f -exec cat \{} \; | wc -l
317
+ 857365
318
+
319
+ real 0m3.458s
320
+ user 0m0.274s
321
+ sys 0m3.325s
322
+
323
+ $ time find . -name '*.py' -type f -exec cat \{} \; | tqdm | wc -l
324
+ 857366it [00:03, 246471.31it/s]
325
+ 857365
326
+
327
+ real 0m3.585s
328
+ user 0m0.862s
329
+ sys 0m3.358s
330
+
331
+ Note that the usual arguments for ``tqdm`` can also be specified.
332
+
333
+ .. code:: sh
334
+
335
+ $ find . -name '*.py' -type f -exec cat \{} \; |
336
+ tqdm --unit loc --unit_scale --total 857366 >> /dev/null
337
+ 100%|█████████████████████████████████| 857K/857K [00:04<00:00, 246Kloc/s]
338
+
339
+ Backing up a large directory?
340
+
341
+ .. code:: sh
342
+
343
+ $ tar -zcf - docs/ | tqdm --bytes --total `du -sb docs/ | cut -f1` \
344
+ > backup.tgz
345
+ 44%|██████████████▊ | 153M/352M [00:14<00:18, 11.0MB/s]
346
+
347
+ This can be beautified further:
348
+
349
+ .. code:: sh
350
+
351
+ $ BYTES=$(du -sb docs/ | cut -f1)
352
+ $ tar -cf - docs/ \
353
+ | tqdm --bytes --total "$BYTES" --desc Processing | gzip \
354
+ | tqdm --bytes --total "$BYTES" --desc Compressed --position 1 \
355
+ > ~/backup.tgz
356
+ Processing: 100%|██████████████████████| 352M/352M [00:14<00:00, 30.2MB/s]
357
+ Compressed: 42%|█████████▎ | 148M/352M [00:14<00:19, 10.9MB/s]
358
+
359
+ Or done on a file level using 7-zip:
360
+
361
+ .. code:: sh
362
+
363
+ $ 7z a -bd -r backup.7z docs/ | grep Compressing \
364
+ | tqdm --total $(find docs/ -type f | wc -l) --unit files \
365
+ | grep -v Compressing
366
+ 100%|██████████████████████████▉| 15327/15327 [01:00<00:00, 712.96files/s]
367
+
368
+ Pre-existing CLI programs already outputting basic progress information will
369
+ benefit from ``tqdm``'s ``--update`` and ``--update_to`` flags:
370
+
371
+ .. code:: sh
372
+
373
+ $ seq 3 0.1 5 | tqdm --total 5 --update_to --null
374
+ 100%|████████████████████████████████████| 5.0/5 [00:00<00:00, 9673.21it/s]
375
+ $ seq 10 | tqdm --update --null # 1 + 2 + ... + 10 = 55 iterations
376
+ 55it [00:00, 90006.52it/s]
377
+
378
+ FAQ and Known Issues
379
+ --------------------
380
+
381
+ |GitHub-Issues|
382
+
383
+ The most common issues relate to excessive output on multiple lines, instead
384
+ of a neat one-line progress bar.
385
+
386
+ - Consoles in general: require support for carriage return (``CR``, ``\r``).
387
+
388
+ * Some cloud logging consoles which don't support ``\r`` properly
389
+ (`cloudwatch <https://github.com/tqdm/tqdm/issues/966>`__,
390
+ `K8s <https://github.com/tqdm/tqdm/issues/1319>`__) may benefit from
391
+ ``export TQDM_POSITION=-1``.
392
+
393
+ - Nested progress bars:
394
+
395
+ * Consoles in general: require support for moving cursors up to the
396
+ previous line. For example,
397
+ `IDLE <https://github.com/tqdm/tqdm/issues/191#issuecomment-230168030>`__,
398
+ `ConEmu <https://github.com/tqdm/tqdm/issues/254>`__ and
399
+ `PyCharm <https://github.com/tqdm/tqdm/issues/203>`__ (also
400
+ `here <https://github.com/tqdm/tqdm/issues/208>`__,
401
+ `here <https://github.com/tqdm/tqdm/issues/307>`__, and
402
+ `here <https://github.com/tqdm/tqdm/issues/454#issuecomment-335416815>`__)
403
+ lack full support.
404
+ * Windows: additionally may require the Python module ``colorama``
405
+ to ensure nested bars stay within their respective lines.
406
+
407
+ - Unicode:
408
+
409
+ * Environments which report that they support unicode will have solid smooth
410
+ progress bars. The fallback is an ``ascii``-only bar.
411
+ * Windows consoles often only partially support unicode and thus
412
+ `often require explicit ascii=True <https://github.com/tqdm/tqdm/issues/454#issuecomment-335416815>`__
413
+ (also `here <https://github.com/tqdm/tqdm/issues/499>`__). This is due to
414
+ either normal-width unicode characters being incorrectly displayed as
415
+ "wide", or some unicode characters not rendering.
416
+
417
+ - Wrapping generators:
418
+
419
+ * Generator wrapper functions tend to hide the length of iterables.
420
+ ``tqdm`` does not.
421
+ * Replace ``tqdm(enumerate(...))`` with ``enumerate(tqdm(...))`` or
422
+ ``tqdm(enumerate(x), total=len(x), ...)``.
423
+ The same applies to ``numpy.ndenumerate``.
424
+ * Replace ``tqdm(zip(a, b))`` with ``zip(tqdm(a), b)`` or even
425
+ ``zip(tqdm(a), tqdm(b))``.
426
+ * The same applies to ``itertools``.
427
+ * Some useful convenience functions can be found under ``tqdm.contrib``.
428
+
429
+ - `No intermediate output in docker-compose <https://github.com/tqdm/tqdm/issues/771>`__:
430
+ use ``docker-compose run`` instead of ``docker-compose up`` and ``tty: true``.
431
+
432
+ - Overriding defaults via environment variables:
433
+ e.g. in CI/cloud jobs, ``export TQDM_MININTERVAL=5`` to avoid log spam.
434
+ This override logic is handled by the ``tqdm.utils.envwrap`` decorator
435
+ (useful independent of ``tqdm``).
436
+
437
+ If you come across any other difficulties, browse and file |GitHub-Issues|.
438
+
439
+ Documentation
440
+ -------------
441
+
442
+ |Py-Versions| |README-Hits| (Since 19 May 2016)
443
+
444
+ .. code:: python
445
+
446
+ class tqdm():
447
+ """
448
+ Decorate an iterable object, returning an iterator which acts exactly
449
+ like the original iterable, but prints a dynamically updating
450
+ progress bar every time a value is requested.
451
+ """
452
+
453
+ @envwrap("tqdm") # override defaults via env vars
454
+ def __init__(self, iterable=None, desc=None, total=None, leave=True,
455
+ file=None, ncols=None, mininterval=0.1,
456
+ maxinterval=10.0, miniters=None, ascii=None, disable=False,
457
+ unit='it', unit_scale=False, dynamic_ncols=False,
458
+ smoothing=0.3, bar_format=None, initial=0, position=None,
459
+ postfix=None, unit_divisor=1000, write_bytes=False,
460
+ lock_args=None, nrows=None, colour=None, delay=0):
461
+
462
+ Parameters
463
+ ~~~~~~~~~~
464
+
465
+ * iterable : iterable, optional
466
+ Iterable to decorate with a progress bar.
467
+ Leave blank to manually manage the updates.
468
+ * desc : str, optional
469
+ Prefix for the progress bar.
470
+ * total : int or float, optional
471
+ The number of expected iterations. If unspecified,
472
+ len(iterable) is used if possible. If float("inf") or as a last
473
+ resort, only basic progress statistics are displayed
474
+ (no ETA, no progress bar).
475
+ If ``gui`` is True and this parameter needs subsequent updating,
476
+ specify an initial arbitrary large positive number,
477
+ e.g. 9e9.
478
+ * leave : bool, optional
479
+ If [default: True], keeps all traces of the progress bar
480
+ upon termination of iteration.
481
+ If ``None``, will leave only if ``position`` is ``0``.
482
+ * file : ``io.TextIOWrapper`` or ``io.StringIO``, optional
483
+ Specifies where to output the progress messages
484
+ (default: sys.stderr). Uses ``file.write(str)`` and ``file.flush()``
485
+ methods. For encoding, see ``write_bytes``.
486
+ * ncols : int, optional
487
+ The width of the entire output message. If specified,
488
+ dynamically resizes the progress bar to stay within this bound.
489
+ If unspecified, attempts to use environment width. The
490
+ fallback is a meter width of 10 and no limit for the counter and
491
+ statistics. If 0, will not print any meter (only stats).
492
+ * mininterval : float, optional
493
+ Minimum progress display update interval [default: 0.1] seconds.
494
+ * maxinterval : float, optional
495
+ Maximum progress display update interval [default: 10] seconds.
496
+ Automatically adjusts ``miniters`` to correspond to ``mininterval``
497
+ after long display update lag. Only works if ``dynamic_miniters``
498
+ or monitor thread is enabled.
499
+ * miniters : int or float, optional
500
+ Minimum progress display update interval, in iterations.
501
+ If 0 and ``dynamic_miniters``, will automatically adjust to equal
502
+ ``mininterval`` (more CPU efficient, good for tight loops).
503
+ If > 0, will skip display of specified number of iterations.
504
+ Tweak this and ``mininterval`` to get very efficient loops.
505
+ If your progress is erratic with both fast and slow iterations
506
+ (network, skipping items, etc) you should set miniters=1.
507
+ * ascii : bool or str, optional
508
+ If unspecified or False, use unicode (smooth blocks) to fill
509
+ the meter. The fallback is to use ASCII characters " 123456789#".
510
+ * disable : bool, optional
511
+ Whether to disable the entire progress bar wrapper
512
+ [default: False]. If set to None, disable on non-TTY.
513
+ * unit : str, optional
514
+ String that will be used to define the unit of each iteration
515
+ [default: it].
516
+ * unit_scale : bool or int or float, optional
517
+ If 1 or True, the number of iterations will be reduced/scaled
518
+ automatically and a metric prefix following the
519
+ International System of Units standard will be added
520
+ (kilo, mega, etc.) [default: False]. If any other non-zero
521
+ number, will scale ``total`` and ``n``.
522
+ * dynamic_ncols : bool, optional
523
+ If set, constantly alters ``ncols`` and ``nrows`` to the
524
+ environment (allowing for window resizes) [default: False].
525
+ * smoothing : float, optional
526
+ Exponential moving average smoothing factor for speed estimates
527
+ (ignored in GUI mode). Ranges from 0 (average speed) to 1
528
+ (current/instantaneous speed) [default: 0.3].
529
+ * bar_format : str, optional
530
+ Specify a custom bar string formatting. May impact performance.
531
+ [default: '{l_bar}{bar}{r_bar}'], where
532
+ l_bar='{desc}: {percentage:3.0f}%|' and
533
+ r_bar='| {n_fmt}/{total_fmt} [{elapsed}<{remaining}, '
534
+ '{rate_fmt}{postfix}]'
535
+ Possible vars: l_bar, bar, r_bar, n, n_fmt, total, total_fmt,
536
+ percentage, elapsed, elapsed_s, ncols, nrows, desc, unit,
537
+ rate, rate_fmt, rate_noinv, rate_noinv_fmt,
538
+ rate_inv, rate_inv_fmt, postfix, unit_divisor,
539
+ remaining, remaining_s, eta.
540
+ Note that a trailing ": " is automatically removed after {desc}
541
+ if the latter is empty.
542
+ * initial : int or float, optional
543
+ The initial counter value. Useful when restarting a progress
544
+ bar [default: 0]. If using float, consider specifying ``{n:.3f}``
545
+ or similar in ``bar_format``, or specifying ``unit_scale``.
546
+ * position : int, optional
547
+ Specify the line offset to print this bar (starting from 0)
548
+ Automatic if unspecified.
549
+ Useful to manage multiple bars at once (eg, from threads).
550
+ * postfix : dict or ``*``, optional
551
+ Specify additional stats to display at the end of the bar.
552
+ Calls ``set_postfix(**postfix)`` if possible (dict).
553
+ * unit_divisor : float, optional
554
+ [default: 1000], ignored unless ``unit_scale`` is True.
555
+ * write_bytes : bool, optional
556
+ Whether to write bytes. If (default: False) will write unicode.
557
+ * lock_args : tuple, optional
558
+ Passed to ``refresh`` for intermediate output
559
+ (initialisation, iterating, and updating).
560
+ * nrows : int, optional
561
+ The screen height. If specified, hides nested bars outside this
562
+ bound. If unspecified, attempts to use environment height.
563
+ The fallback is 20.
564
+ * colour : str, optional
565
+ Bar colour (e.g. 'green', '#00ff00').
566
+ * delay : float, optional
567
+ Don't display until [default: 0] seconds have elapsed.
568
+
569
+ Extra CLI Options
570
+ ~~~~~~~~~~~~~~~~~
571
+
572
+ * delim : chr, optional
573
+ Delimiting character [default: '\n']. Use '\0' for null.
574
+ N.B.: on Windows systems, Python converts '\n' to '\r\n'.
575
+ * buf_size : int, optional
576
+ String buffer size in bytes [default: 256]
577
+ used when ``delim`` is specified.
578
+ * bytes : bool, optional
579
+ If true, will count bytes, ignore ``delim``, and default
580
+ ``unit_scale`` to True, ``unit_divisor`` to 1024, and ``unit`` to 'B'.
581
+ * tee : bool, optional
582
+ If true, passes ``stdin`` to both ``stderr`` and ``stdout``.
583
+ * update : bool, optional
584
+ If true, will treat input as newly elapsed iterations,
585
+ i.e. numbers to pass to ``update()``. Note that this is slow
586
+ (~2e5 it/s) since every input must be decoded as a number.
587
+ * update_to : bool, optional
588
+ If true, will treat input as total elapsed iterations,
589
+ i.e. numbers to assign to ``self.n``. Note that this is slow
590
+ (~2e5 it/s) since every input must be decoded as a number.
591
+ * null : bool, optional
592
+ If true, will discard input (no stdout).
593
+ * manpath : str, optional
594
+ Directory in which to install tqdm man pages.
595
+ * comppath : str, optional
596
+ Directory in which to place tqdm completion.
597
+ * log : str, optional
598
+ CRITICAL|FATAL|ERROR|WARN(ING)|[default: 'INFO']|DEBUG|NOTSET.
599
+
600
+ Returns
601
+ ~~~~~~~
602
+
603
+ * out : decorated iterator.
604
+
605
+ .. code:: python
606
+
607
+ class tqdm():
608
+ def update(self, n=1):
609
+ """
610
+ Manually update the progress bar, useful for streams
611
+ such as reading files.
612
+ E.g.:
613
+ >>> t = tqdm(total=filesize) # Initialise
614
+ >>> for current_buffer in stream:
615
+ ... ...
616
+ ... t.update(len(current_buffer))
617
+ >>> t.close()
618
+ The last line is highly recommended, but possibly not necessary if
619
+ `t.update()` will be called in such a way that `filesize` will be
620
+ exactly reached and printed.
621
+
622
+ Parameters
623
+ ----------
624
+ n : int or float, optional
625
+ Increment to add to the internal counter of iterations
626
+ [default: 1]. If using float, consider specifying `{n:.3f}`
627
+ or similar in `bar_format`, or specifying `unit_scale`.
628
+
629
+ Returns
630
+ -------
631
+ out : bool or None
632
+ True if a `display()` was triggered.
633
+ """
634
+
635
+ def close(self):
636
+ """Cleanup and (if leave=False) close the progress bar."""
637
+
638
+ def clear(self, nomove=False):
639
+ """Clear current bar display."""
640
+
641
+ def refresh(self):
642
+ """
643
+ Force refresh the display of this bar.
644
+
645
+ Parameters
646
+ ----------
647
+ nolock : bool, optional
648
+ If `True`, does not lock.
649
+ If [default: `False`]: calls `acquire()` on internal lock.
650
+ lock_args : tuple, optional
651
+ Passed to internal lock's `acquire()`.
652
+ If specified, will only `display()` if `acquire()` returns `True`.
653
+ """
654
+
655
+ def unpause(self):
656
+ """Restart tqdm timer from last print time."""
657
+
658
+ def reset(self, total=None):
659
+ """
660
+ Resets to 0 iterations for repeated use.
661
+
662
+ Consider combining with `leave=True`.
663
+
664
+ Parameters
665
+ ----------
666
+ total : int or float, optional. Total to use for the new bar.
667
+ """
668
+
669
+ def set_description(self, desc=None, refresh=True):
670
+ """
671
+ Set/modify description of the progress bar.
672
+
673
+ Parameters
674
+ ----------
675
+ desc : str, optional
676
+ refresh : bool, optional
677
+ Forces refresh [default: True].
678
+ """
679
+
680
+ def set_postfix(self, ordered_dict=None, refresh=True, **tqdm_kwargs):
681
+ """
682
+ Set/modify postfix (additional stats)
683
+ with automatic formatting based on datatype.
684
+
685
+ Parameters
686
+ ----------
687
+ ordered_dict : dict or OrderedDict, optional
688
+ refresh : bool, optional
689
+ Forces refresh [default: True].
690
+ kwargs : dict, optional
691
+ """
692
+
693
+ @classmethod
694
+ def write(cls, s, file=sys.stdout, end="\n"):
695
+ """Print a message via tqdm (without overlap with bars)."""
696
+
697
+ @property
698
+ def format_dict(self):
699
+ """Public API for read-only member access."""
700
+
701
+ def display(self, msg=None, pos=None):
702
+ """
703
+ Use `self.sp` to display `msg` in the specified `pos`.
704
+
705
+ Consider overloading this function when inheriting to use e.g.:
706
+ `self.some_frontend(**self.format_dict)` instead of `self.sp`.
707
+
708
+ Parameters
709
+ ----------
710
+ msg : str, optional. What to display (default: `repr(self)`).
711
+ pos : int, optional. Position to `moveto`
712
+ (default: `abs(self.pos)`).
713
+ """
714
+
715
+ @classmethod
716
+ @contextmanager
717
+ def wrapattr(cls, stream, method, total=None, bytes=True, **tqdm_kwargs):
718
+ """
719
+ stream : file-like object.
720
+ method : str, "read" or "write". The result of `read()` and
721
+ the first argument of `write()` should have a `len()`.
722
+
723
+ >>> with tqdm.wrapattr(file_obj, "read", total=file_obj.size) as fobj:
724
+ ... while True:
725
+ ... chunk = fobj.read(chunk_size)
726
+ ... if not chunk:
727
+ ... break
728
+ """
729
+
730
+ @classmethod
731
+ def pandas(cls, *targs, **tqdm_kwargs):
732
+ """Registers the current `tqdm` class with `pandas`."""
733
+
734
+ def trange(*args, **tqdm_kwargs):
735
+ """Shortcut for `tqdm(range(*args), **tqdm_kwargs)`."""
736
+
737
+ Convenience Functions
738
+ ~~~~~~~~~~~~~~~~~~~~~
739
+
740
+ .. code:: python
741
+
742
+ def tqdm.contrib.tenumerate(iterable, start=0, total=None,
743
+ tqdm_class=tqdm.auto.tqdm, **tqdm_kwargs):
744
+ """Equivalent of `numpy.ndenumerate` or builtin `enumerate`."""
745
+
746
+ def tqdm.contrib.tzip(iter1, *iter2plus, **tqdm_kwargs):
747
+ """Equivalent of builtin `zip`."""
748
+
749
+ def tqdm.contrib.tmap(function, *sequences, **tqdm_kwargs):
750
+ """Equivalent of builtin `map`."""
751
+
752
+ Submodules
753
+ ~~~~~~~~~~
754
+
755
+ .. code:: python
756
+
757
+ class tqdm.notebook.tqdm(tqdm.tqdm):
758
+ """IPython/Jupyter Notebook widget."""
759
+
760
+ class tqdm.auto.tqdm(tqdm.tqdm):
761
+ """Automatically chooses between `tqdm.notebook` and `tqdm.tqdm`."""
762
+
763
+ class tqdm.asyncio.tqdm(tqdm.tqdm):
764
+ """Asynchronous version."""
765
+ @classmethod
766
+ def as_completed(cls, fs, *, loop=None, timeout=None, total=None,
767
+ **tqdm_kwargs):
768
+ """Wrapper for `asyncio.as_completed`."""
769
+
770
+ class tqdm.gui.tqdm(tqdm.tqdm):
771
+ """Matplotlib GUI version."""
772
+
773
+ class tqdm.tk.tqdm(tqdm.tqdm):
774
+ """Tkinter GUI version."""
775
+
776
+ class tqdm.rich.tqdm(tqdm.tqdm):
777
+ """`rich.progress` version."""
778
+
779
+ class tqdm.keras.TqdmCallback(keras.callbacks.Callback):
780
+ """Keras callback for epoch and batch progress."""
781
+
782
+ class tqdm.dask.TqdmCallback(dask.callbacks.Callback):
783
+ """Dask callback for task progress."""
784
+
785
+
786
+ ``contrib``
787
+ +++++++++++
788
+
789
+ The ``tqdm.contrib`` package also contains experimental modules:
790
+
791
+ - `tqdm.contrib.itertools <https://tqdm.github.io/docs/contrib.itertools/>`_: Thin wrappers around ``itertools``
792
+ - `tqdm.contrib.concurrent <https://tqdm.github.io/docs/contrib.concurrent/>`_: Thin wrappers around ``concurrent.futures``
793
+ - `tqdm.contrib.slack <https://tqdm.github.io/docs/contrib.slack/>`_: Posts to `Slack <https://slack.com>`__ bots
794
+ - `tqdm.contrib.discord <https://tqdm.github.io/docs/contrib.discord/>`_: Posts to `Discord <https://discord.com>`__ bots
795
+ - `tqdm.contrib.telegram <https://tqdm.github.io/docs/contrib.telegram/>`_: Posts to `Telegram <https://telegram.org>`__ bots
796
+ - `tqdm.contrib.bells <https://tqdm.github.io/docs/shortcuts/>`_: Automagically enables all optional features
797
+
798
+ * ``auto``, ``pandas``, ``slack``, ``discord``, ``telegram``
799
+
800
+ .. image:: https://tqdm.github.io/img/screenshot-discord.png
801
+ :alt: Screenshot of `tqdm.contrib.discord` in action
802
+
803
+ Examples and Advanced Usage
804
+ ---------------------------
805
+
806
+ - See the `examples <https://github.com/tqdm/tqdm/tree/master/examples>`__
807
+ folder;
808
+ - import the module and run ``help()``;
809
+ - consult the `wiki <https://github.com/tqdm/tqdm/wiki>`__;
810
+
811
+ * this has an
812
+ `excellent article <https://github.com/tqdm/tqdm/wiki/How-to-make-a-great-Progress-Bar>`__
813
+ on how to make a **great** progress bar;
814
+
815
+ - check out the `slides from PyData London <https://tqdm.github.io/PyData2019/slides.html>`__, or
816
+ - run the |binder-demo|.
817
+
818
+ Description and additional stats
819
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
820
+
821
+ Custom information can be displayed and updated dynamically on ``tqdm`` bars
822
+ with the ``desc`` and ``postfix`` arguments:
823
+
824
+ .. code:: python
825
+
826
+ from tqdm import tqdm, trange
827
+ from random import random, randint
828
+ from time import sleep
829
+
830
+ with trange(10) as t:
831
+ for i in t:
832
+ # Description will be displayed on the left
833
+ t.set_description('GEN %i' % i)
834
+ # Postfix will be displayed on the right,
835
+ # formatted automatically based on argument's datatype
836
+ t.set_postfix(loss=random(), gen=randint(1,999), str='h',
837
+ lst=[1, 2])
838
+ sleep(0.1)
839
+
840
+ with tqdm(total=10, bar_format="{postfix[0]} {postfix[1][value]:>8.2g}",
841
+ postfix=["Batch", {"value": 0}]) as t:
842
+ for i in range(10):
843
+ sleep(0.1)
844
+ t.postfix[1]["value"] = i / 2
845
+ t.update()
846
+
847
+ Points to remember when using ``{postfix[...]}`` in the ``bar_format`` string:
848
+
849
+ - ``postfix`` also needs to be passed as an initial argument in a compatible
850
+ format, and
851
+ - ``postfix`` will be auto-converted to a string if it is a ``dict``-like
852
+ object. To prevent this behaviour, insert an extra item into the dictionary
853
+ where the key is not a string.
854
+
855
+ Additional ``bar_format`` parameters may also be defined by overriding
856
+ ``format_dict``, and the bar itself may be modified using ``ascii``:
857
+
858
+ .. code:: python
859
+
860
+ from tqdm import tqdm
861
+ class TqdmExtraFormat(tqdm):
862
+ """Provides a `total_time` format parameter"""
863
+ @property
864
+ def format_dict(self):
865
+ d = super().format_dict
866
+ total_time = d["elapsed"] * (d["total"] or 0) / max(d["n"], 1)
867
+ d.update(total_time=self.format_interval(total_time) + " in total")
868
+ return d
869
+
870
+ for i in TqdmExtraFormat(
871
+ range(9), ascii=" .oO0",
872
+ bar_format="{total_time}: {percentage:.0f}%|{bar}{r_bar}"):
873
+ if i == 4:
874
+ break
875
+
876
+ .. code::
877
+
878
+ 00:00 in total: 44%|0000. | 4/9 [00:00<00:00, 962.93it/s]
879
+
880
+ Note that ``{bar}`` also supports a format specifier ``[width][type]``.
881
+
882
+ - ``width``
883
+
884
+ * unspecified (default): automatic to fill ``ncols``
885
+ * ``int >= 0``: fixed width overriding ``ncols`` logic
886
+ * ``int < 0``: subtract from the automatic default
887
+
888
+ - ``type``
889
+
890
+ * ``a``: ascii (``ascii=True`` override)
891
+ * ``u``: unicode (``ascii=False`` override)
892
+ * ``b``: blank (``ascii=" "`` override)
893
+
894
+ This means a fixed bar with right-justified text may be created by using:
895
+ ``bar_format="{l_bar}{bar:10}|{bar:-10b}right-justified"``
896
+
897
+ Nested progress bars
898
+ ~~~~~~~~~~~~~~~~~~~~
899
+
900
+ ``tqdm`` supports nested progress bars. Here's an example:
901
+
902
+ .. code:: python
903
+
904
+ from tqdm.auto import trange
905
+ from time import sleep
906
+
907
+ for i in trange(4, desc='1st loop'):
908
+ for j in trange(5, desc='2nd loop'):
909
+ for k in trange(50, desc='3rd loop', leave=False):
910
+ sleep(0.01)
911
+
912
+ For manual control over positioning (e.g. for multi-processing use),
913
+ you may specify ``position=n`` where ``n=0`` for the outermost bar,
914
+ ``n=1`` for the next, and so on.
915
+ However, it's best to check if ``tqdm`` can work without manual ``position``
916
+ first.
917
+
918
+ .. code:: python
919
+
920
+ from time import sleep
921
+ from tqdm import trange, tqdm
922
+ from multiprocessing import Pool, RLock, freeze_support
923
+
924
+ L = list(range(9))
925
+
926
+ def progresser(n):
927
+ interval = 0.001 / (n + 2)
928
+ total = 5000
929
+ text = f"#{n}, est. {interval * total:<04.2}s"
930
+ for _ in trange(total, desc=text, position=n):
931
+ sleep(interval)
932
+
933
+ if __name__ == '__main__':
934
+ freeze_support() # for Windows support
935
+ tqdm.set_lock(RLock()) # for managing output contention
936
+ p = Pool(initializer=tqdm.set_lock, initargs=(tqdm.get_lock(),))
937
+ p.map(progresser, L)
938
+
939
+ Note that in Python 3, ``tqdm.write`` is thread-safe:
940
+
941
+ .. code:: python
942
+
943
+ from time import sleep
944
+ from tqdm import tqdm, trange
945
+ from concurrent.futures import ThreadPoolExecutor
946
+
947
+ L = list(range(9))
948
+
949
+ def progresser(n):
950
+ interval = 0.001 / (n + 2)
951
+ total = 5000
952
+ text = f"#{n}, est. {interval * total:<04.2}s"
953
+ for _ in trange(total, desc=text):
954
+ sleep(interval)
955
+ if n == 6:
956
+ tqdm.write("n == 6 completed.")
957
+ tqdm.write("`tqdm.write()` is thread-safe in py3!")
958
+
959
+ if __name__ == '__main__':
960
+ with ThreadPoolExecutor() as p:
961
+ p.map(progresser, L)
962
+
963
+ Hooks and callbacks
964
+ ~~~~~~~~~~~~~~~~~~~
965
+
966
+ ``tqdm`` can easily support callbacks/hooks and manual updates.
967
+ Here's an example with ``urllib``:
968
+
969
+ **``urllib.urlretrieve`` documentation**
970
+
971
+ | [...]
972
+ | If present, the hook function will be called once
973
+ | on establishment of the network connection and once after each block read
974
+ | thereafter. The hook will be passed three arguments; a count of blocks
975
+ | transferred so far, a block size in bytes, and the total size of the file.
976
+ | [...]
977
+
978
+ .. code:: python
979
+
980
+ import urllib, os
981
+ from tqdm import tqdm
982
+ urllib = getattr(urllib, 'request', urllib)
983
+
984
+ class TqdmUpTo(tqdm):
985
+ """Provides `update_to(n)` which uses `tqdm.update(delta_n)`."""
986
+ def update_to(self, b=1, bsize=1, tsize=None):
987
+ """
988
+ b : int, optional
989
+ Number of blocks transferred so far [default: 1].
990
+ bsize : int, optional
991
+ Size of each block (in tqdm units) [default: 1].
992
+ tsize : int, optional
993
+ Total size (in tqdm units). If [default: None] remains unchanged.
994
+ """
995
+ if tsize is not None:
996
+ self.total = tsize
997
+ return self.update(b * bsize - self.n) # also sets self.n = b * bsize
998
+
999
+ eg_link = "https://cgi.cdcl.ml/matryoshka.zip"
1000
+ with TqdmUpTo(unit='B', unit_scale=True, unit_divisor=1024, miniters=1,
1001
+ desc=eg_link.split('/')[-1]) as t: # all optional kwargs
1002
+ urllib.urlretrieve(eg_link, filename=os.devnull,
1003
+ reporthook=t.update_to, data=None)
1004
+ t.total = t.n
1005
+
1006
+ Inspired by `twine#242 <https://github.com/pypa/twine/pull/242>`__.
1007
+ Functional alternative in
1008
+ `examples/tqdm_wget.py <https://github.com/tqdm/tqdm/blob/master/examples/tqdm_wget.py>`__.
1009
+
1010
+ It is recommend to use ``miniters=1`` whenever there is potentially
1011
+ large differences in iteration speed (e.g. downloading a file over
1012
+ a patchy connection).
1013
+
1014
+ **Wrapping read/write methods**
1015
+
1016
+ To measure throughput through a file-like object's ``read`` or ``write``
1017
+ methods, use ``CallbackIOWrapper``:
1018
+
1019
+ .. code:: python
1020
+
1021
+ from tqdm.auto import tqdm
1022
+ from tqdm.utils import CallbackIOWrapper
1023
+
1024
+ with tqdm(total=file_obj.size,
1025
+ unit='B', unit_scale=True, unit_divisor=1024) as t:
1026
+ fobj = CallbackIOWrapper(t.update, file_obj, "read")
1027
+ while True:
1028
+ chunk = fobj.read(chunk_size)
1029
+ if not chunk:
1030
+ break
1031
+ t.reset()
1032
+ # ... continue to use `t` for something else
1033
+
1034
+ Alternatively, use the even simpler ``wrapattr`` convenience function,
1035
+ which would condense both the ``urllib`` and ``CallbackIOWrapper`` examples
1036
+ down to:
1037
+
1038
+ .. code:: python
1039
+
1040
+ import urllib, os
1041
+ from tqdm import tqdm
1042
+
1043
+ eg_link = "https://cgi.cdcl.ml/matryoshka.zip"
1044
+ response = getattr(urllib, 'request', urllib).urlopen(eg_link)
1045
+ with tqdm.wrapattr(open(os.devnull, "wb"), "write",
1046
+ miniters=1, desc=eg_link.split('/')[-1],
1047
+ total=getattr(response, 'length', None)) as fout:
1048
+ for chunk in response:
1049
+ fout.write(chunk)
1050
+
1051
+ The ``requests`` equivalent is nearly identical:
1052
+
1053
+ .. code:: python
1054
+
1055
+ import requests, os
1056
+ from tqdm import tqdm
1057
+
1058
+ eg_link = "https://cgi.cdcl.ml/matryoshka.zip"
1059
+ response = requests.get(eg_link, stream=True)
1060
+ with tqdm.wrapattr(open(os.devnull, "wb"), "write",
1061
+ miniters=1, desc=eg_link.split('/')[-1],
1062
+ total=int(response.headers.get('content-length', 0))) as fout:
1063
+ for chunk in response.iter_content(chunk_size=4096):
1064
+ fout.write(chunk)
1065
+
1066
+ **Custom callback**
1067
+
1068
+ ``tqdm`` is known for intelligently skipping unnecessary displays. To make a
1069
+ custom callback take advantage of this, simply use the return value of
1070
+ ``update()``. This is set to ``True`` if a ``display()`` was triggered.
1071
+
1072
+ .. code:: python
1073
+
1074
+ from tqdm.auto import tqdm as std_tqdm
1075
+
1076
+ def external_callback(*args, **kwargs):
1077
+ ...
1078
+
1079
+ class TqdmExt(std_tqdm):
1080
+ def update(self, n=1):
1081
+ displayed = super().update(n)
1082
+ if displayed:
1083
+ external_callback(**self.format_dict)
1084
+ return displayed
1085
+
1086
+ ``asyncio``
1087
+ ~~~~~~~~~~~
1088
+
1089
+ Note that ``break`` isn't currently caught by asynchronous iterators.
1090
+ This means that ``tqdm`` cannot clean up after itself in this case:
1091
+
1092
+ .. code:: python
1093
+
1094
+ from tqdm.asyncio import tqdm
1095
+
1096
+ async for i in tqdm(range(9)):
1097
+ if i == 2:
1098
+ break
1099
+
1100
+ Instead, either call ``pbar.close()`` manually or use the context manager syntax:
1101
+
1102
+ .. code:: python
1103
+
1104
+ from tqdm.asyncio import tqdm
1105
+
1106
+ with tqdm(range(9)) as pbar:
1107
+ async for i in pbar:
1108
+ if i == 2:
1109
+ break
1110
+
1111
+ Pandas Integration
1112
+ ~~~~~~~~~~~~~~~~~~
1113
+
1114
+ Due to popular demand we've added support for ``pandas`` -- here's an example
1115
+ for ``DataFrame.progress_apply`` and ``DataFrameGroupBy.progress_apply``:
1116
+
1117
+ .. code:: python
1118
+
1119
+ import pandas as pd
1120
+ import numpy as np
1121
+ from tqdm import tqdm
1122
+
1123
+ df = pd.DataFrame(np.random.randint(0, 100, (100000, 6)))
1124
+
1125
+ # Register `pandas.progress_apply` and `pandas.Series.map_apply` with `tqdm`
1126
+ # (can use `tqdm.gui.tqdm`, `tqdm.notebook.tqdm`, optional kwargs, etc.)
1127
+ tqdm.pandas(desc="my bar!")
1128
+
1129
+ # Now you can use `progress_apply` instead of `apply`
1130
+ # and `progress_map` instead of `map`
1131
+ df.progress_apply(lambda x: x**2)
1132
+ # can also groupby:
1133
+ # df.groupby(0).progress_apply(lambda x: x**2)
1134
+
1135
+ In case you're interested in how this works (and how to modify it for your
1136
+ own callbacks), see the
1137
+ `examples <https://github.com/tqdm/tqdm/tree/master/examples>`__
1138
+ folder or import the module and run ``help()``.
1139
+
1140
+ Keras Integration
1141
+ ~~~~~~~~~~~~~~~~~
1142
+
1143
+ A ``keras`` callback is also available:
1144
+
1145
+ .. code:: python
1146
+
1147
+ from tqdm.keras import TqdmCallback
1148
+
1149
+ ...
1150
+
1151
+ model.fit(..., verbose=0, callbacks=[TqdmCallback()])
1152
+
1153
+ Dask Integration
1154
+ ~~~~~~~~~~~~~~~~
1155
+
1156
+ A ``dask`` callback is also available:
1157
+
1158
+ .. code:: python
1159
+
1160
+ from tqdm.dask import TqdmCallback
1161
+
1162
+ with TqdmCallback(desc="compute"):
1163
+ ...
1164
+ arr.compute()
1165
+
1166
+ # or use callback globally
1167
+ cb = TqdmCallback(desc="global")
1168
+ cb.register()
1169
+ arr.compute()
1170
+
1171
+ IPython/Jupyter Integration
1172
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1173
+
1174
+ IPython/Jupyter is supported via the ``tqdm.notebook`` submodule:
1175
+
1176
+ .. code:: python
1177
+
1178
+ from tqdm.notebook import trange, tqdm
1179
+ from time import sleep
1180
+
1181
+ for i in trange(3, desc='1st loop'):
1182
+ for j in tqdm(range(100), desc='2nd loop'):
1183
+ sleep(0.01)
1184
+
1185
+ In addition to ``tqdm`` features, the submodule provides a native Jupyter
1186
+ widget (compatible with IPython v1-v4 and Jupyter), fully working nested bars
1187
+ and colour hints (blue: normal, green: completed, red: error/interrupt,
1188
+ light blue: no ETA); as demonstrated below.
1189
+
1190
+ |Screenshot-Jupyter1|
1191
+ |Screenshot-Jupyter2|
1192
+ |Screenshot-Jupyter3|
1193
+
1194
+ The ``notebook`` version supports percentage or pixels for overall width
1195
+ (e.g.: ``ncols='100%'`` or ``ncols='480px'``).
1196
+
1197
+ It is also possible to let ``tqdm`` automatically choose between
1198
+ console or notebook versions by using the ``autonotebook`` submodule:
1199
+
1200
+ .. code:: python
1201
+
1202
+ from tqdm.autonotebook import tqdm
1203
+ tqdm.pandas()
1204
+
1205
+ Note that this will issue a ``TqdmExperimentalWarning`` if run in a notebook
1206
+ since it is not meant to be possible to distinguish between ``jupyter notebook``
1207
+ and ``jupyter console``. Use ``auto`` instead of ``autonotebook`` to suppress
1208
+ this warning.
1209
+
1210
+ Note that notebooks will display the bar in the cell where it was created.
1211
+ This may be a different cell from the one where it is used.
1212
+ If this is not desired, either
1213
+
1214
+ - delay the creation of the bar to the cell where it must be displayed, or
1215
+ - create the bar with ``display=False``, and in a later cell call
1216
+ ``display(bar.container)``:
1217
+
1218
+ .. code:: python
1219
+
1220
+ from tqdm.notebook import tqdm
1221
+ pbar = tqdm(..., display=False)
1222
+
1223
+ .. code:: python
1224
+
1225
+ # different cell
1226
+ display(pbar.container)
1227
+
1228
+ The ``keras`` callback has a ``display()`` method which can be used likewise:
1229
+
1230
+ .. code:: python
1231
+
1232
+ from tqdm.keras import TqdmCallback
1233
+ cbk = TqdmCallback(display=False)
1234
+
1235
+ .. code:: python
1236
+
1237
+ # different cell
1238
+ cbk.display()
1239
+ model.fit(..., verbose=0, callbacks=[cbk])
1240
+
1241
+ Another possibility is to have a single bar (near the top of the notebook)
1242
+ which is constantly re-used (using ``reset()`` rather than ``close()``).
1243
+ For this reason, the notebook version (unlike the CLI version) does not
1244
+ automatically call ``close()`` upon ``Exception``.
1245
+
1246
+ .. code:: python
1247
+
1248
+ from tqdm.notebook import tqdm
1249
+ pbar = tqdm()
1250
+
1251
+ .. code:: python
1252
+
1253
+ # different cell
1254
+ iterable = range(100)
1255
+ pbar.reset(total=len(iterable)) # initialise with new `total`
1256
+ for i in iterable:
1257
+ pbar.update()
1258
+ pbar.refresh() # force print final status but don't `close()`
1259
+
1260
+ Custom Integration
1261
+ ~~~~~~~~~~~~~~~~~~
1262
+
1263
+ To change the default arguments (such as making ``dynamic_ncols=True``),
1264
+ simply use built-in Python magic:
1265
+
1266
+ .. code:: python
1267
+
1268
+ from functools import partial
1269
+ from tqdm import tqdm as std_tqdm
1270
+ tqdm = partial(std_tqdm, dynamic_ncols=True)
1271
+
1272
+ For further customisation,
1273
+ ``tqdm`` may be inherited from to create custom callbacks (as with the
1274
+ ``TqdmUpTo`` example `above <#hooks-and-callbacks>`__) or for custom frontends
1275
+ (e.g. GUIs such as notebook or plotting packages). In the latter case:
1276
+
1277
+ 1. ``def __init__()`` to call ``super().__init__(..., gui=True)`` to disable
1278
+ terminal ``status_printer`` creation.
1279
+ 2. Redefine: ``close()``, ``clear()``, ``display()``.
1280
+
1281
+ Consider overloading ``display()`` to use e.g.
1282
+ ``self.frontend(**self.format_dict)`` instead of ``self.sp(repr(self))``.
1283
+
1284
+ Some submodule examples of inheritance:
1285
+
1286
+ - `tqdm/notebook.py <https://github.com/tqdm/tqdm/blob/master/tqdm/notebook.py>`__
1287
+ - `tqdm/gui.py <https://github.com/tqdm/tqdm/blob/master/tqdm/gui.py>`__
1288
+ - `tqdm/tk.py <https://github.com/tqdm/tqdm/blob/master/tqdm/tk.py>`__
1289
+ - `tqdm/contrib/slack.py <https://github.com/tqdm/tqdm/blob/master/tqdm/contrib/slack.py>`__
1290
+ - `tqdm/contrib/discord.py <https://github.com/tqdm/tqdm/blob/master/tqdm/contrib/discord.py>`__
1291
+ - `tqdm/contrib/telegram.py <https://github.com/tqdm/tqdm/blob/master/tqdm/contrib/telegram.py>`__
1292
+
1293
+ Dynamic Monitor/Meter
1294
+ ~~~~~~~~~~~~~~~~~~~~~
1295
+
1296
+ You can use a ``tqdm`` as a meter which is not monotonically increasing.
1297
+ This could be because ``n`` decreases (e.g. a CPU usage monitor) or ``total``
1298
+ changes.
1299
+
1300
+ One example would be recursively searching for files. The ``total`` is the
1301
+ number of objects found so far, while ``n`` is the number of those objects which
1302
+ are files (rather than folders):
1303
+
1304
+ .. code:: python
1305
+
1306
+ from tqdm import tqdm
1307
+ import os.path
1308
+
1309
+ def find_files_recursively(path, show_progress=True):
1310
+ files = []
1311
+ # total=1 assumes `path` is a file
1312
+ t = tqdm(total=1, unit="file", disable=not show_progress)
1313
+ if not os.path.exists(path):
1314
+ raise IOError("Cannot find:" + path)
1315
+
1316
+ def append_found_file(f):
1317
+ files.append(f)
1318
+ t.update()
1319
+
1320
+ def list_found_dir(path):
1321
+ """returns os.listdir(path) assuming os.path.isdir(path)"""
1322
+ listing = os.listdir(path)
1323
+ # subtract 1 since a "file" we found was actually this directory
1324
+ t.total += len(listing) - 1
1325
+ # fancy way to give info without forcing a refresh
1326
+ t.set_postfix(dir=path[-10:], refresh=False)
1327
+ t.update(0) # may trigger a refresh
1328
+ return listing
1329
+
1330
+ def recursively_search(path):
1331
+ if os.path.isdir(path):
1332
+ for f in list_found_dir(path):
1333
+ recursively_search(os.path.join(path, f))
1334
+ else:
1335
+ append_found_file(path)
1336
+
1337
+ recursively_search(path)
1338
+ t.set_postfix(dir=path)
1339
+ t.close()
1340
+ return files
1341
+
1342
+ Using ``update(0)`` is a handy way to let ``tqdm`` decide when to trigger a
1343
+ display refresh to avoid console spamming.
1344
+
1345
+ Writing messages
1346
+ ~~~~~~~~~~~~~~~~
1347
+
1348
+ This is a work in progress (see
1349
+ `#737 <https://github.com/tqdm/tqdm/issues/737>`__).
1350
+
1351
+ Since ``tqdm`` uses a simple printing mechanism to display progress bars,
1352
+ you should not write any message in the terminal using ``print()`` while
1353
+ a progress bar is open.
1354
+
1355
+ To write messages in the terminal without any collision with ``tqdm`` bar
1356
+ display, a ``.write()`` method is provided:
1357
+
1358
+ .. code:: python
1359
+
1360
+ from tqdm.auto import tqdm, trange
1361
+ from time import sleep
1362
+
1363
+ bar = trange(10)
1364
+ for i in bar:
1365
+ # Print using tqdm class method .write()
1366
+ sleep(0.1)
1367
+ if not (i % 3):
1368
+ tqdm.write("Done task %i" % i)
1369
+ # Can also use bar.write()
1370
+
1371
+ By default, this will print to standard output ``sys.stdout``. but you can
1372
+ specify any file-like object using the ``file`` argument. For example, this
1373
+ can be used to redirect the messages writing to a log file or class.
1374
+
1375
+ Redirecting writing
1376
+ ~~~~~~~~~~~~~~~~~~~
1377
+
1378
+ If using a library that can print messages to the console, editing the library
1379
+ by replacing ``print()`` with ``tqdm.write()`` may not be desirable.
1380
+ In that case, redirecting ``sys.stdout`` to ``tqdm.write()`` is an option.
1381
+
1382
+ To redirect ``sys.stdout``, create a file-like class that will write
1383
+ any input string to ``tqdm.write()``, and supply the arguments
1384
+ ``file=sys.stdout, dynamic_ncols=True``.
1385
+
1386
+ A reusable canonical example is given below:
1387
+
1388
+ .. code:: python
1389
+
1390
+ from time import sleep
1391
+ import contextlib
1392
+ import sys
1393
+ from tqdm import tqdm
1394
+ from tqdm.contrib import DummyTqdmFile
1395
+
1396
+
1397
+ @contextlib.contextmanager
1398
+ def std_out_err_redirect_tqdm():
1399
+ orig_out_err = sys.stdout, sys.stderr
1400
+ try:
1401
+ sys.stdout, sys.stderr = map(DummyTqdmFile, orig_out_err)
1402
+ yield orig_out_err[0]
1403
+ # Relay exceptions
1404
+ except Exception as exc:
1405
+ raise exc
1406
+ # Always restore sys.stdout/err if necessary
1407
+ finally:
1408
+ sys.stdout, sys.stderr = orig_out_err
1409
+
1410
+ def some_fun(i):
1411
+ print("Fee, fi, fo,".split()[i])
1412
+
1413
+ # Redirect stdout to tqdm.write() (don't forget the `as save_stdout`)
1414
+ with std_out_err_redirect_tqdm() as orig_stdout:
1415
+ # tqdm needs the original stdout
1416
+ # and dynamic_ncols=True to autodetect console width
1417
+ for i in tqdm(range(3), file=orig_stdout, dynamic_ncols=True):
1418
+ sleep(.5)
1419
+ some_fun(i)
1420
+
1421
+ # After the `with`, printing is restored
1422
+ print("Done!")
1423
+
1424
+ Redirecting ``logging``
1425
+ ~~~~~~~~~~~~~~~~~~~~~~~
1426
+
1427
+ Similar to ``sys.stdout``/``sys.stderr`` as detailed above, console ``logging``
1428
+ may also be redirected to ``tqdm.write()``.
1429
+
1430
+ Warning: if also redirecting ``sys.stdout``/``sys.stderr``, make sure to
1431
+ redirect ``logging`` first if needed.
1432
+
1433
+ Helper methods are available in ``tqdm.contrib.logging``. For example:
1434
+
1435
+ .. code:: python
1436
+
1437
+ import logging
1438
+ from tqdm import trange
1439
+ from tqdm.contrib.logging import logging_redirect_tqdm
1440
+
1441
+ LOG = logging.getLogger(__name__)
1442
+
1443
+ if __name__ == '__main__':
1444
+ logging.basicConfig(level=logging.INFO)
1445
+ with logging_redirect_tqdm():
1446
+ for i in trange(9):
1447
+ if i == 4:
1448
+ LOG.info("console logging redirected to `tqdm.write()`")
1449
+ # logging restored
1450
+
1451
+ Monitoring thread, intervals and miniters
1452
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1453
+
1454
+ ``tqdm`` implements a few tricks to increase efficiency and reduce overhead.
1455
+
1456
+ - Avoid unnecessary frequent bar refreshing: ``mininterval`` defines how long
1457
+ to wait between each refresh. ``tqdm`` always gets updated in the background,
1458
+ but it will display only every ``mininterval``.
1459
+ - Reduce number of calls to check system clock/time.
1460
+ - ``mininterval`` is more intuitive to configure than ``miniters``.
1461
+ A clever adjustment system ``dynamic_miniters`` will automatically adjust
1462
+ ``miniters`` to the amount of iterations that fit into time ``mininterval``.
1463
+ Essentially, ``tqdm`` will check if it's time to print without actually
1464
+ checking time. This behaviour can be still be bypassed by manually setting
1465
+ ``miniters``.
1466
+
1467
+ However, consider a case with a combination of fast and slow iterations.
1468
+ After a few fast iterations, ``dynamic_miniters`` will set ``miniters`` to a
1469
+ large number. When iteration rate subsequently slows, ``miniters`` will
1470
+ remain large and thus reduce display update frequency. To address this:
1471
+
1472
+ - ``maxinterval`` defines the maximum time between display refreshes.
1473
+ A concurrent monitoring thread checks for overdue updates and forces one
1474
+ where necessary.
1475
+
1476
+ The monitoring thread should not have a noticeable overhead, and guarantees
1477
+ updates at least every 10 seconds by default.
1478
+ This value can be directly changed by setting the ``monitor_interval`` of
1479
+ any ``tqdm`` instance (i.e. ``t = tqdm.tqdm(...); t.monitor_interval = 2``).
1480
+ The monitor thread may be disabled application-wide by setting
1481
+ ``tqdm.tqdm.monitor_interval = 0`` before instantiation of any ``tqdm`` bar.
1482
+
1483
+
1484
+ Merch
1485
+ -----
1486
+
1487
+ You can buy `tqdm branded merch <https://tqdm.github.io/merch>`__ now!
1488
+
1489
+ Contributions
1490
+ -------------
1491
+
1492
+ |GitHub-Commits| |GitHub-Issues| |GitHub-PRs| |OpenHub-Status| |GitHub-Contributions| |CII Best Practices|
1493
+
1494
+ All source code is hosted on `GitHub <https://github.com/tqdm/tqdm>`__.
1495
+ Contributions are welcome.
1496
+
1497
+ See the
1498
+ `CONTRIBUTING <https://github.com/tqdm/tqdm/blob/master/CONTRIBUTING.md>`__
1499
+ file for more information.
1500
+
1501
+ Developers who have contributed more that 5 *loc* (surviving lines of code):
1502
+
1503
+ |git-fame|
1504
+
1505
+ Honourable mentions:
1506
+
1507
+ - Casper da Costa-Luis `casperdcl <https://github.com/casperdcl>`__ primary maintainer |Gift-Casper|
1508
+ - Stephen Larroque `lrq3000 <https://github.com/lrq3000>`__ maintainer
1509
+ - Hadrien Mary `hadim <https://github.com/hadim>`__ maintainer
1510
+ - Mikhail Korobov `kmike <https://github.com/kmike>`__ maintainer
1511
+ - Noam Yorav-Raphael `noamraph <https://github.com/noamraph>`__ original author
1512
+
1513
+ Ports to Other Languages
1514
+ ~~~~~~~~~~~~~~~~~~~~~~~~
1515
+
1516
+ A list is available on
1517
+ `this wiki page <https://github.com/tqdm/tqdm/wiki/tqdm-ports>`__.
1518
+
1519
+
1520
+ LICENCE
1521
+ -------
1522
+
1523
+ Open Source (OSI approved): |LICENCE|
1524
+
1525
+ Citation information: |DOI|
1526
+
1527
+ |README-Hits| (Since 19 May 2016)
1528
+
1529
+ .. |Logo| image:: https://tqdm.github.io/img/logo.gif
1530
+ .. |Screenshot| image:: https://tqdm.github.io/img/tqdm.gif
1531
+ .. |Video| image:: https://tqdm.github.io/img/video.jpg
1532
+ :target: https://tqdm.github.io/video
1533
+ .. |Slides| image:: https://tqdm.github.io/img/slides.jpg
1534
+ :target: https://tqdm.github.io/PyData2019/slides.html
1535
+ .. |Merch| image:: https://tqdm.github.io/img/merch.jpg
1536
+ :target: https://tqdm.github.io/merch
1537
+ .. |Build-Status| image:: https://img.shields.io/github/actions/workflow/status/tqdm/tqdm/test.yml?branch=master&label=tqdm&logo=GitHub
1538
+ :target: https://github.com/tqdm/tqdm/actions/workflows/test.yml
1539
+ .. |Coverage-Status| image:: https://img.shields.io/coveralls/github/tqdm/tqdm/master?logo=coveralls
1540
+ :target: https://coveralls.io/github/tqdm/tqdm
1541
+ .. |Branch-Coverage-Status| image:: https://codecov.io/gh/tqdm/tqdm/branch/master/graph/badge.svg
1542
+ :target: https://codecov.io/gh/tqdm/tqdm
1543
+ .. |Codacy-Grade| image:: https://app.codacy.com/project/badge/Grade/3f965571598f44549c7818f29cdcf177
1544
+ :target: https://app.codacy.com/gh/tqdm/tqdm/dashboard
1545
+ .. |CII Best Practices| image:: https://bestpractices.coreinfrastructure.org/projects/3264/badge
1546
+ :target: https://bestpractices.coreinfrastructure.org/projects/3264
1547
+ .. |GitHub-Status| image:: https://img.shields.io/github/tag/tqdm/tqdm.svg?maxAge=86400&logo=github&logoColor=white
1548
+ :target: https://github.com/tqdm/tqdm/releases
1549
+ .. |GitHub-Forks| image:: https://img.shields.io/github/forks/tqdm/tqdm.svg?logo=github&logoColor=white
1550
+ :target: https://github.com/tqdm/tqdm/network
1551
+ .. |GitHub-Stars| image:: https://img.shields.io/github/stars/tqdm/tqdm.svg?logo=github&logoColor=white
1552
+ :target: https://github.com/tqdm/tqdm/stargazers
1553
+ .. |GitHub-Commits| image:: https://img.shields.io/github/commit-activity/y/tqdm/tqdm.svg?logo=git&logoColor=white
1554
+ :target: https://github.com/tqdm/tqdm/graphs/commit-activity
1555
+ .. |GitHub-Issues| image:: https://img.shields.io/github/issues-closed/tqdm/tqdm.svg?logo=github&logoColor=white
1556
+ :target: https://github.com/tqdm/tqdm/issues?q=
1557
+ .. |GitHub-PRs| image:: https://img.shields.io/github/issues-pr-closed/tqdm/tqdm.svg?logo=github&logoColor=white
1558
+ :target: https://github.com/tqdm/tqdm/pulls
1559
+ .. |GitHub-Contributions| image:: https://img.shields.io/github/contributors/tqdm/tqdm.svg?logo=github&logoColor=white
1560
+ :target: https://github.com/tqdm/tqdm/graphs/contributors
1561
+ .. |GitHub-Updated| image:: https://img.shields.io/github/last-commit/tqdm/tqdm/master.svg?logo=github&logoColor=white&label=pushed
1562
+ :target: https://github.com/tqdm/tqdm/pulse
1563
+ .. |git-fame| image:: https://git-fame.cdcl.ml/gh/tqdm/tqdm?min=5&w=1&M=1&C=1&excl=(png|gif|jpg)$&enum=1&auth=share
1564
+ :alt: git-fame.cdcl.ml/gh/tqdm/tqdm
1565
+ :target: https://git-fame.cdcl.ml/gh/tqdm/tqdm?w=1&M=1&C=1&excl=(png|gif|jpg)$&enum=1&auth=share
1566
+ .. |Gift-Casper| image:: https://img.shields.io/badge/sponsor-casper-ff69b4.svg
1567
+ :target: https://cdcl.ml/sponsor
1568
+ .. |Versions| image:: https://img.shields.io/pypi/v/tqdm.svg
1569
+ :target: https://tqdm.github.io/releases
1570
+ .. |PyPI-Downloads| image:: https://static.pepy.tech/personalized-badge/tqdm?left_text=downloads%2Fmonth
1571
+ :target: https://pepy.tech/project/tqdm
1572
+ .. |Py-Versions| image:: https://img.shields.io/pypi/pyversions/tqdm.svg?logo=python&logoColor=white
1573
+ :target: https://pypi.org/project/tqdm
1574
+ .. |Conda-Forge-Status| image:: https://img.shields.io/conda/v/conda-forge/tqdm.svg?label=conda-forge&logo=conda-forge
1575
+ :target: https://anaconda.org/conda-forge/tqdm
1576
+ .. |Snapcraft| image:: https://img.shields.io/badge/snap-install-82BEA0.svg?logo=snapcraft
1577
+ :target: https://snapcraft.io/tqdm
1578
+ .. |Docker| image:: https://img.shields.io/badge/docker-pull-blue.svg?logo=docker&logoColor=white
1579
+ :target: https://hub.docker.com/r/tqdm/tqdm
1580
+ .. |Libraries-Rank| image:: https://img.shields.io/librariesio/sourcerank/pypi/tqdm.svg?logo=koding&logoColor=white
1581
+ :target: https://libraries.io/pypi/tqdm
1582
+ .. |Libraries-Dependents| image:: https://img.shields.io/librariesio/dependent-repos/pypi/tqdm.svg?logo=koding&logoColor=white
1583
+ :target: https://github.com/tqdm/tqdm/network/dependents
1584
+ .. |OpenHub-Status| image:: https://www.openhub.net/p/tqdm/widgets/project_thin_badge?format=gif
1585
+ :target: https://www.openhub.net/p/tqdm?ref=Thin+badge
1586
+ .. |awesome-python| image:: https://awesome.re/mentioned-badge.svg
1587
+ :target: https://github.com/vinta/awesome-python
1588
+ .. |LICENCE| image:: https://img.shields.io/pypi/l/tqdm.svg
1589
+ :target: https://raw.githubusercontent.com/tqdm/tqdm/master/LICENCE
1590
+ .. |DOI| image:: https://img.shields.io/badge/DOI-10.5281/zenodo.595120-blue.svg
1591
+ :target: https://doi.org/10.5281/zenodo.595120
1592
+ .. |colab-demo| image:: https://colab.research.google.com/assets/colab-badge.svg
1593
+ :target: https://colab.research.google.com/github/tqdm/tqdm/blob/master/DEMO.ipynb
1594
+ .. |binder-demo| image:: https://mybinder.org/badge_logo.svg
1595
+ :target: https://mybinder.org/v2/gh/tqdm/tqdm/master?filepath=DEMO.ipynb
1596
+ .. |Screenshot-Jupyter1| image:: https://tqdm.github.io/img/jupyter-1.gif
1597
+ .. |Screenshot-Jupyter2| image:: https://tqdm.github.io/img/jupyter-2.gif
1598
+ .. |Screenshot-Jupyter3| image:: https://tqdm.github.io/img/jupyter-3.gif
1599
+ .. |README-Hits| image:: https://cgi.cdcl.ml/hits?q=tqdm&style=social&r=https://github.com/tqdm/tqdm&l=https://tqdm.github.io/img/favicon.png&f=https://tqdm.github.io/img/logo.gif
1600
+ :target: https://cgi.cdcl.ml/hits?q=tqdm&a=plot&r=https://github.com/tqdm/tqdm&l=https://tqdm.github.io/img/favicon.png&f=https://tqdm.github.io/img/logo.gif&style=social
.venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/RECORD ADDED
@@ -0,0 +1,73 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ../../../bin/tqdm,sha256=rucCCUVlHdONB1hjTa3oLODsVh0RL7FXaqThv5xyjHU,239
2
+ tqdm-4.70.1.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4
3
+ tqdm-4.70.1.dist-info/METADATA,sha256=pdpwuWav6jp1lxYEG61xh_Ls4CwiNIz558ClErvxX1c,57366
4
+ tqdm-4.70.1.dist-info/RECORD,,
5
+ tqdm-4.70.1.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
6
+ tqdm-4.70.1.dist-info/WHEEL,sha256=YVMoNqKzERt-wjUZwJ33xBGAwnFl-4cqbYkTtWa4itE,91
7
+ tqdm-4.70.1.dist-info/entry_points.txt,sha256=ReJCH7Ui3Zyh6M16E4OhsZ1oU7WtMXCfbtoyBhGO29Y,39
8
+ tqdm-4.70.1.dist-info/licenses/LICENCE,sha256=_P-Hw6R86AKKhRKqGC1PzwrRyQVE7nXPmzQ2hMrBlN4,1985
9
+ tqdm-4.70.1.dist-info/top_level.txt,sha256=NLiUJNfmc9At15s7JURiwvqMEjUi9G5PMGRrmMYzNSM,5
10
+ tqdm/__init__.py,sha256=9mQNYSSqP99JasubEC1POJLMmhkkBH6cJZxPIR5G2pQ,1572
11
+ tqdm/__main__.py,sha256=bYt9eEaoRQWdejEHFD8REx9jxVEdZptECFsV7F49Ink,30
12
+ tqdm/__pycache__/__init__.cpython-312.pyc,,
13
+ tqdm/__pycache__/__main__.cpython-312.pyc,,
14
+ tqdm/__pycache__/_main.cpython-312.pyc,,
15
+ tqdm/__pycache__/_monitor.cpython-312.pyc,,
16
+ tqdm/__pycache__/_tqdm.cpython-312.pyc,,
17
+ tqdm/__pycache__/_tqdm_gui.cpython-312.pyc,,
18
+ tqdm/__pycache__/_tqdm_notebook.cpython-312.pyc,,
19
+ tqdm/__pycache__/_tqdm_pandas.cpython-312.pyc,,
20
+ tqdm/__pycache__/_utils.cpython-312.pyc,,
21
+ tqdm/__pycache__/asyncio.cpython-312.pyc,,
22
+ tqdm/__pycache__/auto.cpython-312.pyc,,
23
+ tqdm/__pycache__/autonotebook.cpython-312.pyc,,
24
+ tqdm/__pycache__/cli.cpython-312.pyc,,
25
+ tqdm/__pycache__/dask.cpython-312.pyc,,
26
+ tqdm/__pycache__/gui.cpython-312.pyc,,
27
+ tqdm/__pycache__/keras.cpython-312.pyc,,
28
+ tqdm/__pycache__/notebook.cpython-312.pyc,,
29
+ tqdm/__pycache__/rich.cpython-312.pyc,,
30
+ tqdm/__pycache__/std.cpython-312.pyc,,
31
+ tqdm/__pycache__/tk.cpython-312.pyc,,
32
+ tqdm/__pycache__/utils.cpython-312.pyc,,
33
+ tqdm/__pycache__/version.cpython-312.pyc,,
34
+ tqdm/_main.py,sha256=9ySvgmi_2Sw4CAo5UDW0Q2dxfTryboEWGHohfCJz0sA,283
35
+ tqdm/_monitor.py,sha256=1VcavuotYSN6K-1jbpNuy6HYtr3mwo5Nh_jZMQ-jg3A,4013
36
+ tqdm/_tqdm.py,sha256=LfLCuJ6bpsVo9xilmtBXyEm1vGnUCFrliW85j3J-nD4,283
37
+ tqdm/_tqdm_gui.py,sha256=03Hc8KayxJveieI5-0-2NGiDpLvw9jZekofJUV7CCwk,287
38
+ tqdm/_tqdm_notebook.py,sha256=BuHiLuxu6uEfZFaPJW3RPpPaxaVctEQA3kdSJSDL1hw,307
39
+ tqdm/_tqdm_pandas.py,sha256=c9jptUgigN6axRDhRd4Rif98Tmxeopc1nFNFhIpbFUE,888
40
+ tqdm/_utils.py,sha256=CfLztxFY-QRiNfxQCqAb2N8E13uauIM95RSQiFlaEuE,559
41
+ tqdm/asyncio.py,sha256=IpcGo6ZFwc6KKHYj5s7h4kaRiogcabJ6PcqHj6jdy0I,3196
42
+ tqdm/auto.py,sha256=nDZflj6p2zKkjBCNBourrhS81zYfZy1_dQvbckrdW8o,871
43
+ tqdm/autonotebook.py,sha256=2pNgGCJDsesNNyYnmSve8BNQLiGSgo97SsPoMXCrNRQ,1440
44
+ tqdm/cli.py,sha256=t1j_PqI0SuMyhJGoBxMPCXY-UTbfjciaAQYxAU_f_V0,11011
45
+ tqdm/completion.sh,sha256=j79KbSmpIj_E11jfTfBXrGnUTzKXVpQ1vGVQvsyDRl4,946
46
+ tqdm/contrib/__init__.py,sha256=1GMYYE866WCvlHg5MdmzOvPsQj4ZuMlXzz8xcRcJD60,2479
47
+ tqdm/contrib/__pycache__/__init__.cpython-312.pyc,,
48
+ tqdm/contrib/__pycache__/bells.cpython-312.pyc,,
49
+ tqdm/contrib/__pycache__/concurrent.cpython-312.pyc,,
50
+ tqdm/contrib/__pycache__/discord.cpython-312.pyc,,
51
+ tqdm/contrib/__pycache__/itertools.cpython-312.pyc,,
52
+ tqdm/contrib/__pycache__/logging.cpython-312.pyc,,
53
+ tqdm/contrib/__pycache__/slack.cpython-312.pyc,,
54
+ tqdm/contrib/__pycache__/telegram.cpython-312.pyc,,
55
+ tqdm/contrib/__pycache__/utils_worker.cpython-312.pyc,,
56
+ tqdm/contrib/bells.py,sha256=IaxC2YW57xHDinxdUDQHvSego0HSTdDTExQQENvSB_k,921
57
+ tqdm/contrib/concurrent.py,sha256=CpxrwcKaQRH7nwTPG3mVYuleGs_u0MNhW4hTuabpYYs,9873
58
+ tqdm/contrib/discord.py,sha256=LPjxDbmfiYtw3OAm_WhtwbX9BVYDlPc8lJ96aY3YZDE,5337
59
+ tqdm/contrib/itertools.py,sha256=MA9-Jvb3ToseppInvev2iF4bokN7GQy4Q4LgjUyYdA4,2949
60
+ tqdm/contrib/logging.py,sha256=0nFn2C7qUUiKPB19qTGuS9Lfja8aiFW0u9kybRdG0hU,3902
61
+ tqdm/contrib/slack.py,sha256=sC182v7xBkfGftnDeUmQALMOfwQzU3ZiNf1Q_XA1DjI,4049
62
+ tqdm/contrib/telegram.py,sha256=ybTraGjUQx5m443TsX6pJ7Uxrpsh1m4a43BTWVl_4e4,5081
63
+ tqdm/contrib/utils_worker.py,sha256=vaxyJyagYwOCQXLUMd86bCbI4sPqZysuMGbDSGmvEWo,1199
64
+ tqdm/dask.py,sha256=9Ei58eVqTossRLhAfWyUFCduXYKjmLmwkaXIy-CHYfs,1319
65
+ tqdm/gui.py,sha256=maQ7jgB5leWHwxMlbBv08hpe5lytvmH0hEARu22GRdU,5481
66
+ tqdm/keras.py,sha256=ugd80-xCxMqnrbx_DEOpmj6c2Sh1xoVtQ8V9-bw29eo,4396
67
+ tqdm/notebook.py,sha256=6xkUTcYRsFxN4_BSUYYZ51kAgI7ycnT0HLpP9HukEqg,10888
68
+ tqdm/rich.py,sha256=J04yq6y2Ur9012zC7PkczA1t7cDjet88hmBkrAv-s2s,5255
69
+ tqdm/std.py,sha256=3XbZZd5SxZCBnew3ZkQiDLNdxIMeQO-0wwlEiE_FfYY,58047
70
+ tqdm/tk.py,sha256=3VsB1MDAkCItaWu7CmMb2CoTLMiqmDiEgNi3yiqQ5GY,6702
71
+ tqdm/tqdm.1,sha256=MLg9qjeHThZpPEQbWVrf5P5gOXMKHE_X606FSOBI9eU,7538
72
+ tqdm/utils.py,sha256=o_f0V32H_wrn0XmRno3j9pJ9xlp5xL0fHT3gtqL-k58,9746
73
+ tqdm/version.py,sha256=0uH4TLe8I8H71x29dlmtEZBObLT3b5IW-nytF3V0IVw,233
.venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/REQUESTED ADDED
File without changes
.venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/WHEEL ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
 
1
+ Wheel-Version: 1.0
2
+ Generator: setuptools (84.0.0)
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
5
+
.venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/entry_points.txt ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ [console_scripts]
2
+ tqdm = tqdm.cli:main
.venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/licenses/LICENCE ADDED
@@ -0,0 +1,49 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ `tqdm` is a product of collaborative work.
2
+ Unless otherwise stated, all authors (see commit logs) retain copyright
3
+ for their respective work, and release the work under the MIT licence
4
+ (text below).
5
+
6
+ Exceptions or notable authors are listed below
7
+ in reverse chronological order:
8
+
9
+ * files: *
10
+ MPL-2.0 2015-2026 (c) Casper da Costa-Luis
11
+ [casperdcl](https://github.com/casperdcl).
12
+ * files: tqdm/_tqdm.py
13
+ MIT 2016 (c) [PR #96] on behalf of Google Inc.
14
+ * files: tqdm/_tqdm.py README.rst .gitignore
15
+ MIT 2013 (c) Noam Yorav-Raphael, original author.
16
+
17
+ [PR #96]: https://github.com/tqdm/tqdm/pull/96
18
+
19
+
20
+ Mozilla Public Licence (MPL) v. 2.0 - Exhibit A
21
+ -----------------------------------------------
22
+
23
+ This Source Code Form is subject to the terms of the
24
+ Mozilla Public License, v. 2.0.
25
+ If a copy of the MPL was not distributed with this project,
26
+ You can obtain one at https://mozilla.org/MPL/2.0/.
27
+
28
+
29
+ MIT License (MIT)
30
+ -----------------
31
+
32
+ Copyright (c) 2013 noamraph
33
+
34
+ Permission is hereby granted, free of charge, to any person obtaining a copy of
35
+ this software and associated documentation files (the "Software"), to deal in
36
+ the Software without restriction, including without limitation the rights to
37
+ use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
38
+ the Software, and to permit persons to whom the Software is furnished to do so,
39
+ subject to the following conditions:
40
+
41
+ The above copyright notice and this permission notice shall be included in all
42
+ copies or substantial portions of the Software.
43
+
44
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
45
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
46
+ FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
47
+ COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
48
+ IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
49
+ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
.venv/lib/python3.12/site-packages/tqdm-4.70.1.dist-info/top_level.txt ADDED
@@ -0,0 +1 @@
 
 
1
+ tqdm
.venv/lib/python3.12/site-packages/tqdm/auto.py ADDED
@@ -0,0 +1,40 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Enables multiple commonly used features.
3
+
4
+ Method resolution order:
5
+
6
+ - `tqdm.autonotebook` without import warnings
7
+ - `tqdm.asyncio`
8
+ - `tqdm.std` base class
9
+
10
+ Usage:
11
+ >>> from tqdm.auto import trange, tqdm
12
+ >>> for i in trange(10):
13
+ ... ...
14
+ """
15
+ import warnings
16
+
17
+ from .std import TqdmExperimentalWarning
18
+
19
+ with warnings.catch_warnings():
20
+ warnings.simplefilter("ignore", category=TqdmExperimentalWarning)
21
+ from .autonotebook import tqdm as notebook_tqdm
22
+
23
+ from .asyncio import tqdm as asyncio_tqdm
24
+ from .std import tqdm as std_tqdm
25
+
26
+ if notebook_tqdm != std_tqdm:
27
+ class tqdm(notebook_tqdm, asyncio_tqdm): # pylint: disable=inconsistent-mro
28
+ pass
29
+ else:
30
+ tqdm = asyncio_tqdm
31
+
32
+
33
+ def trange(*args, **kwargs):
34
+ """
35
+ A shortcut for `tqdm.auto.tqdm(range(*args), **kwargs)`.
36
+ """
37
+ return tqdm(range(*args), **kwargs)
38
+
39
+
40
+ __all__ = ["tqdm", "trange"]
.venv/lib/python3.12/site-packages/tqdm/autonotebook.py ADDED
@@ -0,0 +1,38 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Automatically choose between `tqdm.notebook` and `tqdm.std`.
3
+
4
+ Usage:
5
+ >>> from tqdm.autonotebook import trange, tqdm
6
+ >>> for i in trange(10):
7
+ ... ...
8
+ """
9
+ import os
10
+ import sys
11
+ from warnings import warn
12
+
13
+ try:
14
+ if 'ipykernel.zmqshell' in sys.modules:
15
+ if any(i == 'QT_API' or i.startswith('SPYDER') for i in os.environ):
16
+ raise ImportError("console") # jupyter-qtconsole/spyder
17
+ ipy = sys.modules['IPython'].get_ipython().__class__.__name__.lower()
18
+ if 'qt' in ipy or 'spyder' in ipy:
19
+ raise ImportError("console") # older jupyter-qtconsole/spyder
20
+ # jupyter-notebook/jupyterlab/vscode/binder/colab
21
+ elif 'IPython.utils._process_emscripten' in sys.modules:
22
+ pass # jupyterlite (pyodide)/jupyterlite-xeus
23
+ else:
24
+ raise ImportError("console") # ipython/jupyter-console
25
+ from .notebook import WARN_NOIPYW, IProgress
26
+ if IProgress is None:
27
+ from .std import TqdmWarning
28
+ warn(WARN_NOIPYW, TqdmWarning, stacklevel=2)
29
+ raise ImportError('ipywidgets')
30
+ except Exception:
31
+ from .std import tqdm, trange
32
+ else: # pragma: no cover
33
+ from .notebook import tqdm, trange
34
+ from .std import TqdmExperimentalWarning
35
+ warn("Using `tqdm.autonotebook.tqdm` in notebook mode."
36
+ " Use `tqdm.tqdm` instead to force console mode"
37
+ " (e.g. in jupyter console)", TqdmExperimentalWarning, stacklevel=2)
38
+ __all__ = ["tqdm", "trange"]
.venv/lib/python3.12/site-packages/tqdm/cli.py ADDED
@@ -0,0 +1,324 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Module version for monitoring CLI pipes (`... | python -m tqdm | ...`).
3
+ """
4
+ import logging
5
+ import re
6
+ import sys
7
+ from ast import literal_eval
8
+ from textwrap import indent
9
+
10
+ from .std import TqdmKeyError, TqdmTypeError, tqdm
11
+ from .version import __version__
12
+
13
+ __all__ = ["main"]
14
+ log = logging.getLogger(__name__)
15
+
16
+
17
+ def cast(val, typ):
18
+ log.debug((val, typ))
19
+ if " or " in typ:
20
+ for t in typ.split(" or "):
21
+ try:
22
+ return cast(val, t)
23
+ except TqdmTypeError:
24
+ pass
25
+ raise TqdmTypeError(f"{val} : {typ}")
26
+
27
+ # sys.stderr.write('\ndebug | `val:type`: `' + val + ':' + typ + '`.\n')
28
+ if typ == 'bool':
29
+ if (val == 'True') or (val == ''):
30
+ return True
31
+ if val == 'False':
32
+ return False
33
+ raise TqdmTypeError(val + ' : ' + typ)
34
+ if typ == 'chr':
35
+ if len(val) == 1:
36
+ return val.encode()
37
+ if re.match(r"^\\\w+$", val):
38
+ return literal_eval(f'"{val}"').encode()
39
+ raise TqdmTypeError(f"{val} : {typ}")
40
+ if typ == 'str':
41
+ return val
42
+ if typ == 'int':
43
+ try:
44
+ return int(val)
45
+ except ValueError as exc:
46
+ raise TqdmTypeError(f"{val} : {typ}") from exc
47
+ if typ == 'float':
48
+ try:
49
+ return float(val)
50
+ except ValueError as exc:
51
+ raise TqdmTypeError(f"{val} : {typ}") from exc
52
+ raise TqdmTypeError(f"{val} : {typ}")
53
+
54
+
55
+ def posix_pipe(fin, fout, delim=b'\\n', buf_size=256,
56
+ callback=lambda float: None, callback_len=True):
57
+ """
58
+ Params
59
+ ------
60
+ fin : binary file with `read(buf_size : int)` method
61
+ fout : binary file with `write` (and optionally `flush`) methods.
62
+ callback : function(float), e.g.: `tqdm.update`
63
+ callback_len : If (default: True) do `callback(len(buffer))`.
64
+ Otherwise, do `callback(data) for data in buffer.split(delim)`.
65
+ """
66
+ fp_write = fout.write
67
+
68
+ if not delim:
69
+ while True:
70
+ tmp = fin.read(buf_size)
71
+
72
+ # flush at EOF
73
+ if not tmp:
74
+ getattr(fout, 'flush', lambda: None)()
75
+ return
76
+
77
+ fp_write(tmp)
78
+ callback(len(tmp))
79
+ # return
80
+
81
+ buf = b''
82
+ len_delim = len(delim)
83
+ # n = 0
84
+ while True:
85
+ tmp = fin.read(buf_size)
86
+
87
+ # flush at EOF
88
+ if not tmp:
89
+ if buf:
90
+ fp_write(buf)
91
+ if callback_len:
92
+ # n += 1 + buf.count(delim)
93
+ callback(1 + buf.count(delim))
94
+ else:
95
+ for i in buf.split(delim):
96
+ callback(i)
97
+ getattr(fout, 'flush', lambda: None)()
98
+ return # n
99
+
100
+ while True:
101
+ i = tmp.find(delim)
102
+ if i < 0:
103
+ buf += tmp
104
+ break
105
+ fp_write(buf + tmp[:i + len(delim)])
106
+ # n += 1
107
+ callback(1 if callback_len else (buf + tmp[:i]))
108
+ buf = b''
109
+ tmp = tmp[i + len_delim:]
110
+
111
+
112
+ # ((opt, type), ... )
113
+ RE_OPTS = re.compile(r'\n {4}(\S+)\s{2,}:\s*([^,]+)')
114
+ # better split method assuming no positional args
115
+ RE_SHLEX = re.compile(r'\s*(?<!\S)--?([^\s=]+)(\s+|=|$)')
116
+
117
+ # TODO: add custom support for some of the following?
118
+ UNSUPPORTED_OPTS = ('iterable', 'gui', 'out', 'file')
119
+
120
+ # The 8 leading spaces are required for consistency
121
+ CLI_EXTRA_DOC = r"""
122
+ Extra CLI Options
123
+ -----------------
124
+ name : type, optional
125
+ TODO: find out why this is needed.
126
+ delim : chr, optional
127
+ Delimiting character [default: '\n']. Use '\0' for null.
128
+ N.B.: on Windows systems, Python converts '\n' to '\r\n'.
129
+ buf_size : int, optional
130
+ String buffer size in bytes [default: 256]
131
+ used when `delim` is specified.
132
+ bytes : bool, optional
133
+ If true, will count bytes, ignore `delim`, and default
134
+ `unit_scale` to True, `unit_divisor` to 1024, and `unit` to 'B'.
135
+ tee : bool, optional
136
+ If true, passes `stdin` to both `stderr` and `stdout`.
137
+ update : bool, optional
138
+ If true, will treat input as newly elapsed iterations,
139
+ i.e. numbers to pass to `update()`. Note that this is slow
140
+ (~2e5 it/s) since every input must be decoded as a number.
141
+ update_to : bool, optional
142
+ If true, will treat input as total elapsed iterations,
143
+ i.e. numbers to assign to `self.n`. Note that this is slow
144
+ (~2e5 it/s) since every input must be decoded as a number.
145
+ null : bool, optional
146
+ If true, will discard input (no stdout).
147
+ manpath : str, optional
148
+ Directory in which to install tqdm man pages.
149
+ comppath : str, optional
150
+ Directory in which to place tqdm completion.
151
+ log : str, optional
152
+ CRITICAL|FATAL|ERROR|WARN(ING)|[default: 'INFO']|DEBUG|NOTSET.
153
+ """
154
+
155
+
156
+ def main(fp=sys.stderr, argv=None):
157
+ """
158
+ Parameters (internal use only)
159
+ ---------
160
+ fp : file-like object for tqdm
161
+ argv : list (default: sys.argv[1:])
162
+ """
163
+ if argv is None:
164
+ argv = sys.argv[1:]
165
+ try:
166
+ log_idx = argv.index('--log')
167
+ except ValueError:
168
+ for i in argv:
169
+ if i.startswith('--log='):
170
+ logLevel = i[len('--log='):]
171
+ break
172
+ else:
173
+ logLevel = 'INFO'
174
+ else:
175
+ # argv.pop(log_idx)
176
+ # logLevel = argv.pop(log_idx)
177
+ logLevel = argv[log_idx + 1]
178
+ logging.basicConfig(level=getattr(logging, logLevel),
179
+ format="%(levelname)s:%(module)s:%(lineno)d:%(message)s")
180
+
181
+ # py<3.13 doesn't dedent docstrings
182
+ d = (tqdm.__doc__ if sys.version_info < (3, 13)
183
+ else indent(tqdm.__doc__, " ")) + CLI_EXTRA_DOC
184
+
185
+ opt_types = dict(RE_OPTS.findall(d))
186
+ # opt_types['delim'] = 'chr'
187
+
188
+ for o in UNSUPPORTED_OPTS:
189
+ opt_types.pop(o)
190
+
191
+ log.debug(sorted(opt_types.items()))
192
+
193
+ # d = RE_OPTS.sub(r' --\1=<\1> : \2', d)
194
+ split = RE_OPTS.split(d)
195
+ opt_types_desc = zip(split[1::3], split[2::3], split[3::3])
196
+ d = ''.join(('\n --{0} : {2}{3}' if otd[1] == 'bool' else
197
+ '\n --{0}=<{1}> : {2}{3}').format(
198
+ otd[0].replace('_', '-'), otd[0], *otd[1:])
199
+ for otd in opt_types_desc if otd[0] not in UNSUPPORTED_OPTS)
200
+
201
+ help_short = "Usage:\n tqdm [--help | options]\n"
202
+ d = help_short + """
203
+ Options:
204
+ -h, --help Print this help and exit.
205
+ -v, --version Print version and exit.
206
+ """ + d.strip('\n') + '\n'
207
+
208
+ # opts = docopt(d, version=__version__)
209
+ if any(v in argv for v in ('-v', '--version')):
210
+ sys.stdout.write(__version__ + '\n')
211
+ sys.exit(0)
212
+ elif any(v in argv for v in ('-h', '--help')):
213
+ sys.stdout.write(d + '\n')
214
+ sys.exit(0)
215
+ elif argv and argv[0][:2] != '--':
216
+ sys.stderr.write(f"Error:Unknown argument:{argv[0]}\n{help_short}")
217
+
218
+ argv = RE_SHLEX.split(' '.join(["tqdm"] + argv))
219
+ opts = dict(zip(argv[1::3], argv[3::3]))
220
+
221
+ log.debug(opts)
222
+ opts.pop('log', True)
223
+
224
+ tqdm_args = {'file': fp}
225
+ try:
226
+ for (o, v) in opts.items():
227
+ o = o.replace('-', '_')
228
+ try:
229
+ tqdm_args[o] = cast(v, opt_types[o])
230
+ except KeyError as e:
231
+ raise TqdmKeyError(str(e))
232
+ log.debug('args:' + str(tqdm_args))
233
+
234
+ delim_per_char = tqdm_args.pop('bytes', False)
235
+ update = tqdm_args.pop('update', False)
236
+ update_to = tqdm_args.pop('update_to', False)
237
+ if sum((delim_per_char, update, update_to)) > 1:
238
+ raise TqdmKeyError("Can only have one of --bytes --update --update_to")
239
+ except Exception:
240
+ fp.write("\nError:\n" + help_short)
241
+ stdin, stdout_write = sys.stdin, sys.stdout.write
242
+ for i in stdin:
243
+ stdout_write(i)
244
+ raise
245
+ else:
246
+ buf_size = tqdm_args.pop('buf_size', 256)
247
+ delim = tqdm_args.pop('delim', b'\\n')
248
+ tee = tqdm_args.pop('tee', False)
249
+ manpath = tqdm_args.pop('manpath', None)
250
+ comppath = tqdm_args.pop('comppath', None)
251
+ if tqdm_args.pop('null', False):
252
+ class stdout:
253
+ @staticmethod
254
+ def write(_):
255
+ pass
256
+ else:
257
+ stdout = sys.stdout
258
+ stdout = getattr(stdout, 'buffer', stdout)
259
+ stdin = getattr(sys.stdin, 'buffer', sys.stdin)
260
+ if manpath or comppath:
261
+ try: # py<3.9
262
+ import importlib_resources as resources
263
+ except ImportError:
264
+ from importlib import resources
265
+ from pathlib import Path
266
+
267
+ def cp(name, dst):
268
+ """copy resource `name` to `dst`"""
269
+ fi = resources.files('tqdm') / name
270
+ dst.write_bytes(fi.read_bytes())
271
+ log.info("written:%s", dst)
272
+ if manpath is not None:
273
+ cp('tqdm.1', Path(manpath) / 'tqdm.1')
274
+ if comppath is not None:
275
+ cp('completion.sh', Path(comppath) / 'tqdm_completion.sh')
276
+ sys.exit(0)
277
+ if tee:
278
+ stdout_write = stdout.write
279
+ fp_write = getattr(fp, 'buffer', fp).write
280
+
281
+ class stdout: # pylint: disable=function-redefined
282
+ @staticmethod
283
+ def write(x):
284
+ with tqdm.external_write_mode(file=fp):
285
+ fp_write(x)
286
+ stdout_write(x)
287
+ if delim_per_char:
288
+ tqdm_args.setdefault('unit', 'B')
289
+ tqdm_args.setdefault('unit_scale', True)
290
+ tqdm_args.setdefault('unit_divisor', 1024)
291
+ log.debug(tqdm_args)
292
+ with tqdm(**tqdm_args) as t:
293
+ posix_pipe(stdin, stdout, '', buf_size, t.update)
294
+ elif delim == b'\\n':
295
+ log.debug(tqdm_args)
296
+ write = stdout.write
297
+ if update or update_to:
298
+ with tqdm(**tqdm_args) as t:
299
+ if update:
300
+ def callback(i):
301
+ t.update(literal_eval(i.decode()))
302
+ else: # update_to
303
+ def callback(i):
304
+ t.update(literal_eval(i.decode()) - t.n)
305
+ for i in stdin:
306
+ write(i)
307
+ callback(i)
308
+ else:
309
+ for i in tqdm(stdin, **tqdm_args):
310
+ write(i)
311
+ else:
312
+ log.debug(tqdm_args)
313
+ with tqdm(**tqdm_args) as t:
314
+ callback_len = False
315
+ if update:
316
+ def callback(i):
317
+ t.update(literal_eval(i.decode()))
318
+ elif update_to:
319
+ def callback(i):
320
+ t.update(literal_eval(i.decode()) - t.n)
321
+ else:
322
+ callback = t.update
323
+ callback_len = True
324
+ posix_pipe(stdin, stdout, delim, buf_size, callback, callback_len)
.venv/lib/python3.12/site-packages/tqdm/completion.sh ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/usr/bin/env bash
2
+ _tqdm(){
3
+ local cur prv
4
+ cur="${COMP_WORDS[COMP_CWORD]}"
5
+ prv="${COMP_WORDS[COMP_CWORD - 1]}"
6
+
7
+ case ${prv} in
8
+ --bar_format|--buf_size|--colour|--comppath|--delay|--delim|--desc|--initial|--lock_args|--manpath|--maxinterval|--mininterval|--miniters|--ncols|--nrows|--position|--postfix|--smoothing|--total|--unit|--unit_divisor)
9
+ # await user input
10
+ ;;
11
+ "--log")
12
+ COMPREPLY=($(compgen -W 'CRITICAL FATAL ERROR WARN WARNING INFO DEBUG NOTSET' -- ${cur}))
13
+ ;;
14
+ *)
15
+ COMPREPLY=($(compgen -W '--ascii --bar_format --buf_size --bytes --colour --comppath --delay --delim --desc --disable --dynamic_ncols --help --initial --leave --lock_args --log --manpath --maxinterval --mininterval --miniters --ncols --nrows --null --position --postfix --smoothing --tee --total --unit --unit_divisor --unit_scale --update --update_to --version --write_bytes -h -v' -- ${cur}))
16
+ ;;
17
+ esac
18
+ }
19
+ complete -F _tqdm tqdm
.venv/lib/python3.12/site-packages/tqdm/contrib/__init__.py ADDED
@@ -0,0 +1,91 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Thin wrappers around common functions.
3
+
4
+ Subpackages contain potentially unstable extensions.
5
+ """
6
+ from warnings import warn
7
+
8
+ from ..auto import tqdm as tqdm_auto
9
+ from ..std import TqdmDeprecationWarning, tqdm
10
+ from ..utils import ObjectWrapper
11
+
12
+ __author__ = {"github.com/": ["casperdcl"]}
13
+ __all__ = ['tenumerate', 'tzip', 'tmap']
14
+
15
+
16
+ class DummyTqdmFile(ObjectWrapper):
17
+ """Dummy file-like that will write to tqdm"""
18
+
19
+ def __init__(self, wrapped):
20
+ super().__init__(wrapped)
21
+ self._buf = []
22
+
23
+ def write(self, x, nolock=False):
24
+ nl = b"\n" if isinstance(x, bytes) else "\n"
25
+ pre, sep, post = x.rpartition(nl)
26
+ if sep:
27
+ blank = type(nl)()
28
+ tqdm.write(blank.join(self._buf + [pre, sep]),
29
+ end=blank, file=self._wrapped, nolock=nolock)
30
+ self._buf = [post]
31
+ else:
32
+ self._buf.append(x)
33
+
34
+ def __del__(self):
35
+ if self._buf:
36
+ blank = type(self._buf[0])()
37
+ try:
38
+ tqdm.write(blank.join(self._buf), end=blank, file=self._wrapped)
39
+ except (OSError, ValueError):
40
+ pass
41
+
42
+
43
+ def builtin_iterable(func):
44
+ """Returns `func`"""
45
+ warn("This function has no effect, and will be removed in tqdm==5.0.0",
46
+ TqdmDeprecationWarning, stacklevel=2)
47
+ return func
48
+
49
+
50
+ def tenumerate(iterable, start=0, total=None, tqdm_class=tqdm_auto, **tqdm_kwargs):
51
+ """
52
+ Equivalent of `numpy.ndenumerate` or builtin `enumerate`.
53
+
54
+ Parameters
55
+ ----------
56
+ tqdm_class : [default: tqdm.auto.tqdm].
57
+ """
58
+ try:
59
+ import numpy as np
60
+ except ImportError:
61
+ pass
62
+ else:
63
+ if isinstance(iterable, np.ndarray):
64
+ return tqdm_class(np.ndenumerate(iterable), total=total or iterable.size,
65
+ **tqdm_kwargs)
66
+ return enumerate(tqdm_class(iterable, total=total, **tqdm_kwargs), start)
67
+
68
+
69
+ def tzip(iter1, *iter2plus, **tqdm_kwargs):
70
+ """
71
+ Equivalent of builtin `zip`.
72
+
73
+ Parameters
74
+ ----------
75
+ tqdm_class : [default: tqdm.auto.tqdm].
76
+ """
77
+ kwargs = tqdm_kwargs.copy()
78
+ tqdm_class = kwargs.pop("tqdm_class", tqdm_auto)
79
+ yield from zip(tqdm_class(iter1, **kwargs), *iter2plus)
80
+
81
+
82
+ def tmap(function, *sequences, **tqdm_kwargs):
83
+ """
84
+ Equivalent of builtin `map`.
85
+
86
+ Parameters
87
+ ----------
88
+ tqdm_class : [default: tqdm.auto.tqdm].
89
+ """
90
+ for i in tzip(*sequences, **tqdm_kwargs):
91
+ yield function(*i)
.venv/lib/python3.12/site-packages/tqdm/contrib/bells.py ADDED
@@ -0,0 +1,28 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Even more features than `tqdm.auto` (all the bells & whistles):
3
+
4
+ - `tqdm.auto`
5
+ - `tqdm.tqdm.pandas`
6
+ - `tqdm.contrib.slack`
7
+ + uses `${TQDM_SLACK_TOKEN}` and `${TQDM_SLACK_CHANNEL}`
8
+ - `tqdm.contrib.telegram`
9
+ + uses `${TQDM_TELEGRAM_TOKEN}` and `${TQDM_TELEGRAM_CHAT_ID}`
10
+ - `tqdm.contrib.discord`
11
+ + uses `${TQDM_DISCORD_TOKEN}` and `${TQDM_DISCORD_CHANNEL_ID}`
12
+ """
13
+ __all__ = ['tqdm', 'trange']
14
+ import warnings
15
+ from os import getenv
16
+
17
+ if getenv("TQDM_SLACK_TOKEN") and getenv("TQDM_SLACK_CHANNEL"):
18
+ from .slack import tqdm, trange
19
+ elif getenv("TQDM_TELEGRAM_TOKEN") and getenv("TQDM_TELEGRAM_CHAT_ID"):
20
+ from .telegram import tqdm, trange
21
+ elif getenv("TQDM_DISCORD_TOKEN") and getenv("TQDM_DISCORD_CHANNEL_ID"):
22
+ from .discord import tqdm, trange
23
+ else:
24
+ from ..auto import tqdm, trange
25
+
26
+ with warnings.catch_warnings():
27
+ warnings.simplefilter("ignore", category=FutureWarning)
28
+ tqdm.pandas()
.venv/lib/python3.12/site-packages/tqdm/contrib/concurrent.py ADDED
@@ -0,0 +1,259 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Thin wrappers around `concurrent.futures`.
3
+ """
4
+ import sys
5
+ from contextlib import contextmanager
6
+ from operator import length_hint
7
+
8
+ from ..auto import tqdm as tqdm_auto
9
+ from ..std import TqdmWarning
10
+
11
+ __author__ = {"github.com/": ["casperdcl"]}
12
+ __all__ = ['thread_map', 'process_map', 'interpreter_map']
13
+
14
+
15
+ class _InterpreterLock:
16
+ """Reentrant lock backed by a cross-interpreter queue."""
17
+ from threading import get_ident
18
+ from time import monotonic as _time
19
+
20
+ def __init__(self, queue):
21
+ from threading import RLock
22
+ self._queue = queue
23
+ self._lock = RLock()
24
+ self._owner = None
25
+ self._depth = 0
26
+
27
+ def acquire(self, blocking=True, timeout=-1):
28
+ from queue import Empty
29
+ start = self._time()
30
+ if timeout == -1:
31
+ acquired = self._lock.acquire(blocking)
32
+ else:
33
+ acquired = self._lock.acquire(blocking, timeout)
34
+ if not acquired:
35
+ return False
36
+ if self._depth:
37
+ self._depth += 1
38
+ return True
39
+ try:
40
+ if not blocking:
41
+ self._queue.get_nowait()
42
+ elif timeout == -1:
43
+ self._queue.get()
44
+ else:
45
+ remaining = max(0, timeout - (self._time() - start))
46
+ self._queue.get(timeout=remaining)
47
+ except Empty:
48
+ self._lock.release()
49
+ return False
50
+ self._owner = self.get_ident()
51
+ self._depth = 1
52
+ return True
53
+
54
+ def release(self):
55
+ if self._owner != self.get_ident():
56
+ raise RuntimeError("cannot release un-acquired lock")
57
+ self._depth -= 1
58
+ if not self._depth:
59
+ self._owner = None
60
+ self._queue.put(None)
61
+ self._lock.release()
62
+
63
+ def __enter__(self):
64
+ self.acquire()
65
+ return self
66
+
67
+ def __exit__(self, *exc):
68
+ self.release()
69
+
70
+
71
+ @contextmanager
72
+ def ensure_lock(tqdm_class, lock_name="", lock=None):
73
+ """get (create if necessary) and then restore `tqdm_class`'s lock"""
74
+ old_lock = getattr(tqdm_class, '_lock', None) # don't create a new lock
75
+ if lock is None:
76
+ lock = old_lock or tqdm_class.get_lock() # maybe create a new lock
77
+ lock = getattr(lock, lock_name, lock) # maybe subtype
78
+ tqdm_class.set_lock(lock)
79
+ yield lock
80
+ if old_lock is None:
81
+ del tqdm_class._lock
82
+ else:
83
+ tqdm_class.set_lock(old_lock)
84
+
85
+
86
+ def _get_interpreter_init(tqdm_class, lock_queue_id):
87
+ """Return an initializer which bootstraps the parent import path and lock."""
88
+ code = (
89
+ "import sys\n"
90
+ f"sys.path[:] = {sys.path!r}\n"
91
+ "from concurrent import interpreters\n"
92
+ "from importlib import import_module\n"
93
+ "from tqdm.contrib.concurrent import _InterpreterLock\n"
94
+ f"tqdm_class = import_module({tqdm_class.__module__!r})\n"
95
+ f"for name in {tqdm_class.__qualname__.split('.')!r}:\n"
96
+ " tqdm_class = getattr(tqdm_class, name)\n"
97
+ "tqdm_class.monitor_interval = 0\n"
98
+ f"tqdm_class.set_lock(_InterpreterLock(interpreters.Queue({lock_queue_id!r})))")
99
+ return exec, (code,)
100
+
101
+
102
+ def _min_map_len(iterables):
103
+ """min(map(length_hint, iterables), default=0)"""
104
+ return min((n for it in iterables if (n := length_hint(it, -1)) >= 0), default=0)
105
+
106
+
107
+ def _executor_map(
108
+ PoolExecutor, fn, *iterables, max_workers=None, timeout=None, chunksize=1, lock_name="",
109
+ tqdm_class=tqdm_auto, smoothing=0.0, _lock=None, _initializer=None, _initargs=None,
110
+ **tqdm_kwargs
111
+ ):
112
+ """
113
+ Implementation of `thread_map`, `process_map` and `interpreter_map`.
114
+
115
+ Parameters
116
+ ----------
117
+ max_workers : int
118
+ timeout : int
119
+ buffersize : int
120
+ Requires Python>=3.14.
121
+ thread_name_prefix : str
122
+ max_tasks_per_child : int
123
+ mp_context : str
124
+ """
125
+ kwargs = tqdm_kwargs.copy()
126
+ if 'total' not in kwargs:
127
+ kwargs['total'] = _min_map_len(iterables)
128
+ map_kwargs = {}
129
+ if 'buffersize' in kwargs:
130
+ map_kwargs['buffersize'] = kwargs.pop('buffersize')
131
+ pool_kwargs = {}
132
+ for k in ('thread_name_prefix', 'max_tasks_per_child', 'mp_context'):
133
+ if k in kwargs:
134
+ pool_kwargs[k] = kwargs.pop(k)
135
+ dynamic_miniters = None
136
+ if kwargs['total'] and 'miniters' not in kwargs:
137
+ try:
138
+ from os import process_cpu_count as cpu_count
139
+ except ImportError:
140
+ from os import cpu_count
141
+ # thread & process pools have different default workers, but we KISS here
142
+ rough_max = max_workers or min(32, (cpu_count() or 1) + 4)
143
+ if kwargs['total'] > rough_max:
144
+ kwargs['miniters'] = rough_max
145
+ dynamic_miniters = True
146
+ with ensure_lock(tqdm_class, lock_name=lock_name, lock=_lock) as lk:
147
+ # share lock in case workers are already using `tqdm`
148
+ if _initializer is None:
149
+ _initializer = tqdm_class.set_lock
150
+ _initargs = (lk,)
151
+ with PoolExecutor(max_workers=max_workers, initializer=_initializer, initargs=_initargs,
152
+ **pool_kwargs) as ex:
153
+ with tqdm_class(smoothing=smoothing, **kwargs) as pbar:
154
+ if dynamic_miniters is not None:
155
+ pbar.dynamic_miniters = True
156
+ orisubmit = ex.submit
157
+
158
+ def patchsubmit(*args, **kwargs):
159
+ fut = orisubmit(*args, **kwargs)
160
+ fut.add_done_callback(lambda _: pbar.update())
161
+ return fut
162
+ ex.submit = patchsubmit
163
+ return list(ex.map(
164
+ fn, *iterables, timeout=timeout, chunksize=chunksize, **map_kwargs))
165
+
166
+
167
+ def thread_map(fn, *iterables, **tqdm_kwargs):
168
+ """
169
+ Equivalent of `list(map(fn, *iterables))`
170
+ driven by `concurrent.futures.ThreadPoolExecutor`.
171
+
172
+ Parameters
173
+ ----------
174
+ max_workers : int, optional
175
+ Maximum number of workers to spawn; passed to `concurrent.futures.ThreadPoolExecutor`.
176
+ thread_name_prefix : str, optional
177
+ Passed to `concurrent.futures.ThreadPoolExecutor` [default: ''].
178
+ timeout : int or float, optional
179
+ Seconds to wait before raising `TimeoutError` if `__next__` is called and the
180
+ result isn't available. [default: None].
181
+ buffersize : int, optional
182
+ Requires Python>=3.14 [default: None].
183
+ tqdm_class : optional
184
+ `tqdm` class to use for bars [default: tqdm.auto.tqdm].
185
+ smoothing : float, optional
186
+ Passed to `tqdm_class`; the [default: 0] is average (due to erratic update frequency).
187
+ lock_name : str, optional
188
+ Member of `tqdm_class.get_lock()` to use [default: ''].
189
+ """
190
+ from concurrent.futures import ThreadPoolExecutor
191
+ return _executor_map(ThreadPoolExecutor, fn, *iterables, **tqdm_kwargs)
192
+
193
+
194
+ def interpreter_map(fn, *iterables, **tqdm_kwargs):
195
+ """
196
+ Equivalent of `list(map(fn, *iterables))`
197
+ driven by `concurrent.futures.InterpreterPoolExecutor` (Python 3.14+).
198
+
199
+ Parameters
200
+ ----------
201
+ Same as `thread_map`.
202
+
203
+ Notes
204
+ -----
205
+ `fn`, its arguments, and its return values must be pickleable.
206
+ Worker progress bars using the same `tqdm_class` share a cross-interpreter write lock.
207
+ """
208
+ from concurrent import interpreters
209
+ from concurrent.futures import InterpreterPoolExecutor
210
+ lock_queue = interpreters.create_queue()
211
+ lock_queue.put(None)
212
+ tqdm_class = tqdm_kwargs.get("tqdm_class", tqdm_auto)
213
+ initializer, initargs = _get_interpreter_init(tqdm_class, lock_queue.id)
214
+ return _executor_map(
215
+ InterpreterPoolExecutor, fn, *iterables, _lock=_InterpreterLock(lock_queue),
216
+ _initializer=initializer, _initargs=initargs, **tqdm_kwargs)
217
+
218
+
219
+ def process_map(fn, *iterables, lock_name="mp_lock", **tqdm_kwargs):
220
+ """
221
+ Equivalent of `list(map(fn, *iterables))`
222
+ driven by `concurrent.futures.ProcessPoolExecutor`.
223
+
224
+ Parameters
225
+ ----------
226
+ max_workers : int, optional
227
+ Maximum number of workers to spawn; passed to `concurrent.futures.ProcessPoolExecutor`.
228
+ timeout : int or float, optional
229
+ Seconds to wait before raising `TimeoutError` if `__next__` is called and the
230
+ result isn't available. [default: None].
231
+ chunksize : int, optional
232
+ Approximate size of chunks sent to worker processes; passed to
233
+ `concurrent.futures.ProcessPoolExecutor.map`. [default: 1].
234
+ buffersize : int, optional
235
+ Requires Python>=3.14 [default: None].
236
+ max_tasks_per_child : int, optional
237
+ Maximum number of tasks a worker process can complete before being replaced
238
+ with a new process; passed to `concurrent.futures.ProcessPoolExecutor`.
239
+ mp_context : multiprocessing.BaseContext, optional
240
+ Multiprocessing context to use, e.g. `multiprocessing.get_context('fork')`.
241
+ lock_name : str, optional
242
+ Member of `tqdm_class.get_lock()` to use [default: mp_lock].
243
+ tqdm_class : optional
244
+ `tqdm` class to use for bars [default: tqdm.auto.tqdm].
245
+ smoothing : float, optional
246
+ Passed to `tqdm_class`; the [default: 0] is average (due to erratic update frequency).
247
+ """
248
+ from concurrent.futures import ProcessPoolExecutor
249
+ if iterables and 'chunksize' not in tqdm_kwargs:
250
+ # default `chunksize=1` has poor performance for large iterables
251
+ # (most time spent dispatching items to workers).
252
+ shortest_iterable_len = _min_map_len(iterables)
253
+ if shortest_iterable_len > 1000:
254
+ from warnings import warn
255
+ warn("Iterable length %d > 1000 but `chunksize` is not set."
256
+ " This may seriously degrade multiprocess performance."
257
+ " Set `chunksize=1` or more." % shortest_iterable_len,
258
+ TqdmWarning, stacklevel=2)
259
+ return _executor_map(ProcessPoolExecutor, fn, *iterables, lock_name=lock_name, **tqdm_kwargs)
.venv/lib/python3.12/site-packages/tqdm/contrib/discord.py ADDED
@@ -0,0 +1,155 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Sends updates to a Discord bot.
3
+
4
+ Usage:
5
+ >>> from tqdm.contrib.discord import tqdm, trange
6
+ >>> for i in trange(10, token='{token}', channel_id='{channel_id}'):
7
+ ... ...
8
+
9
+ ![screenshot](https://tqdm.github.io/img/screenshot-discord.png)
10
+ """
11
+ from warnings import warn
12
+
13
+ from requests import Session
14
+ from requests.utils import default_user_agent
15
+
16
+ from ..auto import tqdm as tqdm_auto
17
+ from ..std import TqdmWarning
18
+ from ..utils import envwrap
19
+ from ..version import __version__
20
+ from .utils_worker import MonoWorker
21
+
22
+ __author__ = {"github.com/": ["casperdcl", "guigoruiz1"]}
23
+ __all__ = ['DiscordIO', 'tqdm_discord', 'tdrange', 'tqdm', 'trange']
24
+
25
+
26
+ class DiscordIO(MonoWorker):
27
+ """Non-blocking file-like IO using a Discord Bot."""
28
+ API = 'https://discord.com/api/v10'
29
+ UA = f"tqdm (https://tqdm.github.io, {__version__}) {default_user_agent()}"
30
+
31
+ def __init__(self, token, channel_id):
32
+ """Creates a new message in the given `channel_id`."""
33
+ super().__init__()
34
+ self.token = token
35
+ self.channel_id = channel_id
36
+ self.session = Session()
37
+ self.text = self.__class__.__name__
38
+ self.message_id # pylint: disable=pointless-statement
39
+
40
+ @property
41
+ def message_id(self):
42
+ if hasattr(self, '_message_id'):
43
+ return self._message_id # pylint: disable=access-member-before-definition
44
+ try:
45
+ req = self.session.post(
46
+ f'{self.API}/channels/{self.channel_id}/messages',
47
+ headers={'Authorization': f'Bot {self.token}', 'User-Agent': self.UA},
48
+ json={'content': f"`{self.text}`"})
49
+ res = req.json()
50
+ req.raise_for_status()
51
+ except Exception as e:
52
+ if req.status_code == 429:
53
+ warn("Creation rate limit: try increasing `mininterval`.",
54
+ TqdmWarning, stacklevel=2)
55
+ else:
56
+ tqdm_auto.write(str(e))
57
+ else:
58
+ self._message_id = res['id']
59
+ return self._message_id
60
+
61
+ def write(self, s):
62
+ """Replaces internal `message_id`'s text with `s`."""
63
+ if not s:
64
+ s = "..."
65
+ s = s.replace('\r', '').strip()
66
+ if s == self.text:
67
+ return # avoid duplicate message Bot error
68
+ message_id = self.message_id
69
+ if message_id is None:
70
+ return
71
+ self.text = s
72
+ try:
73
+ future = self.submit(
74
+ self.session.patch,
75
+ f'{self.API}/channels/{self.channel_id}/messages/{message_id}',
76
+ headers={'Authorization': f'Bot {self.token}', 'User-Agent': self.UA},
77
+ json={'content': f"`{self.text}`"})
78
+ except Exception as e:
79
+ tqdm_auto.write(str(e))
80
+ else:
81
+ return future
82
+
83
+ def delete(self):
84
+ """Deletes internal `message_id`."""
85
+ try:
86
+ future = self.submit(
87
+ self.session.delete,
88
+ f'{self.API}/channels/{self.channel_id}/messages/{self.message_id}',
89
+ headers={'Authorization': f'Bot {self.token}', 'User-Agent': self.UA})
90
+ except Exception as e:
91
+ tqdm_auto.write(str(e))
92
+ else:
93
+ return future
94
+
95
+
96
+ class tqdm_discord(tqdm_auto): # pylint: disable=inconsistent-mro
97
+ """
98
+ Standard `tqdm.auto.tqdm` but also sends updates to a Discord Bot.
99
+ May take a few seconds to create (`__init__`).
100
+
101
+ - create a discord bot (not public, no requirement of OAuth2 code
102
+ grant, only send message permissions) & invite it to a channel:
103
+ <https://discordpy.readthedocs.io/en/latest/discord.html>
104
+ - copy the bot `{token}` & `{channel_id}` and paste below
105
+
106
+ >>> from tqdm.contrib.discord import tqdm, trange
107
+ >>> for i in tqdm(iterable, token='{token}', channel_id='{channel_id}'):
108
+ ... ...
109
+ """
110
+ @envwrap("tqdm", "discord", is_method=True)
111
+ def __init__(self, *args, token=None, channel_id=None, **kwargs):
112
+ """
113
+ Parameters
114
+ ----------
115
+ token : str, required. Discord bot token
116
+ [default: ${TQDM_DISCORD_TOKEN}].
117
+ channel_id : int, required. Discord channel ID
118
+ [default: ${TQDM_DISCORD_CHANNEL_ID}].
119
+
120
+ See `tqdm.auto.tqdm.__init__` for other parameters.
121
+ """
122
+ if not kwargs.get('disable'):
123
+ kwargs = kwargs.copy()
124
+ self.dio = DiscordIO(token, channel_id)
125
+ super().__init__(*args, **kwargs)
126
+
127
+ def display(self, **kwargs): # pylint: disable=arguments-differ
128
+ super().display(**kwargs)
129
+ fmt = self.format_dict
130
+ if fmt.get('bar_format', None):
131
+ fmt['bar_format'] = fmt['bar_format'].replace(
132
+ '<bar/>', '{bar:10u}').replace('{bar}', '{bar:10u}')
133
+ self.dio.write(self.format_meter(**fmt))
134
+
135
+ def clear(self, *args, **kwargs):
136
+ super().clear(*args, **kwargs)
137
+ if not self.disable:
138
+ self.dio.write("")
139
+
140
+ def close(self):
141
+ if self.disable:
142
+ return
143
+ super().close()
144
+ if not (self.leave or (self.leave is None and self.pos == 0)):
145
+ self.dio.delete()
146
+
147
+
148
+ def tdrange(*args, **kwargs):
149
+ """Shortcut for `tqdm.contrib.discord.tqdm(range(*args), **kwargs)`."""
150
+ return tqdm_discord(range(*args), **kwargs)
151
+
152
+
153
+ # Aliases
154
+ tqdm = tqdm_discord
155
+ trange = tdrange
.venv/lib/python3.12/site-packages/tqdm/contrib/itertools.py ADDED
@@ -0,0 +1,92 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Thin wrappers around `itertools`.
3
+ """
4
+ import itertools
5
+ import math
6
+
7
+ from ..auto import tqdm as tqdm_auto
8
+
9
+ __author__ = {"github.com/": ["casperdcl"]}
10
+ __all__ = [
11
+ 'chain', 'product', 'permutations', 'combinations', 'combinations_with_replacement', 'batched']
12
+
13
+
14
+ def chain(*iterables, total=None, tqdm_class=tqdm_auto, **kwargs):
15
+ """Equivalent of `itertools.chain`."""
16
+ if total is None:
17
+ try:
18
+ total = sum(map(len, iterables))
19
+ except (TypeError, AttributeError):
20
+ pass
21
+ return tqdm_class(itertools.chain(*iterables), total=total, **kwargs)
22
+
23
+
24
+ def product(*iterables, repeat=1, total=None, tqdm_class=tqdm_auto, **kwargs):
25
+ """Equivalent of `itertools.product`."""
26
+ if total is None:
27
+ try:
28
+ lens = list(map(len, iterables))
29
+ except (TypeError, AttributeError):
30
+ pass
31
+ else:
32
+ total = math.prod(lens) ** repeat
33
+ yield from tqdm_class(itertools.product(*iterables, repeat=repeat), total=total, **kwargs)
34
+
35
+
36
+ def permutations(iterable, r=None, total=None, tqdm_class=tqdm_auto, **kwargs):
37
+ """Equivalent of `itertools.permutations`."""
38
+ if total is None:
39
+ try:
40
+ n = len(iterable)
41
+ except (TypeError, AttributeError):
42
+ pass
43
+ else:
44
+ r = n if r is None else r
45
+ if r > n:
46
+ total = 0
47
+ else:
48
+ total = math.perm(n, r)
49
+ return tqdm_class(itertools.permutations(iterable, r), total=total, **kwargs)
50
+
51
+
52
+ def combinations(iterable, r, total=None, tqdm_class=tqdm_auto, **kwargs):
53
+ """Equivalent of `itertools.combinations`."""
54
+ if total is None:
55
+ try:
56
+ n = len(iterable)
57
+ except (TypeError, AttributeError):
58
+ pass
59
+ else:
60
+ if r > n:
61
+ total = 0
62
+ else:
63
+ total = math.comb(n, r)
64
+ return tqdm_class(itertools.combinations(iterable, r), total=total, **kwargs)
65
+
66
+
67
+ def combinations_with_replacement(iterable, r, total=None, tqdm_class=tqdm_auto, **kwargs):
68
+ """Equivalent of `itertools.combinations_with_replacement`."""
69
+ if total is None:
70
+ try:
71
+ n = len(iterable)
72
+ except (TypeError, AttributeError):
73
+ pass
74
+ else:
75
+ total = 1
76
+ for i in range(n+r-1, n-1, -1):
77
+ total *= i
78
+ for i in range(1, r+1):
79
+ total //= i
80
+ return tqdm_class(itertools.combinations_with_replacement(iterable, r), total=total, **kwargs)
81
+
82
+
83
+ def batched(iterable, n, total=None, tqdm_class=tqdm_auto, **kwargs):
84
+ """Equivalent of `itertools.batched`."""
85
+ if total is None:
86
+ try:
87
+ total = len(iterable)
88
+ except (TypeError, AttributeError):
89
+ pass
90
+ return tqdm_class(itertools.batched(iterable, n), unit_scale=n,
91
+ total=(total+n-1) // n if total is not None else None,
92
+ **kwargs)
.venv/lib/python3.12/site-packages/tqdm/contrib/logging.py ADDED
@@ -0,0 +1,128 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Helper functionality for interoperability with stdlib `logging`.
3
+ """
4
+ import logging
5
+ import sys
6
+ from contextlib import contextmanager
7
+
8
+ try:
9
+ from typing import Iterator, List, Optional, Type # noqa: F401, pylint: disable=unused-import
10
+ except ImportError:
11
+ pass
12
+
13
+ from ..std import tqdm as std_tqdm
14
+
15
+
16
+ class _TqdmLoggingHandler(logging.StreamHandler):
17
+ def __init__(
18
+ self,
19
+ tqdm_class=std_tqdm # type: Type[std_tqdm]
20
+ ):
21
+ super().__init__()
22
+ self.tqdm_class = tqdm_class
23
+
24
+ def emit(self, record):
25
+ try:
26
+ msg = self.format(record)
27
+ self.tqdm_class.write(msg, file=self.stream)
28
+ self.flush()
29
+ except (KeyboardInterrupt, SystemExit):
30
+ raise
31
+ except: # noqa pylint: disable=bare-except
32
+ self.handleError(record)
33
+
34
+
35
+ def _is_console_logging_handler(handler):
36
+ return (isinstance(handler, logging.StreamHandler)
37
+ and handler.stream in {sys.stdout, sys.stderr})
38
+
39
+
40
+ def _get_first_found_console_logging_handler(handlers):
41
+ for handler in handlers:
42
+ if _is_console_logging_handler(handler):
43
+ return handler
44
+
45
+
46
+ @contextmanager
47
+ def logging_redirect_tqdm(
48
+ loggers=None, # type: Optional[List[logging.Logger]],
49
+ tqdm_class=std_tqdm # type: Type[std_tqdm]
50
+ ):
51
+ # type: (...) -> Iterator[None]
52
+ """
53
+ Context manager redirecting console logging to `tqdm.write()`, leaving
54
+ other logging handlers (e.g. log files) unaffected.
55
+
56
+ Parameters
57
+ ----------
58
+ loggers : list, optional
59
+ Which handlers to redirect (default: [logging.root]).
60
+ tqdm_class : optional
61
+
62
+ Example
63
+ -------
64
+ ```python
65
+ import logging
66
+ from tqdm import trange
67
+ from tqdm.contrib.logging import logging_redirect_tqdm
68
+
69
+ LOG = logging.getLogger(__name__)
70
+
71
+ if __name__ == '__main__':
72
+ logging.basicConfig(level=logging.INFO)
73
+ with logging_redirect_tqdm():
74
+ for i in trange(9):
75
+ if i == 4:
76
+ LOG.info("console logging redirected to `tqdm.write()`")
77
+ # logging restored
78
+ ```
79
+ """
80
+ if loggers is None:
81
+ loggers = [logging.root]
82
+ original_handlers_list = [logger.handlers for logger in loggers]
83
+ try:
84
+ for logger in loggers:
85
+ tqdm_handler = _TqdmLoggingHandler(tqdm_class)
86
+ orig_handler = _get_first_found_console_logging_handler(logger.handlers)
87
+ if orig_handler is not None:
88
+ tqdm_handler.setFormatter(orig_handler.formatter)
89
+ tqdm_handler.stream = orig_handler.stream
90
+ for log_filter in orig_handler.filters:
91
+ tqdm_handler.addFilter(log_filter)
92
+ logger.handlers = [
93
+ handler for handler in logger.handlers
94
+ if not _is_console_logging_handler(handler)] + [tqdm_handler]
95
+ yield
96
+ finally:
97
+ for logger, original_handlers in zip(loggers, original_handlers_list):
98
+ logger.handlers = original_handlers
99
+
100
+
101
+ @contextmanager
102
+ def tqdm_logging_redirect(
103
+ *args,
104
+ # loggers=None, # type: Optional[List[logging.Logger]]
105
+ # tqdm=None, # type: Optional[Type[tqdm.tqdm]]
106
+ **kwargs
107
+ ):
108
+ # type: (...) -> Iterator[None]
109
+ """
110
+ Convenience shortcut for:
111
+ ```python
112
+ with tqdm_class(*args, **tqdm_kwargs) as pbar:
113
+ with logging_redirect_tqdm(loggers=loggers, tqdm_class=tqdm_class):
114
+ yield pbar
115
+ ```
116
+
117
+ Parameters
118
+ ----------
119
+ tqdm_class : optional, (default: tqdm.std.tqdm).
120
+ loggers : optional, list.
121
+ **tqdm_kwargs : passed to `tqdm_class`.
122
+ """
123
+ tqdm_kwargs = kwargs.copy()
124
+ loggers = tqdm_kwargs.pop('loggers', None)
125
+ tqdm_class = tqdm_kwargs.pop('tqdm_class', std_tqdm)
126
+ with tqdm_class(*args, **tqdm_kwargs) as pbar:
127
+ with logging_redirect_tqdm(loggers=loggers, tqdm_class=tqdm_class):
128
+ yield pbar
.venv/lib/python3.12/site-packages/tqdm/contrib/slack.py ADDED
@@ -0,0 +1,119 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Sends updates to a Slack app.
3
+
4
+ Usage:
5
+ >>> from tqdm.contrib.slack import tqdm, trange
6
+ >>> for i in trange(10, token='{token}', channel='{channel}'):
7
+ ... ...
8
+
9
+ ![screenshot](https://tqdm.github.io/img/screenshot-slack.png)
10
+ """
11
+ import logging
12
+
13
+ try:
14
+ from slack_sdk import WebClient
15
+ except ImportError:
16
+ raise ImportError("Please `pip install slack-sdk`")
17
+
18
+ from ..auto import tqdm as tqdm_auto
19
+ from ..utils import envwrap
20
+ from .utils_worker import MonoWorker
21
+
22
+ __author__ = {"github.com/": ["0x2b3bfa0", "casperdcl"]}
23
+ __all__ = ['SlackIO', 'tqdm_slack', 'tsrange', 'tqdm', 'trange']
24
+
25
+
26
+ class SlackIO(MonoWorker):
27
+ """Non-blocking file-like IO using a Slack app."""
28
+ def __init__(self, token, channel):
29
+ """Creates a new message in the given `channel`."""
30
+ super().__init__()
31
+ self.client = WebClient(token=token)
32
+ self.text = self.__class__.__name__
33
+ try:
34
+ self.message = self.client.chat_postMessage(channel=channel, text=self.text)
35
+ except Exception as e:
36
+ tqdm_auto.write(str(e))
37
+ self.message = None
38
+
39
+ def write(self, s):
40
+ """Replaces internal `message`'s text with `s`."""
41
+ if not s:
42
+ s = "..."
43
+ s = s.replace('\r', '').strip()
44
+ if s == self.text:
45
+ return # skip duplicate message
46
+ message = self.message
47
+ if message is None:
48
+ return
49
+ self.text = s
50
+ try:
51
+ future = self.submit(self.client.chat_update, channel=message['channel'],
52
+ ts=message['ts'], text='`' + s + '`')
53
+ except Exception as e:
54
+ tqdm_auto.write(str(e))
55
+ else:
56
+ return future
57
+
58
+
59
+ class tqdm_slack(tqdm_auto): # pylint: disable=inconsistent-mro
60
+ """
61
+ Standard `tqdm.auto.tqdm` but also sends updates to a Slack app.
62
+ May take a few seconds to create (`__init__`).
63
+
64
+ - create a Slack app with the `chat:write` scope & invite it to a
65
+ channel: <https://api.slack.com/authentication/basics>
66
+ - copy the bot `{token}` & `{channel}` and paste below
67
+ >>> from tqdm.contrib.slack import tqdm, trange
68
+ >>> for i in tqdm(iterable, token='{token}', channel='{channel}'):
69
+ ... ...
70
+ """
71
+ @envwrap("tqdm", "slack", is_method=True)
72
+ def __init__(self, *args, token=None, channel=None, **kwargs):
73
+ """
74
+ Parameters
75
+ ----------
76
+ token : str, required. Slack token
77
+ [default: ${TQDM_SLACK_TOKEN}].
78
+ channel : int, required. Slack channel
79
+ [default: ${TQDM_SLACK_CHANNEL}].
80
+ mininterval : float, optional.
81
+ Minimum of [default: 1.5] to avoid rate limit.
82
+
83
+ See `tqdm.auto.tqdm.__init__` for other parameters.
84
+ """
85
+ if not kwargs.get('disable'):
86
+ kwargs = kwargs.copy()
87
+ logging.getLogger("HTTPClient").setLevel(logging.WARNING)
88
+ self.sio = SlackIO(token, channel)
89
+ kwargs['mininterval'] = max(1.5, kwargs.get('mininterval', 1.5))
90
+ super().__init__(*args, **kwargs)
91
+
92
+ def display(self, **kwargs): # pylint: disable=arguments-differ
93
+ super().display(**kwargs)
94
+ fmt = self.format_dict
95
+ if fmt.get('bar_format', None):
96
+ fmt['bar_format'] = fmt['bar_format'].replace(
97
+ '<bar/>', '`{bar:10}`').replace('{bar}', '`{bar:10u}`')
98
+ elif self.total:
99
+ fmt['bar_format'] = '{l_bar}`{bar:10}`{r_bar}'
100
+ if fmt['ascii'] is False:
101
+ fmt['ascii'] = [":black_square:", ":small_blue_diamond:", ":large_blue_diamond:",
102
+ ":large_blue_square:"]
103
+ fmt['ncols'] = 336
104
+ self.sio.write(self.format_meter(**fmt))
105
+
106
+ def clear(self, *args, **kwargs):
107
+ super().clear(*args, **kwargs)
108
+ if not self.disable:
109
+ self.sio.write("")
110
+
111
+
112
+ def tsrange(*args, **kwargs):
113
+ """Shortcut for `tqdm.contrib.slack.tqdm(range(*args), **kwargs)`."""
114
+ return tqdm_slack(range(*args), **kwargs)
115
+
116
+
117
+ # Aliases
118
+ tqdm = tqdm_slack
119
+ trange = tsrange
.venv/lib/python3.12/site-packages/tqdm/contrib/telegram.py ADDED
@@ -0,0 +1,152 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Sends updates to a Telegram bot.
3
+
4
+ Usage:
5
+ >>> from tqdm.contrib.telegram import tqdm, trange
6
+ >>> for i in trange(10, token='{token}', chat_id='{chat_id}'):
7
+ ... ...
8
+
9
+ ![screenshot](https://tqdm.github.io/img/screenshot-telegram.gif)
10
+ """
11
+ from warnings import warn
12
+
13
+ from requests import Session
14
+
15
+ from ..auto import tqdm as tqdm_auto
16
+ from ..std import TqdmWarning
17
+ from ..utils import envwrap
18
+ from .utils_worker import MonoWorker
19
+
20
+ __author__ = {"github.com/": ["casperdcl"]}
21
+ __all__ = ['TelegramIO', 'tqdm_telegram', 'ttgrange', 'tqdm', 'trange']
22
+
23
+
24
+ class TelegramIO(MonoWorker):
25
+ """Non-blocking file-like IO using a Telegram Bot."""
26
+ API = 'https://api.telegram.org/bot'
27
+
28
+ def __init__(self, token, chat_id):
29
+ """Creates a new message in the given `chat_id`."""
30
+ super().__init__()
31
+ self.token = token
32
+ self.chat_id = chat_id
33
+ self.session = Session()
34
+ self.text = self.__class__.__name__
35
+ self.message_id # pylint: disable=pointless-statement
36
+
37
+ @property
38
+ def message_id(self):
39
+ if hasattr(self, '_message_id'):
40
+ return self._message_id # pylint: disable=access-member-before-definition
41
+ try:
42
+ req = self.session.post(
43
+ f'{self.API}{self.token}/sendMessage',
44
+ data={'text': f"`{self.text}`", 'chat_id': self.chat_id,
45
+ 'parse_mode': 'MarkdownV2'})
46
+ res = req.json()
47
+ req.raise_for_status()
48
+ except Exception as e:
49
+ if req.status_code == 429:
50
+ warn("Creation rate limit: try increasing `mininterval`.",
51
+ TqdmWarning, stacklevel=2)
52
+ else:
53
+ tqdm_auto.write(str(e))
54
+ else:
55
+ self._message_id = res['result']['message_id']
56
+ return self._message_id
57
+
58
+ def write(self, s):
59
+ """Replaces internal `message_id`'s text with `s`."""
60
+ if not s:
61
+ s = "..."
62
+ s = s.replace('\r', '').strip()
63
+ if s == self.text:
64
+ return # avoid duplicate message Bot error
65
+ message_id = self.message_id
66
+ if message_id is None:
67
+ return
68
+ self.text = s
69
+ try:
70
+ future = self.submit(
71
+ self.session.post, f'{self.API}{self.token}/editMessageText',
72
+ data={'text': f"`{s}`", 'chat_id': self.chat_id,
73
+ 'message_id': message_id, 'parse_mode': 'MarkdownV2'})
74
+ except Exception as e:
75
+ tqdm_auto.write(str(e))
76
+ else:
77
+ return future
78
+
79
+ def delete(self):
80
+ """Deletes internal `message_id`."""
81
+ try:
82
+ future = self.submit(
83
+ self.session.post, '{self.API}{self.token}/deleteMessage',
84
+ data={'chat_id': self.chat_id, 'message_id': self.message_id})
85
+ except Exception as e:
86
+ tqdm_auto.write(str(e))
87
+ else:
88
+ return future
89
+
90
+
91
+ class tqdm_telegram(tqdm_auto): # pylint: disable=inconsistent-mro
92
+ """
93
+ Standard `tqdm.auto.tqdm` but also sends updates to a Telegram Bot.
94
+ May take a few seconds to create (`__init__`).
95
+
96
+ - create a bot <https://core.telegram.org/bots#6-botfather>
97
+ - copy its `{token}`
98
+ - add the bot to a chat and send it a message such as `/start`
99
+ - go to <https://api.telegram.org/bot`{token}`/getUpdates> to find out
100
+ the `{chat_id}`
101
+ - paste the `{token}` & `{chat_id}` below
102
+
103
+ >>> from tqdm.contrib.telegram import tqdm, trange
104
+ >>> for i in tqdm(iterable, token='{token}', chat_id='{chat_id}'):
105
+ ... ...
106
+ """
107
+ @envwrap("tqdm", "telegram", is_method=True)
108
+ def __init__(self, *args, token=None, chat_id=None, **kwargs):
109
+ """
110
+ Parameters
111
+ ----------
112
+ token : str, required. Telegram token
113
+ [default: ${TQDM_TELEGRAM_TOKEN}].
114
+ chat_id : str, required. Telegram chat ID
115
+ [default: ${TQDM_TELEGRAM_CHAT_ID}].
116
+
117
+ See `tqdm.auto.tqdm.__init__` for other parameters.
118
+ """
119
+ if not kwargs.get('disable'):
120
+ kwargs = kwargs.copy()
121
+ self.tgio = TelegramIO(token, chat_id)
122
+ super().__init__(*args, **kwargs)
123
+
124
+ def display(self, **kwargs): # pylint: disable=arguments-differ
125
+ super().display(**kwargs)
126
+ fmt = self.format_dict
127
+ if fmt.get('bar_format', None):
128
+ fmt['bar_format'] = fmt['bar_format'].replace(
129
+ '<bar/>', '{bar:10u}').replace('{bar}', '{bar:10u}')
130
+ self.tgio.write(self.format_meter(**fmt))
131
+
132
+ def clear(self, *args, **kwargs):
133
+ super().clear(*args, **kwargs)
134
+ if not self.disable:
135
+ self.tgio.write("")
136
+
137
+ def close(self):
138
+ if self.disable:
139
+ return
140
+ super().close()
141
+ if not (self.leave or (self.leave is None and self.pos == 0)):
142
+ self.tgio.delete()
143
+
144
+
145
+ def ttgrange(*args, **kwargs):
146
+ """Shortcut for `tqdm.contrib.telegram.tqdm(range(*args), **kwargs)`."""
147
+ return tqdm_telegram(range(*args), **kwargs)
148
+
149
+
150
+ # Aliases
151
+ tqdm = tqdm_telegram
152
+ trange = ttgrange
.venv/lib/python3.12/site-packages/tqdm/contrib/utils_worker.py ADDED
@@ -0,0 +1,38 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ IO/concurrency helpers for `tqdm.contrib`.
3
+ """
4
+ from collections import deque
5
+ from concurrent.futures import ThreadPoolExecutor
6
+
7
+ from ..auto import tqdm as tqdm_auto
8
+
9
+ __author__ = {"github.com/": ["casperdcl"]}
10
+ __all__ = ['MonoWorker']
11
+
12
+
13
+ class MonoWorker:
14
+ """
15
+ Supports one running task and one waiting task.
16
+ The waiting task is the most recent submitted (others are discarded).
17
+ """
18
+ def __init__(self):
19
+ self.pool = ThreadPoolExecutor(max_workers=1)
20
+ self.futures = deque([], 2)
21
+
22
+ def submit(self, func, *args, **kwargs):
23
+ """`func(*args, **kwargs)` may replace currently waiting task."""
24
+ futures = self.futures
25
+ if len(futures) == futures.maxlen:
26
+ running = futures.popleft()
27
+ if not running.done():
28
+ if len(futures): # clear waiting
29
+ waiting = futures.pop()
30
+ waiting.cancel()
31
+ futures.appendleft(running) # re-insert running
32
+ try:
33
+ waiting = self.pool.submit(func, *args, **kwargs)
34
+ except Exception as e:
35
+ tqdm_auto.write(str(e))
36
+ else:
37
+ futures.append(waiting)
38
+ return waiting
.venv/lib/python3.12/site-packages/tqdm/dask.py ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from functools import partial
2
+
3
+ from dask.callbacks import Callback
4
+
5
+ from .auto import tqdm as tqdm_auto
6
+
7
+ __author__ = {"github.com/": ["casperdcl"]}
8
+ __all__ = ['TqdmCallback']
9
+
10
+
11
+ class TqdmCallback(Callback):
12
+ """Dask callback for task progress."""
13
+ def __init__(self, start=None, pretask=None, tqdm_class=tqdm_auto,
14
+ **tqdm_kwargs):
15
+ """
16
+ Parameters
17
+ ----------
18
+ tqdm_class : optional
19
+ `tqdm` class to use for bars [default: `tqdm.auto.tqdm`].
20
+ tqdm_kwargs : optional
21
+ Any other arguments used for all bars.
22
+ """
23
+ super().__init__(start=start, pretask=pretask)
24
+ if tqdm_kwargs:
25
+ tqdm_class = partial(tqdm_class, **tqdm_kwargs)
26
+ self.tqdm_class = tqdm_class
27
+
28
+ def _start_state(self, _, state):
29
+ self.pbar = self.tqdm_class(total=sum(
30
+ len(state[k]) for k in ['ready', 'waiting', 'running', 'finished']))
31
+
32
+ def _posttask(self, *_, **__):
33
+ self.pbar.update()
34
+
35
+ def _finish(self, *_, **__):
36
+ self.pbar.close()
37
+
38
+ def display(self):
39
+ """Displays in the current cell in Notebooks."""
40
+ container = getattr(self.bar, 'container', None)
41
+ if container is None:
42
+ return
43
+ from .notebook import display
44
+ display(container)
.venv/lib/python3.12/site-packages/tqdm/gui.py ADDED
@@ -0,0 +1,179 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Matplotlib GUI progress bar decorator for iterators.
3
+
4
+ Usage:
5
+ >>> from tqdm.gui import trange, tqdm
6
+ >>> for i in trange(10):
7
+ ... ...
8
+ """
9
+ # future division is important to divide integers and get as
10
+ # a result precise floating numbers (instead of truncated int)
11
+ import re
12
+ from warnings import warn
13
+
14
+ # to inherit from the tqdm class
15
+ from .std import TqdmExperimentalWarning
16
+ from .std import tqdm as std_tqdm
17
+
18
+ # import compatibility functions and utilities
19
+
20
+ __author__ = {"github.com/": ["casperdcl", "lrq3000"]}
21
+ __all__ = ['tqdm_gui', 'tgrange', 'tqdm', 'trange']
22
+
23
+
24
+ class tqdm_gui(std_tqdm): # pragma: no cover
25
+ """Experimental Matplotlib GUI version of tqdm!"""
26
+ # TODO: @classmethod: write() on GUI?
27
+ def __init__(self, *args, **kwargs):
28
+ from collections import deque
29
+
30
+ import matplotlib as mpl
31
+ import matplotlib.pyplot as plt
32
+ kwargs = kwargs.copy()
33
+ kwargs['gui'] = True
34
+ colour = kwargs.pop('colour', 'g')
35
+ super().__init__(*args, **kwargs)
36
+
37
+ if self.disable:
38
+ return
39
+
40
+ warn("GUI is experimental/alpha", TqdmExperimentalWarning, stacklevel=2)
41
+ self.mpl = mpl
42
+ self.plt = plt
43
+
44
+ # Remember if external environment uses toolbars
45
+ self.toolbar = self.mpl.rcParams['toolbar']
46
+ self.mpl.rcParams['toolbar'] = 'None'
47
+
48
+ self.mininterval = max(self.mininterval, 0.5)
49
+ self.fig, ax = plt.subplots(figsize=(9, 2.2))
50
+ # self.fig.subplots_adjust(bottom=0.2)
51
+ total = self.__len__() # avoids TypeError on None #971
52
+ if total is not None:
53
+ self.xdata = []
54
+ self.ydata = []
55
+ self.zdata = []
56
+ else:
57
+ self.xdata = deque([])
58
+ self.ydata = deque([])
59
+ self.zdata = deque([])
60
+ self.line1, = ax.plot(self.xdata, self.ydata, color='b')
61
+ self.line2, = ax.plot(self.xdata, self.zdata, color='k')
62
+ ax.set_ylim(0, 0.001)
63
+ if total is not None:
64
+ ax.set_xlim(0, 100)
65
+ ax.set_xlabel("percent")
66
+ self.fig.legend((self.line1, self.line2), ("cur", "est"),
67
+ loc='center right')
68
+ # progress bar
69
+ self.hspan = plt.axhspan(0, 0.001, xmin=0, xmax=0, color=colour)
70
+ else:
71
+ # ax.set_xlim(-60, 0)
72
+ ax.set_xlim(0, 60)
73
+ ax.invert_xaxis()
74
+ ax.set_xlabel("seconds")
75
+ ax.legend(("cur", "est"), loc='lower left')
76
+ ax.grid()
77
+ # ax.set_xlabel('seconds')
78
+ ax.set_ylabel((self.unit if self.unit else "it") + "/s")
79
+ if self.unit_scale:
80
+ plt.ticklabel_format(style='sci', axis='y', scilimits=(0, 0))
81
+ ax.yaxis.get_offset_text().set_x(-0.15)
82
+
83
+ # Remember if external environment is interactive
84
+ self.wasion = plt.isinteractive()
85
+ plt.ion()
86
+ self.ax = ax
87
+
88
+ def close(self):
89
+ if self.disable:
90
+ return
91
+
92
+ self.disable = True
93
+
94
+ with self.get_lock():
95
+ self._instances.remove(self)
96
+
97
+ # Restore toolbars
98
+ self.mpl.rcParams['toolbar'] = self.toolbar
99
+ # Return to non-interactive mode
100
+ if not self.wasion:
101
+ self.plt.ioff()
102
+ if self.leave:
103
+ self.display()
104
+ else:
105
+ self.plt.close(self.fig)
106
+
107
+ def clear(self, *_, **__):
108
+ pass
109
+
110
+ def display(self, *_, **__):
111
+ n = self.n
112
+ cur_t = self._time()
113
+ elapsed = cur_t - self.start_t
114
+ delta_it = n - self.last_print_n
115
+ delta_t = cur_t - self.last_print_t
116
+
117
+ # Inline due to multiple calls
118
+ total = self.total
119
+ xdata = self.xdata
120
+ ydata = self.ydata
121
+ zdata = self.zdata
122
+ ax = self.ax
123
+ line1 = self.line1
124
+ line2 = self.line2
125
+ hspan = getattr(self, 'hspan', None)
126
+ # instantaneous rate
127
+ y = delta_it / delta_t
128
+ # overall rate
129
+ z = n / elapsed
130
+ # update line data
131
+ xdata.append(n * 100.0 / total if total else cur_t)
132
+ ydata.append(y)
133
+ zdata.append(z)
134
+
135
+ # Discard old values
136
+ # xmin, xmax = ax.get_xlim()
137
+ # if (not total) and elapsed > xmin * 1.1:
138
+ if (not total) and elapsed > 66:
139
+ xdata.popleft()
140
+ ydata.popleft()
141
+ zdata.popleft()
142
+
143
+ ymin, ymax = ax.get_ylim()
144
+ if y > ymax or z > ymax:
145
+ ymax = 1.1 * y
146
+ ax.set_ylim(ymin, ymax)
147
+ ax.figure.canvas.draw()
148
+
149
+ if total:
150
+ line1.set_data(xdata, ydata)
151
+ line2.set_data(xdata, zdata)
152
+ if hspan:
153
+ hspan.set_xy((0, ymin))
154
+ hspan.set_height(ymax - ymin)
155
+ hspan.set_width(n / total)
156
+ else:
157
+ t_ago = [cur_t - i for i in xdata]
158
+ line1.set_data(t_ago, ydata)
159
+ line2.set_data(t_ago, zdata)
160
+
161
+ d = self.format_dict
162
+ # remove {bar}
163
+ d['bar_format'] = (d['bar_format'] or "{l_bar}<bar/>{r_bar}").replace(
164
+ "{bar}", "<bar/>")
165
+ msg = self.format_meter(**d)
166
+ if '<bar/>' in msg:
167
+ msg = "".join(re.split(r'\|?<bar/>\|?', msg, maxsplit=1))
168
+ ax.set_title(msg, fontname="DejaVu Sans Mono", fontsize=11)
169
+ self.plt.pause(1e-9)
170
+
171
+
172
+ def tgrange(*args, **kwargs):
173
+ """Shortcut for `tqdm.gui.tqdm(range(*args), **kwargs)`."""
174
+ return tqdm_gui(range(*args), **kwargs)
175
+
176
+
177
+ # Aliases
178
+ tqdm = tqdm_gui
179
+ trange = tgrange
.venv/lib/python3.12/site-packages/tqdm/keras.py ADDED
@@ -0,0 +1,123 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from copy import copy
2
+ from functools import partial
3
+
4
+ from .auto import tqdm as tqdm_auto
5
+
6
+ try:
7
+ import keras
8
+ except (ImportError, AttributeError) as e:
9
+ try:
10
+ from tensorflow import keras
11
+ except ImportError:
12
+ raise e
13
+ __author__ = {"github.com/": ["casperdcl"]}
14
+ __all__ = ['TqdmCallback']
15
+
16
+
17
+ class TqdmCallback(keras.callbacks.Callback):
18
+ """Keras callback for epoch and batch progress."""
19
+ @staticmethod
20
+ def bar2callback(bar, pop=None, delta=(lambda logs: 1)):
21
+ def callback(_, logs=None):
22
+ n = delta(logs)
23
+ if logs:
24
+ if pop:
25
+ logs = copy(logs)
26
+ for i in pop:
27
+ logs.pop(i, 0)
28
+ bar.set_postfix(logs, refresh=False)
29
+ bar.update(n)
30
+
31
+ return callback
32
+
33
+ def __init__(self, epochs=None, data_size=None, batch_size=None, verbose=1,
34
+ tqdm_class=tqdm_auto, **tqdm_kwargs):
35
+ """
36
+ Parameters
37
+ ----------
38
+ epochs : int, optional
39
+ data_size : int, optional
40
+ Number of training pairs.
41
+ batch_size : int, optional
42
+ Number of training pairs per batch.
43
+ verbose : int
44
+ 0: epoch, 1: batch (transient), 2: batch. [default: 1].
45
+ Will be set to `0` unless both `data_size` and `batch_size`
46
+ are given.
47
+ tqdm_class : optional
48
+ `tqdm` class to use for bars [default: `tqdm.auto.tqdm`].
49
+ tqdm_kwargs : optional
50
+ Any other arguments used for all bars.
51
+ """
52
+ if tqdm_kwargs:
53
+ tqdm_class = partial(tqdm_class, **tqdm_kwargs)
54
+ self.tqdm_class = tqdm_class
55
+ self.epoch_bar = tqdm_class(total=epochs, unit='epoch')
56
+ self.on_epoch_end = self.bar2callback(self.epoch_bar)
57
+ if data_size and batch_size:
58
+ self.batches = batches = (data_size + batch_size - 1) // batch_size
59
+ else:
60
+ self.batches = batches = None
61
+ self.verbose = verbose
62
+ if verbose == 1:
63
+ self.batch_bar = tqdm_class(total=batches, unit='batch', leave=False)
64
+ self.on_batch_end = self.bar2callback(
65
+ self.batch_bar, pop=['batch', 'size'],
66
+ delta=lambda logs: logs.get('size', 1))
67
+
68
+ def on_train_begin(self, *_, **__):
69
+ params = self.params.get
70
+ auto_total = params('epochs', params('nb_epoch', None))
71
+ if auto_total is not None and auto_total != self.epoch_bar.total:
72
+ self.epoch_bar.reset(total=auto_total)
73
+
74
+ def on_epoch_begin(self, epoch, *_, **__):
75
+ if self.epoch_bar.n < epoch:
76
+ ebar = self.epoch_bar
77
+ ebar.n = ebar.last_print_n = ebar.initial = epoch
78
+ if self.verbose:
79
+ params = self.params.get
80
+ total = params('samples', params(
81
+ 'nb_sample', params('steps', None))) or self.batches
82
+ if self.verbose == 2:
83
+ if hasattr(self, 'batch_bar'):
84
+ self.batch_bar.close()
85
+ self.batch_bar = self.tqdm_class(
86
+ total=total, unit='batch', leave=True,
87
+ unit_scale=1 / (params('batch_size', 1) or 1))
88
+ self.on_batch_end = self.bar2callback(
89
+ self.batch_bar, pop=['batch', 'size'],
90
+ delta=lambda logs: logs.get('size', 1))
91
+ elif self.verbose == 1:
92
+ self.batch_bar.unit_scale = 1 / (params('batch_size', 1) or 1)
93
+ self.batch_bar.reset(total=total)
94
+ else:
95
+ raise KeyError('Unknown verbosity')
96
+
97
+ def on_train_end(self, *_, **__):
98
+ if hasattr(self, 'batch_bar'):
99
+ self.batch_bar.close()
100
+ self.epoch_bar.close()
101
+
102
+ def display(self):
103
+ """Displays in the current cell in Notebooks."""
104
+ container = getattr(self.epoch_bar, 'container', None)
105
+ if container is None:
106
+ return
107
+ from .notebook import display
108
+ display(container)
109
+ batch_bar = getattr(self, 'batch_bar', None)
110
+ if batch_bar is not None:
111
+ display(batch_bar.container)
112
+
113
+ @staticmethod
114
+ def _implements_train_batch_hooks():
115
+ return True
116
+
117
+ @staticmethod
118
+ def _implements_test_batch_hooks():
119
+ return True
120
+
121
+ @staticmethod
122
+ def _implements_predict_batch_hooks():
123
+ return True
.venv/lib/python3.12/site-packages/tqdm/notebook.py ADDED
@@ -0,0 +1,317 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ IPython/Jupyter Notebook progress bar decorator for iterators.
3
+ Includes a default `range` iterator printing to `stderr`.
4
+
5
+ Usage:
6
+ >>> from tqdm.notebook import trange, tqdm
7
+ >>> for i in trange(10):
8
+ ... ...
9
+ """
10
+ # import compatibility functions and utilities
11
+ import re
12
+ import sys
13
+ from html import escape
14
+ from weakref import proxy
15
+
16
+ # to inherit from the tqdm class
17
+ from .std import tqdm as std_tqdm
18
+
19
+ if True: # pragma: no cover
20
+ # import IPython/Jupyter base widget and display utilities
21
+ IPY = 0
22
+ try: # IPython 4.x
23
+ import ipywidgets # noqa: F401, pylint: disable=unused-import
24
+ IPY = 4
25
+ except ImportError: # IPython 3.x / 2.x
26
+ IPY = 32
27
+ import warnings
28
+ with warnings.catch_warnings():
29
+ warnings.filterwarnings(
30
+ 'ignore', message=".*The `IPython.html` package has been deprecated.*")
31
+ try:
32
+ import IPython.html.widgets
33
+ except ImportError:
34
+ pass
35
+ else:
36
+ ipywidgets = IPython.html.widgets
37
+
38
+ try: # IPython 4.x / 3.x
39
+ if IPY == 32:
40
+ from IPython.html.widgets import HTML
41
+ from IPython.html.widgets import FloatProgress as IProgress
42
+ from IPython.html.widgets import HBox
43
+ IPY = 3
44
+ else:
45
+ from ipywidgets import HTML
46
+ from ipywidgets import FloatProgress as IProgress
47
+ from ipywidgets import HBox
48
+ except ImportError:
49
+ try: # IPython 2.x
50
+ from IPython.html.widgets import HTML
51
+ from IPython.html.widgets import ContainerWidget as HBox
52
+ from IPython.html.widgets import FloatProgressWidget as IProgress
53
+ IPY = 2
54
+ except ImportError:
55
+ IPY = 0
56
+ IProgress = None
57
+ HBox = object
58
+
59
+ try:
60
+ from IPython.display import display # , clear_output
61
+ except ImportError:
62
+ pass
63
+
64
+ __author__ = {"github.com/": ["lrq3000", "casperdcl", "alexanderkuk"]}
65
+ __all__ = ['tqdm_notebook', 'tnrange', 'tqdm', 'trange']
66
+ WARN_NOIPYW = ("IProgress not found. Please update jupyter and ipywidgets."
67
+ " See https://ipywidgets.readthedocs.io/en/stable"
68
+ "/user_install.html")
69
+
70
+
71
+ class TqdmHBox(HBox):
72
+ """`ipywidgets.HBox` with a pretty representation"""
73
+ def _json_(self, pretty=None):
74
+ pbar = getattr(self, 'pbar', None)
75
+ if pbar is None:
76
+ return {}
77
+ d = pbar.format_dict
78
+ if pretty is not None:
79
+ d["ascii"] = not pretty
80
+ return d
81
+
82
+ def __repr__(self, pretty=False):
83
+ pbar = getattr(self, 'pbar', None)
84
+ if pbar is None:
85
+ return super().__repr__()
86
+ return pbar.format_meter(**self._json_(pretty))
87
+
88
+ def _repr_pretty_(self, pp, *_, **__):
89
+ pp.text(self.__repr__(True))
90
+
91
+
92
+ class tqdm_notebook(std_tqdm):
93
+ """
94
+ Experimental IPython/Jupyter Notebook widget using tqdm!
95
+ """
96
+ @staticmethod
97
+ def status_printer(_, total=None, desc=None, ncols=None):
98
+ """
99
+ Manage the printing of an IPython/Jupyter Notebook progress bar widget.
100
+ """
101
+ # Fallback to text bar if there's no total
102
+ # DEPRECATED: replaced with an 'info' style bar
103
+ # if not total:
104
+ # return super(tqdm_notebook, tqdm_notebook).status_printer(file)
105
+
106
+ # fp = file
107
+
108
+ # Prepare IPython progress bar
109
+ if IProgress is None: # #187 #451 #558 #872
110
+ raise ImportError(WARN_NOIPYW)
111
+ if total:
112
+ pbar = IProgress(min=0, max=total)
113
+ else: # No total? Show info style bar with no progress tqdm status
114
+ pbar = IProgress(min=0, max=1)
115
+ pbar.value = 1
116
+ pbar.bar_style = 'info'
117
+ if ncols is None:
118
+ pbar.layout.width = "20px"
119
+
120
+ ltext = HTML()
121
+ rtext = HTML()
122
+ if desc:
123
+ ltext.value = desc
124
+ container = TqdmHBox(children=[ltext, pbar, rtext])
125
+ # Prepare layout
126
+ if ncols is not None: # use default style of ipywidgets
127
+ # ncols could be 100, "100px", "100%"
128
+ ncols = str(ncols) # ipywidgets only accepts string
129
+ try:
130
+ if int(ncols) > 0: # isnumeric and positive
131
+ ncols += 'px'
132
+ except ValueError:
133
+ pass
134
+ pbar.layout.flex = '2'
135
+ container.layout.width = ncols
136
+ container.layout.display = 'inline-flex'
137
+ container.layout.flex_flow = 'row wrap'
138
+
139
+ return container
140
+
141
+ def display(self, msg=None, pos=None,
142
+ # additional signals
143
+ close=False, bar_style=None, check_delay=True):
144
+ # Note: contrary to native tqdm, msg='' does NOT clear bar
145
+ # goal is to keep all infos if error happens so user knows
146
+ # at which iteration the loop failed.
147
+
148
+ # Clear previous output (really necessary?)
149
+ # clear_output(wait=1)
150
+
151
+ if not msg and not close:
152
+ d = self.format_dict
153
+ # remove {bar}
154
+ d['bar_format'] = (d['bar_format'] or "{l_bar}<bar/>{r_bar}").replace(
155
+ "{bar}", "<bar/>")
156
+ msg = self.format_meter(**d)
157
+
158
+ ltext, pbar, rtext = self.container.children
159
+ pbar.value = self.n
160
+
161
+ if msg:
162
+ msg = msg.replace(' ', '\u2007') # fix html space padding
163
+ # html escape special characters (like '&')
164
+ if '<bar/>' in msg:
165
+ left, right = map(escape, re.split(r'\|?<bar/>\|?', msg, maxsplit=1))
166
+ else:
167
+ left, right = '', escape(msg)
168
+
169
+ # Update description
170
+ ltext.value = left
171
+ # never clear the bar (signal: msg='')
172
+ if right:
173
+ rtext.value = right
174
+
175
+ # Change bar style
176
+ if bar_style:
177
+ # Hack-ish way to avoid the danger bar_style being overridden by
178
+ # success because the bar gets closed after the error...
179
+ if pbar.bar_style != 'danger' or bar_style != 'success':
180
+ pbar.bar_style = bar_style
181
+
182
+ # Special signal to close the bar
183
+ if close and pbar.bar_style != 'danger': # hide only if no error
184
+ try:
185
+ self.container.close()
186
+ except AttributeError:
187
+ self.container.visible = False
188
+ self.container.layout.visibility = 'hidden' # IPYW>=8
189
+
190
+ if check_delay and self.delay > 0 and not self.displayed:
191
+ display(self.container)
192
+ self.displayed = True
193
+
194
+ @property
195
+ def colour(self):
196
+ if hasattr(self, 'container'):
197
+ return self.container.children[-2].style.bar_color
198
+
199
+ @colour.setter
200
+ def colour(self, bar_color):
201
+ if hasattr(self, 'container'):
202
+ self.container.children[-2].style.bar_color = bar_color
203
+
204
+ def __init__(self, *args, **kwargs):
205
+ """
206
+ Supports the usual `tqdm.tqdm` parameters as well as those listed below.
207
+
208
+ Parameters
209
+ ----------
210
+ display : Whether to call `display(self.container)` immediately
211
+ [default: True].
212
+ """
213
+ kwargs = kwargs.copy()
214
+ # Setup default output
215
+ file_kwarg = kwargs.get('file', sys.stderr)
216
+ if file_kwarg is sys.stderr or file_kwarg is None:
217
+ kwargs['file'] = sys.stdout # avoid the red block in IPython
218
+
219
+ # Initialize parent class + avoid printing by using gui=True
220
+ kwargs['gui'] = True
221
+ # convert disable = None to False
222
+ kwargs['disable'] = bool(kwargs.get('disable', False))
223
+ colour = kwargs.pop('colour', None)
224
+ display_here = kwargs.pop('display', True)
225
+ super().__init__(*args, **kwargs)
226
+ if self.disable or not kwargs['gui']:
227
+ self.disp = lambda *_, **__: None
228
+ return
229
+
230
+ # Get bar width
231
+ self.ncols = '100%' if self.dynamic_ncols else kwargs.get("ncols", None)
232
+
233
+ # Replace with IPython progress bar display (with correct total)
234
+ unit_scale = 1 if self.unit_scale is True else self.unit_scale or 1
235
+ total = self.total * unit_scale if self.total else self.total
236
+ self.container = self.status_printer(self.fp, total, self.desc, self.ncols)
237
+ self.container.pbar = proxy(self)
238
+ self.displayed = False
239
+ if display_here and self.delay <= 0:
240
+ display(self.container)
241
+ self.displayed = True
242
+ self.disp = self.display
243
+ self.colour = colour
244
+
245
+ # Print initial bar state
246
+ if not self.disable:
247
+ self.display(check_delay=False)
248
+
249
+ def __iter__(self):
250
+ try:
251
+ it = super().__iter__()
252
+ yield from it
253
+ # NB: except ... [ as ...] breaks IPython async KeyboardInterrupt
254
+ except: # NOQA
255
+ self.disp(bar_style='danger')
256
+ raise
257
+ # NB: don't `finally: close()`
258
+ # since this could be a shared bar which the user will `reset()`
259
+
260
+ def update(self, n=1):
261
+ try:
262
+ return super().update(n=n)
263
+ # NB: except ... [ as ...] breaks IPython async KeyboardInterrupt
264
+ except: # NOQA
265
+ # cannot catch KeyboardInterrupt when using manual tqdm
266
+ # as the interrupt will most likely happen on another statement
267
+ self.disp(bar_style='danger')
268
+ raise
269
+ # NB: don't `finally: close()`
270
+ # since this could be a shared bar which the user will `reset()`
271
+
272
+ def close(self):
273
+ if self.disable:
274
+ return
275
+ super().close()
276
+ # Try to detect if there was an error or KeyboardInterrupt
277
+ # in manual mode: if n < total, things probably got wrong
278
+ if self.total and self.n < self.total:
279
+ self.disp(bar_style='danger', check_delay=False)
280
+ else:
281
+ if self.leave:
282
+ self.disp(bar_style='success', check_delay=False)
283
+ else:
284
+ self.disp(close=True, check_delay=False)
285
+
286
+ def clear(self, *_, **__):
287
+ pass
288
+
289
+ def reset(self, total=None):
290
+ """
291
+ Resets to 0 iterations for repeated use.
292
+
293
+ Consider combining with `leave=True`.
294
+
295
+ Parameters
296
+ ----------
297
+ total : int or float, optional. Total to use for the new bar.
298
+ """
299
+ if self.disable:
300
+ return super().reset(total=total)
301
+ _, pbar, _ = self.container.children
302
+ pbar.bar_style = ''
303
+ if total is not None:
304
+ pbar.max = total
305
+ if not self.total and self.ncols is None: # no longer unknown total
306
+ pbar.layout.width = None # reset width
307
+ return super().reset(total=total)
308
+
309
+
310
+ def tnrange(*args, **kwargs):
311
+ """Shortcut for `tqdm.notebook.tqdm(range(*args), **kwargs)`."""
312
+ return tqdm_notebook(range(*args), **kwargs)
313
+
314
+
315
+ # Aliases
316
+ tqdm = tqdm_notebook
317
+ trange = tnrange
.venv/lib/python3.12/site-packages/tqdm/rich.py ADDED
@@ -0,0 +1,154 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ `rich.progress` decorator for iterators.
3
+
4
+ Usage:
5
+ >>> from tqdm.rich import trange, tqdm
6
+ >>> for i in trange(10):
7
+ ... ...
8
+ """
9
+ from warnings import warn
10
+
11
+ from rich.progress import (
12
+ BarColumn, Progress, ProgressColumn, Text, TimeElapsedColumn, TimeRemainingColumn, filesize)
13
+
14
+ from .std import TqdmExperimentalWarning
15
+ from .std import tqdm as std_tqdm
16
+
17
+ __author__ = {"github.com/": ["casperdcl"]}
18
+ __all__ = ['tqdm_rich', 'trrange', 'tqdm', 'trange']
19
+
20
+
21
+ class FractionColumn(ProgressColumn):
22
+ """Renders completed/total, e.g. '0.5/2.3 G'."""
23
+ def __init__(self, unit_scale=False, unit_divisor=1000):
24
+ self.unit_scale = unit_scale
25
+ self.unit_divisor = unit_divisor
26
+ super().__init__()
27
+
28
+ def render(self, task):
29
+ """Calculate common unit for completed and total."""
30
+ completed = int(task.completed)
31
+ # total is None when the iterable has no length (e.g. a generator)
32
+ total = int(task.total) if task.total is not None else None
33
+ base = total if total is not None else completed
34
+ if self.unit_scale:
35
+ unit, suffix = filesize.pick_unit_and_suffix(
36
+ base,
37
+ ["", "K", "M", "G", "T", "P", "E", "Z", "Y"],
38
+ self.unit_divisor,
39
+ )
40
+ else:
41
+ unit, suffix = filesize.pick_unit_and_suffix(base, [""], 1)
42
+ precision = 0 if unit == 1 else 1
43
+ total_str = f"{total/unit:,.{precision}f}" if total is not None else "?"
44
+ return Text(
45
+ f"{completed/unit:,.{precision}f}/{total_str} {suffix}",
46
+ style="progress.download")
47
+
48
+
49
+ class RateColumn(ProgressColumn):
50
+ """Renders human readable transfer speed."""
51
+ def __init__(self, unit="", unit_scale=False, unit_divisor=1000):
52
+ self.unit = unit
53
+ self.unit_scale = unit_scale
54
+ self.unit_divisor = unit_divisor
55
+ super().__init__()
56
+
57
+ def render(self, task):
58
+ """Show data transfer speed."""
59
+ speed = task.speed
60
+ if speed is None:
61
+ return Text(f"? {self.unit}/s", style="progress.data.speed")
62
+ if self.unit_scale:
63
+ unit, suffix = filesize.pick_unit_and_suffix(
64
+ speed,
65
+ ["", "K", "M", "G", "T", "P", "E", "Z", "Y"],
66
+ self.unit_divisor,
67
+ )
68
+ else:
69
+ unit, suffix = filesize.pick_unit_and_suffix(speed, [""], 1)
70
+ precision = 0 if unit == 1 else 1
71
+ return Text(f"{speed/unit:,.{precision}f} {suffix}{self.unit}/s",
72
+ style="progress.data.speed")
73
+
74
+
75
+ class tqdm_rich(std_tqdm): # pragma: no cover
76
+ """Experimental rich.progress GUI version of tqdm!"""
77
+ # TODO: @classmethod: write()?
78
+ def __init__(self, *args, **kwargs):
79
+ """
80
+ This class accepts the following parameters *in addition* to
81
+ the parameters accepted by `tqdm`.
82
+
83
+ Parameters
84
+ ----------
85
+ progress : tuple, optional
86
+ arguments for `rich.progress.Progress()`.
87
+ options : dict, optional
88
+ keyword arguments for `rich.progress.Progress()`.
89
+ """
90
+ kwargs = kwargs.copy()
91
+ kwargs['gui'] = True
92
+ # convert disable = None to False
93
+ kwargs['disable'] = bool(kwargs.get('disable', False))
94
+ progress = kwargs.pop('progress', None)
95
+ options = kwargs.pop('options', {}).copy()
96
+ super().__init__(*args, **kwargs)
97
+
98
+ if self.disable:
99
+ return
100
+
101
+ warn("rich is experimental/alpha", TqdmExperimentalWarning, stacklevel=2)
102
+ d = self.format_dict
103
+ if progress is None:
104
+ progress = (
105
+ "[progress.description]{task.description}"
106
+ "[progress.percentage]{task.percentage:>4.0f}%",
107
+ BarColumn(bar_width=None),
108
+ FractionColumn(
109
+ unit_scale=d['unit_scale'], unit_divisor=d['unit_divisor']),
110
+ "[", TimeElapsedColumn(), "<", TimeRemainingColumn(),
111
+ ",", RateColumn(unit=d['unit'], unit_scale=d['unit_scale'],
112
+ unit_divisor=d['unit_divisor']), "]"
113
+ )
114
+ options.setdefault('transient', not self.leave)
115
+ self._prog = Progress(*progress, **options)
116
+ self._prog.__enter__()
117
+ self._task_id = self._prog.add_task(self.desc or "", **d)
118
+
119
+ def close(self):
120
+ if self.disable:
121
+ return
122
+ self.display() # print 100%, vis #1306
123
+ super().close()
124
+ self._prog.__exit__(None, None, None)
125
+
126
+ def clear(self, *_, **__):
127
+ pass
128
+
129
+ def display(self, *_, **__):
130
+ if not hasattr(self, '_task_id'):
131
+ return
132
+ self._prog.update(self._task_id, completed=self.n, description=self.desc)
133
+
134
+ def reset(self, total=None):
135
+ """
136
+ Resets to 0 iterations for repeated use.
137
+
138
+ Parameters
139
+ ----------
140
+ total : int or float, optional. Total to use for the new bar.
141
+ """
142
+ if hasattr(self, '_prog'):
143
+ self._prog.reset(total=total)
144
+ super().reset(total=total)
145
+
146
+
147
+ def trrange(*args, **kwargs):
148
+ """Shortcut for `tqdm.rich.tqdm(range(*args), **kwargs)`."""
149
+ return tqdm_rich(range(*args), **kwargs)
150
+
151
+
152
+ # Aliases
153
+ tqdm = tqdm_rich
154
+ trange = trrange
.venv/lib/python3.12/site-packages/tqdm/std.py ADDED
@@ -0,0 +1,1532 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Customisable progress bar decorator for iterators.
3
+ Includes a default `range` iterator printing to `stderr`.
4
+
5
+ Usage:
6
+ >>> from tqdm import trange, tqdm
7
+ >>> for i in trange(10):
8
+ ... ...
9
+ """
10
+ import sys
11
+ from collections import OrderedDict, defaultdict
12
+ from contextlib import contextmanager
13
+ from datetime import datetime, timedelta, timezone
14
+ from numbers import Number
15
+ from time import time
16
+ from warnings import warn
17
+ from weakref import WeakSet
18
+
19
+ from ._monitor import TMonitor
20
+ from .utils import (
21
+ CallbackIOWrapper, Comparable, DisableOnWriteError, FormatReplace, SimpleTextIOWrapper,
22
+ _is_ascii, _screen_shape_wrapper, _supports_unicode, _term_move_up, disp_len, disp_trim,
23
+ envwrap)
24
+
25
+ __author__ = "https://github.com/tqdm/tqdm#contributions"
26
+ __all__ = ['tqdm', 'trange',
27
+ 'TqdmTypeError', 'TqdmKeyError', 'TqdmWarning',
28
+ 'TqdmExperimentalWarning', 'TqdmDeprecationWarning',
29
+ 'TqdmMonitorWarning']
30
+
31
+
32
+ class TqdmTypeError(TypeError):
33
+ pass
34
+
35
+
36
+ class TqdmKeyError(KeyError):
37
+ pass
38
+
39
+
40
+ class TqdmWarning(Warning):
41
+ """base class for all tqdm warnings.
42
+
43
+ Used for non-external-code-breaking errors, such as garbled printing.
44
+ """
45
+ def __init__(self, msg, fp_write=None): # noqa: B042
46
+ if fp_write is not None:
47
+ fp_write("\n" + self.__class__.__name__ + ": " + str(msg).rstrip() + '\n')
48
+ else:
49
+ super().__init__(msg)
50
+
51
+
52
+ class TqdmExperimentalWarning(TqdmWarning, FutureWarning):
53
+ """beta feature, unstable API and behaviour"""
54
+
55
+
56
+ class TqdmDeprecationWarning(TqdmWarning, DeprecationWarning):
57
+ """may be removed in a future release"""
58
+ # not suppressed if raised
59
+
60
+
61
+ class TqdmMonitorWarning(TqdmWarning, RuntimeWarning):
62
+ """tqdm monitor errors which do not affect external functionality"""
63
+
64
+
65
+ def TRLock(*args, **kwargs):
66
+ """threading RLock"""
67
+ try:
68
+ from threading import RLock
69
+ return RLock(*args, **kwargs)
70
+ except (ImportError, OSError): # pragma: no cover
71
+ pass
72
+
73
+
74
+ class TqdmDefaultWriteLock:
75
+ """
76
+ Provide a default write lock for thread and multiprocessing safety.
77
+ Works only on platforms supporting `fork` (so Windows is excluded).
78
+ You must initialise a `tqdm` or `TqdmDefaultWriteLock` instance
79
+ before forking in order for the write lock to work.
80
+ On Windows, you need to supply the lock from the parent to the children as
81
+ an argument to joblib or the parallelism lib you use.
82
+ """
83
+ # global thread lock so no setup required for multithreading.
84
+ # NB: Do not create multiprocessing lock as it sets the multiprocessing
85
+ # context, disallowing `spawn()`/`forkserver()`
86
+ th_lock = TRLock()
87
+
88
+ def __init__(self):
89
+ # Create global parallelism locks to avoid racing issues with parallel
90
+ # bars works only if fork available (Linux/MacOSX, but not Windows)
91
+ cls = type(self)
92
+ root_lock = cls.th_lock
93
+ if root_lock is not None:
94
+ root_lock.acquire()
95
+ cls.create_mp_lock()
96
+ self.locks = [lk for lk in [cls.mp_lock, cls.th_lock] if lk is not None]
97
+ if root_lock is not None:
98
+ root_lock.release()
99
+
100
+ def acquire(self, *a, **k):
101
+ for lock in self.locks:
102
+ lock.acquire(*a, **k)
103
+
104
+ def release(self):
105
+ for lock in self.locks[::-1]: # Release in inverse order of acquisition
106
+ lock.release()
107
+
108
+ def __enter__(self):
109
+ self.acquire()
110
+
111
+ def __exit__(self, *exc):
112
+ self.release()
113
+
114
+ @classmethod
115
+ def create_mp_lock(cls):
116
+ if not hasattr(cls, 'mp_lock'):
117
+ try:
118
+ from multiprocessing import RLock
119
+ cls.mp_lock = RLock()
120
+ except (ImportError, OSError): # pragma: no cover
121
+ cls.mp_lock = None
122
+
123
+ @classmethod
124
+ def create_th_lock(cls):
125
+ assert hasattr(cls, 'th_lock')
126
+ warn("create_th_lock not needed anymore", TqdmDeprecationWarning, stacklevel=2)
127
+
128
+
129
+ class Bar:
130
+ """
131
+ `str.format`-able bar with format specifiers: `[width][type]`
132
+
133
+ - `width`
134
+ + unspecified (default): use `self.default_len`
135
+ + `int >= 0`: overrides `self.default_len`
136
+ + `int < 0`: subtract from `self.default_len`
137
+ - `type`
138
+ + `a`: ascii (`charset=self.ASCII` override)
139
+ + `u`: unicode (`charset=self.UTF` override)
140
+ + `b`: blank (`charset=" "` override)
141
+ """
142
+ ASCII = " 123456789#"
143
+ UTF = " " + ''.join(map(chr, range(0x258F, 0x2587, -1)))
144
+ BLANK = " "
145
+ COLOUR_RESET = '\x1b[0m'
146
+ COLOUR_RGB = '\x1b[38;2;%d;%d;%dm'
147
+ COLOURS = {'BLACK': '\x1b[30m', 'RED': '\x1b[31m', 'GREEN': '\x1b[32m',
148
+ 'YELLOW': '\x1b[33m', 'BLUE': '\x1b[34m', 'MAGENTA': '\x1b[35m',
149
+ 'CYAN': '\x1b[36m', 'WHITE': '\x1b[37m'}
150
+
151
+ def __init__(self, frac, default_len=10, charset=UTF, colour=None):
152
+ if not 0 <= frac <= 1:
153
+ warn("clamping frac to range [0, 1]", TqdmWarning, stacklevel=2)
154
+ frac = max(0, min(1, frac))
155
+ assert default_len > 0
156
+ self.frac = frac
157
+ self.default_len = default_len
158
+ self.charset = charset
159
+ self.colour = colour
160
+
161
+ @property
162
+ def colour(self):
163
+ return self._colour
164
+
165
+ @colour.setter
166
+ def colour(self, value):
167
+ if not value:
168
+ self._colour = None
169
+ return
170
+ try:
171
+ if value.upper() in self.COLOURS:
172
+ self._colour = self.COLOURS[value.upper()]
173
+ elif value[0] == '#' and len(value) == 7:
174
+ self._colour = self.COLOUR_RGB % tuple(
175
+ int(i, 16) for i in (value[1:3], value[3:5], value[5:7]))
176
+ else:
177
+ raise KeyError
178
+ except (KeyError, AttributeError):
179
+ warn(f"Unknown colour ({value}); valid choices:"
180
+ f" [hex (#00ff00), {', '.join(self.COLOURS)}]", TqdmWarning, stacklevel=2)
181
+ self._colour = None
182
+
183
+ def __format__(self, format_spec):
184
+ if format_spec:
185
+ _type = format_spec[-1].lower()
186
+ try:
187
+ charset = {'a': self.ASCII, 'u': self.UTF, 'b': self.BLANK}[_type]
188
+ except KeyError:
189
+ charset = self.charset
190
+ else:
191
+ format_spec = format_spec[:-1]
192
+ if format_spec:
193
+ N_BARS = int(format_spec)
194
+ if N_BARS < 0:
195
+ N_BARS += self.default_len
196
+ else:
197
+ N_BARS = self.default_len
198
+ else:
199
+ charset = self.charset
200
+ N_BARS = self.default_len
201
+
202
+ nsyms = len(charset) - 1
203
+ bar_length, frac_bar_length = divmod(int(self.frac * N_BARS * nsyms), nsyms)
204
+
205
+ res = charset[-1] * bar_length
206
+ if bar_length < N_BARS: # whitespace padding
207
+ res = res + charset[frac_bar_length] + charset[0] * (N_BARS - bar_length - 1)
208
+ return self.colour + res + self.COLOUR_RESET if self.colour else res
209
+
210
+
211
+ class EMA:
212
+ """
213
+ Exponential moving average: smoothing to give progressively lower
214
+ weights to older values.
215
+
216
+ Parameters
217
+ ----------
218
+ smoothing : float, optional
219
+ Smoothing factor in range [0, 1], [default: 0.3].
220
+ Increase to give more weight to recent values.
221
+ Ranges from 0 (yields old value) to 1 (yields new value).
222
+ """
223
+ def __init__(self, smoothing=0.3):
224
+ self.alpha = smoothing
225
+ self.last = 0
226
+ self.calls = 0
227
+
228
+ def __call__(self, x=None):
229
+ """
230
+ Parameters
231
+ ----------
232
+ x : float
233
+ New value to include in EMA.
234
+ """
235
+ beta = 1 - self.alpha
236
+ if x is not None:
237
+ self.last = self.alpha * x + beta * self.last
238
+ self.calls += 1
239
+ return self.last / (1 - beta ** self.calls) if self.calls else self.last
240
+
241
+
242
+ class tqdm(Comparable):
243
+ """
244
+ Decorate an iterable object, returning an iterator which acts exactly
245
+ like the original iterable, but prints a dynamically updating
246
+ progress bar every time a value is requested.
247
+
248
+ Parameters
249
+ ----------
250
+ iterable : iterable, optional
251
+ Iterable to decorate with a progress bar.
252
+ Leave blank to manually manage the updates.
253
+ desc : str, optional
254
+ Prefix for the progress bar.
255
+ total : int or float, optional
256
+ The number of expected iterations. If unspecified,
257
+ len(iterable) is used if possible. If float("inf") or as a last
258
+ resort, only basic progress statistics are displayed
259
+ (no ETA, no progress bar).
260
+ If `gui` is True and this parameter needs subsequent updating,
261
+ specify an initial arbitrary large positive number,
262
+ e.g. 9e9.
263
+ leave : bool, optional
264
+ If [default: True], keeps all traces of the progress bar
265
+ upon termination of iteration.
266
+ If `None`, will leave only if `position` is `0`.
267
+ file : `io.TextIOWrapper` or `io.StringIO`, optional
268
+ Specifies where to output the progress messages
269
+ (default: sys.stderr). Uses `file.write(str)` and `file.flush()`
270
+ methods. For encoding, see `write_bytes`.
271
+ ncols : int, optional
272
+ The width of the entire output message. If specified,
273
+ dynamically resizes the progress bar to stay within this bound.
274
+ If unspecified, attempts to use environment width. The
275
+ fallback is a meter width of 10 and no limit for the counter and
276
+ statistics. If 0, will not print any meter (only stats).
277
+ mininterval : float, optional
278
+ Minimum progress display update interval [default: 0.1] seconds.
279
+ maxinterval : float, optional
280
+ Maximum progress display update interval [default: 10] seconds.
281
+ Automatically adjusts `miniters` to correspond to `mininterval`
282
+ after long display update lag. Only works if `dynamic_miniters`
283
+ or monitor thread is enabled.
284
+ miniters : int or float, optional
285
+ Minimum progress display update interval, in iterations.
286
+ If 0 and `dynamic_miniters`, will automatically adjust to equal
287
+ `mininterval` (more CPU efficient, good for tight loops).
288
+ If > 0, will skip display of specified number of iterations.
289
+ Tweak this and `mininterval` to get very efficient loops.
290
+ If your progress is erratic with both fast and slow iterations
291
+ (network, skipping items, etc) you should set miniters=1.
292
+ ascii : bool or str, optional
293
+ If unspecified or False, use unicode (smooth blocks) to fill
294
+ the meter. The fallback is to use ASCII characters " 123456789#".
295
+ disable : bool, optional
296
+ Whether to disable the entire progress bar wrapper
297
+ [default: False]. If set to None, disable on non-TTY.
298
+ unit : str, optional
299
+ String that will be used to define the unit of each iteration
300
+ [default: it].
301
+ unit_scale : bool or int or float, optional
302
+ If 1 or True, the number of iterations will be reduced/scaled
303
+ automatically and a metric prefix following the
304
+ International System of Units standard will be added
305
+ (kilo, mega, etc.) [default: False]. If any other non-zero
306
+ number, will scale `total` and `n`.
307
+ dynamic_ncols : bool, optional
308
+ If set, constantly alters `ncols` and `nrows` to the
309
+ environment (allowing for window resizes) [default: False].
310
+ smoothing : float, optional
311
+ Exponential moving average smoothing factor for speed estimates
312
+ (ignored in GUI mode). Ranges from 0 (average speed) to 1
313
+ (current/instantaneous speed) [default: 0.3].
314
+ bar_format : str, optional
315
+ Specify a custom bar string formatting. May impact performance.
316
+ [default: '{l_bar}{bar}{r_bar}'], where
317
+ l_bar='{desc}: {percentage:3.0f}%|' and
318
+ r_bar='| {n_fmt}/{total_fmt} [{elapsed}<{remaining}, '
319
+ '{rate_fmt}{postfix}]'
320
+ Possible vars: l_bar, bar, r_bar, n, n_fmt, total, total_fmt,
321
+ percentage, elapsed, elapsed_s, ncols, nrows, desc, unit,
322
+ rate, rate_fmt, rate_noinv, rate_noinv_fmt,
323
+ rate_inv, rate_inv_fmt, postfix, unit_divisor,
324
+ remaining, remaining_s, eta.
325
+ Note that a trailing ": " is automatically removed after {desc}
326
+ if the latter is empty.
327
+ initial : int or float, optional
328
+ The initial counter value. Useful when restarting a progress
329
+ bar [default: 0]. If using float, consider specifying `{n:.3f}`
330
+ or similar in `bar_format`, or specifying `unit_scale`.
331
+ position : int, optional
332
+ Specify the line offset to print this bar (starting from 0)
333
+ Automatic if unspecified.
334
+ Useful to manage multiple bars at once (eg, from threads).
335
+ postfix : dict or *, optional
336
+ Specify additional stats to display at the end of the bar.
337
+ Calls `set_postfix(**postfix)` if possible (dict).
338
+ unit_divisor : float, optional
339
+ [default: 1000], ignored unless `unit_scale` is True.
340
+ write_bytes : bool, optional
341
+ Whether to write bytes. If (default: False) will write unicode.
342
+ lock_args : tuple, optional
343
+ Passed to `refresh` for intermediate output
344
+ (initialisation, iterating, and updating).
345
+ nrows : int, optional
346
+ The screen height. If specified, hides nested bars outside this
347
+ bound. If unspecified, attempts to use environment height.
348
+ The fallback is 20.
349
+ colour : str, optional
350
+ Bar colour (e.g. 'green', '#00ff00').
351
+ delay : float, optional
352
+ Don't display until [default: 0] seconds have elapsed.
353
+ gui : bool, optional
354
+ WARNING: internal parameter - do not use.
355
+ Use tqdm.gui.tqdm(...) instead. If set, will attempt to use
356
+ matplotlib animations for a graphical output [default: False].
357
+
358
+ Returns
359
+ -------
360
+ out : decorated iterator.
361
+ """
362
+
363
+ monitor_interval = 10 # set to 0 to disable the thread
364
+ monitor = None
365
+ _instances = WeakSet()
366
+
367
+ @staticmethod
368
+ def format_sizeof(num, suffix='', divisor=1000):
369
+ """
370
+ Formats a number (greater than unity) with SI Order of Magnitude
371
+ prefixes.
372
+
373
+ Parameters
374
+ ----------
375
+ num : float
376
+ Number ( >= 1) to format.
377
+ suffix : str, optional
378
+ Post-postfix [default: ''].
379
+ divisor : float, optional
380
+ Divisor between prefixes [default: 1000].
381
+
382
+ Returns
383
+ -------
384
+ out : str
385
+ Number with Order of Magnitude SI unit postfix.
386
+ """
387
+ for unit in ['', 'k', 'M', 'G', 'T', 'P', 'E', 'Z']:
388
+ if abs(num) < 999.5:
389
+ if abs(num) < 99.95:
390
+ if abs(num) < 9.995:
391
+ return f'{num:1.2f}{unit}{suffix}'
392
+ return f'{num:2.1f}{unit}{suffix}'
393
+ return f'{num:3.0f}{unit}{suffix}'
394
+ num /= divisor
395
+ return f'{num:3.1f}Y{suffix}'
396
+
397
+ @staticmethod
398
+ def format_interval(t):
399
+ """
400
+ Formats a number of seconds as a clock time, [H:]MM:SS
401
+
402
+ Parameters
403
+ ----------
404
+ t : int
405
+ Number of seconds.
406
+
407
+ Returns
408
+ -------
409
+ out : str
410
+ [H:]MM:SS
411
+ """
412
+ sign = '-' if t < 0 else ''
413
+ mins, s = divmod(abs(int(t)), 60)
414
+ h, m = divmod(mins, 60)
415
+ return f'{sign}{h:d}:{m:02d}:{s:02d}' if h else f'{sign}{m:02d}:{s:02d}'
416
+
417
+ @staticmethod
418
+ def format_num(n):
419
+ """
420
+ Intelligent scientific notation (.3g).
421
+
422
+ Parameters
423
+ ----------
424
+ n : int or float or Numeric
425
+ A Number.
426
+
427
+ Returns
428
+ -------
429
+ out : str
430
+ Formatted number.
431
+ """
432
+ f = f'{n:.3g}'.replace('e+0', 'e+').replace('e-0', 'e-')
433
+ n = str(n)
434
+ return f if len(f) < len(n) else n
435
+
436
+ @staticmethod
437
+ def status_printer(file):
438
+ """
439
+ Manage the printing and in-place updating of a line of characters.
440
+ Note that if the string is longer than a line, then in-place
441
+ updating may not work (it will print a new line at each refresh).
442
+ """
443
+ fp = file
444
+ fp_flush = getattr(fp, 'flush', lambda: None) # pragma: no cover
445
+ if fp in (sys.stderr, sys.stdout):
446
+ getattr(sys.stderr, 'flush', lambda: None)()
447
+ getattr(sys.stdout, 'flush', lambda: None)()
448
+
449
+ def fp_write(s):
450
+ fp.write(str(s))
451
+ fp_flush()
452
+
453
+ last_len = [0]
454
+
455
+ def print_status(s):
456
+ len_s = disp_len(s)
457
+ fp_write('\r' + s + (' ' * max(last_len[0] - len_s, 0)))
458
+ last_len[0] = len_s
459
+
460
+ return print_status
461
+
462
+ @staticmethod
463
+ def format_meter(n, total, elapsed, ncols=None, prefix='',
464
+ ascii=False, # pylint: disable=redefined-builtin
465
+ unit='it', unit_scale=False, rate=None, bar_format=None, postfix=None,
466
+ unit_divisor=1000, initial=0, colour=None, **extra_kwargs):
467
+ """
468
+ Return a string-based progress bar given some parameters
469
+
470
+ Parameters
471
+ ----------
472
+ n : int or float
473
+ Number of finished iterations.
474
+ total : int or float
475
+ The expected total number of iterations. If meaningless (None),
476
+ only basic progress statistics are displayed (no ETA).
477
+ elapsed : float
478
+ Number of seconds passed since start.
479
+ ncols : int, optional
480
+ The width of the entire output message. If specified,
481
+ dynamically resizes `{bar}` to stay within this bound
482
+ [default: None]. If `0`, will not print any bar (only stats).
483
+ The fallback is `{bar:10}`.
484
+ prefix : str, optional
485
+ Prefix message (included in total width) [default: ''].
486
+ Use as {desc} in bar_format string.
487
+ ascii : bool, optional or str, optional
488
+ If not set, use unicode (smooth blocks) to fill the meter
489
+ [default: False]. The fallback is to use ASCII characters
490
+ " 123456789#".
491
+ unit : str, optional
492
+ The iteration unit [default: 'it'].
493
+ unit_scale : bool or int or float, optional
494
+ If 1 or True, the number of iterations will be printed with an
495
+ appropriate SI metric prefix (k = 10^3, M = 10^6, etc.)
496
+ [default: False]. If any other non-zero number, will scale
497
+ `total` and `n`.
498
+ rate : float, optional
499
+ Manual override for iteration rate.
500
+ If [default: None], uses n/elapsed.
501
+ bar_format : str, optional
502
+ Specify a custom bar string formatting. May impact performance.
503
+ [default: '{l_bar}{bar}{r_bar}'], where
504
+ l_bar='{desc}: {percentage:3.0f}%|' and
505
+ r_bar='| {n_fmt}/{total_fmt} [{elapsed}<{remaining}, '
506
+ '{rate_fmt}{postfix}]'
507
+ Possible vars: l_bar, bar, r_bar, n, n_fmt, total, total_fmt,
508
+ percentage, elapsed, elapsed_s, ncols, nrows, desc, unit,
509
+ rate, rate_fmt, rate_noinv, rate_noinv_fmt,
510
+ rate_inv, rate_inv_fmt, postfix, unit_divisor,
511
+ remaining, remaining_s, eta.
512
+ Note that a trailing ": " is automatically removed after {desc}
513
+ if the latter is empty.
514
+ postfix : *, optional
515
+ Similar to `prefix`, but placed at the end
516
+ (e.g. for additional stats).
517
+ Note: postfix is usually a string (not a dict) for this method,
518
+ and will if possible be set to postfix = ', ' + postfix.
519
+ However other types are supported (#382).
520
+ unit_divisor : float, optional
521
+ [default: 1000], ignored unless `unit_scale` is True.
522
+ initial : int or float, optional
523
+ The initial counter value [default: 0].
524
+ colour : str, optional
525
+ Bar colour (e.g. 'green', '#00ff00').
526
+
527
+ Returns
528
+ -------
529
+ out : Formatted meter and stats, ready to display.
530
+ """
531
+
532
+ # sanity check: total
533
+ if total and (n >= (total + 0.5) or total == float("inf")):
534
+ # allow float imprecision (#849) or inf (#651)
535
+ total = None
536
+
537
+ # apply custom scale if necessary
538
+ if unit_scale and unit_scale not in (True, 1):
539
+ if total:
540
+ total *= unit_scale
541
+ n *= unit_scale
542
+ if rate:
543
+ rate *= unit_scale # by default rate = self.avg_dn / self.avg_dt
544
+ unit_scale = False
545
+
546
+ elapsed_str = tqdm.format_interval(elapsed)
547
+
548
+ # if unspecified, attempt to use rate = average speed
549
+ # (we allow manual override since predicting time is an arcane art)
550
+ if rate is None and elapsed:
551
+ rate = (n - initial) / elapsed
552
+ inv_rate = 1 / rate if rate else None
553
+ format_sizeof = tqdm.format_sizeof
554
+ rate_noinv_fmt = ((format_sizeof(rate) if unit_scale else f'{rate:5.2f}')
555
+ if rate else '?') + unit + '/s'
556
+ rate_inv_fmt = (
557
+ (format_sizeof(inv_rate) if unit_scale else f'{inv_rate:5.2f}')
558
+ if inv_rate else '?') + 's/' + unit
559
+ rate_fmt = rate_inv_fmt if inv_rate and inv_rate > 1 else rate_noinv_fmt
560
+
561
+ if unit_scale:
562
+ n_fmt = format_sizeof(n, divisor=unit_divisor)
563
+ total_fmt = format_sizeof(total, divisor=unit_divisor) if total is not None else '?'
564
+ else:
565
+ n_fmt = str(n)
566
+ total_fmt = str(total) if total is not None else '?'
567
+
568
+ try:
569
+ postfix = ', ' + postfix if postfix else ''
570
+ except TypeError:
571
+ pass
572
+
573
+ remaining = (total - n) / rate if rate and total else 0
574
+ remaining_str = tqdm.format_interval(remaining) if rate else '?'
575
+ try:
576
+ eta_dt = (datetime.now() + timedelta(seconds=remaining)
577
+ if rate and total else datetime.fromtimestamp(0, timezone.utc))
578
+ except OverflowError:
579
+ eta_dt = datetime.max
580
+
581
+ # format the stats displayed to the left and right sides of the bar
582
+ if prefix:
583
+ # old prefix setup work around
584
+ bool_prefix_colon_already = (prefix[-2:] == ": ")
585
+ l_bar = prefix if bool_prefix_colon_already else prefix + ": "
586
+ else:
587
+ l_bar = ''
588
+
589
+ r_bar = f'| {n_fmt}/{total_fmt} [{elapsed_str}<{remaining_str}, {rate_fmt}{postfix}]'
590
+
591
+ # Custom bar formatting
592
+ # Populate a dict with all available progress indicators
593
+ format_dict = {
594
+ # slight extension of self.format_dict
595
+ 'n': n, 'n_fmt': n_fmt, 'total': total, 'total_fmt': total_fmt,
596
+ 'elapsed': elapsed_str, 'elapsed_s': elapsed,
597
+ 'ncols': ncols, 'desc': prefix or '', 'unit': unit,
598
+ 'rate': inv_rate if inv_rate and inv_rate > 1 else rate,
599
+ 'rate_fmt': rate_fmt, 'rate_noinv': rate,
600
+ 'rate_noinv_fmt': rate_noinv_fmt, 'rate_inv': inv_rate,
601
+ 'rate_inv_fmt': rate_inv_fmt,
602
+ 'postfix': postfix, 'unit_divisor': unit_divisor,
603
+ 'colour': colour,
604
+ # plus more useful definitions
605
+ 'remaining': remaining_str, 'remaining_s': remaining,
606
+ 'l_bar': l_bar, 'r_bar': r_bar, 'eta': eta_dt,
607
+ **extra_kwargs}
608
+
609
+ # total is known: we can predict some stats
610
+ if total:
611
+ # fractional and percentage progress
612
+ frac = n / total
613
+ percentage = frac * 100
614
+
615
+ l_bar += f'{percentage:3.0f}%|'
616
+
617
+ if ncols == 0:
618
+ return l_bar[:-1] + r_bar[1:]
619
+
620
+ format_dict.update(l_bar=l_bar)
621
+ if bar_format:
622
+ format_dict.update(percentage=percentage)
623
+
624
+ # auto-remove colon for empty `{desc}`
625
+ if not prefix:
626
+ bar_format = bar_format.replace("{desc}: ", '')
627
+ else:
628
+ bar_format = "{l_bar}{bar}{r_bar}"
629
+
630
+ full_bar = FormatReplace()
631
+ nobar = bar_format.format(bar=full_bar, **format_dict) # no `{bar}`
632
+ if not full_bar.format_called:
633
+ return disp_trim(nobar, ncols) if ncols else nobar
634
+
635
+ # Formatting progress bar space available for bar's display
636
+ full_bar = Bar(frac,
637
+ max(1, ncols - disp_len(nobar)) if ncols else 10,
638
+ charset=Bar.ASCII if ascii is True else ascii or Bar.UTF,
639
+ colour=colour)
640
+ if not _is_ascii(full_bar.charset) and _is_ascii(bar_format):
641
+ bar_format = str(bar_format)
642
+ res = bar_format.format(bar=full_bar, **format_dict)
643
+ return disp_trim(res, ncols) if ncols else res
644
+
645
+ elif bar_format:
646
+ # user-specified bar_format but no total
647
+ l_bar += '|'
648
+ format_dict.update(l_bar=l_bar, percentage=0)
649
+ full_bar = FormatReplace()
650
+ nobar = bar_format.format(bar=full_bar, **format_dict)
651
+ if not full_bar.format_called:
652
+ return disp_trim(nobar, ncols) if ncols else nobar
653
+ full_bar = Bar(0,
654
+ max(1, ncols - disp_len(nobar)) if ncols else 10,
655
+ charset=Bar.BLANK, colour=colour)
656
+ res = bar_format.format(bar=full_bar, **format_dict)
657
+ return disp_trim(res, ncols) if ncols else res
658
+ else:
659
+ # no total: no bar & ETA, just progress stats
660
+ res = (f'{(prefix + ": ") if prefix else ""}'
661
+ f'{n_fmt}{unit} [{elapsed_str}, {rate_fmt}{postfix}]')
662
+ return disp_trim(res, ncols) if ncols else res
663
+
664
+ def __new__(cls, *_, **__):
665
+ instance = object.__new__(cls)
666
+ with cls.get_lock(): # also constructs lock if non-existent
667
+ cls._instances.add(instance)
668
+ # create monitoring thread
669
+ if cls.monitor_interval and (cls.monitor is None
670
+ or not cls.monitor.report()):
671
+ try:
672
+ cls.monitor = TMonitor(cls, cls.monitor_interval)
673
+ except Exception as e: # pragma: nocover
674
+ warn("tqdm:disabling monitor support"
675
+ " (monitor_interval = 0) due to:\n" + str(e),
676
+ TqdmMonitorWarning, stacklevel=2)
677
+ cls.monitor_interval = 0
678
+ return instance
679
+
680
+ @classmethod
681
+ def _get_free_pos(cls, instance=None):
682
+ """Skips specified instance."""
683
+ positions = {abs(inst.pos) for inst in cls._instances
684
+ if inst is not instance and hasattr(inst, "pos")}
685
+ return min(set(range(len(positions) + 1)).difference(positions))
686
+
687
+ @classmethod
688
+ def _decr_instances(cls, instance):
689
+ """
690
+ Remove from list and reposition another unfixed bar
691
+ to fill the new gap.
692
+
693
+ This means that by default (where all nested bars are unfixed),
694
+ order is not maintained but screen flicker/blank space is minimised.
695
+ (tqdm<=4.44.1 moved ALL subsequent unfixed bars up.)
696
+ """
697
+ with cls._lock:
698
+ try:
699
+ cls._instances.remove(instance)
700
+ except KeyError:
701
+ # if not instance.gui: # pragma: no cover
702
+ # raise
703
+ pass # py2: maybe magically removed already
704
+ # else:
705
+ if not instance.gui:
706
+ last = (instance.nrows or 20) - 1
707
+ # find unfixed (`pos >= 0`) overflow (`pos >= nrows - 1`)
708
+ instances = list(filter(
709
+ lambda i: hasattr(i, "pos") and last <= i.pos,
710
+ cls._instances))
711
+ # set first found to current `pos`
712
+ if instances:
713
+ inst = min(instances, key=lambda i: i.pos)
714
+ inst.clear(nolock=True)
715
+ inst.pos = abs(instance.pos)
716
+
717
+ @classmethod
718
+ def write(cls, s, file=None, end="\n", nolock=False):
719
+ """Print a message via tqdm (without overlap with bars)."""
720
+ fp = file if file is not None else sys.stdout
721
+ if fp is None:
722
+ return
723
+ with cls.external_write_mode(file=file, nolock=nolock):
724
+ # Write the message
725
+ fp.write(s)
726
+ fp.write(end)
727
+
728
+ @classmethod
729
+ @contextmanager
730
+ def external_write_mode(cls, file=None, nolock=False):
731
+ """
732
+ Disable tqdm within context and refresh tqdm when exits.
733
+ Useful when writing to standard output stream
734
+ """
735
+ fp = file if file is not None else sys.stdout
736
+ if fp is None:
737
+ yield
738
+ return
739
+
740
+ try:
741
+ if not nolock:
742
+ cls.get_lock().acquire()
743
+ # Clear all bars
744
+ inst_cleared = []
745
+ for inst in getattr(cls, '_instances', []):
746
+ # Clear instance if in the target output file
747
+ # or if write output + tqdm output are both either
748
+ # sys.stdout or sys.stderr (because both are mixed in terminal)
749
+ if hasattr(inst, "start_t") and (inst.fp == fp or all(
750
+ f in (sys.stdout, sys.stderr) for f in (fp, inst.fp))):
751
+ inst.clear(nolock=True)
752
+ inst_cleared.append(inst)
753
+ yield
754
+ # Force refresh display of bars we cleared
755
+ for inst in inst_cleared:
756
+ inst.refresh(nolock=True)
757
+ finally:
758
+ if not nolock:
759
+ cls._lock.release()
760
+
761
+ @classmethod
762
+ def set_lock(cls, lock):
763
+ """Set the global lock."""
764
+ cls._lock = lock
765
+
766
+ @classmethod
767
+ def get_lock(cls):
768
+ """Get the global lock. Construct it if it does not exist."""
769
+ if not hasattr(cls, '_lock'):
770
+ cls._lock = TqdmDefaultWriteLock()
771
+ return cls._lock
772
+
773
+ @classmethod
774
+ def pandas(cls, **tqdm_kwargs):
775
+ """
776
+ Registers the current `tqdm` class with
777
+ pandas.core.
778
+ ( frame.DataFrame
779
+ | series.Series
780
+ | groupby.(generic.)DataFrameGroupBy
781
+ | groupby.(generic.)SeriesGroupBy
782
+ ).progress_apply
783
+
784
+ A new instance will be created every time `progress_apply` is called,
785
+ and each instance will automatically `close()` upon completion.
786
+
787
+ Parameters
788
+ ----------
789
+ tqdm_kwargs : arguments for the tqdm instance
790
+
791
+ Examples
792
+ --------
793
+ >>> import pandas as pd
794
+ >>> import numpy as np
795
+ >>> from tqdm import tqdm
796
+ >>> from tqdm.gui import tqdm as tqdm_gui
797
+ >>>
798
+ >>> df = pd.DataFrame(np.random.randint(0, 100, (100000, 6)))
799
+ >>> tqdm.pandas(ncols=50) # can use tqdm_gui, optional kwargs, etc
800
+ >>> # Now you can use `progress_apply` instead of `apply`
801
+ >>> df.groupby(0).progress_apply(lambda x: x**2)
802
+
803
+ References
804
+ ----------
805
+ <https://stackoverflow.com/questions/18603270/\
806
+ progress-indicator-during-pandas-operations-python>
807
+ """
808
+ from warnings import catch_warnings, simplefilter
809
+
810
+ from pandas.core.frame import DataFrame
811
+ from pandas.core.series import Series
812
+ try:
813
+ with catch_warnings():
814
+ simplefilter("ignore", category=FutureWarning)
815
+ from pandas import Panel
816
+ except ImportError: # pandas>=1.2.0
817
+ Panel = None
818
+ Rolling, Expanding = None, None
819
+ try: # pandas>=1.0.0
820
+ from pandas.core.window.rolling import _Rolling_and_Expanding
821
+ except ImportError:
822
+ try: # pandas>=0.18.0
823
+ from pandas.core.window import _Rolling_and_Expanding
824
+ except ImportError: # pandas>=1.2.0
825
+ try: # pandas>=1.2.0
826
+ from pandas.core.window.expanding import Expanding
827
+ from pandas.core.window.rolling import Rolling
828
+ _Rolling_and_Expanding = Rolling, Expanding
829
+ except ImportError: # pragma: no cover
830
+ _Rolling_and_Expanding = None
831
+ try: # pandas>=0.25.0
832
+ from pandas.core.groupby.generic import SeriesGroupBy # , NDFrameGroupBy
833
+ from pandas.core.groupby.generic import DataFrameGroupBy
834
+ except ImportError: # pragma: no cover
835
+ try: # pandas>=0.23.0
836
+ from pandas.core.groupby.groupby import DataFrameGroupBy, SeriesGroupBy
837
+ except ImportError:
838
+ from pandas.core.groupby import DataFrameGroupBy, SeriesGroupBy
839
+ try: # pandas>=0.23.0
840
+ from pandas.core.groupby.groupby import GroupBy
841
+ except ImportError: # pragma: no cover
842
+ from pandas.core.groupby import GroupBy
843
+
844
+ try: # pandas>=0.23.0
845
+ from pandas.core.groupby.groupby import PanelGroupBy
846
+ except ImportError:
847
+ try:
848
+ from pandas.core.groupby import PanelGroupBy
849
+ except ImportError: # pandas>=0.25.0
850
+ PanelGroupBy = None
851
+
852
+ tqdm_kwargs = tqdm_kwargs.copy()
853
+ deprecated_t = [tqdm_kwargs.pop('deprecated_t', None)]
854
+
855
+ def inner_generator(df_function='apply'):
856
+ def inner(df, func, *args, **kwargs):
857
+ """
858
+ Parameters
859
+ ----------
860
+ df : (DataFrame|Series)[GroupBy]
861
+ Data (may be grouped).
862
+ func : function
863
+ To be applied on the (grouped) data.
864
+ **kwargs : optional
865
+ Transmitted to `df.apply()`.
866
+ """
867
+
868
+ # Precompute total iterations
869
+ total = tqdm_kwargs.pop("total", getattr(df, 'ngroups', None))
870
+ if total is None: # not grouped
871
+ if df_function == 'applymap':
872
+ total = df.size
873
+ elif isinstance(df, Series):
874
+ total = len(df)
875
+ elif (_Rolling_and_Expanding is None or
876
+ not isinstance(df, _Rolling_and_Expanding)):
877
+ # DataFrame or Panel
878
+ axis = kwargs.get('axis', 0)
879
+ if axis == 'index':
880
+ axis = 0
881
+ elif axis == 'columns':
882
+ axis = 1
883
+ # when axis=0, total is shape[axis1]
884
+ total = df.size // df.shape[axis]
885
+
886
+ # Init bar
887
+ if deprecated_t[0] is not None:
888
+ t = deprecated_t[0]
889
+ deprecated_t[0] = None
890
+ else:
891
+ t = cls(total=total, **tqdm_kwargs)
892
+
893
+ if len(args) > 0:
894
+ # *args intentionally not supported (see #244, #299)
895
+ TqdmDeprecationWarning(
896
+ "Except func, normal arguments are intentionally" +
897
+ " not supported by" +
898
+ " `(DataFrame|Series|GroupBy).progress_apply`." +
899
+ " Use keyword arguments instead.",
900
+ fp_write=getattr(t.fp, 'write', sys.stderr.write))
901
+
902
+ try: # pandas>=1.3.0,<3.0
903
+ from pandas.core.common import is_builtin_func
904
+ except ImportError: # pandas<1.3.0
905
+ is_builtin_func = getattr(df, '_is_builtin_func', lambda f: f)
906
+ try:
907
+ func = is_builtin_func(func)
908
+ except TypeError:
909
+ pass
910
+
911
+ # Define bar updating wrapper
912
+ def wrapper(*args, **kwargs):
913
+ # update tbar correctly
914
+ # it seems `pandas apply` calls `func` twice
915
+ # on the first column/row to decide whether it can
916
+ # take a fast or slow code path; so stop when t.total==t.n
917
+ t.update(n=1 if not t.total or t.n < t.total else 0)
918
+ return func(*args, **kwargs)
919
+
920
+ # Apply the provided function (in **kwargs)
921
+ # on the df using our wrapper (which provides bar updating)
922
+ try:
923
+ return getattr(df, df_function)(wrapper, **kwargs)
924
+ finally:
925
+ t.close()
926
+
927
+ return inner
928
+
929
+ # Monkeypatch pandas to provide easy methods
930
+ # Enable custom tqdm progress in pandas!
931
+ Series.progress_apply = inner_generator()
932
+ SeriesGroupBy.progress_apply = inner_generator()
933
+ Series.progress_map = inner_generator('map')
934
+ SeriesGroupBy.progress_map = inner_generator('map')
935
+
936
+ DataFrame.progress_apply = inner_generator()
937
+ DataFrameGroupBy.progress_apply = inner_generator()
938
+ DataFrame.progress_applymap = inner_generator('applymap')
939
+ DataFrame.progress_map = inner_generator('map')
940
+ DataFrameGroupBy.progress_map = inner_generator('map')
941
+
942
+ if Panel is not None:
943
+ Panel.progress_apply = inner_generator()
944
+ if PanelGroupBy is not None:
945
+ PanelGroupBy.progress_apply = inner_generator()
946
+
947
+ GroupBy.progress_apply = inner_generator()
948
+ GroupBy.progress_aggregate = inner_generator('aggregate')
949
+ GroupBy.progress_transform = inner_generator('transform')
950
+
951
+ if Rolling is not None and Expanding is not None:
952
+ Rolling.progress_apply = inner_generator()
953
+ Expanding.progress_apply = inner_generator()
954
+ elif _Rolling_and_Expanding is not None:
955
+ _Rolling_and_Expanding.progress_apply = inner_generator()
956
+
957
+ # override defaults via env vars
958
+ @envwrap("tqdm", is_method=True, types={'total': float, 'ncols': int, 'miniters': float,
959
+ 'position': int, 'nrows': int})
960
+ def __init__(self, iterable=None, desc=None, total=None, leave=True, file=None,
961
+ ncols=None, mininterval=0.1, maxinterval=10.0, miniters=None,
962
+ ascii=None, # pylint: disable=redefined-builtin
963
+ disable=False, unit='it', unit_scale=False, dynamic_ncols=False, smoothing=0.3,
964
+ bar_format=None, initial=0, position=None, postfix=None, unit_divisor=1000,
965
+ write_bytes=False, lock_args=None, nrows=None, colour=None, delay=0.0, gui=False,
966
+ **kwargs):
967
+ """see tqdm.tqdm for arguments"""
968
+ if file is None:
969
+ file = sys.stderr
970
+
971
+ if write_bytes:
972
+ # Despite coercing unicode into bytes, py2 sys.std* streams
973
+ # should have bytes written to them.
974
+ file = SimpleTextIOWrapper(
975
+ file, encoding=getattr(file, 'encoding', None) or 'utf-8')
976
+
977
+ file = DisableOnWriteError(file, tqdm_instance=self)
978
+
979
+ if disable is None and hasattr(file, "isatty") and not file.isatty():
980
+ disable = True
981
+
982
+ if total is None and iterable is not None:
983
+ try:
984
+ total = len(iterable)
985
+ except (TypeError, AttributeError):
986
+ total = None
987
+ if total == float("inf"):
988
+ total = None # same as unknown
989
+
990
+ if disable:
991
+ self.iterable = iterable
992
+ self.disable = disable
993
+ with self._lock:
994
+ self.pos = self._get_free_pos(self)
995
+ self._instances.remove(self)
996
+ self.n = initial
997
+ self.total = total
998
+ self.leave = leave
999
+ return
1000
+
1001
+ if kwargs:
1002
+ self.disable = True
1003
+ with self._lock:
1004
+ self.pos = self._get_free_pos(self)
1005
+ self._instances.remove(self)
1006
+ raise (
1007
+ TqdmDeprecationWarning(
1008
+ "`nested` is deprecated and automated.\n"
1009
+ "Use `position` instead for manual control.\n",
1010
+ fp_write=getattr(file, 'write', sys.stderr.write))
1011
+ if "nested" in kwargs else
1012
+ TqdmKeyError("Unknown argument(s): " + str(kwargs)))
1013
+
1014
+ # Preprocess the arguments
1015
+ if (
1016
+ (ncols is None or nrows is None) and (file in (sys.stderr, sys.stdout))
1017
+ ) or dynamic_ncols: # pragma: no cover
1018
+ if dynamic_ncols:
1019
+ dynamic_ncols = _screen_shape_wrapper()
1020
+ if dynamic_ncols:
1021
+ ncols, nrows = dynamic_ncols(file)
1022
+ else:
1023
+ _dynamic_ncols = _screen_shape_wrapper()
1024
+ if _dynamic_ncols:
1025
+ _ncols, _nrows = _dynamic_ncols(file)
1026
+ if ncols is None:
1027
+ ncols = _ncols
1028
+ if nrows is None:
1029
+ nrows = _nrows
1030
+
1031
+ if miniters is None:
1032
+ miniters = 0
1033
+ dynamic_miniters = True
1034
+ else:
1035
+ dynamic_miniters = False
1036
+
1037
+ if mininterval is None:
1038
+ mininterval = 0
1039
+
1040
+ if maxinterval is None:
1041
+ maxinterval = 0
1042
+
1043
+ if ascii is None:
1044
+ ascii = not _supports_unicode(file)
1045
+
1046
+ if bar_format and ascii is not True and not _is_ascii(ascii):
1047
+ # Convert bar format into unicode since terminal uses unicode
1048
+ bar_format = str(bar_format)
1049
+
1050
+ if smoothing is None:
1051
+ smoothing = 0
1052
+
1053
+ # Store the arguments
1054
+ self.iterable = iterable
1055
+ self.desc = desc or ''
1056
+ self.total = total
1057
+ self.leave = leave
1058
+ self.fp = file
1059
+ self.ncols = ncols
1060
+ self.nrows = nrows
1061
+ self.mininterval = mininterval
1062
+ self.maxinterval = maxinterval
1063
+ self.miniters = miniters
1064
+ self.dynamic_miniters = dynamic_miniters
1065
+ self.ascii = ascii
1066
+ self.disable = disable
1067
+ self.unit = unit
1068
+ self.unit_scale = unit_scale
1069
+ self.unit_divisor = unit_divisor
1070
+ self.initial = initial
1071
+ self.lock_args = lock_args
1072
+ self.delay = delay
1073
+ self.gui = gui
1074
+ self.dynamic_ncols = dynamic_ncols
1075
+ self.smoothing = smoothing
1076
+ self._ema_dn = EMA(smoothing)
1077
+ self._ema_dt = EMA(smoothing)
1078
+ self._ema_miniters = EMA(smoothing)
1079
+ self.bar_format = bar_format
1080
+ self.postfix = None
1081
+ self.colour = colour
1082
+ self._time = time
1083
+ if postfix:
1084
+ try:
1085
+ self.set_postfix(refresh=False, **postfix)
1086
+ except TypeError:
1087
+ self.postfix = postfix
1088
+
1089
+ # Init the iterations counters
1090
+ self.last_print_n = initial
1091
+ self.n = initial
1092
+
1093
+ # if nested, at initial sp() call we replace '\r' by '\n' to
1094
+ # not overwrite the outer progress bar
1095
+ with self._lock:
1096
+ # mark fixed positions as negative
1097
+ self.pos = self._get_free_pos(self) if position is None else -position
1098
+
1099
+ if not gui:
1100
+ # Initialize the screen printer
1101
+ self.sp = self.status_printer(self.fp)
1102
+ if delay <= 0:
1103
+ self.refresh(lock_args=self.lock_args)
1104
+
1105
+ # Init the time counter
1106
+ self.last_print_t = self._time()
1107
+ # NB: Avoid race conditions by setting start_t at the very end of init
1108
+ self.start_t = self.last_print_t
1109
+
1110
+ def __bool__(self):
1111
+ if self.total is not None:
1112
+ return self.total > 0
1113
+ if self.iterable is None:
1114
+ raise TypeError('bool() undefined when iterable == total == None')
1115
+ return bool(self.iterable)
1116
+
1117
+ def __len__(self):
1118
+ return (
1119
+ self.total if self.iterable is None
1120
+ else self.iterable.shape[0] if hasattr(self.iterable, "shape")
1121
+ else len(self.iterable) if hasattr(self.iterable, "__len__")
1122
+ else self.iterable.__length_hint__() if hasattr(self.iterable, "__length_hint__")
1123
+ else getattr(self, "total", None))
1124
+
1125
+ def __reversed__(self):
1126
+ try:
1127
+ orig = self.iterable
1128
+ except AttributeError:
1129
+ raise TypeError("'tqdm' object is not reversible")
1130
+ else:
1131
+ self.iterable = reversed(self.iterable)
1132
+ return self.__iter__()
1133
+ finally:
1134
+ self.iterable = orig
1135
+
1136
+ def __contains__(self, item):
1137
+ contains = getattr(self.iterable, '__contains__', None)
1138
+ return (contains(item) if contains is not None # pylint: disable=not-callable
1139
+ else item in self.__iter__())
1140
+
1141
+ def __enter__(self):
1142
+ return self
1143
+
1144
+ def __exit__(self, exc_type, exc_value, traceback):
1145
+ try:
1146
+ self.close()
1147
+ except AttributeError:
1148
+ # maybe eager thread cleanup upon external error
1149
+ if (exc_type, exc_value, traceback) == (None, None, None):
1150
+ raise
1151
+ warn("AttributeError ignored", TqdmWarning, stacklevel=2)
1152
+
1153
+ def __del__(self):
1154
+ self.close()
1155
+
1156
+ def __str__(self):
1157
+ return self.format_meter(**self.format_dict)
1158
+
1159
+ @property
1160
+ def _comparable(self):
1161
+ return abs(getattr(self, "pos", 1 << 31))
1162
+
1163
+ def __hash__(self):
1164
+ return id(self)
1165
+
1166
+ def __iter__(self):
1167
+ """Backward-compatibility to use: for x in tqdm(iterable)"""
1168
+
1169
+ # Inlining instance variables as locals (speed optimisation)
1170
+ iterable = self.iterable
1171
+
1172
+ # If the bar is disabled, then just walk the iterable
1173
+ # (note: keep this check outside the loop for performance)
1174
+ if self.disable:
1175
+ yield from iterable
1176
+ return
1177
+
1178
+ mininterval = self.mininterval
1179
+ last_print_t = self.last_print_t
1180
+ last_print_n = self.last_print_n
1181
+ min_start_t = self.start_t + self.delay
1182
+ n = self.n
1183
+ time = self._time
1184
+
1185
+ try:
1186
+ for obj in iterable:
1187
+ yield obj
1188
+ # Update and possibly print the progress bar.
1189
+ # Note: does not call self.update(1) for speed optimisation.
1190
+ n += 1
1191
+
1192
+ if n - last_print_n >= self.miniters:
1193
+ cur_t = time()
1194
+ dt = cur_t - last_print_t
1195
+ if dt >= mininterval and cur_t >= min_start_t:
1196
+ self.update(n - last_print_n)
1197
+ last_print_n = self.last_print_n
1198
+ last_print_t = self.last_print_t
1199
+ finally:
1200
+ self.n = n
1201
+ self.close()
1202
+
1203
+ def update(self, n=1):
1204
+ """
1205
+ Manually update the progress bar, useful for streams
1206
+ such as reading files.
1207
+ E.g.:
1208
+ >>> t = tqdm(total=filesize) # Initialise
1209
+ >>> for current_buffer in stream:
1210
+ ... ...
1211
+ ... t.update(len(current_buffer))
1212
+ >>> t.close()
1213
+ The last line is highly recommended, but possibly not necessary if
1214
+ `t.update()` will be called in such a way that `filesize` will be
1215
+ exactly reached and printed.
1216
+
1217
+ Parameters
1218
+ ----------
1219
+ n : int or float, optional
1220
+ Increment to add to the internal counter of iterations
1221
+ [default: 1]. If using float, consider specifying `{n:.3f}`
1222
+ or similar in `bar_format`, or specifying `unit_scale`.
1223
+
1224
+ Returns
1225
+ -------
1226
+ out : bool or None
1227
+ True if a `display()` was triggered.
1228
+ """
1229
+ if self.disable:
1230
+ return
1231
+
1232
+ if n < 0:
1233
+ self.last_print_n += n # for auto-refresh logic to work
1234
+ self.n += n
1235
+
1236
+ # check counter first to reduce calls to time()
1237
+ if self.n - self.last_print_n >= self.miniters:
1238
+ cur_t = self._time()
1239
+ dt = cur_t - self.last_print_t
1240
+ if dt >= self.mininterval and cur_t >= self.start_t + self.delay:
1241
+ cur_t = self._time()
1242
+ dn = self.n - self.last_print_n # >= n
1243
+ if self.smoothing and dt and dn:
1244
+ # EMA (not just overall average)
1245
+ self._ema_dn(dn)
1246
+ self._ema_dt(dt)
1247
+ self.refresh(lock_args=self.lock_args)
1248
+ if self.dynamic_miniters:
1249
+ # If no `miniters` was specified, adjust automatically to the
1250
+ # maximum iteration rate seen so far between two prints.
1251
+ # e.g.: After running `tqdm.update(5)`, subsequent
1252
+ # calls to `tqdm.update()` will only cause an update after
1253
+ # at least 5 more iterations.
1254
+ if self.maxinterval and dt >= self.maxinterval:
1255
+ self.miniters = dn * (self.mininterval or self.maxinterval) / dt
1256
+ elif self.smoothing:
1257
+ # EMA miniters update
1258
+ self.miniters = self._ema_miniters(
1259
+ dn * (self.mininterval / dt if self.mininterval and dt
1260
+ else 1))
1261
+ else:
1262
+ # max iters between two prints
1263
+ self.miniters = max(self.miniters, dn)
1264
+
1265
+ # Store old values for next call
1266
+ self.last_print_n = self.n
1267
+ self.last_print_t = cur_t
1268
+ return True
1269
+
1270
+ def close(self):
1271
+ """Cleanup and (if leave=False) close the progress bar."""
1272
+ if getattr(self, 'disable', True):
1273
+ return
1274
+
1275
+ # Prevent multiple closures
1276
+ self.disable = True
1277
+
1278
+ # decrement instance pos and remove from internal set
1279
+ pos = abs(self.pos)
1280
+ self._decr_instances(self)
1281
+
1282
+ if not hasattr(self, 'last_print_t'):
1283
+ return
1284
+ if self.last_print_t < self.start_t + self.delay:
1285
+ # haven't ever displayed; nothing to clear
1286
+ return
1287
+
1288
+ # GUI mode
1289
+ if getattr(self, 'sp', None) is None:
1290
+ return
1291
+
1292
+ # annoyingly, _supports_unicode isn't good enough
1293
+ def fp_write(s):
1294
+ self.fp.write(str(s))
1295
+
1296
+ try:
1297
+ fp_write('')
1298
+ except ValueError as e:
1299
+ if 'closed' in str(e):
1300
+ return
1301
+ raise # pragma: no cover
1302
+
1303
+ leave = pos == 0 if self.leave is None else self.leave
1304
+
1305
+ with self._lock:
1306
+ if leave:
1307
+ # stats for overall rate (no weighted average)
1308
+ self._ema_dt = lambda: None
1309
+ self.display(pos=0)
1310
+ fp_write('\n')
1311
+ else:
1312
+ # clear previous display
1313
+ if self.display(msg='', pos=pos) and not pos:
1314
+ fp_write('\r')
1315
+
1316
+ def clear(self, nolock=False):
1317
+ """Clear current bar display."""
1318
+ if self.disable:
1319
+ return
1320
+
1321
+ if not nolock:
1322
+ self._lock.acquire()
1323
+ pos = abs(self.pos)
1324
+ if pos < (self.nrows or 20):
1325
+ self.moveto(pos)
1326
+ self.sp('')
1327
+ self.fp.write('\r') # place cursor back at the beginning of line
1328
+ self.moveto(-pos)
1329
+ if not nolock:
1330
+ self._lock.release()
1331
+
1332
+ def refresh(self, nolock=False, lock_args=None):
1333
+ """
1334
+ Force refresh the display of this bar.
1335
+
1336
+ Parameters
1337
+ ----------
1338
+ nolock : bool, optional
1339
+ If `True`, does not lock.
1340
+ If [default: `False`]: calls `acquire()` on internal lock.
1341
+ lock_args : tuple, optional
1342
+ Passed to internal lock's `acquire()`.
1343
+ If specified, will only `display()` if `acquire()` returns `True`.
1344
+ """
1345
+ if self.disable:
1346
+ return
1347
+
1348
+ if not nolock:
1349
+ if lock_args:
1350
+ if not self._lock.acquire(*lock_args):
1351
+ return False
1352
+ else:
1353
+ self._lock.acquire()
1354
+ self.display()
1355
+ if not nolock:
1356
+ self._lock.release()
1357
+ return True
1358
+
1359
+ def unpause(self):
1360
+ """Restart tqdm timer from last print time."""
1361
+ if self.disable:
1362
+ return
1363
+ cur_t = self._time()
1364
+ self.start_t += cur_t - self.last_print_t
1365
+ self.last_print_t = cur_t
1366
+
1367
+ def reset(self, total=None):
1368
+ """
1369
+ Resets to 0 iterations for repeated use.
1370
+
1371
+ Consider combining with `leave=True`.
1372
+
1373
+ Parameters
1374
+ ----------
1375
+ total : int or float, optional. Total to use for the new bar.
1376
+ """
1377
+ self.n = 0
1378
+ if total is not None:
1379
+ self.total = None if total == float("inf") else total
1380
+ if self.disable:
1381
+ return
1382
+ self.last_print_n = 0
1383
+ self.last_print_t = self.start_t = self._time()
1384
+ self._ema_dn = EMA(self.smoothing)
1385
+ self._ema_dt = EMA(self.smoothing)
1386
+ self._ema_miniters = EMA(self.smoothing)
1387
+ self.refresh()
1388
+
1389
+ def set_description(self, desc=None, refresh=True):
1390
+ """
1391
+ Set/modify description of the progress bar.
1392
+
1393
+ Parameters
1394
+ ----------
1395
+ desc : str, optional
1396
+ refresh : bool, optional
1397
+ Forces refresh [default: True].
1398
+ """
1399
+ self.desc = desc + ': ' if desc else ''
1400
+ if refresh:
1401
+ self.refresh()
1402
+
1403
+ def set_description_str(self, desc=None, refresh=True):
1404
+ """Set/modify description without ': ' appended."""
1405
+ self.desc = desc or ''
1406
+ if refresh:
1407
+ self.refresh()
1408
+
1409
+ def set_postfix(self, ordered_dict=None, refresh=True, **kwargs):
1410
+ """
1411
+ Set/modify postfix (additional stats)
1412
+ with automatic formatting based on datatype.
1413
+
1414
+ Parameters
1415
+ ----------
1416
+ ordered_dict : dict or OrderedDict, optional
1417
+ refresh : bool, optional
1418
+ Forces refresh [default: True].
1419
+ kwargs : dict, optional
1420
+ """
1421
+ # Sort in alphabetical order to be more deterministic
1422
+ postfix = OrderedDict([] if ordered_dict is None else ordered_dict)
1423
+ for key in sorted(kwargs.keys()):
1424
+ postfix[key] = kwargs[key]
1425
+ # Preprocess stats according to datatype
1426
+ for key in postfix.keys():
1427
+ # Number: limit the length of the string
1428
+ if isinstance(postfix[key], Number):
1429
+ postfix[key] = self.format_num(postfix[key])
1430
+ # Else for any other type, try to get the string conversion
1431
+ elif not isinstance(postfix[key], str):
1432
+ postfix[key] = str(postfix[key])
1433
+ # Else if it's a string, don't need to preprocess anything
1434
+ # Stitch together to get the final postfix
1435
+ self.postfix = ', '.join(key + '=' + postfix[key].strip()
1436
+ for key in postfix.keys())
1437
+ if refresh:
1438
+ self.refresh()
1439
+
1440
+ def set_postfix_str(self, s='', refresh=True):
1441
+ """
1442
+ Postfix without dictionary expansion, similar to prefix handling.
1443
+ """
1444
+ self.postfix = str(s)
1445
+ if refresh:
1446
+ self.refresh()
1447
+
1448
+ def moveto(self, n):
1449
+ # TODO: private method
1450
+ self.fp.write('\n' * n + _term_move_up() * -n)
1451
+ getattr(self.fp, 'flush', lambda: None)()
1452
+
1453
+ @property
1454
+ def format_dict(self):
1455
+ """Public API for read-only member access."""
1456
+ if self.disable and not hasattr(self, 'unit'):
1457
+ return defaultdict(lambda: None, {
1458
+ 'n': self.n, 'total': self.total, 'elapsed': 0, 'unit': 'it'})
1459
+ if self.dynamic_ncols:
1460
+ self.ncols, self.nrows = self.dynamic_ncols(self.fp)
1461
+ return {
1462
+ 'n': self.n, 'total': self.total,
1463
+ 'elapsed': self._time() - self.start_t if hasattr(self, 'start_t') else 0,
1464
+ 'ncols': self.ncols, 'nrows': self.nrows, 'prefix': self.desc,
1465
+ 'ascii': self.ascii, 'unit': self.unit, 'unit_scale': self.unit_scale,
1466
+ 'rate': self._ema_dn() / self._ema_dt() if self._ema_dt() else None,
1467
+ 'bar_format': self.bar_format, 'postfix': self.postfix,
1468
+ 'unit_divisor': self.unit_divisor, 'initial': self.initial,
1469
+ 'colour': self.colour}
1470
+
1471
+ def display(self, msg=None, pos=None):
1472
+ """
1473
+ Use `self.sp` to display `msg` in the specified `pos`.
1474
+
1475
+ Consider overloading this function when inheriting to use e.g.:
1476
+ `self.some_frontend(**self.format_dict)` instead of `self.sp`.
1477
+
1478
+ Parameters
1479
+ ----------
1480
+ msg : str, optional. What to display (default: `repr(self)`).
1481
+ pos : int, optional. Position to `moveto`
1482
+ (default: `abs(self.pos)`).
1483
+ """
1484
+ if pos is None:
1485
+ pos = abs(self.pos)
1486
+
1487
+ nrows = self.nrows or 20
1488
+ if pos >= nrows - 1:
1489
+ if pos >= nrows:
1490
+ return False
1491
+ if msg or msg is None: # override at `nrows - 1`
1492
+ msg = " ... (more hidden) ..."
1493
+
1494
+ if not hasattr(self, "sp"):
1495
+ raise TqdmDeprecationWarning(
1496
+ "Please use `tqdm.gui.tqdm(...)`"
1497
+ " instead of `tqdm(..., gui=True)`\n",
1498
+ fp_write=getattr(self.fp, 'write', sys.stderr.write))
1499
+
1500
+ if pos:
1501
+ self.moveto(pos)
1502
+ self.sp(self.__str__() if msg is None else msg)
1503
+ if pos:
1504
+ self.moveto(-pos)
1505
+ return True
1506
+
1507
+ @classmethod
1508
+ @contextmanager
1509
+ def wrapattr(cls, stream, method, total=None, bytes=True, # pylint: disable=redefined-builtin
1510
+ **tqdm_kwargs):
1511
+ """
1512
+ stream : file-like object.
1513
+ method : str, "read" or "write". The result of `read()` and
1514
+ the first argument of `write()` should have a `len()`.
1515
+
1516
+ >>> with tqdm.wrapattr(file_obj, "read", total=file_obj.size) as fobj:
1517
+ ... while True:
1518
+ ... chunk = fobj.read(chunk_size)
1519
+ ... if not chunk:
1520
+ ... break
1521
+ """
1522
+ with cls(total=total, **tqdm_kwargs) as t:
1523
+ if bytes:
1524
+ t.unit = "B"
1525
+ t.unit_scale = True
1526
+ t.unit_divisor = 1024
1527
+ yield CallbackIOWrapper(t.update, stream, method)
1528
+
1529
+
1530
+ def trange(*args, **kwargs):
1531
+ """Shortcut for tqdm(range(*args), **kwargs)."""
1532
+ return tqdm(range(*args), **kwargs)
.venv/lib/python3.12/site-packages/tqdm/tk.py ADDED
@@ -0,0 +1,196 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ Tkinter GUI progress bar decorator for iterators.
3
+
4
+ Usage:
5
+ >>> from tqdm.tk import trange, tqdm
6
+ >>> for i in trange(10):
7
+ ... ...
8
+ """
9
+ import re
10
+ import sys
11
+ import tkinter
12
+ import tkinter.ttk as ttk
13
+ from warnings import warn
14
+
15
+ from .std import TqdmExperimentalWarning, TqdmWarning
16
+ from .std import tqdm as std_tqdm
17
+
18
+ __author__ = {"github.com/": ["richardsheridan", "casperdcl"]}
19
+ __all__ = ['tqdm_tk', 'ttkrange', 'tqdm', 'trange']
20
+
21
+
22
+ class tqdm_tk(std_tqdm): # pragma: no cover
23
+ """
24
+ Experimental Tkinter GUI version of tqdm!
25
+
26
+ Note: Window interactivity suffers if `tqdm_tk` is not running within
27
+ a Tkinter mainloop and values are generated infrequently. In this case,
28
+ consider calling `tqdm_tk.refresh()` frequently in the Tk thread.
29
+ """
30
+
31
+ # TODO: @classmethod: write()?
32
+
33
+ def __init__(self, *args, **kwargs):
34
+ """
35
+ This class accepts the following parameters *in addition* to
36
+ the parameters accepted by `tqdm`.
37
+
38
+ Parameters
39
+ ----------
40
+ grab : bool, optional
41
+ Grab the input across all windows of the process.
42
+ tk_parent : `tkinter.Wm`, optional
43
+ Parent Tk window.
44
+ cancel_callback : Callable, optional
45
+ Create a cancel button and set `cancel_callback` to be called
46
+ when the cancel or window close button is clicked.
47
+ """
48
+ kwargs = kwargs.copy()
49
+ kwargs['gui'] = True
50
+ # convert disable = None to False
51
+ kwargs['disable'] = bool(kwargs.get('disable', False))
52
+ self._warn_leave = 'leave' in kwargs
53
+ grab = kwargs.pop('grab', False)
54
+ tk_parent = kwargs.pop('tk_parent', None)
55
+ self._cancel_callback = kwargs.pop('cancel_callback', None)
56
+ super().__init__(*args, **kwargs)
57
+
58
+ if self.disable:
59
+ return
60
+
61
+ if tk_parent is None: # Discover parent widget
62
+ try:
63
+ tk_parent = tkinter._default_root
64
+ except AttributeError:
65
+ raise AttributeError(
66
+ "`tk_parent` required when using `tkinter.NoDefaultRoot()`")
67
+ if tk_parent is None: # use new default root window as display
68
+ self._tk_window = tkinter.Tk()
69
+ else: # some other windows already exist
70
+ self._tk_window = tkinter.Toplevel()
71
+ else:
72
+ self._tk_window = tkinter.Toplevel(tk_parent)
73
+
74
+ warn("GUI is experimental/alpha", TqdmExperimentalWarning, stacklevel=2)
75
+ self._tk_dispatching = self._tk_dispatching_helper()
76
+
77
+ self._tk_window.protocol("WM_DELETE_WINDOW", self.cancel)
78
+ self._tk_window.wm_title(self.desc)
79
+ self._tk_window.wm_attributes("-topmost", 1)
80
+ self._tk_window.after(0, lambda: self._tk_window.wm_attributes("-topmost", 0))
81
+ self._tk_n_var = tkinter.DoubleVar(self._tk_window, value=0)
82
+ self._tk_text_var = tkinter.StringVar(self._tk_window)
83
+ pbar_frame = ttk.Frame(self._tk_window, padding=5)
84
+ pbar_frame.pack()
85
+ _tk_label = ttk.Label(pbar_frame, textvariable=self._tk_text_var,
86
+ wraplength=600, anchor="center", justify="center")
87
+ _tk_label.pack()
88
+ self._tk_pbar = ttk.Progressbar(
89
+ pbar_frame, variable=self._tk_n_var, length=450)
90
+ if self.total is not None:
91
+ self._tk_pbar.configure(maximum=self.total)
92
+ else:
93
+ self._tk_pbar.configure(mode="indeterminate")
94
+ self._tk_pbar.pack()
95
+ if self._cancel_callback is not None:
96
+ _tk_button = ttk.Button(pbar_frame, text="Cancel", command=self.cancel)
97
+ _tk_button.pack()
98
+ if grab:
99
+ self._tk_window.grab_set()
100
+
101
+ def close(self):
102
+ if self.disable:
103
+ return
104
+
105
+ self.disable = True
106
+
107
+ with self.get_lock():
108
+ self._instances.remove(self)
109
+
110
+ def _close():
111
+ self._tk_window.after('idle', self._tk_window.destroy)
112
+ if not self._tk_dispatching:
113
+ self._tk_window.update()
114
+
115
+ self._tk_window.protocol("WM_DELETE_WINDOW", _close)
116
+
117
+ # if leave is set but we are self-dispatching, the left window is
118
+ # totally unresponsive unless the user manually dispatches
119
+ if not self.leave:
120
+ _close()
121
+ elif not self._tk_dispatching:
122
+ if self._warn_leave:
123
+ warn("leave flag ignored if not in tkinter mainloop",
124
+ TqdmWarning, stacklevel=2)
125
+ _close()
126
+
127
+ def clear(self, *_, **__):
128
+ pass
129
+
130
+ def display(self, *_, **__):
131
+ self._tk_n_var.set(self.n)
132
+ d = self.format_dict
133
+ # remove {bar}
134
+ d['bar_format'] = (d['bar_format'] or "{l_bar}<bar/>{r_bar}").replace(
135
+ "{bar}", "<bar/>")
136
+ msg = self.format_meter(**d)
137
+ if '<bar/>' in msg:
138
+ msg = "".join(re.split(r'\|?<bar/>\|?', msg, maxsplit=1))
139
+ self._tk_text_var.set(msg)
140
+ if not self._tk_dispatching:
141
+ self._tk_window.update()
142
+
143
+ def set_description(self, desc=None, refresh=True):
144
+ self.set_description_str(desc, refresh)
145
+
146
+ def set_description_str(self, desc=None, refresh=True):
147
+ self.desc = desc
148
+ if not self.disable:
149
+ self._tk_window.wm_title(desc)
150
+ if refresh and not self._tk_dispatching:
151
+ self._tk_window.update()
152
+
153
+ def cancel(self):
154
+ """
155
+ `cancel_callback()` followed by `close()`
156
+ when close/cancel buttons clicked.
157
+ """
158
+ if self._cancel_callback is not None:
159
+ self._cancel_callback()
160
+ self.close()
161
+
162
+ def reset(self, total=None):
163
+ """
164
+ Resets to 0 iterations for repeated use.
165
+
166
+ Parameters
167
+ ----------
168
+ total : int or float, optional. Total to use for the new bar.
169
+ """
170
+ if hasattr(self, '_tk_pbar'):
171
+ if total is None:
172
+ self._tk_pbar.configure(maximum=100, mode="indeterminate")
173
+ else:
174
+ self._tk_pbar.configure(maximum=total, mode="determinate")
175
+ super().reset(total=total)
176
+
177
+ @staticmethod
178
+ def _tk_dispatching_helper():
179
+ """determine if Tkinter mainloop is dispatching events"""
180
+ codes = {tkinter.mainloop.__code__, tkinter.Misc.mainloop.__code__}
181
+ for frame in sys._current_frames().values():
182
+ while frame:
183
+ if frame.f_code in codes:
184
+ return True
185
+ frame = frame.f_back
186
+ return False
187
+
188
+
189
+ def ttkrange(*args, **kwargs):
190
+ """Shortcut for `tqdm.tk.tqdm(range(*args), **kwargs)`."""
191
+ return tqdm_tk(range(*args), **kwargs)
192
+
193
+
194
+ # Aliases
195
+ tqdm = tqdm_tk
196
+ trange = ttkrange
.venv/lib/python3.12/site-packages/tqdm/tqdm.1 ADDED
@@ -0,0 +1,241 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .TH "TQDM" "1" "2015\-2026" "tqdm User Manuals"
2
+ .SH NAME
3
+ tqdm \- fast, extensible progress bar for Python and CLI
4
+ .SH SYNOPSIS
5
+ tqdm [\f[I]options\f[R]]
6
+ .SH DESCRIPTION
7
+ See \c
8
+ .UR https://github.com/tqdm/tqdm
9
+ .UE \c
10
+ \&.
11
+ Can be used as a pipe:
12
+ .IP
13
+ .EX
14
+ $ \f[I]# count lines of code\f[R]
15
+ $ cat *.py \f[B]|\f[R] tqdm \f[B]|\f[R] wc \-l
16
+ 327it [00:00, 981773.38it/s]
17
+ 327
18
+
19
+ $ \f[I]# find all files\f[R]
20
+ $ find . \-name \(dq*.py\(dq \f[B]|\f[R] tqdm \f[B]|\f[R] wc \-l
21
+ 432it [00:00, 833842.30it/s]
22
+ 432
23
+
24
+ \f[I]# ... and more info\f[R]
25
+ $ find . \-name \(aq*.py\(aq \-exec wc \-l \(rs{} \(rs; \(rs
26
+ \f[B]|\f[R] tqdm \-\-total 432 \-\-unit files \-\-desc counting \(rs
27
+ \f[B]|\f[R] awk \(aq{ sum += $1 }; END { print sum }\(aq
28
+ counting: 100%\f[B]|\f[R]█████████\f[B]|\f[R] 432/432 [00:00<00:00, 794361.83files/s]
29
+ 131998
30
+ .EE
31
+ .SH OPTIONS
32
+ .TP
33
+ \-h, \-\-help
34
+ Print this help and exit.
35
+ .TP
36
+ \-v, \-\-version
37
+ Print version and exit.
38
+ .TP
39
+ \-\-desc=\f[I]desc\f[R]
40
+ str, optional.
41
+ Prefix for the progress bar.
42
+ .TP
43
+ \-\-total=\f[I]total\f[R]
44
+ int or float, optional.
45
+ The number of expected iterations.
46
+ If unspecified, len(iterable) is used if possible.
47
+ If float(\(lqinf\(rq) or as a last resort, only basic progress
48
+ statistics are displayed (no ETA, no progress bar).
49
+ If \f[CR]gui\f[R] is True and this parameter needs subsequent updating,
50
+ specify an initial arbitrary large positive number, e.g.\ 9e9.
51
+ .TP
52
+ \-\-leave
53
+ bool, optional.
54
+ If [default: True], keeps all traces of the progress bar upon
55
+ termination of iteration.
56
+ If \f[CR]None\f[R], will leave only if \f[CR]position\f[R] is
57
+ \f[CR]0\f[R].
58
+ .TP
59
+ \-\-ncols=\f[I]ncols\f[R]
60
+ int, optional.
61
+ The width of the entire output message.
62
+ If specified, dynamically resizes the progress bar to stay within this
63
+ bound.
64
+ If unspecified, attempts to use environment width.
65
+ The fallback is a meter width of 10 and no limit for the counter and
66
+ statistics.
67
+ If 0, will not print any meter (only stats).
68
+ .TP
69
+ \-\-mininterval=\f[I]mininterval\f[R]
70
+ float, optional.
71
+ Minimum progress display update interval [default: 0.1] seconds.
72
+ .TP
73
+ \-\-maxinterval=\f[I]maxinterval\f[R]
74
+ float, optional.
75
+ Maximum progress display update interval [default: 10] seconds.
76
+ Automatically adjusts \f[CR]miniters\f[R] to correspond to
77
+ \f[CR]mininterval\f[R] after long display update lag.
78
+ Only works if \f[CR]dynamic_miniters\f[R] or monitor thread is enabled.
79
+ .TP
80
+ \-\-miniters=\f[I]miniters\f[R]
81
+ int or float, optional.
82
+ Minimum progress display update interval, in iterations.
83
+ If 0 and \f[CR]dynamic_miniters\f[R], will automatically adjust to equal
84
+ \f[CR]mininterval\f[R] (more CPU efficient, good for tight loops).
85
+ If > 0, will skip display of specified number of iterations.
86
+ Tweak this and \f[CR]mininterval\f[R] to get very efficient loops.
87
+ If your progress is erratic with both fast and slow iterations (network,
88
+ skipping items, etc) you should set miniters=1.
89
+ .TP
90
+ \-\-ascii=\f[I]ascii\f[R]
91
+ bool or str, optional.
92
+ If unspecified or False, use unicode (smooth blocks) to fill the meter.
93
+ The fallback is to use ASCII characters \(rq 123456789#\(lq.
94
+ .TP
95
+ \-\-disable
96
+ bool, optional.
97
+ Whether to disable the entire progress bar wrapper [default: False].
98
+ If set to None, disable on non\-TTY.
99
+ .TP
100
+ \-\-unit=\f[I]unit\f[R]
101
+ str, optional.
102
+ String that will be used to define the unit of each iteration [default:
103
+ it].
104
+ .TP
105
+ \-\-unit\-scale=\f[I]unit_scale\f[R]
106
+ bool or int or float, optional.
107
+ If 1 or True, the number of iterations will be reduced/scaled
108
+ automatically and a metric prefix following the International System of
109
+ Units standard will be added (kilo, mega, etc.)
110
+ [default: False].
111
+ If any other non\-zero number, will scale \f[CR]total\f[R] and
112
+ \f[CR]n\f[R].
113
+ .TP
114
+ \-\-dynamic\-ncols
115
+ bool, optional.
116
+ If set, constantly alters \f[CR]ncols\f[R] and \f[CR]nrows\f[R] to the
117
+ environment (allowing for window resizes) [default: False].
118
+ .TP
119
+ \-\-smoothing=\f[I]smoothing\f[R]
120
+ float, optional.
121
+ Exponential moving average smoothing factor for speed estimates (ignored
122
+ in GUI mode).
123
+ Ranges from 0 (average speed) to 1 (current/instantaneous speed)
124
+ [default: 0.3].
125
+ .TP
126
+ \-\-bar\-format=\f[I]bar_format\f[R]
127
+ str, optional.
128
+ Specify a custom bar string formatting.
129
+ May impact performance.
130
+ [default: `{l_bar}{bar}{r_bar}'], where l_bar=`{desc}:
131
+ {percentage:3.0f}%|' and r_bar=`| {n_fmt}/{total_fmt}
132
+ [{elapsed}<{remaining}, \(cq \(cq{rate_fmt}{postfix}]' Possible vars:
133
+ l_bar, bar, r_bar, n, n_fmt, total, total_fmt, percentage, elapsed,
134
+ elapsed_s, ncols, nrows, desc, unit, rate, rate_fmt, rate_noinv,
135
+ rate_noinv_fmt, rate_inv, rate_inv_fmt, postfix, unit_divisor,
136
+ remaining, remaining_s, eta.
137
+ Note that a trailing \(lq:\(rq is automatically removed after {desc} if
138
+ the latter is empty.
139
+ .TP
140
+ \-\-initial=\f[I]initial\f[R]
141
+ int or float, optional.
142
+ The initial counter value.
143
+ Useful when restarting a progress bar [default: 0].
144
+ If using float, consider specifying \f[CR]{n:.3f}\f[R] or similar in
145
+ \f[CR]bar_format\f[R], or specifying \f[CR]unit_scale\f[R].
146
+ .TP
147
+ \-\-position=\f[I]position\f[R]
148
+ int, optional.
149
+ Specify the line offset to print this bar (starting from 0) Automatic if
150
+ unspecified.
151
+ Useful to manage multiple bars at once (eg, from threads).
152
+ .TP
153
+ \-\-postfix=\f[I]postfix\f[R]
154
+ dict or *, optional.
155
+ Specify additional stats to display at the end of the bar.
156
+ Calls \f[CR]set_postfix(**postfix)\f[R] if possible (dict).
157
+ .TP
158
+ \-\-unit\-divisor=\f[I]unit_divisor\f[R]
159
+ float, optional.
160
+ [default: 1000], ignored unless \f[CR]unit_scale\f[R] is True.
161
+ .TP
162
+ \-\-write\-bytes
163
+ bool, optional.
164
+ Whether to write bytes.
165
+ If (default: False) will write unicode.
166
+ .TP
167
+ \-\-lock\-args=\f[I]lock_args\f[R]
168
+ tuple, optional.
169
+ Passed to \f[CR]refresh\f[R] for intermediate output (initialisation,
170
+ iterating, and updating).
171
+ .TP
172
+ \-\-nrows=\f[I]nrows\f[R]
173
+ int, optional.
174
+ The screen height.
175
+ If specified, hides nested bars outside this bound.
176
+ If unspecified, attempts to use environment height.
177
+ The fallback is 20.
178
+ .TP
179
+ \-\-colour=\f[I]colour\f[R]
180
+ str, optional.
181
+ Bar colour (e.g.\ `green', `#00ff00').
182
+ .TP
183
+ \-\-delay=\f[I]delay\f[R]
184
+ float, optional.
185
+ Don\(cqt display until [default: 0] seconds have elapsed.
186
+ .TP
187
+ \-\-delim=\f[I]delim\f[R]
188
+ chr, optional.
189
+ Delimiting character [default: `\(rsn'].
190
+ Use `\(rs0' for null.
191
+ N.B.: on Windows systems, Python converts `\(rsn' to `\(rsr\(rsn'.
192
+ .TP
193
+ \-\-buf\-size=\f[I]buf_size\f[R]
194
+ int, optional.
195
+ String buffer size in bytes [default: 256] used when \f[CR]delim\f[R] is
196
+ specified.
197
+ .TP
198
+ \-\-bytes
199
+ bool, optional.
200
+ If true, will count bytes, ignore \f[CR]delim\f[R], and default
201
+ \f[CR]unit_scale\f[R] to True, \f[CR]unit_divisor\f[R] to 1024, and
202
+ \f[CR]unit\f[R] to `B'.
203
+ .TP
204
+ \-\-tee
205
+ bool, optional.
206
+ If true, passes \f[CR]stdin\f[R] to both \f[CR]stderr\f[R] and
207
+ \f[CR]stdout\f[R].
208
+ .TP
209
+ \-\-update
210
+ bool, optional.
211
+ If true, will treat input as newly elapsed iterations, i.e.\ numbers to
212
+ pass to \f[CR]update()\f[R].
213
+ Note that this is slow (\(ti2e5 it/s) since every input must be decoded
214
+ as a number.
215
+ .TP
216
+ \-\-update\-to
217
+ bool, optional.
218
+ If true, will treat input as total elapsed iterations, i.e.\ numbers to
219
+ assign to \f[CR]self.n\f[R].
220
+ Note that this is slow (\(ti2e5 it/s) since every input must be decoded
221
+ as a number.
222
+ .TP
223
+ \-\-null
224
+ bool, optional.
225
+ If true, will discard input (no stdout).
226
+ .TP
227
+ \-\-manpath=\f[I]manpath\f[R]
228
+ str, optional.
229
+ Directory in which to install tqdm man pages.
230
+ .TP
231
+ \-\-comppath=\f[I]comppath\f[R]
232
+ str, optional.
233
+ Directory in which to place tqdm completion.
234
+ .TP
235
+ \-\-log=\f[I]log\f[R]
236
+ str, optional.
237
+ CRITICAL|FATAL|ERROR|WARN(ING)|[default: `INFO']|DEBUG|NOTSET.
238
+ .SH AUTHORS
239
+ tqdm developers \c
240
+ .UR https://github.com/tqdm
241
+ .UE \c.
.venv/lib/python3.12/site-packages/tqdm/utils.py ADDED
@@ -0,0 +1,328 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ General helpers required for `tqdm.std`.
3
+ """
4
+ import os
5
+ import re
6
+ import sys
7
+ from functools import partial, partialmethod, wraps
8
+ from inspect import signature
9
+ # TODO consider using wcswidth third-party package for 0-width characters
10
+ from unicodedata import east_asian_width
11
+ from warnings import warn
12
+ from weakref import proxy
13
+
14
+ _range, _unich, _unicode, _basestring = range, chr, str, str
15
+ CUR_OS = sys.platform
16
+ IS_WIN = any(CUR_OS.startswith(i) for i in ['win32', 'cygwin'])
17
+ IS_NIX = any(CUR_OS.startswith(i) for i in ['aix', 'linux', 'darwin', 'freebsd'])
18
+ RE_ANSI = re.compile(r"\x1b\[[;\d]*[A-Za-z]")
19
+
20
+ try:
21
+ if IS_WIN:
22
+ import colorama
23
+ else:
24
+ raise ImportError
25
+ except ImportError:
26
+ colorama = None
27
+ else:
28
+ try:
29
+ colorama.init(strip=False)
30
+ except TypeError:
31
+ colorama.init()
32
+
33
+
34
+ def envwrap(name, app="", types=None, is_method=False):
35
+ """
36
+ Basic (env-only) version of [envwrap](https://github.com/tqdm/envwrap).
37
+ Install `envwrap` for config file support.
38
+ """
39
+ if types is None:
40
+ types = {}
41
+ if name[-1] == "_":
42
+ name = name[:-1]
43
+ warn("Trailing underscore in `name` is automatic", DeprecationWarning, stacklevel=2)
44
+ prefixes = (name, f"{name}_{app}") if app else (name,)
45
+ env_overrides = {}
46
+ for prefix in prefixes:
47
+ prefix = prefix.upper() + "_"
48
+ i = len(prefix)
49
+ env_overrides.update(
50
+ (k[i:].lower(), v) for k, v in os.environ.items() if k.startswith(prefix))
51
+ part = partialmethod if is_method else partial
52
+
53
+ def wrap(func):
54
+ params = signature(func).parameters
55
+ # ignore unknown env vars
56
+ overrides = {k: v for k, v in env_overrides.items() if k in params}
57
+ # infer overrides' `type`s
58
+ for k in overrides:
59
+ param = params[k]
60
+ if param.annotation is not param.empty: # typehints
61
+ for typ in getattr(param.annotation, '__args__', (param.annotation,)):
62
+ try:
63
+ overrides[k] = typ(overrides[k])
64
+ except Exception: # nosec B110
65
+ pass
66
+ else:
67
+ break
68
+ elif param.default is not None: # type of default value
69
+ overrides[k] = type(param.default)(overrides[k])
70
+ else:
71
+ try: # `types` fallback
72
+ overrides[k] = types[k](overrides[k])
73
+ except KeyError: # keep unconverted (`str`)
74
+ pass
75
+ return part(func, **overrides)
76
+ return wrap
77
+
78
+
79
+ try:
80
+ from envwrap import envwrap # noqa: F401, F811, pylint: disable=unused-import
81
+ except ModuleNotFoundError:
82
+ pass
83
+
84
+
85
+ class FormatReplace:
86
+ """
87
+ >>> a = FormatReplace('something')
88
+ >>> f"{a:5d}"
89
+ 'something'
90
+ """ # NOQA: P102
91
+ def __init__(self, replace=''):
92
+ self.replace = replace
93
+ self.format_called = 0
94
+
95
+ def __format__(self, _):
96
+ self.format_called += 1
97
+ return self.replace
98
+
99
+
100
+ class Comparable:
101
+ """Assumes child has self._comparable attr/@property"""
102
+ def __lt__(self, other):
103
+ return self._comparable < other._comparable
104
+
105
+ def __le__(self, other):
106
+ return (self < other) or (self == other)
107
+
108
+ def __eq__(self, other):
109
+ return self._comparable == other._comparable
110
+
111
+ def __ne__(self, other):
112
+ return not self == other
113
+
114
+ def __gt__(self, other):
115
+ return not self <= other
116
+
117
+ def __ge__(self, other):
118
+ return not self < other
119
+
120
+
121
+ class ObjectWrapper:
122
+ def __getattr__(self, name):
123
+ return getattr(self._wrapped, name)
124
+
125
+ def __setattr__(self, name, value):
126
+ return setattr(self._wrapped, name, value)
127
+
128
+ def wrapper_getattr(self, name):
129
+ """Actual `self.getattr` rather than self._wrapped.getattr"""
130
+ try:
131
+ return object.__getattr__(self, name)
132
+ except AttributeError: # py2
133
+ return getattr(self, name)
134
+
135
+ def wrapper_setattr(self, name, value):
136
+ """Actual `self.setattr` rather than self._wrapped.setattr"""
137
+ return object.__setattr__(self, name, value)
138
+
139
+ def __init__(self, wrapped):
140
+ """
141
+ Thin wrapper around a given object
142
+ """
143
+ self.wrapper_setattr('_wrapped', wrapped)
144
+
145
+
146
+ class SimpleTextIOWrapper(ObjectWrapper):
147
+ """
148
+ Change only `.write()` of the wrapped object by encoding the passed
149
+ value and passing the result to the wrapped object's `.write()` method.
150
+ """
151
+ # pylint: disable=too-few-public-methods
152
+ def __init__(self, wrapped, encoding):
153
+ super().__init__(wrapped)
154
+ self.wrapper_setattr('encoding', encoding)
155
+
156
+ def write(self, s):
157
+ """
158
+ Encode `s` and pass to the wrapped object's `.write()` method.
159
+ """
160
+ return self._wrapped.write(s.encode(self.wrapper_getattr('encoding')))
161
+
162
+ def __eq__(self, other):
163
+ return self._wrapped == getattr(other, '_wrapped', other)
164
+
165
+
166
+ class DisableOnWriteError(ObjectWrapper):
167
+ """
168
+ Disable the given `tqdm_instance` upon `write()` or `flush()` errors.
169
+ """
170
+ @staticmethod
171
+ def disable_on_exception(tqdm_instance, func):
172
+ """
173
+ Quietly set `tqdm_instance.miniters=inf` if `func` raises `errno=5`.
174
+ """
175
+ tqdm_instance = proxy(tqdm_instance)
176
+
177
+ def inner(*args, **kwargs):
178
+ try:
179
+ return func(*args, **kwargs)
180
+ except OSError as e:
181
+ if e.errno != 5:
182
+ raise
183
+ try:
184
+ tqdm_instance.miniters = float('inf')
185
+ except ReferenceError:
186
+ pass
187
+ except ValueError as e:
188
+ if 'closed' not in str(e):
189
+ raise
190
+ try:
191
+ tqdm_instance.miniters = float('inf')
192
+ except ReferenceError:
193
+ pass
194
+ return inner
195
+
196
+ def __init__(self, wrapped, tqdm_instance): # noqa: B042
197
+ super().__init__(wrapped)
198
+ if hasattr(wrapped, 'write'):
199
+ self.wrapper_setattr(
200
+ 'write', self.disable_on_exception(tqdm_instance, wrapped.write))
201
+ if hasattr(wrapped, 'flush'):
202
+ self.wrapper_setattr(
203
+ 'flush', self.disable_on_exception(tqdm_instance, wrapped.flush))
204
+
205
+ def __eq__(self, other):
206
+ return self._wrapped == getattr(other, '_wrapped', other)
207
+
208
+
209
+ class CallbackIOWrapper(ObjectWrapper):
210
+ def __init__(self, callback, stream, method="read"):
211
+ """
212
+ Wrap a given `file`-like object's `read()` or `write()` to report
213
+ lengths to the given `callback`
214
+ """
215
+ super().__init__(stream)
216
+ func = getattr(stream, method)
217
+ if method == "write":
218
+ @wraps(func)
219
+ def write(data, *args, **kwargs):
220
+ res = func(data, *args, **kwargs)
221
+ callback(len(data))
222
+ return res
223
+ self.wrapper_setattr('write', write)
224
+ elif method == "read":
225
+ @wraps(func)
226
+ def read(*args, **kwargs):
227
+ data = func(*args, **kwargs)
228
+ callback(len(data))
229
+ return data
230
+ self.wrapper_setattr('read', read)
231
+ else:
232
+ raise KeyError("Can only wrap read/write methods")
233
+
234
+
235
+ def _is_utf(encoding):
236
+ try:
237
+ '\u2588\u2589'.encode(encoding)
238
+ except UnicodeEncodeError:
239
+ return False
240
+ except Exception:
241
+ try:
242
+ return encoding.lower().startswith('utf-') or ('U8' == encoding)
243
+ except Exception:
244
+ return False
245
+ else:
246
+ return True
247
+
248
+
249
+ def _supports_unicode(fp):
250
+ try:
251
+ return _is_utf(fp.encoding)
252
+ except AttributeError:
253
+ return False
254
+
255
+
256
+ def _is_ascii(s):
257
+ if isinstance(s, str):
258
+ for c in s:
259
+ if ord(c) > 255:
260
+ return False
261
+ return True
262
+ return _supports_unicode(s)
263
+
264
+
265
+ def _screen_shape_wrapper(): # pragma: no cover
266
+ """
267
+ Return a function which returns console dimensions (width, height).
268
+ Supported: linux, osx, windows, cygwin.
269
+ """
270
+ def inner(fp):
271
+ try:
272
+ from os import get_terminal_size
273
+ cols, lines = get_terminal_size(getattr(fp, 'fileno', lambda: None)())
274
+ return cols - 1, lines - 1
275
+ except Exception:
276
+ return None, None
277
+
278
+ return inner
279
+
280
+
281
+ def _environ_cols_wrapper(): # pragma: no cover
282
+ """
283
+ Return a function which returns console width.
284
+ Supported: linux, osx, windows, cygwin.
285
+ """
286
+ warn("Use `_screen_shape_wrapper()(file)[0]` instead of"
287
+ " `_environ_cols_wrapper()(file)`", DeprecationWarning, stacklevel=2)
288
+ shape = _screen_shape_wrapper()
289
+ if not shape:
290
+ return None
291
+
292
+ @wraps(shape)
293
+ def inner(fp):
294
+ return shape(fp)[0]
295
+
296
+ return inner
297
+
298
+
299
+ def _term_move_up(): # pragma: no cover
300
+ return '' if (os.name == 'nt') and (colorama is None) else '\x1b[A'
301
+
302
+
303
+ def _text_width(s):
304
+ return sum(2 if east_asian_width(ch) in 'FW' else 1 for ch in str(s))
305
+
306
+
307
+ def disp_len(data):
308
+ """
309
+ Returns the real on-screen length of a string which may contain
310
+ ANSI control codes and wide chars.
311
+ """
312
+ return _text_width(RE_ANSI.sub('', data))
313
+
314
+
315
+ def disp_trim(data, length):
316
+ """
317
+ Trim a string which may contain ANSI control characters.
318
+ """
319
+ if len(data) == disp_len(data):
320
+ return data[:length]
321
+
322
+ ansi_present = bool(RE_ANSI.search(data))
323
+ while disp_len(data) > length: # carefully delete one char at a time
324
+ data = data[:-1]
325
+ if ansi_present and bool(RE_ANSI.search(data)):
326
+ # assume ANSI reset is required
327
+ return data if data.endswith("\033[0m") else data + "\033[0m"
328
+ return data
.venv/lib/python3.12/site-packages/tqdm/version.py ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ """`tqdm` version detector. Precedence: installed dist, git, 'UNKNOWN'."""
2
+ from importlib.metadata import PackageNotFoundError, version
3
+
4
+ try:
5
+ __version__ = version('tqdm')
6
+ except PackageNotFoundError:
7
+ __version__ = "UNKNOWN"
.venv/lib/python3.12/site-packages/typing_extensions-4.16.0.dist-info/INSTALLER ADDED
@@ -0,0 +1 @@
 
 
1
+ pip
.venv/lib/python3.12/site-packages/typing_extensions-4.16.0.dist-info/METADATA ADDED
@@ -0,0 +1,73 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Metadata-Version: 2.4
2
+ Name: typing_extensions
3
+ Version: 4.16.0
4
+ Summary: Backported and Experimental Type Hints for Python 3.9+
5
+ Keywords: annotations,backport,checker,checking,function,hinting,hints,type,typechecking,typehinting,typehints,typing
6
+ Author-email: "Guido van Rossum, Jukka Lehtosalo, Łukasz Langa, Michael Lee" <levkivskyi@gmail.com>
7
+ Requires-Python: >=3.9
8
+ Description-Content-Type: text/markdown
9
+ License-Expression: PSF-2.0
10
+ Classifier: Development Status :: 5 - Production/Stable
11
+ Classifier: Environment :: Console
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: Operating System :: OS Independent
14
+ Classifier: Programming Language :: Python :: 3
15
+ Classifier: Programming Language :: Python :: 3 :: Only
16
+ Classifier: Programming Language :: Python :: 3.9
17
+ Classifier: Programming Language :: Python :: 3.10
18
+ Classifier: Programming Language :: Python :: 3.11
19
+ Classifier: Programming Language :: Python :: 3.12
20
+ Classifier: Programming Language :: Python :: 3.13
21
+ Classifier: Programming Language :: Python :: 3.14
22
+ Classifier: Programming Language :: Python :: 3.15
23
+ Classifier: Topic :: Software Development
24
+ License-File: LICENSE
25
+ Project-URL: Bug Tracker, https://github.com/python/typing_extensions/issues
26
+ Project-URL: Changes, https://github.com/python/typing_extensions/blob/main/CHANGELOG.md
27
+ Project-URL: Documentation, https://typing-extensions.readthedocs.io/
28
+ Project-URL: Home, https://github.com/python/typing_extensions
29
+ Project-URL: Q & A, https://github.com/python/typing/discussions
30
+ Project-URL: Repository, https://github.com/python/typing_extensions
31
+
32
+ # Typing Extensions
33
+
34
+ [![Chat at https://gitter.im/python/typing](https://badges.gitter.im/python/typing.svg)](https://gitter.im/python/typing)
35
+
36
+ [Documentation](https://typing-extensions.readthedocs.io/en/latest/#) –
37
+ [PyPI](https://pypi.org/project/typing-extensions/)
38
+
39
+ ## Overview
40
+
41
+ The `typing_extensions` module serves two related purposes:
42
+
43
+ - Enable use of new type system features on older Python versions. For example,
44
+ `typing.TypeGuard` is new in Python 3.10, but `typing_extensions` allows
45
+ users on previous Python versions to use it too.
46
+ - Enable experimentation with new type system PEPs before they are accepted and
47
+ added to the `typing` module.
48
+
49
+ `typing_extensions` is treated specially by static type checkers such as
50
+ mypy and pyright. Objects defined in `typing_extensions` are treated the same
51
+ way as equivalent forms in `typing`.
52
+
53
+ `typing_extensions` uses
54
+ [Semantic Versioning](https://semver.org/). The
55
+ major version will be incremented only for backwards-incompatible changes.
56
+ Therefore, it's safe to depend
57
+ on `typing_extensions` like this: `typing_extensions ~=x.y`,
58
+ where `x.y` is the first version that includes all features you need.
59
+ [This](https://packaging.python.org/en/latest/specifications/version-specifiers/#compatible-release)
60
+ is equivalent to `typing_extensions >=x.y, <(x+1)`. Do not depend on `~= x.y.z`
61
+ unless you really know what you're doing; that defeats the purpose of
62
+ semantic versioning.
63
+
64
+ ## Included items
65
+
66
+ See [the documentation](https://typing-extensions.readthedocs.io/en/latest/#) for a
67
+ complete listing of module contents.
68
+
69
+ ## Contributing
70
+
71
+ See [CONTRIBUTING.md](https://github.com/python/typing_extensions/blob/main/CONTRIBUTING.md)
72
+ for how to contribute to `typing_extensions`.
73
+
.venv/lib/python3.12/site-packages/typing_extensions-4.16.0.dist-info/RECORD ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ __pycache__/typing_extensions.cpython-312.pyc,,
2
+ typing_extensions-4.16.0.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4
3
+ typing_extensions-4.16.0.dist-info/METADATA,sha256=sFCEyh1Qh5hlF42f_5-r6rYb37HzYb-96VQh_8j5vkY,3310
4
+ typing_extensions-4.16.0.dist-info/RECORD,,
5
+ typing_extensions-4.16.0.dist-info/WHEEL,sha256=G2gURzTEtmeR8nrdXUJfNiB3VYVxigPQ-bEQujpNiNs,82
6
+ typing_extensions-4.16.0.dist-info/licenses/LICENSE,sha256=Oy-B_iHRgcSZxZolbI4ZaEVdZonSaaqFNzv7avQdo78,13936
7
+ typing_extensions.py,sha256=QEDKGh7L7gDROFwSqTCE0cW9RvC3dPB-WufpHE9V5pY,165012
.venv/lib/python3.12/site-packages/typing_extensions-4.16.0.dist-info/WHEEL ADDED
@@ -0,0 +1,4 @@
 
 
 
 
 
1
+ Wheel-Version: 1.0
2
+ Generator: flit 3.12.0
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
.venv/lib/python3.12/site-packages/typing_extensions-4.16.0.dist-info/licenses/LICENSE ADDED
@@ -0,0 +1,279 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ A. HISTORY OF THE SOFTWARE
2
+ ==========================
3
+
4
+ Python was created in the early 1990s by Guido van Rossum at Stichting
5
+ Mathematisch Centrum (CWI, see https://www.cwi.nl) in the Netherlands
6
+ as a successor of a language called ABC. Guido remains Python's
7
+ principal author, although it includes many contributions from others.
8
+
9
+ In 1995, Guido continued his work on Python at the Corporation for
10
+ National Research Initiatives (CNRI, see https://www.cnri.reston.va.us)
11
+ in Reston, Virginia where he released several versions of the
12
+ software.
13
+
14
+ In May 2000, Guido and the Python core development team moved to
15
+ BeOpen.com to form the BeOpen PythonLabs team. In October of the same
16
+ year, the PythonLabs team moved to Digital Creations, which became
17
+ Zope Corporation. In 2001, the Python Software Foundation (PSF, see
18
+ https://www.python.org/psf/) was formed, a non-profit organization
19
+ created specifically to own Python-related Intellectual Property.
20
+ Zope Corporation was a sponsoring member of the PSF.
21
+
22
+ All Python releases are Open Source (see https://opensource.org for
23
+ the Open Source Definition). Historically, most, but not all, Python
24
+ releases have also been GPL-compatible; the table below summarizes
25
+ the various releases.
26
+
27
+ Release Derived Year Owner GPL-
28
+ from compatible? (1)
29
+
30
+ 0.9.0 thru 1.2 1991-1995 CWI yes
31
+ 1.3 thru 1.5.2 1.2 1995-1999 CNRI yes
32
+ 1.6 1.5.2 2000 CNRI no
33
+ 2.0 1.6 2000 BeOpen.com no
34
+ 1.6.1 1.6 2001 CNRI yes (2)
35
+ 2.1 2.0+1.6.1 2001 PSF no
36
+ 2.0.1 2.0+1.6.1 2001 PSF yes
37
+ 2.1.1 2.1+2.0.1 2001 PSF yes
38
+ 2.1.2 2.1.1 2002 PSF yes
39
+ 2.1.3 2.1.2 2002 PSF yes
40
+ 2.2 and above 2.1.1 2001-now PSF yes
41
+
42
+ Footnotes:
43
+
44
+ (1) GPL-compatible doesn't mean that we're distributing Python under
45
+ the GPL. All Python licenses, unlike the GPL, let you distribute
46
+ a modified version without making your changes open source. The
47
+ GPL-compatible licenses make it possible to combine Python with
48
+ other software that is released under the GPL; the others don't.
49
+
50
+ (2) According to Richard Stallman, 1.6.1 is not GPL-compatible,
51
+ because its license has a choice of law clause. According to
52
+ CNRI, however, Stallman's lawyer has told CNRI's lawyer that 1.6.1
53
+ is "not incompatible" with the GPL.
54
+
55
+ Thanks to the many outside volunteers who have worked under Guido's
56
+ direction to make these releases possible.
57
+
58
+
59
+ B. TERMS AND CONDITIONS FOR ACCESSING OR OTHERWISE USING PYTHON
60
+ ===============================================================
61
+
62
+ Python software and documentation are licensed under the
63
+ Python Software Foundation License Version 2.
64
+
65
+ Starting with Python 3.8.6, examples, recipes, and other code in
66
+ the documentation are dual licensed under the PSF License Version 2
67
+ and the Zero-Clause BSD license.
68
+
69
+ Some software incorporated into Python is under different licenses.
70
+ The licenses are listed with code falling under that license.
71
+
72
+
73
+ PYTHON SOFTWARE FOUNDATION LICENSE VERSION 2
74
+ --------------------------------------------
75
+
76
+ 1. This LICENSE AGREEMENT is between the Python Software Foundation
77
+ ("PSF"), and the Individual or Organization ("Licensee") accessing and
78
+ otherwise using this software ("Python") in source or binary form and
79
+ its associated documentation.
80
+
81
+ 2. Subject to the terms and conditions of this License Agreement, PSF hereby
82
+ grants Licensee a nonexclusive, royalty-free, world-wide license to reproduce,
83
+ analyze, test, perform and/or display publicly, prepare derivative works,
84
+ distribute, and otherwise use Python alone or in any derivative version,
85
+ provided, however, that PSF's License Agreement and PSF's notice of copyright,
86
+ i.e., "Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
87
+ 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021, 2022, 2023 Python Software Foundation;
88
+ All Rights Reserved" are retained in Python alone or in any derivative version
89
+ prepared by Licensee.
90
+
91
+ 3. In the event Licensee prepares a derivative work that is based on
92
+ or incorporates Python or any part thereof, and wants to make
93
+ the derivative work available to others as provided herein, then
94
+ Licensee hereby agrees to include in any such work a brief summary of
95
+ the changes made to Python.
96
+
97
+ 4. PSF is making Python available to Licensee on an "AS IS"
98
+ basis. PSF MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR
99
+ IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, PSF MAKES NO AND
100
+ DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS
101
+ FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON WILL NOT
102
+ INFRINGE ANY THIRD PARTY RIGHTS.
103
+
104
+ 5. PSF SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON
105
+ FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS
106
+ A RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON,
107
+ OR ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF.
108
+
109
+ 6. This License Agreement will automatically terminate upon a material
110
+ breach of its terms and conditions.
111
+
112
+ 7. Nothing in this License Agreement shall be deemed to create any
113
+ relationship of agency, partnership, or joint venture between PSF and
114
+ Licensee. This License Agreement does not grant permission to use PSF
115
+ trademarks or trade name in a trademark sense to endorse or promote
116
+ products or services of Licensee, or any third party.
117
+
118
+ 8. By copying, installing or otherwise using Python, Licensee
119
+ agrees to be bound by the terms and conditions of this License
120
+ Agreement.
121
+
122
+
123
+ BEOPEN.COM LICENSE AGREEMENT FOR PYTHON 2.0
124
+ -------------------------------------------
125
+
126
+ BEOPEN PYTHON OPEN SOURCE LICENSE AGREEMENT VERSION 1
127
+
128
+ 1. This LICENSE AGREEMENT is between BeOpen.com ("BeOpen"), having an
129
+ office at 160 Saratoga Avenue, Santa Clara, CA 95051, and the
130
+ Individual or Organization ("Licensee") accessing and otherwise using
131
+ this software in source or binary form and its associated
132
+ documentation ("the Software").
133
+
134
+ 2. Subject to the terms and conditions of this BeOpen Python License
135
+ Agreement, BeOpen hereby grants Licensee a non-exclusive,
136
+ royalty-free, world-wide license to reproduce, analyze, test, perform
137
+ and/or display publicly, prepare derivative works, distribute, and
138
+ otherwise use the Software alone or in any derivative version,
139
+ provided, however, that the BeOpen Python License is retained in the
140
+ Software, alone or in any derivative version prepared by Licensee.
141
+
142
+ 3. BeOpen is making the Software available to Licensee on an "AS IS"
143
+ basis. BEOPEN MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR
144
+ IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, BEOPEN MAKES NO AND
145
+ DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS
146
+ FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE WILL NOT
147
+ INFRINGE ANY THIRD PARTY RIGHTS.
148
+
149
+ 4. BEOPEN SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF THE
150
+ SOFTWARE FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS
151
+ AS A RESULT OF USING, MODIFYING OR DISTRIBUTING THE SOFTWARE, OR ANY
152
+ DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF.
153
+
154
+ 5. This License Agreement will automatically terminate upon a material
155
+ breach of its terms and conditions.
156
+
157
+ 6. This License Agreement shall be governed by and interpreted in all
158
+ respects by the law of the State of California, excluding conflict of
159
+ law provisions. Nothing in this License Agreement shall be deemed to
160
+ create any relationship of agency, partnership, or joint venture
161
+ between BeOpen and Licensee. This License Agreement does not grant
162
+ permission to use BeOpen trademarks or trade names in a trademark
163
+ sense to endorse or promote products or services of Licensee, or any
164
+ third party. As an exception, the "BeOpen Python" logos available at
165
+ http://www.pythonlabs.com/logos.html may be used according to the
166
+ permissions granted on that web page.
167
+
168
+ 7. By copying, installing or otherwise using the software, Licensee
169
+ agrees to be bound by the terms and conditions of this License
170
+ Agreement.
171
+
172
+
173
+ CNRI LICENSE AGREEMENT FOR PYTHON 1.6.1
174
+ ---------------------------------------
175
+
176
+ 1. This LICENSE AGREEMENT is between the Corporation for National
177
+ Research Initiatives, having an office at 1895 Preston White Drive,
178
+ Reston, VA 20191 ("CNRI"), and the Individual or Organization
179
+ ("Licensee") accessing and otherwise using Python 1.6.1 software in
180
+ source or binary form and its associated documentation.
181
+
182
+ 2. Subject to the terms and conditions of this License Agreement, CNRI
183
+ hereby grants Licensee a nonexclusive, royalty-free, world-wide
184
+ license to reproduce, analyze, test, perform and/or display publicly,
185
+ prepare derivative works, distribute, and otherwise use Python 1.6.1
186
+ alone or in any derivative version, provided, however, that CNRI's
187
+ License Agreement and CNRI's notice of copyright, i.e., "Copyright (c)
188
+ 1995-2001 Corporation for National Research Initiatives; All Rights
189
+ Reserved" are retained in Python 1.6.1 alone or in any derivative
190
+ version prepared by Licensee. Alternately, in lieu of CNRI's License
191
+ Agreement, Licensee may substitute the following text (omitting the
192
+ quotes): "Python 1.6.1 is made available subject to the terms and
193
+ conditions in CNRI's License Agreement. This Agreement together with
194
+ Python 1.6.1 may be located on the internet using the following
195
+ unique, persistent identifier (known as a handle): 1895.22/1013. This
196
+ Agreement may also be obtained from a proxy server on the internet
197
+ using the following URL: http://hdl.handle.net/1895.22/1013".
198
+
199
+ 3. In the event Licensee prepares a derivative work that is based on
200
+ or incorporates Python 1.6.1 or any part thereof, and wants to make
201
+ the derivative work available to others as provided herein, then
202
+ Licensee hereby agrees to include in any such work a brief summary of
203
+ the changes made to Python 1.6.1.
204
+
205
+ 4. CNRI is making Python 1.6.1 available to Licensee on an "AS IS"
206
+ basis. CNRI MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR
207
+ IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, CNRI MAKES NO AND
208
+ DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS
209
+ FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON 1.6.1 WILL NOT
210
+ INFRINGE ANY THIRD PARTY RIGHTS.
211
+
212
+ 5. CNRI SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON
213
+ 1.6.1 FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS
214
+ A RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON 1.6.1,
215
+ OR ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF.
216
+
217
+ 6. This License Agreement will automatically terminate upon a material
218
+ breach of its terms and conditions.
219
+
220
+ 7. This License Agreement shall be governed by the federal
221
+ intellectual property law of the United States, including without
222
+ limitation the federal copyright law, and, to the extent such
223
+ U.S. federal law does not apply, by the law of the Commonwealth of
224
+ Virginia, excluding Virginia's conflict of law provisions.
225
+ Notwithstanding the foregoing, with regard to derivative works based
226
+ on Python 1.6.1 that incorporate non-separable material that was
227
+ previously distributed under the GNU General Public License (GPL), the
228
+ law of the Commonwealth of Virginia shall govern this License
229
+ Agreement only as to issues arising under or with respect to
230
+ Paragraphs 4, 5, and 7 of this License Agreement. Nothing in this
231
+ License Agreement shall be deemed to create any relationship of
232
+ agency, partnership, or joint venture between CNRI and Licensee. This
233
+ License Agreement does not grant permission to use CNRI trademarks or
234
+ trade name in a trademark sense to endorse or promote products or
235
+ services of Licensee, or any third party.
236
+
237
+ 8. By clicking on the "ACCEPT" button where indicated, or by copying,
238
+ installing or otherwise using Python 1.6.1, Licensee agrees to be
239
+ bound by the terms and conditions of this License Agreement.
240
+
241
+ ACCEPT
242
+
243
+
244
+ CWI LICENSE AGREEMENT FOR PYTHON 0.9.0 THROUGH 1.2
245
+ --------------------------------------------------
246
+
247
+ Copyright (c) 1991 - 1995, Stichting Mathematisch Centrum Amsterdam,
248
+ The Netherlands. All rights reserved.
249
+
250
+ Permission to use, copy, modify, and distribute this software and its
251
+ documentation for any purpose and without fee is hereby granted,
252
+ provided that the above copyright notice appear in all copies and that
253
+ both that copyright notice and this permission notice appear in
254
+ supporting documentation, and that the name of Stichting Mathematisch
255
+ Centrum or CWI not be used in advertising or publicity pertaining to
256
+ distribution of the software without specific, written prior
257
+ permission.
258
+
259
+ STICHTING MATHEMATISCH CENTRUM DISCLAIMS ALL WARRANTIES WITH REGARD TO
260
+ THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
261
+ FITNESS, IN NO EVENT SHALL STICHTING MATHEMATISCH CENTRUM BE LIABLE
262
+ FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
263
+ WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
264
+ ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
265
+ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
266
+
267
+ ZERO-CLAUSE BSD LICENSE FOR CODE IN THE PYTHON DOCUMENTATION
268
+ ----------------------------------------------------------------------
269
+
270
+ Permission to use, copy, modify, and/or distribute this software for any
271
+ purpose with or without fee is hereby granted.
272
+
273
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
274
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
275
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
276
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
277
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
278
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
279
+ PERFORMANCE OF THIS SOFTWARE.
.venv/lib/python3.12/site-packages/typing_extensions.py ADDED
The diff for this file is too large to render. See raw diff
 
.venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/INSTALLER ADDED
@@ -0,0 +1 @@
 
 
1
+ pip
.venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/METADATA ADDED
@@ -0,0 +1,432 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Metadata-Version: 2.4
2
+ Name: ultralytics
3
+ Version: 8.4.160
4
+ Summary: Ultralytics YOLO 🚀 for SOTA object detection, instance segmentation, semantic segmentation, depth estimation, classification, pose estimation, oriented object detection, and multi-object tracking.
5
+ Author-email: Glenn Jocher <glenn.jocher@ultralytics.com>, Jing Qiu <jing.qiu@ultralytics.com>
6
+ Maintainer-email: Ultralytics <hello@ultralytics.com>
7
+ License: AGPL-3.0
8
+ Project-URL: Homepage, https://ultralytics.com
9
+ Project-URL: Source, https://github.com/ultralytics/ultralytics
10
+ Project-URL: Documentation, https://docs.ultralytics.com
11
+ Project-URL: Bug Reports, https://github.com/ultralytics/ultralytics/issues
12
+ Project-URL: Changelog, https://github.com/ultralytics/ultralytics/releases
13
+ Keywords: machine-learning,deep-learning,computer-vision,ML,DL,AI,RT-DETR,SAM3,YOLO,YOLOv3,YOLOv5,YOLOv8,YOLO11,YOLO26,Platform,Ultralytics
14
+ Classifier: Development Status :: 5 - Production/Stable
15
+ Classifier: Intended Audience :: Developers
16
+ Classifier: Intended Audience :: Education
17
+ Classifier: Intended Audience :: Science/Research
18
+ Classifier: License :: OSI Approved :: GNU Affero General Public License v3 or later (AGPLv3+)
19
+ Classifier: Programming Language :: Python :: 3
20
+ Classifier: Programming Language :: Python :: 3.8
21
+ Classifier: Programming Language :: Python :: 3.9
22
+ Classifier: Programming Language :: Python :: 3.10
23
+ Classifier: Programming Language :: Python :: 3.11
24
+ Classifier: Programming Language :: Python :: 3.12
25
+ Classifier: Programming Language :: Python :: 3.13
26
+ Classifier: Topic :: Software Development
27
+ Classifier: Topic :: Scientific/Engineering
28
+ Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
29
+ Classifier: Topic :: Scientific/Engineering :: Image Recognition
30
+ Classifier: Operating System :: POSIX :: Linux
31
+ Classifier: Operating System :: MacOS
32
+ Classifier: Operating System :: Microsoft :: Windows
33
+ Requires-Python: >=3.8
34
+ Description-Content-Type: text/markdown
35
+ License-File: LICENSE
36
+ Requires-Dist: cloudpickle>=3.1.1
37
+ Requires-Dist: filelock>=3.16.1
38
+ Requires-Dist: numpy>=1.23.0; platform_system != "Darwin"
39
+ Requires-Dist: numpy!=2.0.*,!=2.1.*,!=2.2.*,!=2.3.0,!=2.3.1,!=2.3.2,!=2.3.3,!=2.3.4,>=1.23.0; platform_system == "Darwin"
40
+ Requires-Dist: matplotlib>=3.3.0
41
+ Requires-Dist: opencv-python!=4.13.0.90,>=4.7.0
42
+ Requires-Dist: pillow>=7.1.2
43
+ Requires-Dist: pyyaml>=5.3.1
44
+ Requires-Dist: requests>=2.23.0
45
+ Requires-Dist: torch>=1.8.0
46
+ Requires-Dist: torch!=2.4.0,>=1.8.0; sys_platform == "win32"
47
+ Requires-Dist: torchvision>=0.9.0
48
+ Requires-Dist: psutil>=5.8.0
49
+ Requires-Dist: polars>=0.20.0
50
+ Requires-Dist: nvidia-ml-py>=12.0.0
51
+ Requires-Dist: ultralytics-thop>=2.1.6
52
+ Requires-Dist: ultralytics-platform>=0.1.45; python_version >= "3.11"
53
+ Provides-Extra: dev
54
+ Requires-Dist: ipython; extra == "dev"
55
+ Requires-Dist: pytest; extra == "dev"
56
+ Requires-Dist: pytest-cov; extra == "dev"
57
+ Requires-Dist: pytest-xdist>=3.0.0; extra == "dev"
58
+ Requires-Dist: coverage[toml]; extra == "dev"
59
+ Requires-Dist: zensical>=0.0.58; python_version >= "3.10" and extra == "dev"
60
+ Requires-Dist: minijinja>=2.0.0; extra == "dev"
61
+ Provides-Extra: export-base
62
+ Requires-Dist: onnx>=1.12.0; platform_system != "Darwin" and extra == "export-base"
63
+ Requires-Dist: onnx<1.18.0,>=1.12.0; (platform_system == "Darwin" and python_version < "3.13") and extra == "export-base"
64
+ Requires-Dist: onnx>=1.20.0; (platform_system == "Darwin" and python_version >= "3.13") and extra == "export-base"
65
+ Requires-Dist: onnxslim>=0.1.82; extra == "export-base"
66
+ Requires-Dist: onnxruntime<1.20.0; (python_version < "3.11" and (platform_machine != "aarch64" or platform_system != "Linux")) and extra == "export-base"
67
+ Requires-Dist: onnxruntime>=1.20.0; python_version >= "3.11" and extra == "export-base"
68
+ Provides-Extra: export-openvino
69
+ Requires-Dist: nncf>=2.14.0; python_version >= "3.9" and extra == "export-openvino"
70
+ Requires-Dist: openvino>=2024.0.0; extra == "export-openvino"
71
+ Requires-Dist: packaging>=26.0; (platform_machine == "aarch64" and platform_system == "Linux" and python_version >= "3.9") and extra == "export-openvino"
72
+ Provides-Extra: export-legacy-torch
73
+ Requires-Dist: numpy<2; python_version < "3.13" and extra == "export-legacy-torch"
74
+ Requires-Dist: setuptools<81.0.0; python_version >= "3.9" and extra == "export-legacy-torch"
75
+ Requires-Dist: nncf<3.0.0; python_version >= "3.9" and extra == "export-legacy-torch"
76
+ Provides-Extra: export-tensorflow
77
+ Requires-Dist: numpy<2.0.0; python_version < "3.13" and extra == "export-tensorflow"
78
+ Requires-Dist: tensorflow<=2.19.0,>=2.0.0; python_version < "3.13" and extra == "export-tensorflow"
79
+ Requires-Dist: tensorflow>2.19.0; python_version >= "3.13" and extra == "export-tensorflow"
80
+ Requires-Dist: ydf<0.13.0; (platform_machine != "aarch64" and python_version <= "3.12") and extra == "export-tensorflow"
81
+ Requires-Dist: googleapis-common-protos<1.74.0; python_version <= "3.12" and extra == "export-tensorflow"
82
+ Requires-Dist: tensorstore>=0.1.63; (platform_machine == "aarch64" and python_version >= "3.9") and extra == "export-tensorflow"
83
+ Requires-Dist: h5py!=3.11.0; platform_machine == "aarch64" and extra == "export-tensorflow"
84
+ Provides-Extra: export-coreai
85
+ Requires-Dist: coreai-torch>=0.4.2; (platform_system == "Darwin" and platform_machine == "arm64" and python_version >= "3.11" and python_version < "3.14") and extra == "export-coreai"
86
+ Provides-Extra: export-coreml
87
+ Requires-Dist: numpy<=2.3.5; (platform_system != "Windows" and python_version <= "3.13") and extra == "export-coreml"
88
+ Requires-Dist: coremltools>=9.0; (platform_system != "Windows" and python_version <= "3.13") and extra == "export-coreml"
89
+ Requires-Dist: scikit-learn>=1.3.2; (platform_system != "Windows" and python_version <= "3.13") and extra == "export-coreml"
90
+ Provides-Extra: export-executorch
91
+ Requires-Dist: executorch; extra == "export-executorch"
92
+ Requires-Dist: numpy<=2.3.5; extra == "export-executorch"
93
+ Provides-Extra: export-deepx
94
+ Requires-Dist: dx_com; extra == "export-deepx"
95
+ Requires-Dist: numpy<2; python_version < "3.13" and extra == "export-deepx"
96
+ Provides-Extra: export-litert
97
+ Requires-Dist: litert-torch>=0.9.0; (((platform_system == "Linux" and platform_machine == "x86_64") or platform_system == "Darwin") and python_version >= "3.10") and extra == "export-litert"
98
+ Requires-Dist: ai-edge-litert>=2.1.4; (((platform_system == "Linux" and platform_machine == "x86_64") or platform_system == "Darwin") and python_version >= "3.10") and extra == "export-litert"
99
+ Requires-Dist: ai-edge-quantizer>=0.6.0; (((platform_system == "Linux" and platform_machine == "x86_64") or platform_system == "Darwin") and python_version >= "3.10") and extra == "export-litert"
100
+ Provides-Extra: export
101
+ Requires-Dist: ultralytics[export-base]; extra == "export"
102
+ Requires-Dist: ultralytics[export-openvino]; extra == "export"
103
+ Requires-Dist: ultralytics[export-tensorflow]; extra == "export"
104
+ Requires-Dist: ultralytics[export-coreml]; extra == "export"
105
+ Requires-Dist: ultralytics[export-litert]; extra == "export"
106
+ Requires-Dist: torch<2.13.0,>=2.12.0; (platform_system == "Linux" and platform_machine == "aarch64" and python_version == "3.11") and extra == "export"
107
+ Provides-Extra: solutions
108
+ Requires-Dist: shapely>=2.0.0; extra == "solutions"
109
+ Requires-Dist: lap>=0.5.12; extra == "solutions"
110
+ Requires-Dist: streamlit>=1.51.0; python_version >= "3.10" and extra == "solutions"
111
+ Requires-Dist: streamlit<1.51.0,>=1.29.0; (python_version < "3.10" and (platform_machine != "aarch64" or platform_system != "Linux")) and extra == "solutions"
112
+ Requires-Dist: flask>=3.0.1; extra == "solutions"
113
+ Provides-Extra: llm
114
+ Requires-Dist: openai>=2.0.0; extra == "llm"
115
+ Provides-Extra: logging
116
+ Requires-Dist: wandb; extra == "logging"
117
+ Requires-Dist: tensorboard; extra == "logging"
118
+ Requires-Dist: mlflow; extra == "logging"
119
+ Provides-Extra: extra
120
+ Requires-Dist: ipython; extra == "extra"
121
+ Requires-Dist: albumentations>=1.4.6; extra == "extra"
122
+ Requires-Dist: faster-coco-eval>=1.6.7; extra == "extra"
123
+ Provides-Extra: typing
124
+ Requires-Dist: types-pillow; extra == "typing"
125
+ Requires-Dist: types-psutil; extra == "typing"
126
+ Requires-Dist: types-pyyaml; extra == "typing"
127
+ Requires-Dist: types-requests; extra == "typing"
128
+ Requires-Dist: types-shapely; extra == "typing"
129
+ Dynamic: license-file
130
+
131
+ <div align="center">
132
+ <p>
133
+ <a href="https://www.ultralytics.com/yolo/yolo27?utm_source=github&utm_medium=social&utm_campaign=yolo27-launch-2026&utm_content=banner" target="_blank">
134
+ <img width="100%" src="https://raw.githubusercontent.com/ultralytics/assets/main/yolov8/banner-yolov8.png" alt="Ultralytics YOLO banner"></a>
135
+ </p>
136
+
137
+ [中文](https://docs.ultralytics.com/zh) | [한국어](https://docs.ultralytics.com/ko) | [日本語](https://docs.ultralytics.com/ja) | [Русский](https://docs.ultralytics.com/ru) | [Deutsch](https://docs.ultralytics.com/de) | [Français](https://docs.ultralytics.com/fr) | [Español](https://docs.ultralytics.com/es) | [Português](https://docs.ultralytics.com/pt) | [Türkçe](https://docs.ultralytics.com/tr) | [Tiếng Việt](https://docs.ultralytics.com/vi) | [العربية](https://docs.ultralytics.com/ar) <br>
138
+
139
+ <div>
140
+ <a href="https://github.com/ultralytics/ultralytics/actions/workflows/ci.yml"><img src="https://github.com/ultralytics/ultralytics/actions/workflows/ci.yml/badge.svg" alt="Ultralytics CI"></a>
141
+ <a href="https://clickpy.clickhouse.com/dashboard/ultralytics"><img src="https://static.pepy.tech/badge/ultralytics" alt="Ultralytics Downloads"></a>
142
+ <a href="https://discord.com/invite/ultralytics"><img alt="Ultralytics Discord" src="https://img.shields.io/discord/1089800235347353640?logo=discord&logoColor=white&label=Discord&color=blue"></a>
143
+ <a href="https://community.ultralytics.com"><img alt="Ultralytics Forums" src="https://img.shields.io/discourse/users?server=https%3A%2F%2Fcommunity.ultralytics.com&logo=discourse&label=Forums&color=blue"></a>
144
+ <a href="https://www.reddit.com/r/ultralytics/"><img alt="Ultralytics Reddit" src="https://img.shields.io/reddit/subreddit-subscribers/ultralytics?style=flat&logo=reddit&logoColor=white&label=Reddit&color=blue"></a>
145
+ <br>
146
+ <a href="https://console.paperspace.com/github/ultralytics/ultralytics"><img src="https://assets.paperspace.io/img/gradient-badge.svg" alt="Run Ultralytics on Gradient"></a>
147
+ <a href="https://colab.research.google.com/github/ultralytics/ultralytics/blob/main/examples/tutorial.ipynb"><img src="https://colab.research.google.com/assets/colab-badge.svg" alt="Open Ultralytics In Colab"></a>
148
+ <a href="https://www.kaggle.com/models/ultralytics/yolo26"><img src="https://kaggle.com/static/images/open-in-kaggle.svg" alt="Open Ultralytics In Kaggle"></a>
149
+ <a href="https://mybinder.org/v2/gh/ultralytics/ultralytics/HEAD?labpath=examples%2Ftutorial.ipynb"><img src="https://mybinder.org/badge_logo.svg" alt="Open Ultralytics In Binder"></a>
150
+ </div>
151
+ </div>
152
+ <br>
153
+
154
+ <div align="center">
155
+ <a href="https://trendshift.io/repositories/1556?utm_source=repository-badge&amp;utm_medium=badge&amp;utm_campaign=badge-repository-1556" target="_blank" rel="noopener noreferrer"><img src="https://trendshift.io/api/badge/repositories/1556" alt="ultralytics%2Fultralytics | Trendshift" width="250" height="55"/></a>
156
+ </div>
157
+ <br>
158
+
159
+ [Ultralytics](https://www.ultralytics.com) creates cutting-edge, state-of-the-art (SOTA) [YOLO models](https://www.ultralytics.com/yolo) built on years of foundational research in computer vision and AI. Constantly updated for performance and flexibility, our models are **fast**, **accurate**, and **easy to use**. They excel at [object detection](https://docs.ultralytics.com/tasks/detect), [instance segmentation](https://docs.ultralytics.com/tasks/segment), [semantic segmentation](https://docs.ultralytics.com/tasks/semantic), [depth estimation](https://docs.ultralytics.com/tasks/depth), [image classification](https://docs.ultralytics.com/tasks/classify), [pose estimation](https://docs.ultralytics.com/tasks/pose), and [oriented object detection](https://docs.ultralytics.com/tasks/obb) tasks, and can [track](https://docs.ultralytics.com/modes/track) detected objects across video frames.
160
+
161
+ Find detailed documentation in the [Ultralytics Docs](https://docs.ultralytics.com). Get support via [GitHub Issues](https://github.com/ultralytics/ultralytics/issues/new/choose). Join discussions on [Discord](https://discord.com/invite/ultralytics), [Reddit](https://www.reddit.com/r/ultralytics/), and the [Ultralytics Community Forums](https://community.ultralytics.com)!
162
+
163
+ Request an Enterprise License for commercial use at [Ultralytics Licensing](https://www.ultralytics.com/license).
164
+
165
+ <a href="https://platform.ultralytics.com/ultralytics/yolo26" target="_blank">
166
+ <img width="100%" src="https://raw.githubusercontent.com/ultralytics/assets/refs/heads/main/yolo/performance-comparison.png" alt="YOLO26 performance plots">
167
+ </a>
168
+
169
+ <div align="center">
170
+ <a href="https://github.com/ultralytics"><img src="https://github.com/ultralytics/assets/raw/main/social/logo-social-github.png" width="2%" alt="Ultralytics GitHub"></a>
171
+ <img src="https://github.com/ultralytics/assets/raw/main/social/logo-transparent.png" width="2%" alt="space">
172
+ <a href="https://www.linkedin.com/company/ultralytics/"><img src="https://github.com/ultralytics/assets/raw/main/social/logo-social-linkedin.png" width="2%" alt="Ultralytics LinkedIn"></a>
173
+ <img src="https://github.com/ultralytics/assets/raw/main/social/logo-transparent.png" width="2%" alt="space">
174
+ <a href="https://twitter.com/ultralytics"><img src="https://github.com/ultralytics/assets/raw/main/social/logo-social-twitter.png" width="2%" alt="Ultralytics Twitter"></a>
175
+ <img src="https://github.com/ultralytics/assets/raw/main/social/logo-transparent.png" width="2%" alt="space">
176
+ <a href="https://www.youtube.com/ultralytics?sub_confirmation=1"><img src="https://github.com/ultralytics/assets/raw/main/social/logo-social-youtube.png" width="2%" alt="Ultralytics YouTube"></a>
177
+ <img src="https://github.com/ultralytics/assets/raw/main/social/logo-transparent.png" width="2%" alt="space">
178
+ <a href="https://www.tiktok.com/@ultralytics"><img src="https://github.com/ultralytics/assets/raw/main/social/logo-social-tiktok.png" width="2%" alt="Ultralytics TikTok"></a>
179
+ <img src="https://github.com/ultralytics/assets/raw/main/social/logo-transparent.png" width="2%" alt="space">
180
+ <a href="https://ultralytics.com/bilibili"><img src="https://github.com/ultralytics/assets/raw/main/social/logo-social-bilibili.png" width="2%" alt="Ultralytics BiliBili"></a>
181
+ <img src="https://github.com/ultralytics/assets/raw/main/social/logo-transparent.png" width="2%" alt="space">
182
+ <a href="https://discord.com/invite/ultralytics"><img src="https://github.com/ultralytics/assets/raw/main/social/logo-social-discord.png" width="2%" alt="Ultralytics Discord"></a>
183
+ </div>
184
+
185
+ ## 📄 Documentation
186
+
187
+ See below for quickstart installation and usage examples. For comprehensive guidance on training, validation, prediction, and deployment, refer to our full [Ultralytics Docs](https://docs.ultralytics.com).
188
+
189
+ <details open>
190
+ <summary>Install</summary>
191
+
192
+ Install the `ultralytics` package, including all [requirements](https://github.com/ultralytics/ultralytics/blob/main/pyproject.toml), in a [**Python>=3.8**](https://www.python.org/) environment with [**PyTorch>=1.8**](https://pytorch.org/get-started/locally/).
193
+
194
+ [![PyPI - Version](https://img.shields.io/pypi/v/ultralytics?logo=pypi&logoColor=white)](https://pypi.org/project/ultralytics/) [![Ultralytics Downloads](https://static.pepy.tech/badge/ultralytics)](https://clickpy.clickhouse.com/dashboard/ultralytics) [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/ultralytics?logo=python&logoColor=gold)](https://pypi.org/project/ultralytics/)
195
+
196
+ ```bash
197
+ pip install ultralytics
198
+ ```
199
+
200
+ For alternative installation methods, including [Conda](https://anaconda.org/conda-forge/ultralytics), [Docker](https://hub.docker.com/r/ultralytics/ultralytics), and building from source via Git, please consult the [Quickstart Guide](https://docs.ultralytics.com/quickstart).
201
+
202
+ [![Conda Version](https://img.shields.io/conda/vn/conda-forge/ultralytics?logo=condaforge)](https://anaconda.org/conda-forge/ultralytics) [![Docker Image Version](https://img.shields.io/docker/v/ultralytics/ultralytics?sort=semver&logo=docker)](https://hub.docker.com/r/ultralytics/ultralytics) [![Ultralytics Docker Pulls](https://img.shields.io/docker/pulls/ultralytics/ultralytics?logo=docker)](https://hub.docker.com/r/ultralytics/ultralytics)
203
+
204
+ </details>
205
+
206
+ <details open>
207
+ <summary>Usage</summary>
208
+
209
+ ### CLI
210
+
211
+ You can use Ultralytics YOLO directly from the Command Line Interface (CLI) with the `yolo` command:
212
+
213
+ ```bash
214
+ # Predict using a pretrained YOLO model (e.g., YOLO26n) on an image
215
+ yolo predict model=yolo26n.pt source='https://ultralytics.com/images/bus.jpg'
216
+ ```
217
+
218
+ The `yolo` command supports various tasks and modes, accepting additional arguments like `imgsz=640`. Explore the YOLO [CLI Docs](https://docs.ultralytics.com/usage/cli) for more examples.
219
+
220
+ ### Python
221
+
222
+ Ultralytics YOLO can also be integrated directly into your Python projects. It accepts the same [configuration arguments](https://docs.ultralytics.com/usage/cfg) as the CLI:
223
+
224
+ ```python
225
+ from ultralytics import YOLO
226
+
227
+ # Load a pretrained YOLO26n model
228
+ model = YOLO("yolo26n.pt")
229
+
230
+ # Train the model on the COCO8 dataset for 100 epochs
231
+ train_results = model.train(
232
+ data="coco8.yaml", # Path to dataset configuration file
233
+ epochs=100, # Number of training epochs
234
+ imgsz=640, # Image size for training
235
+ device="cpu", # Device to run on (e.g., 'cpu', 0, [0,1,2,3])
236
+ )
237
+
238
+ # Evaluate the model's performance on the validation set
239
+ metrics = model.val()
240
+
241
+ # Perform object detection on an image
242
+ results = model("path/to/image.jpg") # Predict on an image
243
+ results[0].show() # Display results
244
+
245
+ # Export the model to ONNX format for deployment
246
+ path = model.export(format="onnx") # Returns the path to the exported model
247
+ ```
248
+
249
+ Discover more examples in the YOLO [Python Docs](https://docs.ultralytics.com/usage/python).
250
+
251
+ </details>
252
+
253
+ ## ✨ Models
254
+
255
+ > **[YOLO27 — Coming Soon](https://docs.ultralytics.com/models/yolo27/):** Preview the upcoming family, currently undergoing final R&D. Models are not yet available, and no launch date is set.
256
+
257
+ Ultralytics supports a wide range of YOLO models, from early versions like [YOLOv3](https://docs.ultralytics.com/models/yolov3) to the latest [YOLO26](https://docs.ultralytics.com/models/yolo26). The tables below showcase YOLO26 models pretrained on [COCO](https://docs.ultralytics.com/datasets/detect/coco) for [Detection](https://docs.ultralytics.com/tasks/detect), [Segmentation](https://docs.ultralytics.com/tasks/segment), and [Pose Estimation](https://docs.ultralytics.com/tasks/pose). [Semantic Segmentation](https://docs.ultralytics.com/tasks/semantic) models are pretrained on [Cityscapes](https://docs.ultralytics.com/datasets/semantic/cityscapes), [Depth Estimation](https://docs.ultralytics.com/tasks/depth) models are pretrained on a broad multi-dataset mix and evaluated on [NYU Depth V2](https://cs.nyu.edu/~fergus/datasets/nyu_depth_v2.html), [Classification](https://docs.ultralytics.com/tasks/classify) models are pretrained on [ImageNet](https://docs.ultralytics.com/datasets/classify/imagenet), and [OBB](https://docs.ultralytics.com/tasks/obb) models are pretrained on [DOTAv1](https://docs.ultralytics.com/datasets/obb/dota-v2#dota-v10). [Tracking](https://docs.ultralytics.com/modes/track) mode is compatible with Detection, Segmentation, Pose, and OBB models. The listed [pretrained models](https://docs.ultralytics.com/models) download automatically from the latest Ultralytics [release](https://github.com/ultralytics/assets/releases) on first use.
258
+
259
+ <a href="https://docs.ultralytics.com/tasks" target="_blank">
260
+ <img width="100%" src="https://cdn.ul.run/i/c99d914c3958d0755b5a3d7204b6f24a.avif" alt="Ultralytics YOLO supported tasks">
261
+ </a>
262
+ <br>
263
+ <br>
264
+
265
+ <details open><summary>Detection (COCO)</summary>
266
+
267
+ Explore the [Detection Docs](https://docs.ultralytics.com/tasks/detect) for usage examples. These models are trained on the [COCO dataset](https://cocodataset.org/), featuring 80 object classes.
268
+
269
+ | Model | size<br><sup>(pixels)</sup> | mAP<sup>val<br>50-95</sup> | mAP<sup>val<br>50-95(e2e)</sup> | Speed<br><sup>CPU ONNX<br>(ms)</sup> | Speed<br><sup>T4 TensorRT10<br>(ms)</sup> | params<br><sup>(M)</sup> | FLOPs<br><sup>(B)</sup> |
270
+ | ---------------------------------------------------------------------- | --------------------------- | -------------------------- | ------------------------------- | ------------------------------------ | ----------------------------------------- | ------------------------ | ----------------------- |
271
+ | [YOLO26n](https://platform.ultralytics.com/ultralytics/yolo26/yolo26n) | 640 | 40.9 | 40.1 | 38.9 ± 0.7 | 1.7 ± 0.0 | 2.4 | 5.5 |
272
+ | [YOLO26s](https://platform.ultralytics.com/ultralytics/yolo26/yolo26s) | 640 | 48.6 | 47.8 | 87.2 ± 0.9 | 2.5 ± 0.0 | 9.5 | 20.9 |
273
+ | [YOLO26m](https://platform.ultralytics.com/ultralytics/yolo26/yolo26m) | 640 | 53.1 | 52.5 | 220.0 ± 1.4 | 4.7 ± 0.1 | 20.4 | 68.4 |
274
+ | [YOLO26l](https://platform.ultralytics.com/ultralytics/yolo26/yolo26l) | 640 | 55.0 | 54.4 | 286.2 ± 2.0 | 6.2 ± 0.2 | 24.8 | 86.8 |
275
+ | [YOLO26x](https://platform.ultralytics.com/ultralytics/yolo26/yolo26x) | 640 | 57.5 | 56.9 | 525.8 ± 4.0 | 11.8 ± 0.2 | 55.7 | 194.4 |
276
+
277
+ - **mAP<sup>val</sup>** values refer to single-model single-scale performance on the [COCO val2017](https://cocodataset.org/) dataset. See [YOLO Performance Metrics](https://docs.ultralytics.com/guides/yolo-performance-metrics) for details. <br>Reproduce with `yolo val detect data=coco.yaml device=0`
278
+ - **Speed** metrics are averaged over COCO val images using an [Amazon EC2 P4d](https://aws.amazon.com/ec2/instance-types/p4/) instance. CPU speeds measured with [ONNX](https://onnx.ai/) export. GPU speeds measured with [TensorRT](https://developer.nvidia.com/tensorrt) export. <br>Reproduce with `yolo val detect data=coco.yaml batch=1 device=0|cpu`
279
+
280
+ </details>
281
+
282
+ <details><summary>Segmentation (COCO)</summary>
283
+
284
+ Refer to the [Segmentation Docs](https://docs.ultralytics.com/tasks/segment) for usage examples. These models are trained on [COCO-Seg](https://docs.ultralytics.com/datasets/segment/coco), including 80 classes.
285
+
286
+ | Model | size<br><sup>(pixels)</sup> | mAP<sup>box<br>50-95(e2e)</sup> | mAP<sup>mask<br>50-95(e2e)</sup> | Speed<br><sup>CPU ONNX<br>(ms)</sup> | Speed<br><sup>T4 TensorRT10<br>(ms)</sup> | params<br><sup>(M)</sup> | FLOPs<br><sup>(B)</sup> |
287
+ | ------------------------------------------------------------------------------ | --------------------------- | ------------------------------- | -------------------------------- | ------------------------------------ | ----------------------------------------- | ------------------------ | ----------------------- |
288
+ | [YOLO26n-seg](https://platform.ultralytics.com/ultralytics/yolo26/yolo26n-seg) | 640 | 39.6 | 33.9 | 53.3 ± 0.5 | 2.1 ± 0.0 | 2.7 | 9.3 |
289
+ | [YOLO26s-seg](https://platform.ultralytics.com/ultralytics/yolo26/yolo26s-seg) | 640 | 47.3 | 40.0 | 118.4 ± 0.9 | 3.3 ± 0.0 | 10.4 | 34.5 |
290
+ | [YOLO26m-seg](https://platform.ultralytics.com/ultralytics/yolo26/yolo26m-seg) | 640 | 52.5 | 44.1 | 328.2 ± 2.4 | 6.7 ± 0.1 | 23.6 | 121.7 |
291
+ | [YOLO26l-seg](https://platform.ultralytics.com/ultralytics/yolo26/yolo26l-seg) | 640 | 54.4 | 45.5 | 387.0 ± 3.7 | 8.0 ± 0.1 | 28.0 | 140.1 |
292
+ | [YOLO26x-seg](https://platform.ultralytics.com/ultralytics/yolo26/yolo26x-seg) | 640 | 56.5 | 47.0 | 787.0 ± 6.8 | 16.4 ± 0.1 | 62.8 | 314.0 |
293
+
294
+ - **mAP<sup>val</sup>** values are for single-model single-scale on the [COCO val2017](https://cocodataset.org/) dataset. See [YOLO Performance Metrics](https://docs.ultralytics.com/guides/yolo-performance-metrics) for details. <br>Reproduce with `yolo val segment data=coco.yaml device=0`
295
+ - **Speed** metrics are averaged over COCO val images using an [Amazon EC2 P4d](https://aws.amazon.com/ec2/instance-types/p4/) instance. CPU speeds measured with [ONNX](https://onnx.ai/) export. GPU speeds measured with [TensorRT](https://developer.nvidia.com/tensorrt) export. <br>Reproduce with `yolo val segment data=coco.yaml batch=1 device=0|cpu`
296
+
297
+ </details>
298
+
299
+ <details><summary>Semantic Segmentation (Cityscapes)</summary>
300
+
301
+ See the [Semantic Segmentation Docs](https://docs.ultralytics.com/tasks/semantic) for usage examples. These models are trained on [Cityscapes](https://docs.ultralytics.com/datasets/semantic/cityscapes), including 19 classes.
302
+
303
+ | Model | size<br><sup>(pixels)</sup> | mIoU<sup>val</sup> | Speed<br><sup>RTX3090 PyTorch<br>(ms)</sup> | params<br><sup>(M)</sup> | FLOPs<br><sup>(B)</sup> |
304
+ | ------------------------------------------------------------------------------ | --------------------------- | ------------------ | ------------------------------------------- | ------------------------ | ----------------------- |
305
+ | [YOLO26n-sem](https://platform.ultralytics.com/ultralytics/yolo26/yolo26n-sem) | 1024 &times; 2048 | 78.3 | 4.4 ± 0.0 | 1.6 | 23.8 |
306
+ | [YOLO26s-sem](https://platform.ultralytics.com/ultralytics/yolo26/yolo26s-sem) | 1024 &times; 2048 | 80.8 | 8.4 ± 0.0 | 6.5 | 91.0 |
307
+ | [YOLO26m-sem](https://platform.ultralytics.com/ultralytics/yolo26/yolo26m-sem) | 1024 &times; 2048 | 82.0 | 19.9 ± 0.1 | 14.3 | 305.5 |
308
+ | [YOLO26l-sem](https://platform.ultralytics.com/ultralytics/yolo26/yolo26l-sem) | 1024 &times; 2048 | 82.9 | 26.5 ± 0.1 | 17.8 | 388.2 |
309
+ | [YOLO26x-sem](https://platform.ultralytics.com/ultralytics/yolo26/yolo26x-sem) | 1024 &times; 2048 | 83.6 | 48.9 ± 0.2 | 40.1 | 866.9 |
310
+
311
+ - **mIoU<sup>val</sup>** values are for single-model single-scale on the [Cityscapes](https://www.cityscapes-dataset.com/) validation set. <br>Reproduce with `yolo semantic val data=cityscapes.yaml device=0 imgsz=2048`
312
+ - **Speed** metrics are averaged over Cityscapes validation images using an RTX3090 instance. <br>Reproduce with `yolo semantic val data=cityscapes.yaml batch=1 device=0|cpu imgsz=2048`
313
+
314
+ </details>
315
+
316
+ <details><summary>Depth Estimation (NYU Depth V2)</summary>
317
+
318
+ See the [Depth Estimation Docs](https://docs.ultralytics.com/tasks/depth) for usage examples. These models are pretrained on a broad multi-dataset mix and evaluated on the [NYU Depth V2](https://cs.nyu.edu/~fergus/datasets/nyu_depth_v2.html) Eigen test split, predicting per-pixel depth in meters.
319
+
320
+ | Model | size<br><sup>(pixels)</sup> | delta1<sup>NYU</sup> | abs_rel<sup>NYU</sup> | rmse<sup>NYU</sup> | Speed<br><sup>CPU ONNX<br>(ms)</sup> | Speed<br><sup>T4 TensorRT10<br>(ms)</sup> | params<br><sup>(M)</sup> | FLOPs<br><sup>(B)</sup> |
321
+ | ---------------------------------------------------------------------------------- | --------------------------- | -------------------- | --------------------- | ------------------ | ------------------------------------ | ----------------------------------------- | ------------------------ | ----------------------- |
322
+ | [YOLO26n-depth](https://platform.ultralytics.com/ultralytics/yolo26/yolo26n-depth) | 768 | 0.882 | 0.109 | 0.414 | 272.0 ± 27.2 | 2.7 ± 0.1 | 6.3 | 46.9 |
323
+ | [YOLO26s-depth](https://platform.ultralytics.com/ultralytics/yolo26/yolo26s-depth) | 768 | 0.896 | 0.104 | 0.399 | 393.7 ± 13.1 | 3.8 ± 0.0 | 13.2 | 68.0 |
324
+ | [YOLO26m-depth](https://platform.ultralytics.com/ultralytics/yolo26/yolo26m-depth) | 768 | 0.921 | 0.089 | 0.364 | 621.5 ± 49.7 | 6.0 ± 0.1 | 23.3 | 130.4 |
325
+ | [YOLO26l-depth](https://platform.ultralytics.com/ultralytics/yolo26/yolo26l-depth) | 768 | 0.930 | 0.083 | 0.351 | 821.9 ± 50.7 | 7.7 ± 0.1 | 27.7 | 157.0 |
326
+ | [YOLO26x-depth](https://platform.ultralytics.com/ultralytics/yolo26/yolo26x-depth) | 768 | 0.933 | 0.080 | 0.344 | 1240.9 ± 73.3 | 13.6 ± 0.2 | 57.0 | 301.7 |
327
+
328
+ - **delta1<sup>NYU</sup>** is the percentage of pixels where the predicted depth is within a factor of 1.25 of the ground truth, on the NYU Depth V2 Eigen test split (654 images) with multi-scale + horizontal-flip TTA and log-least-squares alignment.
329
+ - Single-scale accuracy without TTA is reproducible with `yolo depth val model=yolo26n-depth.pt data=nyu-depth.yaml imgsz=768 device=0` (substitute `model=` for each size), which uses median (scale-only) alignment and scores lower: delta1 0.783 (n), 0.793 (s), 0.840 (m), 0.853 (l), 0.860 (x).
330
+ - **abs_rel** is the mean absolute relative error between predicted and ground-truth depth values.
331
+ - **rmse** is the root mean squared error in meters.
332
+ - **Speed** is inference-only latency (pre/post-processing excluded) at `imgsz=768`, `batch=1`, reported as mean ± std over timed runs after warmup. **CPU ONNX** is ONNX Runtime fp32 on a 32-core Intel Xeon (Skylake); **T4 TensorRT10** is TensorRT fp16 on a Tesla T4.
333
+ - **params** and **FLOPs** are measured at 768×768, the training resolution of the released weights.
334
+
335
+ </details>
336
+
337
+ <details><summary>Classification (ImageNet)</summary>
338
+
339
+ Consult the [Classification Docs](https://docs.ultralytics.com/tasks/classify) for usage examples. These models are trained on [ImageNet](https://docs.ultralytics.com/datasets/classify/imagenet), covering 1000 classes.
340
+
341
+ | Model | size<br><sup>(pixels)</sup> | acc<br><sup>top1</sup> | acc<br><sup>top5</sup> | Speed<br><sup>CPU ONNX<br>(ms)</sup> | Speed<br><sup>T4 TensorRT10<br>(ms)</sup> | params<br><sup>(M)</sup> | FLOPs<br><sup>(B) at 224</sup> |
342
+ | ------------------------------------------------------------------------------ | --------------------------- | ---------------------- | ---------------------- | ------------------------------------ | ----------------------------------------- | ------------------------ | ------------------------------ |
343
+ | [YOLO26n-cls](https://platform.ultralytics.com/ultralytics/yolo26/yolo26n-cls) | 224 | 71.4 | 90.1 | 5.0 ± 0.3 | 1.1 ± 0.0 | 2.8 | 0.4 |
344
+ | [YOLO26s-cls](https://platform.ultralytics.com/ultralytics/yolo26/yolo26s-cls) | 224 | 76.0 | 92.9 | 7.9 ± 0.2 | 1.3 ± 0.0 | 6.7 | 1.5 |
345
+ | [YOLO26m-cls](https://platform.ultralytics.com/ultralytics/yolo26/yolo26m-cls) | 224 | 78.1 | 94.2 | 17.2 ± 0.4 | 2.0 ± 0.0 | 11.6 | 4.8 |
346
+ | [YOLO26l-cls](https://platform.ultralytics.com/ultralytics/yolo26/yolo26l-cls) | 224 | 79.0 | 94.6 | 23.2 ± 0.3 | 2.8 ± 0.0 | 14.1 | 6.0 |
347
+ | [YOLO26x-cls](https://platform.ultralytics.com/ultralytics/yolo26/yolo26x-cls) | 224 | 79.9 | 95.0 | 41.4 ± 0.9 | 3.8 ± 0.0 | 29.6 | 13.5 |
348
+
349
+ - **acc** values represent model accuracy on the [ImageNet](https://www.image-net.org/) dataset validation set. <br>Reproduce with `yolo val classify data=path/to/ImageNet device=0`
350
+ - **Speed** metrics are averaged over ImageNet val images using an [Amazon EC2 P4d](https://aws.amazon.com/ec2/instance-types/p4/) instance. CPU speeds measured with [ONNX](https://onnx.ai/) export. GPU speeds measured with [TensorRT](https://developer.nvidia.com/tensorrt) export. <br>Reproduce with `yolo val classify data=path/to/ImageNet batch=1 device=0|cpu`
351
+
352
+ </details>
353
+
354
+ <details><summary>Pose (COCO)</summary>
355
+
356
+ See the [Pose Estimation Docs](https://docs.ultralytics.com/tasks/pose) for usage examples. These models are trained on [COCO-Pose](https://docs.ultralytics.com/datasets/pose/coco), focusing on the 'person' class.
357
+
358
+ | Model | size<br><sup>(pixels)</sup> | mAP<sup>pose<br>50-95(e2e)</sup> | mAP<sup>pose<br>50(e2e)</sup> | Speed<br><sup>CPU ONNX<br>(ms)</sup> | Speed<br><sup>T4 TensorRT10<br>(ms)</sup> | params<br><sup>(M)</sup> | FLOPs<br><sup>(B)</sup> |
359
+ | -------------------------------------------------------------------------------- | --------------------------- | -------------------------------- | ----------------------------- | ------------------------------------ | ----------------------------------------- | ------------------------ | ----------------------- |
360
+ | [YOLO26n-pose](https://platform.ultralytics.com/ultralytics/yolo26/yolo26n-pose) | 640 | 57.2 | 83.3 | 40.3 ± 0.5 | 1.8 ± 0.0 | 2.9 | 7.6 |
361
+ | [YOLO26s-pose](https://platform.ultralytics.com/ultralytics/yolo26/yolo26s-pose) | 640 | 63.0 | 86.6 | 85.3 ± 0.9 | 2.7 ± 0.0 | 10.4 | 24.1 |
362
+ | [YOLO26m-pose](https://platform.ultralytics.com/ultralytics/yolo26/yolo26m-pose) | 640 | 68.8 | 89.6 | 218.0 ± 1.5 | 5.0 ± 0.1 | 21.5 | 73.3 |
363
+ | [YOLO26l-pose](https://platform.ultralytics.com/ultralytics/yolo26/yolo26l-pose) | 640 | 70.4 | 90.5 | 275.4 ± 2.4 | 6.5 ± 0.1 | 25.9 | 91.7 |
364
+ | [YOLO26x-pose](https://platform.ultralytics.com/ultralytics/yolo26/yolo26x-pose) | 640 | 71.6 | 91.6 | 565.4 ± 3.0 | 12.2 ± 0.2 | 57.6 | 202.3 |
365
+
366
+ - **mAP<sup>val</sup>** values are for single-model single-scale on the [COCO Keypoints val2017](https://docs.ultralytics.com/datasets/pose/coco) dataset. See [YOLO Performance Metrics](https://docs.ultralytics.com/guides/yolo-performance-metrics) for details. <br>Reproduce with `yolo val pose data=coco-pose.yaml device=0`
367
+ - **Speed** metrics are averaged over COCO val images using an [Amazon EC2 P4d](https://aws.amazon.com/ec2/instance-types/p4/) instance. CPU speeds measured with [ONNX](https://onnx.ai/) export. GPU speeds measured with [TensorRT](https://developer.nvidia.com/tensorrt) export. <br>Reproduce with `yolo val pose data=coco-pose.yaml batch=1 device=0|cpu`
368
+
369
+ </details>
370
+
371
+ <details><summary>Oriented Bounding Boxes (DOTAv1)</summary>
372
+
373
+ Check the [OBB Docs](https://docs.ultralytics.com/tasks/obb) for usage examples. These models are trained on [DOTAv1](https://docs.ultralytics.com/datasets/obb/dota-v2#dota-v10), including 15 classes.
374
+
375
+ | Model | size<br><sup>(pixels)</sup> | mAP<sup>test<br>50-95(e2e)</sup> | mAP<sup>test<br>50(e2e)</sup> | Speed<br><sup>CPU ONNX<br>(ms)</sup> | Speed<br><sup>T4 TensorRT10<br>(ms)</sup> | params<br><sup>(M)</sup> | FLOPs<br><sup>(B)</sup> |
376
+ | ------------------------------------------------------------------------------ | --------------------------- | -------------------------------- | ----------------------------- | ------------------------------------ | ----------------------------------------- | ------------------------ | ----------------------- |
377
+ | [YOLO26n-obb](https://platform.ultralytics.com/ultralytics/yolo26/yolo26n-obb) | 1024 | 52.4 | 78.9 | 97.7 ± 0.9 | 2.8 ± 0.0 | 2.4 | 14.8 |
378
+ | [YOLO26s-obb](https://platform.ultralytics.com/ultralytics/yolo26/yolo26s-obb) | 1024 | 54.8 | 80.9 | 218.0 ± 1.4 | 4.9 ± 0.1 | 9.8 | 56.7 |
379
+ | [YOLO26m-obb](https://platform.ultralytics.com/ultralytics/yolo26/yolo26m-obb) | 1024 | 55.3 | 81.0 | 579.2 ± 3.8 | 10.2 ± 0.3 | 21.2 | 184.9 |
380
+ | [YOLO26l-obb](https://platform.ultralytics.com/ultralytics/yolo26/yolo26l-obb) | 1024 | 56.2 | 81.6 | 735.6 ± 3.1 | 13.0 ± 0.2 | 25.6 | 232.4 |
381
+ | [YOLO26x-obb](https://platform.ultralytics.com/ultralytics/yolo26/yolo26x-obb) | 1024 | 56.7 | 81.7 | 1485.7 ± 11.5 | 30.5 ± 0.9 | 57.6 | 520.1 |
382
+
383
+ - **mAP<sup>test</sup>** values are for single-model multiscale performance on the [DOTAv1 test set](https://captain-whu.github.io/DOTA/dataset.html). <br>Reproduce by `yolo val obb data=DOTAv1.yaml device=0 split=test` and submit merged results to the [DOTA evaluation server](https://captain-whu.github.io/DOTA/evaluation.html).
384
+ - **Speed** metrics are averaged over [DOTAv1 val images](https://docs.ultralytics.com/datasets/obb/dota-v2#dota-v10) using an [Amazon EC2 P4d](https://aws.amazon.com/ec2/instance-types/p4/) instance. CPU speeds measured with [ONNX](https://onnx.ai/) export. GPU speeds measured with [TensorRT](https://developer.nvidia.com/tensorrt) export. <br>Reproduce by `yolo val obb data=DOTAv1.yaml batch=1 device=0|cpu`
385
+
386
+ </details>
387
+
388
+ ## 🧩 Integrations
389
+
390
+ Our key integrations with leading AI platforms extend the functionality of Ultralytics' offerings, enhancing tasks like dataset labeling, training, visualization, and model management. Discover how Ultralytics, in collaboration with partners like [Weights & Biases](https://docs.ultralytics.com/integrations/weights-biases), [Comet ML](https://docs.ultralytics.com/integrations/comet), [Roboflow](https://docs.ultralytics.com/integrations/roboflow), and [Intel OpenVINO](https://docs.ultralytics.com/integrations/openvino), can optimize your AI workflow. Explore more at [Ultralytics Integrations](https://docs.ultralytics.com/integrations).
391
+
392
+ <a href="https://platform.ultralytics.com" target="_blank">
393
+ <img width="100%" src="https://github.com/ultralytics/assets/raw/main/yolov8/banner-integrations.png" alt="Ultralytics active learning integrations">
394
+ </a>
395
+
396
+ ## 🤝 Contribute
397
+
398
+ We thrive on community collaboration! Ultralytics YOLO wouldn't be the SOTA framework it is without contributions from developers like you. Please see our [Contributing Guide](https://docs.ultralytics.com/help/contributing) to get started. We also welcome your feedback—share your experience by completing our [Survey](https://www.ultralytics.com/survey?utm_source=github&utm_medium=social&utm_campaign=Survey). A huge **Thank You** 🙏 to everyone who contributes!
399
+
400
+ <!-- SVG image from https://opencollective.com/ultralytics/contributors.svg?width=1280 -->
401
+
402
+ [![Ultralytics open-source contributors](https://raw.githubusercontent.com/ultralytics/assets/main/im/image-contributors.png)](https://github.com/ultralytics/ultralytics/graphs/contributors)
403
+
404
+ We look forward to your contributions to help make the Ultralytics ecosystem even better!
405
+
406
+ ## 📜 License
407
+
408
+ Ultralytics offers two licensing options to suit different needs:
409
+
410
+ - **AGPL-3.0 License**: This [OSI-approved](https://opensource.org/license/agpl-3.0) open-source license is perfect for students, researchers, and enthusiasts. It encourages open collaboration and knowledge sharing. See the [LICENSE](https://github.com/ultralytics/ultralytics/blob/main/LICENSE) file for full details.
411
+ - **Ultralytics Enterprise License**: For development and production use, this license enables seamless integration of Ultralytics software and AI models into business products and services, including internal tools, automated workflows, and production deployments, bypassing the open-source requirements of AGPL-3.0. To get started, please contact us via [Ultralytics Licensing](https://www.ultralytics.com/license).
412
+
413
+ ## 📞 Contact
414
+
415
+ For bug reports and feature requests related to Ultralytics software, please visit [GitHub Issues](https://github.com/ultralytics/ultralytics/issues). For questions, discussions, and community support, join our active communities on [Discord](https://discord.com/invite/ultralytics), [Reddit](https://www.reddit.com/r/ultralytics/), and the [Ultralytics Community Forums](https://community.ultralytics.com). We're here to help with all things Ultralytics!
416
+
417
+ <br>
418
+ <div align="center">
419
+ <a href="https://github.com/ultralytics"><img src="https://github.com/ultralytics/assets/raw/main/social/logo-social-github.png" width="3%" alt="Ultralytics GitHub"></a>
420
+ <img src="https://github.com/ultralytics/assets/raw/main/social/logo-transparent.png" width="3%" alt="space">
421
+ <a href="https://www.linkedin.com/company/ultralytics/"><img src="https://github.com/ultralytics/assets/raw/main/social/logo-social-linkedin.png" width="3%" alt="Ultralytics LinkedIn"></a>
422
+ <img src="https://github.com/ultralytics/assets/raw/main/social/logo-transparent.png" width="3%" alt="space">
423
+ <a href="https://twitter.com/ultralytics"><img src="https://github.com/ultralytics/assets/raw/main/social/logo-social-twitter.png" width="3%" alt="Ultralytics Twitter"></a>
424
+ <img src="https://github.com/ultralytics/assets/raw/main/social/logo-transparent.png" width="3%" alt="space">
425
+ <a href="https://www.youtube.com/ultralytics?sub_confirmation=1"><img src="https://github.com/ultralytics/assets/raw/main/social/logo-social-youtube.png" width="3%" alt="Ultralytics YouTube"></a>
426
+ <img src="https://github.com/ultralytics/assets/raw/main/social/logo-transparent.png" width="3%" alt="space">
427
+ <a href="https://www.tiktok.com/@ultralytics"><img src="https://github.com/ultralytics/assets/raw/main/social/logo-social-tiktok.png" width="3%" alt="Ultralytics TikTok"></a>
428
+ <img src="https://github.com/ultralytics/assets/raw/main/social/logo-transparent.png" width="3%" alt="space">
429
+ <a href="https://ultralytics.com/bilibili"><img src="https://github.com/ultralytics/assets/raw/main/social/logo-social-bilibili.png" width="3%" alt="Ultralytics BiliBili"></a>
430
+ <img src="https://github.com/ultralytics/assets/raw/main/social/logo-transparent.png" width="3%" alt="space">
431
+ <a href="https://discord.com/invite/ultralytics"><img src="https://github.com/ultralytics/assets/raw/main/social/logo-social-discord.png" width="3%" alt="Ultralytics Discord"></a>
432
+ </div>
.venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/RECORD ADDED
@@ -0,0 +1,624 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ../../../bin/ultralytics,sha256=WX-brWL1SUqsbGTwxl5HeW8wn6bhgcWatGMHYarFgyI,258
2
+ ../../../bin/yolo,sha256=WX-brWL1SUqsbGTwxl5HeW8wn6bhgcWatGMHYarFgyI,258
3
+ tests/__init__.py,sha256=hgrbjI3dsjk9Ro9oJ5HT0kk4qmTsxGJOijDWKSlBJYk,1512
4
+ tests/__pycache__/__init__.cpython-312.pyc,,
5
+ tests/__pycache__/cache_test_assets.cpython-312.pyc,,
6
+ tests/__pycache__/conftest.cpython-312.pyc,,
7
+ tests/__pycache__/test_cli.cpython-312.pyc,,
8
+ tests/__pycache__/test_cuda.cpython-312.pyc,,
9
+ tests/__pycache__/test_engine.cpython-312.pyc,,
10
+ tests/__pycache__/test_exports.cpython-312.pyc,,
11
+ tests/__pycache__/test_integrations.cpython-312.pyc,,
12
+ tests/__pycache__/test_ndjson_converter.cpython-312.pyc,,
13
+ tests/__pycache__/test_python.cpython-312.pyc,,
14
+ tests/__pycache__/test_solutions.cpython-312.pyc,,
15
+ tests/cache_test_assets.py,sha256=bKqHTLaOkjwbcmhSw1HXMHi7RzFD9mlYAekthPCDxuY,3912
16
+ tests/conftest.py,sha256=syh3U6IsZ9Ii-ZGBBo1iZUcS5RErfaeNiIGzLmKmLd4,5234
17
+ tests/test_cli.py,sha256=lfuL6l4I-zdH9xU5IkcNwIzhTAlPzuxOKImsUg6Y0A0,8285
18
+ tests/test_cuda.py,sha256=ifFIak6IZno6RxJWsWFGF80qS8_K81gKaiR3WFGsEW8,11601
19
+ tests/test_engine.py,sha256=s00D00A5qAepAHfmPyxBeu-oid0KMsGtIALlKIYQGnI,16576
20
+ tests/test_exports.py,sha256=bXmorX2PO-qDdkchMssStwCJrCGZQ_yN02CiGNe_Gss,31053
21
+ tests/test_integrations.py,sha256=H3ND6namUB8Ajwvb_ul12aRFeemslwwa1f7aMmZdAlg,6481
22
+ tests/test_ndjson_converter.py,sha256=-C8w8isPGR4DZ32GrndT9SGDLACm5BX82sqxCsJ15T4,7744
23
+ tests/test_python.py,sha256=PbwyFSdbZLizSEuLbrlsh1B12bpEAr-7z6PPk52K7jw,106586
24
+ tests/test_solutions.py,sha256=Uo7M8oYOdQbBsrxa8qbhFI72bd3c0reF1XMqFS9MByk,19909
25
+ ultralytics-8.4.160.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4
26
+ ultralytics-8.4.160.dist-info/METADATA,sha256=m9n71dx1x1AkF1QlPPnk0LNWkSp5ehoUvzWhfHa0rj0,46654
27
+ ultralytics-8.4.160.dist-info/RECORD,,
28
+ ultralytics-8.4.160.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
29
+ ultralytics-8.4.160.dist-info/WHEEL,sha256=YVMoNqKzERt-wjUZwJ33xBGAwnFl-4cqbYkTtWa4itE,91
30
+ ultralytics-8.4.160.dist-info/entry_points.txt,sha256=YM_wiKyTe9yRrsEfqvYolNO5ngwfoL4-NwgKzc8_7sI,93
31
+ ultralytics-8.4.160.dist-info/licenses/LICENSE,sha256=DZak_2itbUtvHzD3E7GNUYSRK6jdOJ-GqncQ2weavLA,34523
32
+ ultralytics-8.4.160.dist-info/top_level.txt,sha256=XP49TwiMw4QGsvTLSYiJhz1xF_k7ev5mQ8jJXaXi45Q,12
33
+ ultralytics/__init__.py,sha256=MjcMNFArR4cPYhZDVWNGwcX1GWcq8XGnXntVtGX5BVQ,1855
34
+ ultralytics/__pycache__/__init__.cpython-312.pyc,,
35
+ ultralytics/assets/bus.jpg,sha256=wCAZxJecGR63Od3ZRERe9Aja1Weayrb9Ug751DS_vGM,137419
36
+ ultralytics/assets/zidane.jpg,sha256=Ftc4aeMmen1O0A3o6GCDO9FlfBslLpTAw0gnetx7bts,50427
37
+ ultralytics/cfg/__init__.py,sha256=XyCIdsFstVdB82anIc1zyH_4tTnzDz0PBsttzOSEoBU,48520
38
+ ultralytics/cfg/__pycache__/__init__.cpython-312.pyc,,
39
+ ultralytics/cfg/datasets/Argoverse.yaml,sha256=VLuhz_gPQZTAaBFHEzSC9PxMOY3z8TUyUBZVBAm_HFE,3353
40
+ ultralytics/cfg/datasets/DOTAv1.5.yaml,sha256=X-u1bHSwFqf5-vgPIWiJfYev3KK9LHhXZz1ShQNkcc0,1212
41
+ ultralytics/cfg/datasets/DOTAv1.yaml,sha256=GOPKL5JUbdFU_B7jWtOPdz27OnX_DJMCm7WIWrZABr8,1182
42
+ ultralytics/cfg/datasets/GlobalWheat2020.yaml,sha256=_GjE5sxGcpLov7r-M06XsjWlolMiy3xLxs4ksw2lZRc,2143
43
+ ultralytics/cfg/datasets/HomeObjects-3K.yaml,sha256=uQ-wWTT9W-Hr7hiuqa4rMS5ATnkQeMuGReaJsqxeP7U,933
44
+ ultralytics/cfg/datasets/ImageNet.yaml,sha256=06smoReuJ9Q0XmzKlK0Y48z----SeaqgC6zdORy3b28,42528
45
+ ultralytics/cfg/datasets/Objects365.yaml,sha256=fKgiwvntM-RpbfJmAgPmfL3k1lyXl0JZZb6e_RE8v14,9648
46
+ ultralytics/cfg/datasets/SKU-110K.yaml,sha256=cVXoMAOHbik-MAOKqtke6TU2QCaEyn9cBlytqQeKh20,2608
47
+ ultralytics/cfg/datasets/TT100K.yaml,sha256=CMb94ZxiADjg1oKZThY2DrSt7VsqxrxIK3zlCotfQHw,6895
48
+ ultralytics/cfg/datasets/VOC.yaml,sha256=bi2uRXcjuXWyCmCVKFL6bLw9KsRpUgKCoO8Inv-qVE0,3816
49
+ ultralytics/cfg/datasets/VisDrone.yaml,sha256=Yn9g92Ats4tqRiMBzth60kvN7ippLqqdTgJEhJK7Kf4,3395
50
+ ultralytics/cfg/datasets/ade20k.yaml,sha256=8--C9ZPN5bjH-R79n3BKeozkw5tTX2anakx5F5jC35I,4323
51
+ ultralytics/cfg/datasets/african-wildlife.yaml,sha256=GH81S5fG5dAibTw_p1c0ivaLnnvXlGF3kzWtbyU3ejo,914
52
+ ultralytics/cfg/datasets/brain-tumor.yaml,sha256=y5Skd-Yy9wmAfF3E40LYvHQkYsgbDlWU5aKg0EhOwJY,799
53
+ ultralytics/cfg/datasets/carparts-seg.yaml,sha256=4bY17UzYD3f5rYRuPnQsUJQoTFl6XX3jt3wX8zYVihQ,1252
54
+ ultralytics/cfg/datasets/cityscapes.yaml,sha256=hvqK65DEjCM0Xjl9xTqlQxUkYyBQjfRQ2zn561GCnEA,2998
55
+ ultralytics/cfg/datasets/cityscapes8.yaml,sha256=MM7KLZW1Jh2duhIaNM5v6PkUtlFgIypzXDrdnhL5kII,1623
56
+ ultralytics/cfg/datasets/coco-pose.yaml,sha256=BqOkq4lg9FVakySnvAveHdrIBgPR0qIBXTkza3PZMl8,1934
57
+ ultralytics/cfg/datasets/coco.yaml,sha256=OO0esSL61u7Y4Y3PjaVqSybbnCBkvkFTBIXiZE-un38,2583
58
+ ultralytics/cfg/datasets/coco12-formats.yaml,sha256=ZzXepkW2h3u9xJpYYZCPNS9E7htGLKfzxGLTq-aioQo,1952
59
+ ultralytics/cfg/datasets/coco128-seg.yaml,sha256=lr8lrEnrsIM4bqG1YI9hYBrAfygf5CMu9opG8FXJf5Y,1992
60
+ ultralytics/cfg/datasets/coco128.yaml,sha256=B6CDxu3TCY1Mm3x-iRXEbM2N1IyOuXC_sU2ViVg5KEQ,1967
61
+ ultralytics/cfg/datasets/coco8-grayscale.yaml,sha256=ZbTr4lQpqVWCHw9d4Pghi9e3fJagrMLqXqX0wtU06G8,1960
62
+ ultralytics/cfg/datasets/coco8-multispectral.yaml,sha256=mDcNFGmSKT-bBk88EDDnIvuy18utSjAXlso1S581Aok,2062
63
+ ultralytics/cfg/datasets/coco8-pose.yaml,sha256=oaFyz668gJUfiL83UleJSch6UNV-biiL2rLTM6RrZPs,1335
64
+ ultralytics/cfg/datasets/coco8-seg.yaml,sha256=iXAMV5GP2xIO2PHl1JDHXvyIob2neo8RlKHkOVDac7Q,1912
65
+ ultralytics/cfg/datasets/coco8.yaml,sha256=Awqv-gj4oWHcNYfSFqqVbAyJR-WUstnYUVo2uaxE-fo,1887
66
+ ultralytics/cfg/datasets/construction-ppe.yaml,sha256=iSa27Cwowv1vycVK_o3hK8UXwHE8EdNTI6NvDVBynck,1007
67
+ ultralytics/cfg/datasets/crack-seg.yaml,sha256=H11kG8GPQhpvl6C5IEzWoySsQy5p0gYC30BrePVeU-Y,836
68
+ ultralytics/cfg/datasets/depth-arkitscenes.yaml,sha256=Ym_kMKmOhVGDaqbzQqsHyokZFRTlwSzWgOkL95MozyM,934
69
+ ultralytics/cfg/datasets/depth-diode.yaml,sha256=IH7X9SfSSK0-yskqzIAjJktTIok9MnEF-1hDOsTeQ9M,2604
70
+ ultralytics/cfg/datasets/depth-hypersim.yaml,sha256=PoUHvMpL-JPOWoQEGExxQZ5dxiTJlDeRdNT5Ybu7I94,919
71
+ ultralytics/cfg/datasets/depth-kitti.yaml,sha256=8BqOxTR85QdMojOQ7I8Alp6M8RSQ3xZNcMy8MjuEPco,6839
72
+ ultralytics/cfg/datasets/depth-sunrgbd.yaml,sha256=AmeZ6TnXXwg-d97I7YfsspFsnpFPCSAu6HWx0O3IpKs,2618
73
+ ultralytics/cfg/datasets/depth-tartanair.yaml,sha256=zFzkeEPCVru96l9LW1WK69HVmfDK78-IVjolxnpBy90,1078
74
+ ultralytics/cfg/datasets/depth-vkitti2.yaml,sha256=QzynjZVemhBA8_msM-ev6BzxjXx998snPwszPoZ08aY,2655
75
+ ultralytics/cfg/datasets/depth8.yaml,sha256=th5DihHacbV6fswmVQugsTZkHRCX_6AkffN1SAsjCqY,1407
76
+ ultralytics/cfg/datasets/dog-pose.yaml,sha256=OboPj_y8QlEGH9ECqLNuT32RY_YapEo3IUn8Walvym0,1407
77
+ ultralytics/cfg/datasets/dota128.yaml,sha256=Kzktc64z93wTZdg3hvHrZyszlhNTZ4oPVsbXkkmtVGg,1079
78
+ ultralytics/cfg/datasets/dota8-multispectral.yaml,sha256=sZzrP1SUMryEJe8syMb6BsAghIbyfMQuqHI0BxiMRS4,1216
79
+ ultralytics/cfg/datasets/dota8.yaml,sha256=W_3Bcp8dRHeOL0VFWsaaNEXq8Kj2PzgYwVEQqeOtNqQ,1058
80
+ ultralytics/cfg/datasets/hand-keypoints.yaml,sha256=wPLYeZmGQ8lWI89oLwRVMDGnBka6H7yPZCtxeg8P878,1362
81
+ ultralytics/cfg/datasets/kitti.yaml,sha256=PRyDF6bkfG3X4aYv6PTUTSGHiCUsVAA2i9i8KO9OElI,894
82
+ ultralytics/cfg/datasets/lvis.yaml,sha256=t1M8pAfMBEDe9qx9D8f9aLhY2n_d-qKapDF5Sf7jSI8,29577
83
+ ultralytics/cfg/datasets/medical-pills.yaml,sha256=5GLYrB0rwkOrDSe1KswZAuly1LWdNyW1GsASRGHaKEM,791
84
+ ultralytics/cfg/datasets/nyu-depth.yaml,sha256=EVIgKsVOItj4247xKGDb622Ees1JAUGorb3Ip25u_SU,1145
85
+ ultralytics/cfg/datasets/open-images-v7.yaml,sha256=SXRor53GRNFJEB78CQcn08b9ZEWR9MwujFresA9K2Eg,12115
86
+ ultralytics/cfg/datasets/package-seg.yaml,sha256=1Fc7f65s8G3ts6ZTOpzwVDC5_1wMUlRiFsYzrZpXyNo,848
87
+ ultralytics/cfg/datasets/signature.yaml,sha256=134eo-EpaK9XxISzTZnUP2bNtn3Hb-5j_-nO4Pt-JJM,773
88
+ ultralytics/cfg/datasets/tiger-pose.yaml,sha256=DQk5S7uH5JbP3pD6Q7I12AAagNRA3AKiZTeubsjhYR4,1195
89
+ ultralytics/cfg/datasets/xView.yaml,sha256=m2pWXw_SheDPwkPdNEVLIlx9uLhTEOTgOxePe7MG2Jo,5405
90
+ ultralytics/cfg/default.yaml,sha256=BpT6a-NlaIi4k6Z6rcSxckCg0ZDPeZsQw0fpYVC3Kbc,10347
91
+ ultralytics/cfg/models/11/yolo11-cls-resnet18.yaml,sha256=1Ycp9qMrwpb8rq7cqht3Q-1gMN0R87U35nm2j_isdro,524
92
+ ultralytics/cfg/models/11/yolo11-cls.yaml,sha256=17l5GdN-Vst4LvafsK2-q6Li9VX9UlUcT5ClCtikweE,1412
93
+ ultralytics/cfg/models/11/yolo11-obb.yaml,sha256=FHo7xWrhKdN2BBn2xdZ099T2NcqcUJiuyQ0a6zdvrqY,2031
94
+ ultralytics/cfg/models/11/yolo11-pose.yaml,sha256=dWOT9VBRxD8h-jmQC0qWEOvFvyx1CUa0tekt1kOdvmk,2131
95
+ ultralytics/cfg/models/11/yolo11-seg.yaml,sha256=xyTWVhFoSszF1LhNEIznIW8QGKU1z0EAIvkp4OwYtls,2046
96
+ ultralytics/cfg/models/11/yolo11.yaml,sha256=Q9inyGrMdygt30lm1lJuCR5bBkwUDtSm5MC2jsvDeEw,2012
97
+ ultralytics/cfg/models/11/yoloe-11-seg.yaml,sha256=j053cYgHMCRFUxJ7MumNkHz7eq6hxvcMMuNOzNsdV1w,2072
98
+ ultralytics/cfg/models/11/yoloe-11.yaml,sha256=qxKDa8Xt-embNVOLOthfQlt1N0kFFHnGFO74R_CQzUw,2038
99
+ ultralytics/cfg/models/12/yolo12-cls.yaml,sha256=yJBuDOXRYLa-LQipGkLBT97ujKSyXx755zts612JVWc,1407
100
+ ultralytics/cfg/models/12/yolo12-obb.yaml,sha256=2cPJKV7kU1thYxnnNsCJPfWNoTk0l29ZD22U4XTX3wQ,1972
101
+ ultralytics/cfg/models/12/yolo12-pose.yaml,sha256=eBo-9b3o_qv3-jftgCaX0FedeJWOfKHDLJPPfCMwu7M,2072
102
+ ultralytics/cfg/models/12/yolo12-seg.yaml,sha256=0JTqSjyhOTLNTIrIFAOuu6F7yQqMkq1soscAkSZtsz8,1985
103
+ ultralytics/cfg/models/12/yolo12.yaml,sha256=ZeA8LuymJXPNjZ5xkxkZHkcktDaKDzUBb2Kc3gCLC1w,1953
104
+ ultralytics/cfg/models/26/yolo26-cls.yaml,sha256=GmaLvnB62X6r9_mZwpx0b2LTRYIXzVYqSqR3Mcy336g,1432
105
+ ultralytics/cfg/models/26/yolo26-depth.yaml,sha256=QaShA165oh8HEGrSPV1EyhEMp2kHFPfw3lzCDHXRq7s,1664
106
+ ultralytics/cfg/models/26/yolo26-obb.yaml,sha256=A9Ng5nZOow74tYkejxoVyGB2wztIi_cuNqxYrqB5T38,2146
107
+ ultralytics/cfg/models/26/yolo26-p2.yaml,sha256=Dbwvo9_t5e3NolZquMfqFQrQZuop155o1sTaK6tHYnk,2405
108
+ ultralytics/cfg/models/26/yolo26-p6.yaml,sha256=eMRZmGxEgjY7X6PAwRV1vVJcEzjAaB3u8nfG2_GTkl0,2467
109
+ ultralytics/cfg/models/26/yolo26-pose.yaml,sha256=B7qC2WNwI_Jh5SbDj6muuKsF2RF2b_2M9PSM0z8nGI0,2245
110
+ ultralytics/cfg/models/26/yolo26-seg.yaml,sha256=U8A0ijaj4Zu8O9T2lfUMu_yXowWfYumyUfJ4rXT918s,2156
111
+ ultralytics/cfg/models/26/yolo26-sem.yaml,sha256=rX3g2vBk7U9T7ejtCjLWqjOaXaPNMEeR2BWq2oe5nYI,1850
112
+ ultralytics/cfg/models/26/yolo26.yaml,sha256=sdH6DGns7WT5k5U2A4vY1pfDLnIgCzQYenZ95DGvfvA,2120
113
+ ultralytics/cfg/models/26/yoloe-26-seg.yaml,sha256=QlyK3awjLOjs9q0raj0we5QCG1tDy-NvQ2uQzKDoBYk,2223
114
+ ultralytics/cfg/models/26/yoloe-26.yaml,sha256=YWsBS4D3f7QhqLQzYT-LVdCOISo0VaTILIaLKmujDdo,2191
115
+ ultralytics/cfg/models/rt-detr/rtdetr-l.yaml,sha256=hXFvYmdpy13fANWfz2yvtYFKrRljKBAL3HyTMG9lDoM,2043
116
+ ultralytics/cfg/models/rt-detr/rtdetr-resnet101.yaml,sha256=5vCPfihyzXMKCR7kYYIDSHbSHvAzYlWbOZ5Wp9m84Ms,1696
117
+ ultralytics/cfg/models/rt-detr/rtdetr-resnet50.yaml,sha256=Xm-U_m-_okdspiW7qxb5mgN_NPZPvyjXrS1A1KcoaFo,1692
118
+ ultralytics/cfg/models/rt-detr/rtdetr-x.yaml,sha256=QHa3B5Pwd9TA9B3W5lEwrUl-_bAvwGXVqSlvnLSbKNs,2250
119
+ ultralytics/cfg/models/v10/yolov10b.yaml,sha256=W9K-lqgUEKOCpV0Ae7dk8iBUFpSTTFzDPDL3AHnMKfs,1488
120
+ ultralytics/cfg/models/v10/yolov10l.yaml,sha256=YtdL74ivxWxY2jUsYkkUX_WraWsLJtcOKhRNioCwvJg,1488
121
+ ultralytics/cfg/models/v10/yolov10m.yaml,sha256=YQuxn4KjiGqxwK-3BuRSprt86aWxcxn2VngIlHQKxy4,1479
122
+ ultralytics/cfg/models/v10/yolov10n.yaml,sha256=iL9T4XUrTnf001i6e9qF9wEBCUoral_fF5bjIFxJdMU,1474
123
+ ultralytics/cfg/models/v10/yolov10s.yaml,sha256=dG_z0fSweIzCi7Km9OY-Q9IztEOjX67wFsdP4Eam_to,1483
124
+ ultralytics/cfg/models/v10/yolov10x.yaml,sha256=IFIYR5p46OECsHK3yz5UO5CMxR1JNDWeXKzUQQvxM_M,1491
125
+ ultralytics/cfg/models/v3/yolov3-spp.yaml,sha256=hsM-yhdWv-8XlWuaSOVqFJcHUVZ-FmjH4QjkA9CHJZU,1625
126
+ ultralytics/cfg/models/v3/yolov3-tiny.yaml,sha256=SYrSg0m1A6ErUapdrJDI5E-edLaH0oF-NRb558DZgmQ,1330
127
+ ultralytics/cfg/models/v3/yolov3.yaml,sha256=Fvt4_PTwLBpRw3R4v4VQ-1PIiojpoFZD1uuTZySUYSw,1612
128
+ ultralytics/cfg/models/v5/yolov5-p6.yaml,sha256=VKEWykksykSlzvuy7if4yFo9WlblC3hdqcNxJ9bwHek,1994
129
+ ultralytics/cfg/models/v5/yolov5.yaml,sha256=QD8dRe5e5ys52wXPKvNJn622H_3iX0jPzE_2--2dZx0,1626
130
+ ultralytics/cfg/models/v6/yolov6.yaml,sha256=tl04iHe4dVg_78jgupVul5gbqOn5hBhtLKfP3xYxcWA,1813
131
+ ultralytics/cfg/models/v8/yoloe-v8-seg.yaml,sha256=5cjZ2xCMUF2pV7gv1ZoRFEV6Lo6v4slMQt1lU7_Jqtc,2064
132
+ ultralytics/cfg/models/v8/yoloe-v8.yaml,sha256=dujtgHql2RzqqEEpB4UzsEpAXMRarkltnt8vb1usILc,2015
133
+ ultralytics/cfg/models/v8/yolov8-cls-resnet101.yaml,sha256=TAiAkZwUckzjWdY6yn_ulGzM-lnHaY7Yx9v8rI-2WoA,1014
134
+ ultralytics/cfg/models/v8/yolov8-cls-resnet50.yaml,sha256=gbIttNMvj02Rk3eKjq45qgjdmdCo5n_mV9R5xt65OdU,1010
135
+ ultralytics/cfg/models/v8/yolov8-cls.yaml,sha256=G50mnw-C0SWrZpZl5wzov1dugdjZMM6zT30t5cQrcJQ,1019
136
+ ultralytics/cfg/models/v8/yolov8-ghost-p2.yaml,sha256=5MX8D3_8lkj9aKVwpAIC1PZAaMoTFs_Wq-XZUTVn9PU,2505
137
+ ultralytics/cfg/models/v8/yolov8-ghost-p6.yaml,sha256=c7YYnEPx2vrwHjbgr4o_Q9f_NI2X1dx2MrLo9xeOvXc,2575
138
+ ultralytics/cfg/models/v8/yolov8-ghost.yaml,sha256=nxzIlvntFajHbu4DN8ujEx65PREgn7o0Dd6cHp8pHSM,2198
139
+ ultralytics/cfg/models/v8/yolov8-obb.yaml,sha256=Owlncx5peKBTNo3xhkbVxz_1qlzVJR4Z2zNeoR_NDxg,2016
140
+ ultralytics/cfg/models/v8/yolov8-p2.yaml,sha256=ulQ2Pp8oPo9gsPoIQ-s3EVCTM41vknPM1PdPYGOXVPQ,1831
141
+ ultralytics/cfg/models/v8/yolov8-p6.yaml,sha256=TqIsa8gNEW04KmdLxxC9rqhd7PCHlUqkzoiDxnMTio0,2363
142
+ ultralytics/cfg/models/v8/yolov8-pose-p6.yaml,sha256=tfgfYrbVu5biWCWmdTZRr7ZRC-zlAzycsRyaJbDtI1g,2047
143
+ ultralytics/cfg/models/v8/yolov8-pose.yaml,sha256=LdzbiIVknZQMLYB2wzCHqul3NilfKp4nx5SdaGQsF6s,1676
144
+ ultralytics/cfg/models/v8/yolov8-rtdetr.yaml,sha256=5cupHKPHD43cuvd3H3zvNijiqpW9-bFLKg-KMeRzOPE,2055
145
+ ultralytics/cfg/models/v8/yolov8-seg-p6.yaml,sha256=7FlNlY-sB8bCcVty2Hf_nYD8fxZpsqaTgGxTfac8DRI,1958
146
+ ultralytics/cfg/models/v8/yolov8-seg.yaml,sha256=hFeiOFVwTV4zv08IrmTIuzJcUZmYkY7SIi2oV322e6U,1587
147
+ ultralytics/cfg/models/v8/yolov8-world.yaml,sha256=2hNQoybITO5FBNnKKz05Pk9ygeAf4qW7XvkMEfBd90A,2174
148
+ ultralytics/cfg/models/v8/yolov8-worldv2.yaml,sha256=UkdRhk7pauLIZto7QdOrWpW8Mb-3J61RdRuxS5lZC24,2124
149
+ ultralytics/cfg/models/v8/yolov8.yaml,sha256=QFo8MC62CWEDqZr02CwdLYsrv_RpoijFWqyUSywZZyo,1977
150
+ ultralytics/cfg/models/v9/yolov9c-seg.yaml,sha256=UBHoQ_cJV2yp6rMzHXRp46uBAUmKIrbgd3jiEBPRvqI,1447
151
+ ultralytics/cfg/models/v9/yolov9c.yaml,sha256=x1kus_2mQdU9V3ZGg0XdE5WTUU3j8fwGe1Ou3x2aX5I,1426
152
+ ultralytics/cfg/models/v9/yolov9e-seg.yaml,sha256=WVpU5jHgoUuCMVirvmn_ScOmH9d1MyVVIX8XAY8787c,2377
153
+ ultralytics/cfg/models/v9/yolov9e.yaml,sha256=Olr2PlADpkD6N1TiVyAJEMzkrA7SbNul1nOaUF8CS38,2355
154
+ ultralytics/cfg/models/v9/yolov9m.yaml,sha256=WcKQ3xRsC1JMgA42Hx4xzr4FZmtE6B3wKvqhlQxkqw8,1411
155
+ ultralytics/cfg/models/v9/yolov9s.yaml,sha256=cWkQtYNWWOckOBXjd8XrJ_q5v6T_C54xGMP1S3qnpZU,1392
156
+ ultralytics/cfg/models/v9/yolov9t.yaml,sha256=Q8GpSXE7fumhuJiQg4a2SkuS_UmnXqp-eoZxW_C0vEo,1375
157
+ ultralytics/cfg/trackers/botsort.yaml,sha256=jNiJMNO-VVe-B3fzhO7P8KNqcBGFD-YT_ApoF4v9WwE,1385
158
+ ultralytics/cfg/trackers/bytetrack.yaml,sha256=OVcB2UenSRed7j4yexGBtzDEypjnysWiqwUoCq5XO4s,856
159
+ ultralytics/cfg/trackers/deepocsort.yaml,sha256=9y-amFdoivTfHcdD-xWruov_iieqjSwsaGq6beMZC9k,1844
160
+ ultralytics/cfg/trackers/fasttrack.yaml,sha256=YAeLULJ9sh54zQ3BCTY5yO53tPhqzNvFZlfTrClEPtc,1584
161
+ ultralytics/cfg/trackers/ocsort.yaml,sha256=VduR8U2z8BRm2Banrw-fqu63T0SF2mMBnH7WmpqvtuM,1267
162
+ ultralytics/cfg/trackers/tracktrack.yaml,sha256=M_zQz0ICP6vBz_k-h2n5SeP5Kjkhmot94Vf8YSod43o,1889
163
+ ultralytics/data/__init__.py,sha256=KsV__8wWRNzjd-iUeIX57Pvtmet28MSxjHqG1ux-YoM,702
164
+ ultralytics/data/__pycache__/__init__.cpython-312.pyc,,
165
+ ultralytics/data/__pycache__/annotator.cpython-312.pyc,,
166
+ ultralytics/data/__pycache__/augment.cpython-312.pyc,,
167
+ ultralytics/data/__pycache__/base.cpython-312.pyc,,
168
+ ultralytics/data/__pycache__/build.cpython-312.pyc,,
169
+ ultralytics/data/__pycache__/converter.cpython-312.pyc,,
170
+ ultralytics/data/__pycache__/dataset.cpython-312.pyc,,
171
+ ultralytics/data/__pycache__/loaders.cpython-312.pyc,,
172
+ ultralytics/data/__pycache__/split.cpython-312.pyc,,
173
+ ultralytics/data/__pycache__/split_dota.cpython-312.pyc,,
174
+ ultralytics/data/__pycache__/utils.cpython-312.pyc,,
175
+ ultralytics/data/annotator.py,sha256=Xiqm46EBgLjcdJRCHfHsXNNSJGIZINL0-CS-4WeJ8_I,3065
176
+ ultralytics/data/augment.py,sha256=NjGvKZWOF7xELLqkmmvTK2YGFbG7EXGk6OhpK6zh9Cg,144677
177
+ ultralytics/data/base.py,sha256=uX5kc8VRO3E0sYGK_f6I2WFsI6WdS4GJgbn0ZghM1J0,23278
178
+ ultralytics/data/build.py,sha256=w0kDofMHbezIXAD6tCR9SejgiRGYgLWu1zqz_-qGijM,19612
179
+ ultralytics/data/converter.py,sha256=DlW-UJGWHdDuaUC7lNCRCtbj0MXq9Sz2wyLzsSVUL_I,47827
180
+ ultralytics/data/dataset.py,sha256=Kq9g3bzVQOLjRN7mhtZtf7ZlioSgS7PJPJIcJJays9E,59488
181
+ ultralytics/data/loaders.py,sha256=6Run_1xFA1x46C46_7H7kjOyZ6FXM4YA8GBZ4X0Ir1s,34629
182
+ ultralytics/data/scripts/download_weights.sh,sha256=0y8XtZxOru7dVThXDFUXLHBuICgOIqZNUwpyL4Rh6lg,595
183
+ ultralytics/data/scripts/get_coco.sh,sha256=UuJpJeo3qQpTHVINeOpmP0NYmg8PhEFE3A8J3jKrnPw,1768
184
+ ultralytics/data/scripts/get_coco128.sh,sha256=qmRQl_hOKrsdHrTrnyQuFIH01oDz3lfaz138OgGfLt8,650
185
+ ultralytics/data/scripts/get_imagenet.sh,sha256=hr42H16bM47iT27rgS7MpEo-GeOZAYUQXgr0B2cwn48,1705
186
+ ultralytics/data/split.py,sha256=M_fSp011rMWmMqFKpoGsgx3uLWJdPzTDiyXrwwZaOVk,5269
187
+ ultralytics/data/split_dota.py,sha256=oEVbGYYdzKupeI-upeZu8JNwEtSIo0zkaI9dBpbtqeM,12878
188
+ ultralytics/data/utils.py,sha256=hfJNV5vbEy6a9nnrbzRjXs04eoDwmEsGXBy4ia3NZdQ,39335
189
+ ultralytics/engine/__init__.py,sha256=lm6MckFYCPTbqIoX7w0s_daxdjNeBeKW6DXppv1-QUM,70
190
+ ultralytics/engine/__pycache__/__init__.cpython-312.pyc,,
191
+ ultralytics/engine/__pycache__/exporter.cpython-312.pyc,,
192
+ ultralytics/engine/__pycache__/model.cpython-312.pyc,,
193
+ ultralytics/engine/__pycache__/predictor.cpython-312.pyc,,
194
+ ultralytics/engine/__pycache__/results.cpython-312.pyc,,
195
+ ultralytics/engine/__pycache__/trainer.cpython-312.pyc,,
196
+ ultralytics/engine/__pycache__/tuner.cpython-312.pyc,,
197
+ ultralytics/engine/__pycache__/validator.cpython-312.pyc,,
198
+ ultralytics/engine/exporter.py,sha256=DXjD9Pe6RDy50XxLhLiz7xmk4f-a0V-gBzoYg2CYPYI,95619
199
+ ultralytics/engine/model.py,sha256=blwAAdWJHkIAK9ix1_VQhcaaHo3X_9zF3Vi2PC-GPYg,61738
200
+ ultralytics/engine/predictor.py,sha256=zLfaYMY0_guALjjbJWUiW6fom6WiqJuS-o-TTpA_Se4,26443
201
+ ultralytics/engine/results.py,sha256=I0pSf8QrsqweZ0_GHDkRq7A47UCo87Ji3oMUlEiCzFo,74760
202
+ ultralytics/engine/trainer.py,sha256=7VWT9aIrje--KqhH_h4kkMXMdO0WBMWm99F4T29w-kg,70196
203
+ ultralytics/engine/tuner.py,sha256=Fpp8bMK0YYh0PVxRfQ25yviJL73gO5BImrxqvjxs7l4,29414
204
+ ultralytics/engine/validator.py,sha256=UFq4Io55U6FDtdYbvXdO-jMCwjETQt6mDz5F0OX9350,19931
205
+ ultralytics/models/__init__.py,sha256=TVCojzWJkI4N9TQHfSFFR6syzZTZrJ1IvmzsUhbpXwI,670
206
+ ultralytics/models/__pycache__/__init__.cpython-312.pyc,,
207
+ ultralytics/models/__pycache__/llm.cpython-312.pyc,,
208
+ ultralytics/models/fastsam/__init__.py,sha256=Ku89Fy_X8ok3YPEUajjUZ5i4O08jdJMjJHt-3Z99Frk,231
209
+ ultralytics/models/fastsam/__pycache__/__init__.cpython-312.pyc,,
210
+ ultralytics/models/fastsam/__pycache__/model.cpython-312.pyc,,
211
+ ultralytics/models/fastsam/__pycache__/predict.cpython-312.pyc,,
212
+ ultralytics/models/fastsam/__pycache__/utils.cpython-312.pyc,,
213
+ ultralytics/models/fastsam/__pycache__/val.cpython-312.pyc,,
214
+ ultralytics/models/fastsam/model.py,sha256=AySAHLqcK3Z4NBmVBxaJHJPTturAeyYsgvp5iWESPrA,3434
215
+ ultralytics/models/fastsam/predict.py,sha256=ESwsdrswG3OA6FddxWrJwP8ZIfdreaAg4_v6rCjsdpA,9322
216
+ ultralytics/models/fastsam/utils.py,sha256=de9ieh4pBUuTNh5HTiNdRpWZhXAaSfNo3R1FNMt2GOE,879
217
+ ultralytics/models/fastsam/val.py,sha256=MJUKx_NpFEeuqSq9ynX1FJSK6F5RhUJB-PqhQp2Q0YM,2091
218
+ ultralytics/models/llm.py,sha256=fVhr0preQ0lO-woi3dIlxCd_UUSLICxfnhtWwyoAOVU,7685
219
+ ultralytics/models/nas/__init__.py,sha256=Q4ZQak8xNWtV5YSw_pFu0anbCyDxxEAuMMDfMzu6-0s,207
220
+ ultralytics/models/nas/__pycache__/__init__.cpython-312.pyc,,
221
+ ultralytics/models/nas/__pycache__/model.cpython-312.pyc,,
222
+ ultralytics/models/nas/__pycache__/predict.cpython-312.pyc,,
223
+ ultralytics/models/nas/__pycache__/val.cpython-312.pyc,,
224
+ ultralytics/models/nas/model.py,sha256=-JF98xlK2tp92uwXhReE9s1eikRNacvcdiRJ6wyx6Ac,3599
225
+ ultralytics/models/nas/predict.py,sha256=4nbuo9nbvnvI3qVH1ylhLCjo-7oW39MumIesm-1eU3Y,2692
226
+ ultralytics/models/nas/val.py,sha256=MIRym3LQNDIRxnYs5xcOiLkKOgv3enZFXh5_g9Pq2hA,1543
227
+ ultralytics/models/rtdetr/__init__.py,sha256=F4NEQqtcVKFxj97Dh7rkn2Vu3JG4Ea_nxqrBB-9P1vc,225
228
+ ultralytics/models/rtdetr/__pycache__/__init__.cpython-312.pyc,,
229
+ ultralytics/models/rtdetr/__pycache__/model.cpython-312.pyc,,
230
+ ultralytics/models/rtdetr/__pycache__/predict.cpython-312.pyc,,
231
+ ultralytics/models/rtdetr/__pycache__/train.cpython-312.pyc,,
232
+ ultralytics/models/rtdetr/__pycache__/val.cpython-312.pyc,,
233
+ ultralytics/models/rtdetr/model.py,sha256=jJzSh_5E__rVQO7_IkmncpC4jIdu9xNiIxlTTIaFJVw,2269
234
+ ultralytics/models/rtdetr/predict.py,sha256=SU5UPoyxLmFCZ2IsSaYb6vux8bsrw90K79FajFDdl80,3969
235
+ ultralytics/models/rtdetr/train.py,sha256=JTRwzn-syHuh6fFfQgDWa2XfKjY26d9NxRwctHbpZ64,3925
236
+ ultralytics/models/rtdetr/val.py,sha256=R1QHGjif93luFtVZaB_UDfwLlJgJdWjd1DeXd_n1ZuU,8062
237
+ ultralytics/models/sam/__init__.py,sha256=hofz9cGGhxEWpZXX8yLp5k_LQUmWL_Shd9kfzK4U6z0,592
238
+ ultralytics/models/sam/__pycache__/__init__.cpython-312.pyc,,
239
+ ultralytics/models/sam/__pycache__/amg.cpython-312.pyc,,
240
+ ultralytics/models/sam/__pycache__/build.cpython-312.pyc,,
241
+ ultralytics/models/sam/__pycache__/build_sam3.cpython-312.pyc,,
242
+ ultralytics/models/sam/__pycache__/model.cpython-312.pyc,,
243
+ ultralytics/models/sam/__pycache__/predict.cpython-312.pyc,,
244
+ ultralytics/models/sam/amg.py,sha256=aYvJ7jQMkTR3X9KV7SHi3qP3yNchQggWNUurTRZwxQg,11786
245
+ ultralytics/models/sam/build.py,sha256=NUGwH8hKtYtob9vIBb-FzB8QjL5aJ4HpgrwZMFo1IOI,12865
246
+ ultralytics/models/sam/build_sam3.py,sha256=I4TSSIdjGeo9FWnF9iNFBpUnzSX65rWNdzOxXTN0ajo,12658
247
+ ultralytics/models/sam/model.py,sha256=fV-gMkd7zaqphrRMikIPRHasm7GbSWbL1amgL8ZMF_A,7407
248
+ ultralytics/models/sam/modules/__init__.py,sha256=lm6MckFYCPTbqIoX7w0s_daxdjNeBeKW6DXppv1-QUM,70
249
+ ultralytics/models/sam/modules/__pycache__/__init__.cpython-312.pyc,,
250
+ ultralytics/models/sam/modules/__pycache__/blocks.cpython-312.pyc,,
251
+ ultralytics/models/sam/modules/__pycache__/decoders.cpython-312.pyc,,
252
+ ultralytics/models/sam/modules/__pycache__/encoders.cpython-312.pyc,,
253
+ ultralytics/models/sam/modules/__pycache__/memory_attention.cpython-312.pyc,,
254
+ ultralytics/models/sam/modules/__pycache__/sam.cpython-312.pyc,,
255
+ ultralytics/models/sam/modules/__pycache__/tiny_encoder.cpython-312.pyc,,
256
+ ultralytics/models/sam/modules/__pycache__/transformer.cpython-312.pyc,,
257
+ ultralytics/models/sam/modules/__pycache__/utils.cpython-312.pyc,,
258
+ ultralytics/models/sam/modules/blocks.py,sha256=eXfnwhGlKj3kLIr1u9K0iN1aUTxYdbv4bcFSvLbVRe0,44175
259
+ ultralytics/models/sam/modules/decoders.py,sha256=MGUC8zs8FFtSacBwrp4Nva7sgYmCXpULPW-TmVXz4wg,25045
260
+ ultralytics/models/sam/modules/encoders.py,sha256=IDtcpWf2f0OBNUKa81FwRcZFzoG8umIQ7LI8Mm5W2ss,35520
261
+ ultralytics/models/sam/modules/memory_attention.py,sha256=x8AjFkmK7sx4qXDCdJ_yBsxtQBqeldYNBMRe8ntpLHs,13287
262
+ ultralytics/models/sam/modules/sam.py,sha256=qk0pz7QxNX1I4eie3hx-KWxIUn5KLRz5-EcSpS2d_0k,61666
263
+ ultralytics/models/sam/modules/tiny_encoder.py,sha256=w-JWH9NNXCKjyR-9qlfie3xjXHLPPiw6d-fvTIkXxAo,42400
264
+ ultralytics/models/sam/modules/transformer.py,sha256=qGcEt5coPyWeaXjK1nzt-ID5HW2Q30u6tAxSyOkx3Sg,14884
265
+ ultralytics/models/sam/modules/utils.py,sha256=HwHAf_yxMnYc1cs5bAnPIDyOkIbrUMw0qha9TB8olU0,21371
266
+ ultralytics/models/sam/predict.py,sha256=-7sKoSJW43sdWQ1rU6g8InZg7UHygfVdcL-ZQfG4nt8,206505
267
+ ultralytics/models/sam/sam3/__init__.py,sha256=aM4-KimnYgIFe-e5ctLT8e6k9PagvuvKFaHaagDZM7E,144
268
+ ultralytics/models/sam/sam3/__pycache__/__init__.cpython-312.pyc,,
269
+ ultralytics/models/sam/sam3/__pycache__/decoder.cpython-312.pyc,,
270
+ ultralytics/models/sam/sam3/__pycache__/encoder.cpython-312.pyc,,
271
+ ultralytics/models/sam/sam3/__pycache__/geometry_encoders.cpython-312.pyc,,
272
+ ultralytics/models/sam/sam3/__pycache__/maskformer_segmentation.cpython-312.pyc,,
273
+ ultralytics/models/sam/sam3/__pycache__/model_misc.cpython-312.pyc,,
274
+ ultralytics/models/sam/sam3/__pycache__/necks.cpython-312.pyc,,
275
+ ultralytics/models/sam/sam3/__pycache__/sam3_image.cpython-312.pyc,,
276
+ ultralytics/models/sam/sam3/__pycache__/text_encoder_ve.cpython-312.pyc,,
277
+ ultralytics/models/sam/sam3/__pycache__/vitdet.cpython-312.pyc,,
278
+ ultralytics/models/sam/sam3/__pycache__/vl_combiner.cpython-312.pyc,,
279
+ ultralytics/models/sam/sam3/decoder.py,sha256=LLHD8cKvENMnKyjxUtlVTjmGQK4jjxHplMgs5bwh-bc,21593
280
+ ultralytics/models/sam/sam3/encoder.py,sha256=KWAcX8iNgKZINgafFvhmPi_v0xgNelzlu4fQF48owDY,20834
281
+ ultralytics/models/sam/sam3/geometry_encoders.py,sha256=xPI5bkNwTvj8LHBd6QiuSeP7JC42rF2y72Gabl9Uu4w,17666
282
+ ultralytics/models/sam/sam3/maskformer_segmentation.py,sha256=GhAfZ_7MkEHkkanFQCCKMOccH8-tCUp3MKBwc4Q8mrQ,10725
283
+ ultralytics/models/sam/sam3/model_misc.py,sha256=6cn_gjdFkstVnDN8y21JYQeDNOx54k081vrVCE_K5ig,7906
284
+ ultralytics/models/sam/sam3/necks.py,sha256=tyYRPfylf0vkdNm_SjNaAmouA3xq8udsR0pJHPjwYLI,4766
285
+ ultralytics/models/sam/sam3/sam3_image.py,sha256=F4nlCNSF0xVpHAxiPCWyVDH6M8BvajJq3tbNdwHPLPM,14726
286
+ ultralytics/models/sam/sam3/text_encoder_ve.py,sha256=8IAFY1V0CQsKdvNvE-HSKhabxAuL5TJ-a2JP_pK8EXg,12251
287
+ ultralytics/models/sam/sam3/vitdet.py,sha256=fOTtE3_ihvDUKEBbiXzfkloKG0Vow4fOGo4W7QvlAvQ,22103
288
+ ultralytics/models/sam/sam3/vl_combiner.py,sha256=6bCZNuxeBWbRgZJ_-CxOXS3BHoaHBstD8MuZWxFtJys,6997
289
+ ultralytics/models/utils/__init__.py,sha256=lm6MckFYCPTbqIoX7w0s_daxdjNeBeKW6DXppv1-QUM,70
290
+ ultralytics/models/utils/__pycache__/__init__.cpython-312.pyc,,
291
+ ultralytics/models/utils/__pycache__/loss.cpython-312.pyc,,
292
+ ultralytics/models/utils/__pycache__/ops.cpython-312.pyc,,
293
+ ultralytics/models/utils/loss.py,sha256=tTRVZvq0Ot0beUdkEBQ2QJACeI4Zm2tkKCdd-kCH3CI,20909
294
+ ultralytics/models/utils/ops.py,sha256=hF3DM_i-BOIcYWRi7NvXKpxx7DxzQE8cAZhQlIYBnQQ,16471
295
+ ultralytics/models/yolo/__init__.py,sha256=8F7fGMtNWr6da0WUpBaxLHIxuZ5nyxZiP3Ro6BuFhgo,398
296
+ ultralytics/models/yolo/__pycache__/__init__.cpython-312.pyc,,
297
+ ultralytics/models/yolo/__pycache__/model.cpython-312.pyc,,
298
+ ultralytics/models/yolo/classify/__init__.py,sha256=9--HVaNOfI1K7rn_rRqclL8FUAnpfeBrRqEQIaQw2xM,383
299
+ ultralytics/models/yolo/classify/__pycache__/__init__.cpython-312.pyc,,
300
+ ultralytics/models/yolo/classify/__pycache__/predict.cpython-312.pyc,,
301
+ ultralytics/models/yolo/classify/__pycache__/train.cpython-312.pyc,,
302
+ ultralytics/models/yolo/classify/__pycache__/val.cpython-312.pyc,,
303
+ ultralytics/models/yolo/classify/predict.py,sha256=rEUHwxnCX-0Wjx8A84GpoAzSZHAtrcTJEf46SOd0Mpk,5102
304
+ ultralytics/models/yolo/classify/train.py,sha256=kWDo6xFHkP-KwGtzQTAn16tauXbmjPDKwosDNA-_9vU,8709
305
+ ultralytics/models/yolo/classify/val.py,sha256=UVoaUjLlJxq5ACdKPLpEclQARfumjIQywMOXX5WnE94,10742
306
+ ultralytics/models/yolo/depth/__init__.py,sha256=G5M0uC7zkLqkkEjiWXx9qnTC8VaIjPAlMTYPQemtFzM,233
307
+ ultralytics/models/yolo/depth/__pycache__/__init__.cpython-312.pyc,,
308
+ ultralytics/models/yolo/depth/__pycache__/calibrate.cpython-312.pyc,,
309
+ ultralytics/models/yolo/depth/__pycache__/predict.cpython-312.pyc,,
310
+ ultralytics/models/yolo/depth/__pycache__/train.cpython-312.pyc,,
311
+ ultralytics/models/yolo/depth/__pycache__/val.cpython-312.pyc,,
312
+ ultralytics/models/yolo/depth/calibrate.py,sha256=HsQ-0LIT5bqzYRqIavQ2dM6EeSt9YQnopSW5P4pFDsM,15538
313
+ ultralytics/models/yolo/depth/predict.py,sha256=sTx62IM9NPx1GSV6EYJYtQ4nGf3NZxbodxL9i1GCZTw,2162
314
+ ultralytics/models/yolo/depth/train.py,sha256=ilhFyaMoMxA49xr6r1CX5d34gbSM5klumytupoPtbEM,7580
315
+ ultralytics/models/yolo/depth/val.py,sha256=wKZTV9kIqyh6M5C2NkUUS1z7SwVN4Kxl3lK7phXajog,5572
316
+ ultralytics/models/yolo/detect/__init__.py,sha256=GIRsLYR-kT4JJx7lh4ZZAFGBZj0aebokuU0A7JbjDVA,257
317
+ ultralytics/models/yolo/detect/__pycache__/__init__.cpython-312.pyc,,
318
+ ultralytics/models/yolo/detect/__pycache__/predict.cpython-312.pyc,,
319
+ ultralytics/models/yolo/detect/__pycache__/train.cpython-312.pyc,,
320
+ ultralytics/models/yolo/detect/__pycache__/val.cpython-312.pyc,,
321
+ ultralytics/models/yolo/detect/predict.py,sha256=L01OgXeC2lbZ1oZAhHJ6lXal0nY3DMGBFDViKUGiOF0,5474
322
+ ultralytics/models/yolo/detect/train.py,sha256=dtaxgSWe3AmwP3zqH51ZvU7aL3lkFGu7LnbU9yAdz18,12440
323
+ ultralytics/models/yolo/detect/val.py,sha256=sV_LCExB63HZx2pp8kma_O7s7A8F0a7pjdEkPEz091o,28856
324
+ ultralytics/models/yolo/model.py,sha256=Jo_fDLjuukMm8dm2bjL1Wvw01rl6ueci2KqWyCUC6WI,26868
325
+ ultralytics/models/yolo/obb/__init__.py,sha256=tQmpG8wVHsajWkZdmD6cjGohJ4ki64iSXQT8JY_dydo,221
326
+ ultralytics/models/yolo/obb/__pycache__/__init__.cpython-312.pyc,,
327
+ ultralytics/models/yolo/obb/__pycache__/predict.cpython-312.pyc,,
328
+ ultralytics/models/yolo/obb/__pycache__/train.cpython-312.pyc,,
329
+ ultralytics/models/yolo/obb/__pycache__/val.cpython-312.pyc,,
330
+ ultralytics/models/yolo/obb/predict.py,sha256=VA5yRo32IVakZ_5nY75KArfaXnZbANzTkxMVGDm-co4,2634
331
+ ultralytics/models/yolo/obb/train.py,sha256=d-xh-NrM0B_WEn70lOj_XIVEg20hyXe4DYvFj1iur64,3381
332
+ ultralytics/models/yolo/obb/val.py,sha256=5Cc61ejAAyWtzM3v_cpkRrP0e360IUtty--iPYf-xU8,14592
333
+ ultralytics/models/yolo/pose/__init__.py,sha256=_9OFLj19XwvJHBRxQtVW5CV7rvJ_3hDPE97miit0sPc,227
334
+ ultralytics/models/yolo/pose/__pycache__/__init__.cpython-312.pyc,,
335
+ ultralytics/models/yolo/pose/__pycache__/predict.cpython-312.pyc,,
336
+ ultralytics/models/yolo/pose/__pycache__/train.cpython-312.pyc,,
337
+ ultralytics/models/yolo/pose/__pycache__/val.cpython-312.pyc,,
338
+ ultralytics/models/yolo/pose/predict.py,sha256=a_D6-0qCRhTL_ccFe6UTNB1jgaB3Mp1wedLDQpeLPeM,3175
339
+ ultralytics/models/yolo/pose/train.py,sha256=yfN79C7eCrsAp7CJq9i6VRVQxZqfa_SFgGJWtKdhGQ4,4813
340
+ ultralytics/models/yolo/pose/val.py,sha256=EH18gpiwLqMf78-PKN5Xoehd8SyPv_o382OA9pcz5Sc,12489
341
+ ultralytics/models/yolo/segment/__init__.py,sha256=3IThhZ1wlkY9FvmWm9cE-5-ZyE6F1FgzAtQ6jOOFzzw,275
342
+ ultralytics/models/yolo/segment/__pycache__/__init__.cpython-312.pyc,,
343
+ ultralytics/models/yolo/segment/__pycache__/predict.cpython-312.pyc,,
344
+ ultralytics/models/yolo/segment/__pycache__/train.cpython-312.pyc,,
345
+ ultralytics/models/yolo/segment/__pycache__/val.cpython-312.pyc,,
346
+ ultralytics/models/yolo/segment/predict.py,sha256=L4DCWXgvMwsSs_S16xE0VBa4PpnWr4baO75ZQIm94Bw,5556
347
+ ultralytics/models/yolo/segment/train.py,sha256=fjbdj4BwLa8EGwGHcx9hElAxQTqHrNw3h4bz6p1fvz8,3043
348
+ ultralytics/models/yolo/segment/val.py,sha256=mUoSVokRoxURAkIlfIp4n24GuQZwW3sk6tTzj5DIGqQ,13527
349
+ ultralytics/models/yolo/semantic/__init__.py,sha256=yzL8Q1Ap2etFevc5YPsPv57zDFXldRM0X2vRjArFP7E,323
350
+ ultralytics/models/yolo/semantic/__pycache__/__init__.cpython-312.pyc,,
351
+ ultralytics/models/yolo/semantic/__pycache__/predict.cpython-312.pyc,,
352
+ ultralytics/models/yolo/semantic/__pycache__/train.cpython-312.pyc,,
353
+ ultralytics/models/yolo/semantic/__pycache__/val.cpython-312.pyc,,
354
+ ultralytics/models/yolo/semantic/predict.py,sha256=vxjPWsF6anQRdMPLUIwGx_nteykOLbpZoQa5zL8suLQ,4340
355
+ ultralytics/models/yolo/semantic/train.py,sha256=-XWy-AARIQSUjeOxGkOj2W2f4fIWCgM9beZsN0LLMQk,6317
356
+ ultralytics/models/yolo/semantic/val.py,sha256=YooJK3dTG-kwmo13cUq9akCdPWXtojelmky89GvOD2k,8478
357
+ ultralytics/models/yolo/world/__init__.py,sha256=MjFKnREHgSY4pZIRzQIVs0nXbSkXPaAn9FHPHGxggWY,181
358
+ ultralytics/models/yolo/world/__pycache__/__init__.cpython-312.pyc,,
359
+ ultralytics/models/yolo/world/__pycache__/train.cpython-312.pyc,,
360
+ ultralytics/models/yolo/world/__pycache__/train_world.cpython-312.pyc,,
361
+ ultralytics/models/yolo/world/__pycache__/val.cpython-312.pyc,,
362
+ ultralytics/models/yolo/world/train.py,sha256=NxLvKuxAifKTIk9-56tNZDN_oXNbPyGrd_C---ndBxo,8162
363
+ ultralytics/models/yolo/world/train_world.py,sha256=w4kq_lyPmZm2FiC8OA_WtXXxMbR0K4zz-6a72HKwv1c,9436
364
+ ultralytics/models/yolo/world/val.py,sha256=_dXTsd1CbcUJn7hF7BLxYaGBFtfdfTC-ZIRLSeSeByY,2329
365
+ ultralytics/models/yolo/yoloe/__init__.py,sha256=zaZo1_ommaxNv7mD7xpdSomNF4s8mpOcCVTXspg0ncY,760
366
+ ultralytics/models/yolo/yoloe/__pycache__/__init__.cpython-312.pyc,,
367
+ ultralytics/models/yolo/yoloe/__pycache__/predict.cpython-312.pyc,,
368
+ ultralytics/models/yolo/yoloe/__pycache__/train.cpython-312.pyc,,
369
+ ultralytics/models/yolo/yoloe/__pycache__/train_seg.cpython-312.pyc,,
370
+ ultralytics/models/yolo/yoloe/__pycache__/val.cpython-312.pyc,,
371
+ ultralytics/models/yolo/yoloe/predict.py,sha256=ZzcI0VyRoJbUNtzheW_ag9wtqJx5bzmpsu8Buv7f59c,5854
372
+ ultralytics/models/yolo/yoloe/train.py,sha256=WMUL2UBK6pzp7oo4WcN5uP52Oon7aRombdelYSNgP3w,12939
373
+ ultralytics/models/yolo/yoloe/train_seg.py,sha256=1wHPnq2Oeb-efWf4hUt14BM8Shy4oJNi2ItzyfxgffE,905
374
+ ultralytics/models/yolo/yoloe/val.py,sha256=jdwKHkk0JztBgjtbCrmEzXEN8Wb2bBoX49dGJAjO2qc,9229
375
+ ultralytics/nn/__init__.py,sha256=538LZPUKKvc3JCMgiQ4VLGqRN2ZAaVLFcQbeNNHFkEA,545
376
+ ultralytics/nn/__pycache__/__init__.cpython-312.pyc,,
377
+ ultralytics/nn/__pycache__/autobackend.cpython-312.pyc,,
378
+ ultralytics/nn/__pycache__/distill_model.cpython-312.pyc,,
379
+ ultralytics/nn/__pycache__/tasks.cpython-312.pyc,,
380
+ ultralytics/nn/__pycache__/text_model.cpython-312.pyc,,
381
+ ultralytics/nn/autobackend.py,sha256=OHLhHVRQTRwrAQmGu3z4liketWwZKOXEWpLqehQgq0A,18376
382
+ ultralytics/nn/backends/__init__.py,sha256=AT3IYM33czoTRKSfifeGhjD-OyHcgttpbqxv0gAgbCc,1606
383
+ ultralytics/nn/backends/__pycache__/__init__.cpython-312.pyc,,
384
+ ultralytics/nn/backends/__pycache__/ascend.cpython-312.pyc,,
385
+ ultralytics/nn/backends/__pycache__/axelera.cpython-312.pyc,,
386
+ ultralytics/nn/backends/__pycache__/base.cpython-312.pyc,,
387
+ ultralytics/nn/backends/__pycache__/coreai.cpython-312.pyc,,
388
+ ultralytics/nn/backends/__pycache__/coreml.cpython-312.pyc,,
389
+ ultralytics/nn/backends/__pycache__/deepx.cpython-312.pyc,,
390
+ ultralytics/nn/backends/__pycache__/executorch.cpython-312.pyc,,
391
+ ultralytics/nn/backends/__pycache__/hailo.cpython-312.pyc,,
392
+ ultralytics/nn/backends/__pycache__/litert.cpython-312.pyc,,
393
+ ultralytics/nn/backends/__pycache__/mnn.cpython-312.pyc,,
394
+ ultralytics/nn/backends/__pycache__/ncnn.cpython-312.pyc,,
395
+ ultralytics/nn/backends/__pycache__/onnx.cpython-312.pyc,,
396
+ ultralytics/nn/backends/__pycache__/openvino.cpython-312.pyc,,
397
+ ultralytics/nn/backends/__pycache__/paddle.cpython-312.pyc,,
398
+ ultralytics/nn/backends/__pycache__/pytorch.cpython-312.pyc,,
399
+ ultralytics/nn/backends/__pycache__/qnn.cpython-312.pyc,,
400
+ ultralytics/nn/backends/__pycache__/rknn.cpython-312.pyc,,
401
+ ultralytics/nn/backends/__pycache__/tensorflow.cpython-312.pyc,,
402
+ ultralytics/nn/backends/__pycache__/tensorrt.cpython-312.pyc,,
403
+ ultralytics/nn/backends/__pycache__/triton.cpython-312.pyc,,
404
+ ultralytics/nn/backends/ascend.py,sha256=GeNx8TKDPqeo4-EAgI1__C2bfdBRo1Qn21jkrmheJvU,2315
405
+ ultralytics/nn/backends/axelera.py,sha256=Bj4rh3WImlbL8NpaM0VCXT4PFGhky9pt7xNYFSaNY58,2641
406
+ ultralytics/nn/backends/base.py,sha256=ylVXmaBV29wDWk209x1dtVuxPefompDCiEkyjaxvOOo,10175
407
+ ultralytics/nn/backends/coreai.py,sha256=_7pynrFvW-bnPQ_5G2rCR3ZB__6POB0fCRAjDPM0vDM,2392
408
+ ultralytics/nn/backends/coreml.py,sha256=2tSdWcCOrnbwinumMwBsMtU39J2m_6mWcOCqMxCZanc,3937
409
+ ultralytics/nn/backends/deepx.py,sha256=MBGKxuqPQJQLNAcVnF9RRe519mWkElRukhZnQuT2YZg,2629
410
+ ultralytics/nn/backends/executorch.py,sha256=KaCfKE9H4ngfv73ktY3JrLvLVqjRe1Z45lCg4NZxDHY,1569
411
+ ultralytics/nn/backends/hailo.py,sha256=EwPMzumGaf0CpMLl-Pf-Xi2yr3eAXytvhrCi7JLLl4E,11555
412
+ ultralytics/nn/backends/litert.py,sha256=effsmrTHSP2FxpIu3RNgMyO_EMP6F0K5fj5eV40N-jI,5440
413
+ ultralytics/nn/backends/mnn.py,sha256=UYg_a7GmsO9fWWJUc-HIh5e_dMmdg6D-vnRoob54TbM,2220
414
+ ultralytics/nn/backends/ncnn.py,sha256=y180W614YBm-xxObSR3WcY95QHOiZlQ8oFKbNTdKTWs,2390
415
+ ultralytics/nn/backends/onnx.py,sha256=kNUBF1eA2kzVt5EKXoyKYmImEF0mpuvmUQ01LLzT524,10064
416
+ ultralytics/nn/backends/openvino.py,sha256=LtlvTyyOnQLYdfuzapF97-MXYRqOLs0BWE7njSh2Shw,5896
417
+ ultralytics/nn/backends/paddle.py,sha256=JqvnBOZDq9lFlmZ6WdUMpuPcuvCN6X24zKzt5w27f7Y,2844
418
+ ultralytics/nn/backends/pytorch.py,sha256=mLcsv4nMgRsFTC4g_Czknl6_zC72hEqWb1Hh-rB_1Sw,6207
419
+ ultralytics/nn/backends/qnn.py,sha256=Dbg11h9PrkxMGbuthLNSqnhw7kKFP1lGF-Ha_G7MkhY,3311
420
+ ultralytics/nn/backends/rknn.py,sha256=Wi4VVOdW0PDtsFod0o9rn41coiDlNza40uK9azCy9OY,2863
421
+ ultralytics/nn/backends/tensorflow.py,sha256=iiC_KsQbXv4Y7eXljOBHu-DYSBb2WU6PWesRzGz60oA,7062
422
+ ultralytics/nn/backends/tensorrt.py,sha256=DFoo2IiGHCUph-E5bOIJhOaHFpthANbRbOijNu6cjVo,7646
423
+ ultralytics/nn/backends/triton.py,sha256=tfPmifMNxSlH95BPiqASGQd-6k_9URGHYE9HTlQpYFc,1463
424
+ ultralytics/nn/distill_model.py,sha256=_nf11RnJSGFKAGDlJanFU3rn-Can_luu5ydKFenqp1w,14204
425
+ ultralytics/nn/modules/__init__.py,sha256=GoECx_bcD3NuIquK_NAWisX8ScjAkBOc3M4yqv7r2Lo,3390
426
+ ultralytics/nn/modules/__pycache__/__init__.cpython-312.pyc,,
427
+ ultralytics/nn/modules/__pycache__/activation.cpython-312.pyc,,
428
+ ultralytics/nn/modules/__pycache__/block.cpython-312.pyc,,
429
+ ultralytics/nn/modules/__pycache__/conv.cpython-312.pyc,,
430
+ ultralytics/nn/modules/__pycache__/head.cpython-312.pyc,,
431
+ ultralytics/nn/modules/__pycache__/transformer.cpython-312.pyc,,
432
+ ultralytics/nn/modules/__pycache__/utils.cpython-312.pyc,,
433
+ ultralytics/nn/modules/activation.py,sha256=ULZlEWxed-Euw-89XjEBbTTfFWlFtAa78AiH3YeVhdk,2218
434
+ ultralytics/nn/modules/block.py,sha256=-BXGVvxcDW9okyLx7xNlU0nF0BN5L98Ip7kVZ1HiG-M,75557
435
+ ultralytics/nn/modules/conv.py,sha256=VI7h8_ooVCrUa5IOTUJxWU76Cbx2xKswZ6CKlm8wZI0,21132
436
+ ultralytics/nn/modules/head.py,sha256=YXtb3W4tYJxxh-AN8RUA_UCCXz0iMqNJ5tjz8HZW2Xk,83854
437
+ ultralytics/nn/modules/transformer.py,sha256=YIa-EYImoIX0Mp8z9f-QwUXFwpBWQ0Tmgl30-kTspTQ,32625
438
+ ultralytics/nn/modules/utils.py,sha256=GFPEw2DOftXRC0B_M0j03Jp6QRYcezU6tbQDTcsr8_w,4939
439
+ ultralytics/nn/tasks.py,sha256=P0OjD6aRdNGDL7K-BpOiZmukC1oOpLEngbhu8tjD8vA,99504
440
+ ultralytics/nn/text_model.py,sha256=T9oobJQ0tYEMI2jdMEThT6oPf4VESJqf7IhV3s4ruVM,15402
441
+ ultralytics/optim/__init__.py,sha256=7pu_peIqRKkJWdhlQsfhARQnWy19v5baP6jSJK0znYE,116
442
+ ultralytics/optim/__pycache__/__init__.cpython-312.pyc,,
443
+ ultralytics/optim/__pycache__/muon.cpython-312.pyc,,
444
+ ultralytics/optim/muon.py,sha256=_iZIhUJ_ngkcdLh1eAlYoUAFKVCLD970yOl6NPqyFJs,12200
445
+ ultralytics/py.typed,sha256=la67KBlbjXN-_-DfGNcdOcjYumVpKG_Tkw-8n5dnGB4,8
446
+ ultralytics/solutions/__init__.py,sha256=Jj7OcRiYjHH-e104H4xTgjjR5W6aPB4mBRndbaSPmgU,1209
447
+ ultralytics/solutions/__pycache__/__init__.cpython-312.pyc,,
448
+ ultralytics/solutions/__pycache__/ai_gym.cpython-312.pyc,,
449
+ ultralytics/solutions/__pycache__/analytics.cpython-312.pyc,,
450
+ ultralytics/solutions/__pycache__/config.cpython-312.pyc,,
451
+ ultralytics/solutions/__pycache__/distance_calculation.cpython-312.pyc,,
452
+ ultralytics/solutions/__pycache__/heatmap.cpython-312.pyc,,
453
+ ultralytics/solutions/__pycache__/instance_segmentation.cpython-312.pyc,,
454
+ ultralytics/solutions/__pycache__/object_blurrer.cpython-312.pyc,,
455
+ ultralytics/solutions/__pycache__/object_counter.cpython-312.pyc,,
456
+ ultralytics/solutions/__pycache__/object_cropper.cpython-312.pyc,,
457
+ ultralytics/solutions/__pycache__/parking_management.cpython-312.pyc,,
458
+ ultralytics/solutions/__pycache__/queue_management.cpython-312.pyc,,
459
+ ultralytics/solutions/__pycache__/region_counter.cpython-312.pyc,,
460
+ ultralytics/solutions/__pycache__/security_alarm.cpython-312.pyc,,
461
+ ultralytics/solutions/__pycache__/similarity_search.cpython-312.pyc,,
462
+ ultralytics/solutions/__pycache__/solutions.cpython-312.pyc,,
463
+ ultralytics/solutions/__pycache__/speed_estimation.cpython-312.pyc,,
464
+ ultralytics/solutions/__pycache__/streamlit_inference.cpython-312.pyc,,
465
+ ultralytics/solutions/__pycache__/trackzone.cpython-312.pyc,,
466
+ ultralytics/solutions/__pycache__/vision_eye.cpython-312.pyc,,
467
+ ultralytics/solutions/ai_gym.py,sha256=PAjZpzDmyIjxIfbOooTrFmNnZAthJkIMNF-cmOH0R3s,6095
468
+ ultralytics/solutions/analytics.py,sha256=q9FEY3ZiaL8xH3hJ1Lhr0X8AA70sK-b4_joqA95NzZ0,12714
469
+ ultralytics/solutions/config.py,sha256=P7KLPNe1qAUnlE_n3HnY98G8Jp4Pak13oMRMh-_BNC4,6007
470
+ ultralytics/solutions/distance_calculation.py,sha256=zLEjU1jk1K_daotwbxNGRIoNJjNnif8LQ_G7Spkh6to,6020
471
+ ultralytics/solutions/heatmap.py,sha256=R4FR5i9E5oCS6nd7m622Ga0E7yEZ9b61YCSVm_xixc0,5719
472
+ ultralytics/solutions/instance_segmentation.py,sha256=uP810WlECIRAbwgX4lXqV5l8vvLp7zvf0FG0RlaYjUE,3786
473
+ ultralytics/solutions/object_blurrer.py,sha256=MPFZ3glegV-LLfUsJ3QtUXbhf06SyNE8Ud749UVPsVs,4200
474
+ ultralytics/solutions/object_counter.py,sha256=OwHvEGetQYNE7t-7_CgSNwUoVSLXGjKhZc1nZyulKL8,10270
475
+ ultralytics/solutions/object_cropper.py,sha256=9NLr4egGJNPX_2wtf4nQtRo1f_wZlpv7fgJt2Xkp0j0,3551
476
+ ultralytics/solutions/parking_management.py,sha256=6RDFoIFW7lkL7Drvo809WMp0jLmX1nVmedmrcRnMcVs,13815
477
+ ultralytics/solutions/queue_management.py,sha256=NtrGJmxKSlu5gsQw2vmj5E9fQWgIvGDE56IQ_PfMZ_Q,4393
478
+ ultralytics/solutions/region_counter.py,sha256=bjXrCClmts5_Vfd9ipvx4WKKbDQUFQlutwVIzhwIv0k,6428
479
+ ultralytics/solutions/security_alarm.py,sha256=c7odhqvxXOSiLVk1W1deAzDyJ5bQukS_shHayVbl8gc,6273
480
+ ultralytics/solutions/similarity_search.py,sha256=ARkqa47WtSRgdcAeOvX64zLIWDcD3sFcec7O-u17CJ4,9907
481
+ ultralytics/solutions/solutions.py,sha256=d6f_jnEbuZODa4Qn6T9qTVuSn0LLJOEk5fRUkOzjhLY,39011
482
+ ultralytics/solutions/speed_estimation.py,sha256=0q0uw8OdvZHKhwsXAacwIvEUSxLTmW7t8kTfQPkMWpc,6276
483
+ ultralytics/solutions/streamlit_inference.py,sha256=OK26OHSKrXsLe00eE2I53a_W3LunqlaY27KAeLkbXXM,13099
484
+ ultralytics/solutions/templates/similarity-search.html,sha256=epX8XDLasOUx8ISPuKP9M0SRUjRcv_FE1r_EG3QpBtw,4177
485
+ ultralytics/solutions/trackzone.py,sha256=An9tNETx_5DY6xy2ZI8mcrNMXRzEezjm3HRseoO7R2A,3910
486
+ ultralytics/solutions/vision_eye.py,sha256=8aScUfkuUGzrHsxB1k6nC5w8Xa_RqW7W7FcAgTdgE7Q,3006
487
+ ultralytics/trackers/__init__.py,sha256=-1tfYXBxpb-y2rYB7H5oD2R0bxbwEfKXIRdz8dzW5JI,482
488
+ ultralytics/trackers/__pycache__/__init__.cpython-312.pyc,,
489
+ ultralytics/trackers/__pycache__/basetrack.cpython-312.pyc,,
490
+ ultralytics/trackers/__pycache__/bot_sort.cpython-312.pyc,,
491
+ ultralytics/trackers/__pycache__/byte_tracker.cpython-312.pyc,,
492
+ ultralytics/trackers/__pycache__/deep_oc_sort.cpython-312.pyc,,
493
+ ultralytics/trackers/__pycache__/fast_tracker.cpython-312.pyc,,
494
+ ultralytics/trackers/__pycache__/oc_sort.cpython-312.pyc,,
495
+ ultralytics/trackers/__pycache__/track.cpython-312.pyc,,
496
+ ultralytics/trackers/__pycache__/track_tracker.cpython-312.pyc,,
497
+ ultralytics/trackers/basetrack.py,sha256=nvCUuaVP8vUskRi1vRovhLozGqVXJ39UGG3hFyjC9-g,3752
498
+ ultralytics/trackers/bot_sort.py,sha256=HXQXKrkd7zlJMc1ssKR4MaYOrXSITpYzTC6CknzwNUk,10020
499
+ ultralytics/trackers/byte_tracker.py,sha256=igEo5FOwXxlpMke2sr3t_jOonpMh88R2cesJKJYnkyw,23745
500
+ ultralytics/trackers/deep_oc_sort.py,sha256=xjlPYML2I-tWzP76LRvhH9tjoemyzB5hMPC_DfSQkfY,11845
501
+ ultralytics/trackers/fast_tracker.py,sha256=v78bti4_qccQExCaLWkT2gfV3PfTN9QIu1kOK2py6Vw,17560
502
+ ultralytics/trackers/oc_sort.py,sha256=1_Kl1JeDDDrj5ObDj_yvfhqezbygXYl-FPT5GhYKl-s,15550
503
+ ultralytics/trackers/track.py,sha256=oL1eAwoaVvLm4YhXrM078uXycgrlgQF42cQXnICnyAI,6468
504
+ ultralytics/trackers/track_tracker.py,sha256=hoHghNLWuAqZwMv8s1yz5LYPYadcYTJedZLsQom1eg0,28088
505
+ ultralytics/trackers/utils/__init__.py,sha256=lm6MckFYCPTbqIoX7w0s_daxdjNeBeKW6DXppv1-QUM,70
506
+ ultralytics/trackers/utils/__pycache__/__init__.cpython-312.pyc,,
507
+ ultralytics/trackers/utils/__pycache__/gmc.cpython-312.pyc,,
508
+ ultralytics/trackers/utils/__pycache__/kalman_filter.cpython-312.pyc,,
509
+ ultralytics/trackers/utils/__pycache__/matching.cpython-312.pyc,,
510
+ ultralytics/trackers/utils/__pycache__/reid.cpython-312.pyc,,
511
+ ultralytics/trackers/utils/__pycache__/stracks.cpython-312.pyc,,
512
+ ultralytics/trackers/utils/gmc.py,sha256=IbALyBxyLns4gaxJjnwUwhzcG9gZBppKkzFYpcmoVW4,14176
513
+ ultralytics/trackers/utils/kalman_filter.py,sha256=kLB4t6oyQYsb9h_o-4lG5JwDeyxlU0lV3J1rNm33Ofg,21785
514
+ ultralytics/trackers/utils/matching.py,sha256=vOfucS9GSriE553SphCH9mIO6e1bN1rnIB7l6JtO_cc,7818
515
+ ultralytics/trackers/utils/reid.py,sha256=F7yPrrkhHy4TcLxozZadDJfQARfBUfU081rAzUGahwU,8107
516
+ ultralytics/trackers/utils/stracks.py,sha256=xM-Dzae-TInuW9jzNCSxSad2TaAOSnBL8Q68-huHBgc,7980
517
+ ultralytics/utils/__init__.py,sha256=alr4okYlIaZ-Q6B_PuxT8haGdq4O157YU7FQ5b5ZK3U,60554
518
+ ultralytics/utils/__pycache__/__init__.cpython-312.pyc,,
519
+ ultralytics/utils/__pycache__/autobatch.cpython-312.pyc,,
520
+ ultralytics/utils/__pycache__/autodevice.cpython-312.pyc,,
521
+ ultralytics/utils/__pycache__/benchmarks.cpython-312.pyc,,
522
+ ultralytics/utils/__pycache__/checks.cpython-312.pyc,,
523
+ ultralytics/utils/__pycache__/cpu.cpython-312.pyc,,
524
+ ultralytics/utils/__pycache__/dist.cpython-312.pyc,,
525
+ ultralytics/utils/__pycache__/downloads.cpython-312.pyc,,
526
+ ultralytics/utils/__pycache__/events.cpython-312.pyc,,
527
+ ultralytics/utils/__pycache__/files.cpython-312.pyc,,
528
+ ultralytics/utils/__pycache__/git.cpython-312.pyc,,
529
+ ultralytics/utils/__pycache__/instance.cpython-312.pyc,,
530
+ ultralytics/utils/__pycache__/logger.cpython-312.pyc,,
531
+ ultralytics/utils/__pycache__/loss.cpython-312.pyc,,
532
+ ultralytics/utils/__pycache__/metrics.cpython-312.pyc,,
533
+ ultralytics/utils/__pycache__/nms.cpython-312.pyc,,
534
+ ultralytics/utils/__pycache__/ops.cpython-312.pyc,,
535
+ ultralytics/utils/__pycache__/patches.cpython-312.pyc,,
536
+ ultralytics/utils/__pycache__/plotting.cpython-312.pyc,,
537
+ ultralytics/utils/__pycache__/tal.cpython-312.pyc,,
538
+ ultralytics/utils/__pycache__/torch_utils.cpython-312.pyc,,
539
+ ultralytics/utils/__pycache__/tqdm.cpython-312.pyc,,
540
+ ultralytics/utils/__pycache__/triton.cpython-312.pyc,,
541
+ ultralytics/utils/__pycache__/tuner.cpython-312.pyc,,
542
+ ultralytics/utils/__pycache__/uploads.cpython-312.pyc,,
543
+ ultralytics/utils/autobatch.py,sha256=2vuP5FkBxAi_Y91-kBgqfCvcPLoiP-PV1QTKoHePyew,6274
544
+ ultralytics/utils/autodevice.py,sha256=NjBs39AAi7VggHLDhgSxS9RIySmqWVwd3a-ISfk54-o,9329
545
+ ultralytics/utils/benchmarks.py,sha256=p6gFohI4-ad5ovyBCiL3Va1dpuTqLl9PhK31LJT7OGg,29056
546
+ ultralytics/utils/callbacks/__init__.py,sha256=hzL63Rce6VkZhP4Lcim9LKjadixaQG86nKqPhk7IkS0,242
547
+ ultralytics/utils/callbacks/__pycache__/__init__.cpython-312.pyc,,
548
+ ultralytics/utils/callbacks/__pycache__/base.cpython-312.pyc,,
549
+ ultralytics/utils/callbacks/__pycache__/clearml.cpython-312.pyc,,
550
+ ultralytics/utils/callbacks/__pycache__/comet.cpython-312.pyc,,
551
+ ultralytics/utils/callbacks/__pycache__/dvc.cpython-312.pyc,,
552
+ ultralytics/utils/callbacks/__pycache__/mlflow.cpython-312.pyc,,
553
+ ultralytics/utils/callbacks/__pycache__/platform.cpython-312.pyc,,
554
+ ultralytics/utils/callbacks/__pycache__/raytune.cpython-312.pyc,,
555
+ ultralytics/utils/callbacks/__pycache__/tensorboard.cpython-312.pyc,,
556
+ ultralytics/utils/callbacks/__pycache__/wb.cpython-312.pyc,,
557
+ ultralytics/utils/callbacks/base.py,sha256=GO49Xi1uXYB3YO2v7gnNGKeOl7pUo023kiJlhT4mEfw,7022
558
+ ultralytics/utils/callbacks/clearml.py,sha256=AH7JwdZ8qtzlj11Q3MBzoUAzI6fYTb5drqAdpmxpSC8,5902
559
+ ultralytics/utils/callbacks/comet.py,sha256=Rf7H7j2HrKy_b1LUhl80VprwsqRwQem6mp2_eGO5Hzk,25128
560
+ ultralytics/utils/callbacks/dvc.py,sha256=DzT-Q314fap4g7rzXWeTfKw_5aTfnJIkqACAaFGXeg8,7494
561
+ ultralytics/utils/callbacks/mlflow.py,sha256=HiJiPmJgJ82MeCxmPs9Djn1GKLVsp-1N2DeKCMlVEAA,6676
562
+ ultralytics/utils/callbacks/platform.py,sha256=2MyLJd9BqpNs4yvAtGzODnBEGoxQFRhZpYCjxkvukkQ,19001
563
+ ultralytics/utils/callbacks/raytune.py,sha256=ZgPxSq4sdtz9AKeLVp3OQw7C9solTu5UgFckHv13G-8,1296
564
+ ultralytics/utils/callbacks/tensorboard.py,sha256=_RwYg6kqDIgif8v0f08943w7BP-uh-Qi9JCTEkFqqog,5081
565
+ ultralytics/utils/callbacks/wb.py,sha256=AeKl7JTme0J0QpcIUeqxCmARX9R0S0lGUqLY-C-HLuo,8216
566
+ ultralytics/utils/checks.py,sha256=FwP2gznmEmTiHaKTkTKfQs8RZvNurJMmfNa0Ts2YDCw,48113
567
+ ultralytics/utils/cpu.py,sha256=GcCGziGIVqZqa09XZuePE51ccFY4UVr2Zji_Qh0fMVw,4372
568
+ ultralytics/utils/dist.py,sha256=4WbIwjfTwQRDat8uYWnwoWGic1qk1P73hMnHXve_2Q0,5660
569
+ ultralytics/utils/downloads.py,sha256=NEQb1oAhoLrKN0PCu_4rwS6w7HRwp9lOQVY-I71r_hA,32102
570
+ ultralytics/utils/events.py,sha256=pzWYFuzttEdHLqb4BU_Qmo3xaEcnc2MYopnCnZsjL0k,12168
571
+ ultralytics/utils/export/__init__.py,sha256=yRaTZYckdFhj4cm_sRHnGQDWAZ-MuTosQwzdxuabCbg,1022
572
+ ultralytics/utils/export/__pycache__/__init__.cpython-312.pyc,,
573
+ ultralytics/utils/export/__pycache__/ascend.cpython-312.pyc,,
574
+ ultralytics/utils/export/__pycache__/axelera.cpython-312.pyc,,
575
+ ultralytics/utils/export/__pycache__/coreai.cpython-312.pyc,,
576
+ ultralytics/utils/export/__pycache__/coreml.cpython-312.pyc,,
577
+ ultralytics/utils/export/__pycache__/deepx.cpython-312.pyc,,
578
+ ultralytics/utils/export/__pycache__/engine.cpython-312.pyc,,
579
+ ultralytics/utils/export/__pycache__/executorch.cpython-312.pyc,,
580
+ ultralytics/utils/export/__pycache__/imx.cpython-312.pyc,,
581
+ ultralytics/utils/export/__pycache__/litert.cpython-312.pyc,,
582
+ ultralytics/utils/export/__pycache__/mnn.cpython-312.pyc,,
583
+ ultralytics/utils/export/__pycache__/ncnn.cpython-312.pyc,,
584
+ ultralytics/utils/export/__pycache__/onnx.cpython-312.pyc,,
585
+ ultralytics/utils/export/__pycache__/openvino.cpython-312.pyc,,
586
+ ultralytics/utils/export/__pycache__/paddle.cpython-312.pyc,,
587
+ ultralytics/utils/export/__pycache__/qnn.cpython-312.pyc,,
588
+ ultralytics/utils/export/__pycache__/rknn.cpython-312.pyc,,
589
+ ultralytics/utils/export/__pycache__/tensorflow.cpython-312.pyc,,
590
+ ultralytics/utils/export/__pycache__/torchscript.cpython-312.pyc,,
591
+ ultralytics/utils/export/ascend.py,sha256=PoFXC8vJ8lyuW0JDdW6zsA_O2iPARFs46sd8bl8p5To,2840
592
+ ultralytics/utils/export/axelera.py,sha256=VEUCAZ28Uq_Lt6MMlrX524pKRUekxjNuZEyvjVuaJU8,5865
593
+ ultralytics/utils/export/coreai.py,sha256=Olko0yW9uAIwH2GKRCOCilIw6UBZqHumbdDtJNU_twc,2920
594
+ ultralytics/utils/export/coreml.py,sha256=JClrrK-fr6cGPZiNgxE5EeyE4TYS_paGpKsgbF51doY,12083
595
+ ultralytics/utils/export/deepx.py,sha256=xWty2N9pQa5Fyj4quHFWpYkTxgMdUg6Ca9I_4ZBMUuE,2824
596
+ ultralytics/utils/export/engine.py,sha256=ZY1S-TQlaJ8gQNBH1zTG_W-CLlHY9nyYLucgRS0cjHc,22574
597
+ ultralytics/utils/export/executorch.py,sha256=AcIAh0kLWLO2EN2DK2jw5lkRNyNBgbK68XMMDg1E-f4,2829
598
+ ultralytics/utils/export/imx.py,sha256=d4deJYjcfF7zx9sfHvxE0EDzwXR269V9yfokdl5o6Ic,15100
599
+ ultralytics/utils/export/litert.py,sha256=hSqYwUshJCVNTgH6AnilDYTXHXLGmB5hWWd11gqRpZk,7243
600
+ ultralytics/utils/export/mnn.py,sha256=bc-OoP3mFBP1L4oD5b1vP9FST0kLkXRMd2FMnWgTfBs,1892
601
+ ultralytics/utils/export/ncnn.py,sha256=990canQVSyT8exIG-10h8Ddx1jw0o_WmC38i7AdWqhs,2587
602
+ ultralytics/utils/export/onnx.py,sha256=-bV_j5v0Q24v7p7TCf8AfE32OLdS4ZxK6Tr4HFxAMIg,2456
603
+ ultralytics/utils/export/openvino.py,sha256=FpPV_Q17z-Ah8tlEegpuQwfpYkeIgsPlHU-HBkCYko8,3654
604
+ ultralytics/utils/export/paddle.py,sha256=YlZrZj6PT-6RwT1VZdKFz6kRUz46hdQgfBjac2xnc_o,2567
605
+ ultralytics/utils/export/qnn.py,sha256=xok-vL_8b4fvgjuRjqkH4qcb_HshCfw_Hpb8mG494o0,8039
606
+ ultralytics/utils/export/rknn.py,sha256=f1E0tzZ_ukFEp-uVPUZP83dC4frQSAml_uEj0DasiDU,3598
607
+ ultralytics/utils/export/tensorflow.py,sha256=n8fITtW6Jz7HSY8q937oKtTOvcWg19j15efq7BCTDPU,13388
608
+ ultralytics/utils/export/torchscript.py,sha256=bXPk5s2ylZGvuq8nD_PVuk8VsyHSzVQuomgBldQLfDY,1228
609
+ ultralytics/utils/files.py,sha256=0NOGyMA6rD7x0GZm8mg05PwbW1p8waJ-_yTHumvpII0,8371
610
+ ultralytics/utils/git.py,sha256=zREX0CV4MRxhOhjKaW5T4E1V-j_2Ah3MlSXkyjtkXjI,6911
611
+ ultralytics/utils/instance.py,sha256=YJ4k3jmUOa_j7rRTM00ecAr6UwR8B3AePyXD6XvdK5g,21382
612
+ ultralytics/utils/logger.py,sha256=Zxfzo8l17tsB6yuduBXmF0NTD0-ULAUK0O4ypnFQlNc,26255
613
+ ultralytics/utils/loss.py,sha256=4smPRmzCyvuKXoSrHnLyx9d-QIdFgwatTe4Jaeajfdk,71908
614
+ ultralytics/utils/metrics.py,sha256=upUFY1Ivw_XWMMySF8IpzjhcEkaLrehH3eUY_L9YfJc,90637
615
+ ultralytics/utils/nms.py,sha256=GrhhaGWaieSioUtedyYLNAUlY9Agd_AcYQ5JPoDOvi0,12998
616
+ ultralytics/utils/ops.py,sha256=GoA0OGyXD7d57xj3EXCD3t5tE41NvF9m7V23ZiTTYVg,34578
617
+ ultralytics/utils/patches.py,sha256=3SX4btn_lZi20ZI9IuyyamrTjfjFDvb08ciXcBqvJQc,10413
618
+ ultralytics/utils/plotting.py,sha256=MJK9JQIsBN3ALBYuXnmtAczhrAl4cXgBM7dA9SV4PNg,68076
619
+ ultralytics/utils/tal.py,sha256=NxCrfV1XQK7D2pePxuopZJnDwTktl8nmFxtu0-YGpgs,25453
620
+ ultralytics/utils/torch_utils.py,sha256=nZ3k9eAWrcaZ_96Kfby5mSRe7mZ1fp1zg4J7EhW6xHI,55868
621
+ ultralytics/utils/tqdm.py,sha256=t7Tugp52Ik56BpkcLuSsd3SeUQNeHulbCmG9M9GIe6o,18189
622
+ ultralytics/utils/triton.py,sha256=qfA4VJvGVUjUj-uuQzHc0eZ989-iZkdMmuqo4WnotU0,5215
623
+ ultralytics/utils/tuner.py,sha256=nW47PW_WM1pZcMVs82d20owbMgeNdjMoYJlLpnNUqso,21297
624
+ ultralytics/utils/uploads.py,sha256=d0L4CPUBwp0ES8DfMpRjvNG3uG9PZOqSorWjEEcs0Ig,3864
.venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/REQUESTED ADDED
File without changes
.venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/WHEEL ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
 
1
+ Wheel-Version: 1.0
2
+ Generator: setuptools (84.0.0)
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
5
+
.venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/entry_points.txt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ [console_scripts]
2
+ ultralytics = ultralytics.cfg:entrypoint
3
+ yolo = ultralytics.cfg:entrypoint
.venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/licenses/LICENSE ADDED
@@ -0,0 +1,661 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ GNU AFFERO GENERAL PUBLIC LICENSE
2
+ Version 3, 19 November 2007
3
+
4
+ Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>
5
+ Everyone is permitted to copy and distribute verbatim copies
6
+ of this license document, but changing it is not allowed.
7
+
8
+ Preamble
9
+
10
+ The GNU Affero General Public License is a free, copyleft license for
11
+ software and other kinds of works, specifically designed to ensure
12
+ cooperation with the community in the case of network server software.
13
+
14
+ The licenses for most software and other practical works are designed
15
+ to take away your freedom to share and change the works. By contrast,
16
+ our General Public Licenses are intended to guarantee your freedom to
17
+ share and change all versions of a program--to make sure it remains free
18
+ software for all its users.
19
+
20
+ When we speak of free software, we are referring to freedom, not
21
+ price. Our General Public Licenses are designed to make sure that you
22
+ have the freedom to distribute copies of free software (and charge for
23
+ them if you wish), that you receive source code or can get it if you
24
+ want it, that you can change the software or use pieces of it in new
25
+ free programs, and that you know you can do these things.
26
+
27
+ Developers that use our General Public Licenses protect your rights
28
+ with two steps: (1) assert copyright on the software, and (2) offer
29
+ you this License which gives you legal permission to copy, distribute
30
+ and/or modify the software.
31
+
32
+ A secondary benefit of defending all users' freedom is that
33
+ improvements made in alternate versions of the program, if they
34
+ receive widespread use, become available for other developers to
35
+ incorporate. Many developers of free software are heartened and
36
+ encouraged by the resulting cooperation. However, in the case of
37
+ software used on network servers, this result may fail to come about.
38
+ The GNU General Public License permits making a modified version and
39
+ letting the public access it on a server without ever releasing its
40
+ source code to the public.
41
+
42
+ The GNU Affero General Public License is designed specifically to
43
+ ensure that, in such cases, the modified source code becomes available
44
+ to the community. It requires the operator of a network server to
45
+ provide the source code of the modified version running there to the
46
+ users of that server. Therefore, public use of a modified version, on
47
+ a publicly accessible server, gives the public access to the source
48
+ code of the modified version.
49
+
50
+ An older license, called the Affero General Public License and
51
+ published by Affero, was designed to accomplish similar goals. This is
52
+ a different license, not a version of the Affero GPL, but Affero has
53
+ released a new version of the Affero GPL which permits relicensing under
54
+ this license.
55
+
56
+ The precise terms and conditions for copying, distribution and
57
+ modification follow.
58
+
59
+ TERMS AND CONDITIONS
60
+
61
+ 0. Definitions.
62
+
63
+ "This License" refers to version 3 of the GNU Affero General Public License.
64
+
65
+ "Copyright" also means copyright-like laws that apply to other kinds of
66
+ works, such as semiconductor masks.
67
+
68
+ "The Program" refers to any copyrightable work licensed under this
69
+ License. Each licensee is addressed as "you". "Licensees" and
70
+ "recipients" may be individuals or organizations.
71
+
72
+ To "modify" a work means to copy from or adapt all or part of the work
73
+ in a fashion requiring copyright permission, other than the making of an
74
+ exact copy. The resulting work is called a "modified version" of the
75
+ earlier work or a work "based on" the earlier work.
76
+
77
+ A "covered work" means either the unmodified Program or a work based
78
+ on the Program.
79
+
80
+ To "propagate" a work means to do anything with it that, without
81
+ permission, would make you directly or secondarily liable for
82
+ infringement under applicable copyright law, except executing it on a
83
+ computer or modifying a private copy. Propagation includes copying,
84
+ distribution (with or without modification), making available to the
85
+ public, and in some countries other activities as well.
86
+
87
+ To "convey" a work means any kind of propagation that enables other
88
+ parties to make or receive copies. Mere interaction with a user through
89
+ a computer network, with no transfer of a copy, is not conveying.
90
+
91
+ An interactive user interface displays "Appropriate Legal Notices"
92
+ to the extent that it includes a convenient and prominently visible
93
+ feature that (1) displays an appropriate copyright notice, and (2)
94
+ tells the user that there is no warranty for the work (except to the
95
+ extent that warranties are provided), that licensees may convey the
96
+ work under this License, and how to view a copy of this License. If
97
+ the interface presents a list of user commands or options, such as a
98
+ menu, a prominent item in the list meets this criterion.
99
+
100
+ 1. Source Code.
101
+
102
+ The "source code" for a work means the preferred form of the work
103
+ for making modifications to it. "Object code" means any non-source
104
+ form of a work.
105
+
106
+ A "Standard Interface" means an interface that either is an official
107
+ standard defined by a recognized standards body, or, in the case of
108
+ interfaces specified for a particular programming language, one that
109
+ is widely used among developers working in that language.
110
+
111
+ The "System Libraries" of an executable work include anything, other
112
+ than the work as a whole, that (a) is included in the normal form of
113
+ packaging a Major Component, but which is not part of that Major
114
+ Component, and (b) serves only to enable use of the work with that
115
+ Major Component, or to implement a Standard Interface for which an
116
+ implementation is available to the public in source code form. A
117
+ "Major Component", in this context, means a major essential component
118
+ (kernel, window system, and so on) of the specific operating system
119
+ (if any) on which the executable work runs, or a compiler used to
120
+ produce the work, or an object code interpreter used to run it.
121
+
122
+ The "Corresponding Source" for a work in object code form means all
123
+ the source code needed to generate, install, and (for an executable
124
+ work) run the object code and to modify the work, including scripts to
125
+ control those activities. However, it does not include the work's
126
+ System Libraries, or general-purpose tools or generally available free
127
+ programs which are used unmodified in performing those activities but
128
+ which are not part of the work. For example, Corresponding Source
129
+ includes interface definition files associated with source files for
130
+ the work, and the source code for shared libraries and dynamically
131
+ linked subprograms that the work is specifically designed to require,
132
+ such as by intimate data communication or control flow between those
133
+ subprograms and other parts of the work.
134
+
135
+ The Corresponding Source need not include anything that users
136
+ can regenerate automatically from other parts of the Corresponding
137
+ Source.
138
+
139
+ The Corresponding Source for a work in source code form is that
140
+ same work.
141
+
142
+ 2. Basic Permissions.
143
+
144
+ All rights granted under this License are granted for the term of
145
+ copyright on the Program, and are irrevocable provided the stated
146
+ conditions are met. This License explicitly affirms your unlimited
147
+ permission to run the unmodified Program. The output from running a
148
+ covered work is covered by this License only if the output, given its
149
+ content, constitutes a covered work. This License acknowledges your
150
+ rights of fair use or other equivalent, as provided by copyright law.
151
+
152
+ You may make, run and propagate covered works that you do not
153
+ convey, without conditions so long as your license otherwise remains
154
+ in force. You may convey covered works to others for the sole purpose
155
+ of having them make modifications exclusively for you, or provide you
156
+ with facilities for running those works, provided that you comply with
157
+ the terms of this License in conveying all material for which you do
158
+ not control copyright. Those thus making or running the covered works
159
+ for you must do so exclusively on your behalf, under your direction
160
+ and control, on terms that prohibit them from making any copies of
161
+ your copyrighted material outside their relationship with you.
162
+
163
+ Conveying under any other circumstances is permitted solely under
164
+ the conditions stated below. Sublicensing is not allowed; section 10
165
+ makes it unnecessary.
166
+
167
+ 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
168
+
169
+ No covered work shall be deemed part of an effective technological
170
+ measure under any applicable law fulfilling obligations under article
171
+ 11 of the WIPO copyright treaty adopted on 20 December 1996, or
172
+ similar laws prohibiting or restricting circumvention of such
173
+ measures.
174
+
175
+ When you convey a covered work, you waive any legal power to forbid
176
+ circumvention of technological measures to the extent such circumvention
177
+ is effected by exercising rights under this License with respect to
178
+ the covered work, and you disclaim any intention to limit operation or
179
+ modification of the work as a means of enforcing, against the work's
180
+ users, your or third parties' legal rights to forbid circumvention of
181
+ technological measures.
182
+
183
+ 4. Conveying Verbatim Copies.
184
+
185
+ You may convey verbatim copies of the Program's source code as you
186
+ receive it, in any medium, provided that you conspicuously and
187
+ appropriately publish on each copy an appropriate copyright notice;
188
+ keep intact all notices stating that this License and any
189
+ non-permissive terms added in accord with section 7 apply to the code;
190
+ keep intact all notices of the absence of any warranty; and give all
191
+ recipients a copy of this License along with the Program.
192
+
193
+ You may charge any price or no price for each copy that you convey,
194
+ and you may offer support or warranty protection for a fee.
195
+
196
+ 5. Conveying Modified Source Versions.
197
+
198
+ You may convey a work based on the Program, or the modifications to
199
+ produce it from the Program, in the form of source code under the
200
+ terms of section 4, provided that you also meet all of these conditions:
201
+
202
+ a) The work must carry prominent notices stating that you modified
203
+ it, and giving a relevant date.
204
+
205
+ b) The work must carry prominent notices stating that it is
206
+ released under this License and any conditions added under section
207
+ 7. This requirement modifies the requirement in section 4 to
208
+ "keep intact all notices".
209
+
210
+ c) You must license the entire work, as a whole, under this
211
+ License to anyone who comes into possession of a copy. This
212
+ License will therefore apply, along with any applicable section 7
213
+ additional terms, to the whole of the work, and all its parts,
214
+ regardless of how they are packaged. This License gives no
215
+ permission to license the work in any other way, but it does not
216
+ invalidate such permission if you have separately received it.
217
+
218
+ d) If the work has interactive user interfaces, each must display
219
+ Appropriate Legal Notices; however, if the Program has interactive
220
+ interfaces that do not display Appropriate Legal Notices, your
221
+ work need not make them do so.
222
+
223
+ A compilation of a covered work with other separate and independent
224
+ works, which are not by their nature extensions of the covered work,
225
+ and which are not combined with it such as to form a larger program,
226
+ in or on a volume of a storage or distribution medium, is called an
227
+ "aggregate" if the compilation and its resulting copyright are not
228
+ used to limit the access or legal rights of the compilation's users
229
+ beyond what the individual works permit. Inclusion of a covered work
230
+ in an aggregate does not cause this License to apply to the other
231
+ parts of the aggregate.
232
+
233
+ 6. Conveying Non-Source Forms.
234
+
235
+ You may convey a covered work in object code form under the terms
236
+ of sections 4 and 5, provided that you also convey the
237
+ machine-readable Corresponding Source under the terms of this License,
238
+ in one of these ways:
239
+
240
+ a) Convey the object code in, or embodied in, a physical product
241
+ (including a physical distribution medium), accompanied by the
242
+ Corresponding Source fixed on a durable physical medium
243
+ customarily used for software interchange.
244
+
245
+ b) Convey the object code in, or embodied in, a physical product
246
+ (including a physical distribution medium), accompanied by a
247
+ written offer, valid for at least three years and valid for as
248
+ long as you offer spare parts or customer support for that product
249
+ model, to give anyone who possesses the object code either (1) a
250
+ copy of the Corresponding Source for all the software in the
251
+ product that is covered by this License, on a durable physical
252
+ medium customarily used for software interchange, for a price no
253
+ more than your reasonable cost of physically performing this
254
+ conveying of source, or (2) access to copy the
255
+ Corresponding Source from a network server at no charge.
256
+
257
+ c) Convey individual copies of the object code with a copy of the
258
+ written offer to provide the Corresponding Source. This
259
+ alternative is allowed only occasionally and noncommercially, and
260
+ only if you received the object code with such an offer, in accord
261
+ with subsection 6b.
262
+
263
+ d) Convey the object code by offering access from a designated
264
+ place (gratis or for a charge), and offer equivalent access to the
265
+ Corresponding Source in the same way through the same place at no
266
+ further charge. You need not require recipients to copy the
267
+ Corresponding Source along with the object code. If the place to
268
+ copy the object code is a network server, the Corresponding Source
269
+ may be on a different server (operated by you or a third party)
270
+ that supports equivalent copying facilities, provided you maintain
271
+ clear directions next to the object code saying where to find the
272
+ Corresponding Source. Regardless of what server hosts the
273
+ Corresponding Source, you remain obligated to ensure that it is
274
+ available for as long as needed to satisfy these requirements.
275
+
276
+ e) Convey the object code using peer-to-peer transmission, provided
277
+ you inform other peers where the object code and Corresponding
278
+ Source of the work are being offered to the general public at no
279
+ charge under subsection 6d.
280
+
281
+ A separable portion of the object code, whose source code is excluded
282
+ from the Corresponding Source as a System Library, need not be
283
+ included in conveying the object code work.
284
+
285
+ A "User Product" is either (1) a "consumer product", which means any
286
+ tangible personal property which is normally used for personal, family,
287
+ or household purposes, or (2) anything designed or sold for incorporation
288
+ into a dwelling. In determining whether a product is a consumer product,
289
+ doubtful cases shall be resolved in favor of coverage. For a particular
290
+ product received by a particular user, "normally used" refers to a
291
+ typical or common use of that class of product, regardless of the status
292
+ of the particular user or of the way in which the particular user
293
+ actually uses, or expects or is expected to use, the product. A product
294
+ is a consumer product regardless of whether the product has substantial
295
+ commercial, industrial or non-consumer uses, unless such uses represent
296
+ the only significant mode of use of the product.
297
+
298
+ "Installation Information" for a User Product means any methods,
299
+ procedures, authorization keys, or other information required to install
300
+ and execute modified versions of a covered work in that User Product from
301
+ a modified version of its Corresponding Source. The information must
302
+ suffice to ensure that the continued functioning of the modified object
303
+ code is in no case prevented or interfered with solely because
304
+ modification has been made.
305
+
306
+ If you convey an object code work under this section in, or with, or
307
+ specifically for use in, a User Product, and the conveying occurs as
308
+ part of a transaction in which the right of possession and use of the
309
+ User Product is transferred to the recipient in perpetuity or for a
310
+ fixed term (regardless of how the transaction is characterized), the
311
+ Corresponding Source conveyed under this section must be accompanied
312
+ by the Installation Information. But this requirement does not apply
313
+ if neither you nor any third party retains the ability to install
314
+ modified object code on the User Product (for example, the work has
315
+ been installed in ROM).
316
+
317
+ The requirement to provide Installation Information does not include a
318
+ requirement to continue to provide support service, warranty, or updates
319
+ for a work that has been modified or installed by the recipient, or for
320
+ the User Product in which it has been modified or installed. Access to a
321
+ network may be denied when the modification itself materially and
322
+ adversely affects the operation of the network or violates the rules and
323
+ protocols for communication across the network.
324
+
325
+ Corresponding Source conveyed, and Installation Information provided,
326
+ in accord with this section must be in a format that is publicly
327
+ documented (and with an implementation available to the public in
328
+ source code form), and must require no special password or key for
329
+ unpacking, reading or copying.
330
+
331
+ 7. Additional Terms.
332
+
333
+ "Additional permissions" are terms that supplement the terms of this
334
+ License by making exceptions from one or more of its conditions.
335
+ Additional permissions that are applicable to the entire Program shall
336
+ be treated as though they were included in this License, to the extent
337
+ that they are valid under applicable law. If additional permissions
338
+ apply only to part of the Program, that part may be used separately
339
+ under those permissions, but the entire Program remains governed by
340
+ this License without regard to the additional permissions.
341
+
342
+ When you convey a copy of a covered work, you may at your option
343
+ remove any additional permissions from that copy, or from any part of
344
+ it. (Additional permissions may be written to require their own
345
+ removal in certain cases when you modify the work.) You may place
346
+ additional permissions on material, added by you to a covered work,
347
+ for which you have or can give appropriate copyright permission.
348
+
349
+ Notwithstanding any other provision of this License, for material you
350
+ add to a covered work, you may (if authorized by the copyright holders of
351
+ that material) supplement the terms of this License with terms:
352
+
353
+ a) Disclaiming warranty or limiting liability differently from the
354
+ terms of sections 15 and 16 of this License; or
355
+
356
+ b) Requiring preservation of specified reasonable legal notices or
357
+ author attributions in that material or in the Appropriate Legal
358
+ Notices displayed by works containing it; or
359
+
360
+ c) Prohibiting misrepresentation of the origin of that material, or
361
+ requiring that modified versions of such material be marked in
362
+ reasonable ways as different from the original version; or
363
+
364
+ d) Limiting the use for publicity purposes of names of licensors or
365
+ authors of the material; or
366
+
367
+ e) Declining to grant rights under trademark law for use of some
368
+ trade names, trademarks, or service marks; or
369
+
370
+ f) Requiring indemnification of licensors and authors of that
371
+ material by anyone who conveys the material (or modified versions of
372
+ it) with contractual assumptions of liability to the recipient, for
373
+ any liability that these contractual assumptions directly impose on
374
+ those licensors and authors.
375
+
376
+ All other non-permissive additional terms are considered "further
377
+ restrictions" within the meaning of section 10. If the Program as you
378
+ received it, or any part of it, contains a notice stating that it is
379
+ governed by this License along with a term that is a further
380
+ restriction, you may remove that term. If a license document contains
381
+ a further restriction but permits relicensing or conveying under this
382
+ License, you may add to a covered work material governed by the terms
383
+ of that license document, provided that the further restriction does
384
+ not survive such relicensing or conveying.
385
+
386
+ If you add terms to a covered work in accord with this section, you
387
+ must place, in the relevant source files, a statement of the
388
+ additional terms that apply to those files, or a notice indicating
389
+ where to find the applicable terms.
390
+
391
+ Additional terms, permissive or non-permissive, may be stated in the
392
+ form of a separately written license, or stated as exceptions;
393
+ the above requirements apply either way.
394
+
395
+ 8. Termination.
396
+
397
+ You may not propagate or modify a covered work except as expressly
398
+ provided under this License. Any attempt otherwise to propagate or
399
+ modify it is void, and will automatically terminate your rights under
400
+ this License (including any patent licenses granted under the third
401
+ paragraph of section 11).
402
+
403
+ However, if you cease all violation of this License, then your
404
+ license from a particular copyright holder is reinstated (a)
405
+ provisionally, unless and until the copyright holder explicitly and
406
+ finally terminates your license, and (b) permanently, if the copyright
407
+ holder fails to notify you of the violation by some reasonable means
408
+ prior to 60 days after the cessation.
409
+
410
+ Moreover, your license from a particular copyright holder is
411
+ reinstated permanently if the copyright holder notifies you of the
412
+ violation by some reasonable means, this is the first time you have
413
+ received notice of violation of this License (for any work) from that
414
+ copyright holder, and you cure the violation prior to 30 days after
415
+ your receipt of the notice.
416
+
417
+ Termination of your rights under this section does not terminate the
418
+ licenses of parties who have received copies or rights from you under
419
+ this License. If your rights have been terminated and not permanently
420
+ reinstated, you do not qualify to receive new licenses for the same
421
+ material under section 10.
422
+
423
+ 9. Acceptance Not Required for Having Copies.
424
+
425
+ You are not required to accept this License in order to receive or
426
+ run a copy of the Program. Ancillary propagation of a covered work
427
+ occurring solely as a consequence of using peer-to-peer transmission
428
+ to receive a copy likewise does not require acceptance. However,
429
+ nothing other than this License grants you permission to propagate or
430
+ modify any covered work. These actions infringe copyright if you do
431
+ not accept this License. Therefore, by modifying or propagating a
432
+ covered work, you indicate your acceptance of this License to do so.
433
+
434
+ 10. Automatic Licensing of Downstream Recipients.
435
+
436
+ Each time you convey a covered work, the recipient automatically
437
+ receives a license from the original licensors, to run, modify and
438
+ propagate that work, subject to this License. You are not responsible
439
+ for enforcing compliance by third parties with this License.
440
+
441
+ An "entity transaction" is a transaction transferring control of an
442
+ organization, or substantially all assets of one, or subdividing an
443
+ organization, or merging organizations. If propagation of a covered
444
+ work results from an entity transaction, each party to that
445
+ transaction who receives a copy of the work also receives whatever
446
+ licenses to the work the party's predecessor in interest had or could
447
+ give under the previous paragraph, plus a right to possession of the
448
+ Corresponding Source of the work from the predecessor in interest, if
449
+ the predecessor has it or can get it with reasonable efforts.
450
+
451
+ You may not impose any further restrictions on the exercise of the
452
+ rights granted or affirmed under this License. For example, you may
453
+ not impose a license fee, royalty, or other charge for exercise of
454
+ rights granted under this License, and you may not initiate litigation
455
+ (including a cross-claim or counterclaim in a lawsuit) alleging that
456
+ any patent claim is infringed by making, using, selling, offering for
457
+ sale, or importing the Program or any portion of it.
458
+
459
+ 11. Patents.
460
+
461
+ A "contributor" is a copyright holder who authorizes use under this
462
+ License of the Program or a work on which the Program is based. The
463
+ work thus licensed is called the contributor's "contributor version".
464
+
465
+ A contributor's "essential patent claims" are all patent claims
466
+ owned or controlled by the contributor, whether already acquired or
467
+ hereafter acquired, that would be infringed by some manner, permitted
468
+ by this License, of making, using, or selling its contributor version,
469
+ but do not include claims that would be infringed only as a
470
+ consequence of further modification of the contributor version. For
471
+ purposes of this definition, "control" includes the right to grant
472
+ patent sublicenses in a manner consistent with the requirements of
473
+ this License.
474
+
475
+ Each contributor grants you a non-exclusive, worldwide, royalty-free
476
+ patent license under the contributor's essential patent claims, to
477
+ make, use, sell, offer for sale, import and otherwise run, modify and
478
+ propagate the contents of its contributor version.
479
+
480
+ In the following three paragraphs, a "patent license" is any express
481
+ agreement or commitment, however denominated, not to enforce a patent
482
+ (such as an express permission to practice a patent or covenant not to
483
+ sue for patent infringement). To "grant" such a patent license to a
484
+ party means to make such an agreement or commitment not to enforce a
485
+ patent against the party.
486
+
487
+ If you convey a covered work, knowingly relying on a patent license,
488
+ and the Corresponding Source of the work is not available for anyone
489
+ to copy, free of charge and under the terms of this License, through a
490
+ publicly available network server or other readily accessible means,
491
+ then you must either (1) cause the Corresponding Source to be so
492
+ available, or (2) arrange to deprive yourself of the benefit of the
493
+ patent license for this particular work, or (3) arrange, in a manner
494
+ consistent with the requirements of this License, to extend the patent
495
+ license to downstream recipients. "Knowingly relying" means you have
496
+ actual knowledge that, but for the patent license, your conveying the
497
+ covered work in a country, or your recipient's use of the covered work
498
+ in a country, would infringe one or more identifiable patents in that
499
+ country that you have reason to believe are valid.
500
+
501
+ If, pursuant to or in connection with a single transaction or
502
+ arrangement, you convey, or propagate by procuring conveyance of, a
503
+ covered work, and grant a patent license to some of the parties
504
+ receiving the covered work authorizing them to use, propagate, modify
505
+ or convey a specific copy of the covered work, then the patent license
506
+ you grant is automatically extended to all recipients of the covered
507
+ work and works based on it.
508
+
509
+ A patent license is "discriminatory" if it does not include within
510
+ the scope of its coverage, prohibits the exercise of, or is
511
+ conditioned on the non-exercise of one or more of the rights that are
512
+ specifically granted under this License. You may not convey a covered
513
+ work if you are a party to an arrangement with a third party that is
514
+ in the business of distributing software, under which you make payment
515
+ to the third party based on the extent of your activity of conveying
516
+ the work, and under which the third party grants, to any of the
517
+ parties who would receive the covered work from you, a discriminatory
518
+ patent license (a) in connection with copies of the covered work
519
+ conveyed by you (or copies made from those copies), or (b) primarily
520
+ for and in connection with specific products or compilations that
521
+ contain the covered work, unless you entered into that arrangement,
522
+ or that patent license was granted, prior to 28 March 2007.
523
+
524
+ Nothing in this License shall be construed as excluding or limiting
525
+ any implied license or other defenses to infringement that may
526
+ otherwise be available to you under applicable patent law.
527
+
528
+ 12. No Surrender of Others' Freedom.
529
+
530
+ If conditions are imposed on you (whether by court order, agreement or
531
+ otherwise) that contradict the conditions of this License, they do not
532
+ excuse you from the conditions of this License. If you cannot convey a
533
+ covered work so as to satisfy simultaneously your obligations under this
534
+ License and any other pertinent obligations, then as a consequence you may
535
+ not convey it at all. For example, if you agree to terms that obligate you
536
+ to collect a royalty for further conveying from those to whom you convey
537
+ the Program, the only way you could satisfy both those terms and this
538
+ License would be to refrain entirely from conveying the Program.
539
+
540
+ 13. Remote Network Interaction; Use with the GNU General Public License.
541
+
542
+ Notwithstanding any other provision of this License, if you modify the
543
+ Program, your modified version must prominently offer all users
544
+ interacting with it remotely through a computer network (if your version
545
+ supports such interaction) an opportunity to receive the Corresponding
546
+ Source of your version by providing access to the Corresponding Source
547
+ from a network server at no charge, through some standard or customary
548
+ means of facilitating copying of software. This Corresponding Source
549
+ shall include the Corresponding Source for any work covered by version 3
550
+ of the GNU General Public License that is incorporated pursuant to the
551
+ following paragraph.
552
+
553
+ Notwithstanding any other provision of this License, you have
554
+ permission to link or combine any covered work with a work licensed
555
+ under version 3 of the GNU General Public License into a single
556
+ combined work, and to convey the resulting work. The terms of this
557
+ License will continue to apply to the part which is the covered work,
558
+ but the work with which it is combined will remain governed by version
559
+ 3 of the GNU General Public License.
560
+
561
+ 14. Revised Versions of this License.
562
+
563
+ The Free Software Foundation may publish revised and/or new versions of
564
+ the GNU Affero General Public License from time to time. Such new versions
565
+ will be similar in spirit to the present version, but may differ in detail to
566
+ address new problems or concerns.
567
+
568
+ Each version is given a distinguishing version number. If the
569
+ Program specifies that a certain numbered version of the GNU Affero General
570
+ Public License "or any later version" applies to it, you have the
571
+ option of following the terms and conditions either of that numbered
572
+ version or of any later version published by the Free Software
573
+ Foundation. If the Program does not specify a version number of the
574
+ GNU Affero General Public License, you may choose any version ever published
575
+ by the Free Software Foundation.
576
+
577
+ If the Program specifies that a proxy can decide which future
578
+ versions of the GNU Affero General Public License can be used, that proxy's
579
+ public statement of acceptance of a version permanently authorizes you
580
+ to choose that version for the Program.
581
+
582
+ Later license versions may give you additional or different
583
+ permissions. However, no additional obligations are imposed on any
584
+ author or copyright holder as a result of your choosing to follow a
585
+ later version.
586
+
587
+ 15. Disclaimer of Warranty.
588
+
589
+ THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
590
+ APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
591
+ HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
592
+ OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
593
+ THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
594
+ PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
595
+ IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
596
+ ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
597
+
598
+ 16. Limitation of Liability.
599
+
600
+ IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
601
+ WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
602
+ THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
603
+ GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
604
+ USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
605
+ DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
606
+ PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
607
+ EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
608
+ SUCH DAMAGES.
609
+
610
+ 17. Interpretation of Sections 15 and 16.
611
+
612
+ If the disclaimer of warranty and limitation of liability provided
613
+ above cannot be given local legal effect according to their terms,
614
+ reviewing courts shall apply local law that most closely approximates
615
+ an absolute waiver of all civil liability in connection with the
616
+ Program, unless a warranty or assumption of liability accompanies a
617
+ copy of the Program in return for a fee.
618
+
619
+ END OF TERMS AND CONDITIONS
620
+
621
+ How to Apply These Terms to Your New Programs
622
+
623
+ If you develop a new program, and you want it to be of the greatest
624
+ possible use to the public, the best way to achieve this is to make it
625
+ free software which everyone can redistribute and change under these terms.
626
+
627
+ To do so, attach the following notices to the program. It is safest
628
+ to attach them to the start of each source file to most effectively
629
+ state the exclusion of warranty; and each file should have at least
630
+ the "copyright" line and a pointer to where the full notice is found.
631
+
632
+ <one line to give the program's name and a brief idea of what it does.>
633
+ Copyright (C) <year> <name of author>
634
+
635
+ This program is free software: you can redistribute it and/or modify
636
+ it under the terms of the GNU Affero General Public License as published by
637
+ the Free Software Foundation, either version 3 of the License, or
638
+ (at your option) any later version.
639
+
640
+ This program is distributed in the hope that it will be useful,
641
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
642
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
643
+ GNU Affero General Public License for more details.
644
+
645
+ You should have received a copy of the GNU Affero General Public License
646
+ along with this program. If not, see <https://www.gnu.org/licenses/>.
647
+
648
+ Also add information on how to contact you by electronic and paper mail.
649
+
650
+ If your software can interact with users remotely through a computer
651
+ network, you should also make sure that it provides a way for users to
652
+ get its source. For example, if your program is a web application, its
653
+ interface could display a "Source" link that leads users to an archive
654
+ of the code. There are many ways you could offer source, and different
655
+ solutions will be better for different programs; see section 13 for the
656
+ specific requirements.
657
+
658
+ You should also get your employer (if you work as a programmer) or school,
659
+ if any, to sign a "copyright disclaimer" for the program, if necessary.
660
+ For more information on this, and how to apply and follow the GNU AGPL, see
661
+ <https://www.gnu.org/licenses/>.
.venv/lib/python3.12/site-packages/ultralytics-8.4.160.dist-info/top_level.txt ADDED
@@ -0,0 +1 @@
 
 
1
+ ultralytics
.venv/lib/python3.12/site-packages/ultralytics/__init__.py ADDED
@@ -0,0 +1,56 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Ultralytics 🚀 AGPL-3.0 License - https://ultralytics.com/license
2
+
3
+ __version__ = "8.4.160"
4
+
5
+ import importlib
6
+ import os
7
+ import sys
8
+ from typing import TYPE_CHECKING
9
+
10
+ # Set ENV variables (place before imports)
11
+ if not os.environ.get("OMP_NUM_THREADS"):
12
+ os.environ["OMP_NUM_THREADS"] = "1" # default for reduced CPU utilization during training
13
+
14
+ from ultralytics.utils import ASSETS, SETTINGS
15
+ from ultralytics.utils.checks import check_yolo as checks
16
+ from ultralytics.utils.downloads import download
17
+
18
+ settings = SETTINGS
19
+
20
+ MODELS = ("YOLO", "YOLOWorld", "YOLOE", "NAS", "SAM", "FastSAM", "RTDETR", "LLM")
21
+ PLATFORM_EXPORTS = ("Platform", "AsyncPlatform", "APIError", "APIConnectionError")
22
+
23
+ __all__ = ( # noqa: PLE0604
24
+ "__version__",
25
+ "ASSETS",
26
+ *MODELS,
27
+ *(PLATFORM_EXPORTS if sys.version_info >= (3, 11) else ()),
28
+ "checks",
29
+ "download",
30
+ "settings",
31
+ )
32
+
33
+ if TYPE_CHECKING:
34
+ # Enable hints for type checkers
35
+ from ultralytics.models import LLM, YOLO, YOLOWorld, YOLOE, NAS, SAM, FastSAM, RTDETR # noqa
36
+ from ultralytics_platform import APIConnectionError, APIError, AsyncPlatform, Platform # noqa: F401
37
+
38
+
39
+ def __getattr__(name: str):
40
+ """Lazy-import public classes on first access."""
41
+ if name in MODELS:
42
+ return getattr(importlib.import_module("ultralytics.models"), name)
43
+ if name in PLATFORM_EXPORTS:
44
+ if sys.version_info < (3, 11):
45
+ raise ImportError("Ultralytics Platform requires Python 3.11 or newer.")
46
+ return getattr(importlib.import_module("ultralytics_platform"), name)
47
+ raise AttributeError(f"module {__name__} has no attribute {name}")
48
+
49
+
50
+ def __dir__():
51
+ """Extend dir() to include lazily available public names for IDE autocompletion."""
52
+ return sorted(set(globals()) | set(MODELS) | set(PLATFORM_EXPORTS))
53
+
54
+
55
+ if __name__ == "__main__":
56
+ print(__version__)
.venv/lib/python3.12/site-packages/ultralytics/__pycache__/__init__.cpython-312.pyc ADDED
Binary file (2.49 kB). View file
 
.venv/lib/python3.12/site-packages/ultralytics/assets/bus.jpg ADDED

Git LFS Details

  • SHA256: c02019c4979c191eb739ddd944445ef408dad5679acab6fd520ef9d434bfbc63
  • Pointer size: 131 Bytes
  • Size of remote file: 137 kB
.venv/lib/python3.12/site-packages/ultralytics/assets/zidane.jpg ADDED

Git LFS Details

  • SHA256: 16d73869e3267a7d4ed00de8e860833bd1657c1b252e94c0c348277adc7b6edb
  • Pointer size: 130 Bytes
  • Size of remote file: 50.4 kB