diff --git a/.DS_Store b/.DS_Store new file mode 100644 index 0000000000000000000000000000000000000000..8083008f91699db4e7c03a31c965f22009d8533d Binary files /dev/null and b/.DS_Store differ diff --git a/.gitattributes b/.gitattributes index a6344aac8c09253b3b630fb776ae94478aa0275b..50e4cc3f5d2c557323725f7b175661ac14affb8f 100644 --- a/.gitattributes +++ b/.gitattributes @@ -33,3 +33,5 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text *.zip filter=lfs diff=lfs merge=lfs -text *.zst filter=lfs diff=lfs merge=lfs -text *tfevents* filter=lfs diff=lfs merge=lfs -text +*.lance filter=lfs diff=lfs merge=lfs -text +*.idx filter=lfs diff=lfs merge=lfs -text diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..3b0d8f320349005754e2f9c1f63bbc5c89c21beb --- /dev/null +++ b/.gitignore @@ -0,0 +1,110 @@ +# Byte-compiled / optimized / DLL files +__pycache__/ +*.py[cod] +*$py.class + +# C extensions +*.so + +# Distribution / packaging +.Python +env/ +venv/ +build/ +develop-eggs/ +dist/ +downloads/ +eggs/ +.eggs/ +lib/ +lib64/ +parts/ +sdist/ +var/ +wheels/ +share/python-wheels/ +*.egg-info/ +.installed.cfg +*.egg + +# PyInstaller +# Usually these files are written by a python script from a template +# before PyInstaller builds the exe, so as to inject date/other infos into it. +*.manifest +*.spec + +# Installer logs +pip-log.txt +pip-delete-this-directory.txt + +# Unit test / coverage reports +htmlcov/ +.tox/ +.nox/ +.coverage +.coverage.* +.cache +nosetests.xml +coverage.xml +*.cover +*.py,cover +.hypothesis/ +.pytest_cache/ + +# Translations +*.mo +*.pot + +# Django stuff: +*.log +local_settings.py +db.sqlite3 + +# Flask stuff: +instance/ +.webassets-cache + +# Scrapy stuff: +.scrapy + +# Sphinx documentation +docs/_build/ + +# Jupyter Notebook +.ipynb_checkpoints + +# pyenv +.python-version + +# celery beat schedule file +celerybeat-schedule + +# SageMath parsed files +*.sage.py + +# Environments +.env +.venv +env/ +venv/ +ENV/ +env.bak/ +venv.bak/ + +# Spyder project settings +.spyderproject +.spyproject + +# Rope project settings +.ropeproject + +# mkdocs documentation +/site + +# mypy +.mypy_cache/ +.dmypy.json +dmypy.json + +# Pyre type checker +.pyre/ diff --git a/.lancedb/model1_fixed.lance/_indices/4a9890c3-c8d5-4f2e-b1ec-5678a46c625b/index.idx b/.lancedb/model1_fixed.lance/_indices/4a9890c3-c8d5-4f2e-b1ec-5678a46c625b/index.idx new file mode 100644 index 0000000000000000000000000000000000000000..971748e54c1e41d3b7c241d821f0ac98d7437312 --- /dev/null +++ b/.lancedb/model1_fixed.lance/_indices/4a9890c3-c8d5-4f2e-b1ec-5678a46c625b/index.idx @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:be17192e0f5a79a376bf775585a896413429c0c73bb9473530c1be6aba7b3f4c +size 1013792 diff --git a/.lancedb/model1_fixed.lance/_transactions/0-84ab077d-9861-44d8-be21-3ed1140ecfe3.txn b/.lancedb/model1_fixed.lance/_transactions/0-84ab077d-9861-44d8-be21-3ed1140ecfe3.txn new file mode 100644 index 0000000000000000000000000000000000000000..a57e9b9a670bf27e6f567e6f21bbbf3396691235 --- /dev/null +++ b/.lancedb/model1_fixed.lance/_transactions/0-84ab077d-9861-44d8-be21-3ed1140ecfe3.txn @@ -0,0 +1 @@ +$84ab077d-9861-44d8-be21-3ed1140ecfe3²U2vector ÿÿÿÿÿÿÿÿÿ*fixed_size_list:float:38408text ÿÿÿÿÿÿÿÿÿ*string08 \ No newline at end of file diff --git a/.lancedb/model1_fixed.lance/_transactions/1-46b62a4f-9a21-4f27-b9e9-e9676a1c656d.txn b/.lancedb/model1_fixed.lance/_transactions/1-46b62a4f-9a21-4f27-b9e9-e9676a1c656d.txn new file mode 100644 index 0000000000000000000000000000000000000000..9a434f74488b35d34d162688ef3ca79a48ec9a54 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/1-46b62a4f-9a21-4f27-b9e9-e9676a1c656d.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/10-bb361984-1c0c-48db-9782-42927a9cef20.txn b/.lancedb/model1_fixed.lance/_transactions/10-bb361984-1c0c-48db-9782-42927a9cef20.txn new file mode 100644 index 0000000000000000000000000000000000000000..b74d0b3bf20235525d0127e40d4a03afc1db2f61 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/10-bb361984-1c0c-48db-9782-42927a9cef20.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/100-5aea14c0-5f89-4308-b19e-d0d433dc4a14.txn b/.lancedb/model1_fixed.lance/_transactions/100-5aea14c0-5f89-4308-b19e-d0d433dc4a14.txn new file mode 100644 index 0000000000000000000000000000000000000000..1862274d436f6c90a372fc778083c6499152dc5a Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/100-5aea14c0-5f89-4308-b19e-d0d433dc4a14.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/101-a6d05c7a-f2ec-4924-aa0c-de90d30052e5.txn b/.lancedb/model1_fixed.lance/_transactions/101-a6d05c7a-f2ec-4924-aa0c-de90d30052e5.txn new file mode 100644 index 0000000000000000000000000000000000000000..e4e1a67f8295dbc35b58dd5b139e73e37d18e80e Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/101-a6d05c7a-f2ec-4924-aa0c-de90d30052e5.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/102-69b6e9de-9015-4e32-839b-ed344b6af4c0.txn b/.lancedb/model1_fixed.lance/_transactions/102-69b6e9de-9015-4e32-839b-ed344b6af4c0.txn new file mode 100644 index 0000000000000000000000000000000000000000..8ffc63498492c0e11e6bd0209b3b88e4fa83c85a Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/102-69b6e9de-9015-4e32-839b-ed344b6af4c0.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/103-35cc236d-59fd-4e65-afa4-63b65024aca3.txn b/.lancedb/model1_fixed.lance/_transactions/103-35cc236d-59fd-4e65-afa4-63b65024aca3.txn new file mode 100644 index 0000000000000000000000000000000000000000..9e67868815e8a1d29972c98bb7da4f85e835bd6c Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/103-35cc236d-59fd-4e65-afa4-63b65024aca3.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/104-a22a6170-fdbf-4ba7-9e9b-184150dedb89.txn b/.lancedb/model1_fixed.lance/_transactions/104-a22a6170-fdbf-4ba7-9e9b-184150dedb89.txn new file mode 100644 index 0000000000000000000000000000000000000000..516143d82a7ea9939abb360e05fd4323fda99f2d Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/104-a22a6170-fdbf-4ba7-9e9b-184150dedb89.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/105-6f968eef-eef6-445d-9b6e-a6c3ece109a5.txn b/.lancedb/model1_fixed.lance/_transactions/105-6f968eef-eef6-445d-9b6e-a6c3ece109a5.txn new file mode 100644 index 0000000000000000000000000000000000000000..68993a98b2917b1b8b61da6286ea030b3018007e Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/105-6f968eef-eef6-445d-9b6e-a6c3ece109a5.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/106-14417302-b8d2-4492-bcc2-604fecc9a83a.txn b/.lancedb/model1_fixed.lance/_transactions/106-14417302-b8d2-4492-bcc2-604fecc9a83a.txn new file mode 100644 index 0000000000000000000000000000000000000000..72579e10cc57afba92f4ca83100eae4a3f71636a Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/106-14417302-b8d2-4492-bcc2-604fecc9a83a.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/107-34ea30c3-2738-4988-9452-cd456d44b94f.txn b/.lancedb/model1_fixed.lance/_transactions/107-34ea30c3-2738-4988-9452-cd456d44b94f.txn new file mode 100644 index 0000000000000000000000000000000000000000..f1a7885e4806a5b7b74d6d9eed5263a2f605cc75 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/107-34ea30c3-2738-4988-9452-cd456d44b94f.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/108-4fac04b4-ad34-44c3-a6c2-48c86ab521d8.txn b/.lancedb/model1_fixed.lance/_transactions/108-4fac04b4-ad34-44c3-a6c2-48c86ab521d8.txn new file mode 100644 index 0000000000000000000000000000000000000000..c5a5ed6990a9fc53492ebb6511d0edc0ff180e17 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/108-4fac04b4-ad34-44c3-a6c2-48c86ab521d8.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/109-b63e4361-947b-43f8-ad1d-597662c05ddb.txn b/.lancedb/model1_fixed.lance/_transactions/109-b63e4361-947b-43f8-ad1d-597662c05ddb.txn new file mode 100644 index 0000000000000000000000000000000000000000..e98506f891532d3b220e214f4e85007c617cfdc5 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/109-b63e4361-947b-43f8-ad1d-597662c05ddb.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/11-0265e9d3-8851-4406-9537-141757900b3c.txn b/.lancedb/model1_fixed.lance/_transactions/11-0265e9d3-8851-4406-9537-141757900b3c.txn new file mode 100644 index 0000000000000000000000000000000000000000..91e6afbc2c09de620a4e61715cfd609d156f2b57 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/11-0265e9d3-8851-4406-9537-141757900b3c.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/110-77560f7a-a26f-45f1-a262-f761d43c8d99.txn b/.lancedb/model1_fixed.lance/_transactions/110-77560f7a-a26f-45f1-a262-f761d43c8d99.txn new file mode 100644 index 0000000000000000000000000000000000000000..d9b515cce39a6f6fdb2747e602cee684ccfe3765 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/110-77560f7a-a26f-45f1-a262-f761d43c8d99.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/111-94aafcdf-74eb-4b23-99e0-9645081601a4.txn b/.lancedb/model1_fixed.lance/_transactions/111-94aafcdf-74eb-4b23-99e0-9645081601a4.txn new file mode 100644 index 0000000000000000000000000000000000000000..41b069b8346ca2c7f30944a1a0287da19c537f67 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/111-94aafcdf-74eb-4b23-99e0-9645081601a4.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/112-84c0bd2c-a8b2-4cfa-853c-73da2f5fba97.txn b/.lancedb/model1_fixed.lance/_transactions/112-84c0bd2c-a8b2-4cfa-853c-73da2f5fba97.txn new file mode 100644 index 0000000000000000000000000000000000000000..0b05cb9d759c36f69000f36a21d538b38f532719 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/112-84c0bd2c-a8b2-4cfa-853c-73da2f5fba97.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/113-d2158477-e799-4c4d-b297-2a202ad083c5.txn b/.lancedb/model1_fixed.lance/_transactions/113-d2158477-e799-4c4d-b297-2a202ad083c5.txn new file mode 100644 index 0000000000000000000000000000000000000000..77131576e559b628e49e2468f9ac64ea8753df72 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/113-d2158477-e799-4c4d-b297-2a202ad083c5.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/114-2b19a3e4-fb76-4b17-af0e-d5c2260974f8.txn b/.lancedb/model1_fixed.lance/_transactions/114-2b19a3e4-fb76-4b17-af0e-d5c2260974f8.txn new file mode 100644 index 0000000000000000000000000000000000000000..d2a4cb2b6d56fbd1456b39b3ffdc5171b11b886c Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/114-2b19a3e4-fb76-4b17-af0e-d5c2260974f8.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/115-067cc079-1baa-4d99-962e-466cbcd19e29.txn b/.lancedb/model1_fixed.lance/_transactions/115-067cc079-1baa-4d99-962e-466cbcd19e29.txn new file mode 100644 index 0000000000000000000000000000000000000000..d6f879cad5bc66179ec7fc3f9b00b7a91f0d733b Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/115-067cc079-1baa-4d99-962e-466cbcd19e29.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/116-6aedd380-686c-4b41-a5f2-74b7c2d7cbae.txn b/.lancedb/model1_fixed.lance/_transactions/116-6aedd380-686c-4b41-a5f2-74b7c2d7cbae.txn new file mode 100644 index 0000000000000000000000000000000000000000..c5344259e873d89680475a6d4d5fb78188bc54f2 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/116-6aedd380-686c-4b41-a5f2-74b7c2d7cbae.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/117-5a3b3d62-e110-4561-8777-90e5d3c27570.txn b/.lancedb/model1_fixed.lance/_transactions/117-5a3b3d62-e110-4561-8777-90e5d3c27570.txn new file mode 100644 index 0000000000000000000000000000000000000000..a07e17aab74bfa49ae945695e71f077343117f56 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/117-5a3b3d62-e110-4561-8777-90e5d3c27570.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/118-c7d4ff17-4972-4f7c-bd95-bd8a00120772.txn b/.lancedb/model1_fixed.lance/_transactions/118-c7d4ff17-4972-4f7c-bd95-bd8a00120772.txn new file mode 100644 index 0000000000000000000000000000000000000000..e2e2abe92797ef12ad5afe88f46d80d127984329 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/118-c7d4ff17-4972-4f7c-bd95-bd8a00120772.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/119-7dde3c8d-27bb-4695-b830-e4dadb6ca518.txn b/.lancedb/model1_fixed.lance/_transactions/119-7dde3c8d-27bb-4695-b830-e4dadb6ca518.txn new file mode 100644 index 0000000000000000000000000000000000000000..be9d0ece01daeb17991a3acd73c170d4f2f7203a Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/119-7dde3c8d-27bb-4695-b830-e4dadb6ca518.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/12-bceb5d00-6d53-4216-bfc3-303991353a60.txn b/.lancedb/model1_fixed.lance/_transactions/12-bceb5d00-6d53-4216-bfc3-303991353a60.txn new file mode 100644 index 0000000000000000000000000000000000000000..491c570618db5b7896a8b0e75ab704d9da732686 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/12-bceb5d00-6d53-4216-bfc3-303991353a60.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/120-0856b97f-9acf-437c-8732-030120449e80.txn b/.lancedb/model1_fixed.lance/_transactions/120-0856b97f-9acf-437c-8732-030120449e80.txn new file mode 100644 index 0000000000000000000000000000000000000000..b73d223b96ce2ae8cdd4e18da75776ba6679486d Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/120-0856b97f-9acf-437c-8732-030120449e80.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/121-10843277-3346-4595-85d1-fdc527a1ccb6.txn b/.lancedb/model1_fixed.lance/_transactions/121-10843277-3346-4595-85d1-fdc527a1ccb6.txn new file mode 100644 index 0000000000000000000000000000000000000000..e4eea3f4ec69232d3985267a2508deaf5eca3d9a Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/121-10843277-3346-4595-85d1-fdc527a1ccb6.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/122-cba70509-df29-4811-86bb-a89144ea1b37.txn b/.lancedb/model1_fixed.lance/_transactions/122-cba70509-df29-4811-86bb-a89144ea1b37.txn new file mode 100644 index 0000000000000000000000000000000000000000..ad4b4d9ba613705ab1de07005a7b20ca8d8f0f21 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/122-cba70509-df29-4811-86bb-a89144ea1b37.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/123-9e384283-60d8-4a88-816c-bbb3ee544439.txn b/.lancedb/model1_fixed.lance/_transactions/123-9e384283-60d8-4a88-816c-bbb3ee544439.txn new file mode 100644 index 0000000000000000000000000000000000000000..70084ed546e54ce0dcf680aa56e098d440d79968 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/123-9e384283-60d8-4a88-816c-bbb3ee544439.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/124-f5231538-b4a1-44af-8ab3-deefda5da025.txn b/.lancedb/model1_fixed.lance/_transactions/124-f5231538-b4a1-44af-8ab3-deefda5da025.txn new file mode 100644 index 0000000000000000000000000000000000000000..85b391719291b3ac5ae981ea0a1b162c575baab4 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/124-f5231538-b4a1-44af-8ab3-deefda5da025.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/125-3102c01b-9e23-4c9b-a7fc-443b3e4c2c51.txn b/.lancedb/model1_fixed.lance/_transactions/125-3102c01b-9e23-4c9b-a7fc-443b3e4c2c51.txn new file mode 100644 index 0000000000000000000000000000000000000000..9967f825b82c5fe457ad5bc31430909340744945 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/125-3102c01b-9e23-4c9b-a7fc-443b3e4c2c51.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/126-3d112427-9106-4042-9cdb-6d9e8844a00e.txn b/.lancedb/model1_fixed.lance/_transactions/126-3d112427-9106-4042-9cdb-6d9e8844a00e.txn new file mode 100644 index 0000000000000000000000000000000000000000..73130c6990f837734f723b2a38b9f70551b294a4 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/126-3d112427-9106-4042-9cdb-6d9e8844a00e.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/127-bea96de9-61c8-439e-93eb-f255d33eab71.txn b/.lancedb/model1_fixed.lance/_transactions/127-bea96de9-61c8-439e-93eb-f255d33eab71.txn new file mode 100644 index 0000000000000000000000000000000000000000..bf8d2dc5dd093e47756f82b7142dabf49004a394 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/127-bea96de9-61c8-439e-93eb-f255d33eab71.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/128-c7f5ec68-2e35-47a4-bff3-02cf5ed60781.txn b/.lancedb/model1_fixed.lance/_transactions/128-c7f5ec68-2e35-47a4-bff3-02cf5ed60781.txn new file mode 100644 index 0000000000000000000000000000000000000000..bd50897f251fc0dc802cc774c54f8cf17f02f6b3 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/128-c7f5ec68-2e35-47a4-bff3-02cf5ed60781.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/13-94cc5618-4b98-498d-a588-ca803d316dfd.txn b/.lancedb/model1_fixed.lance/_transactions/13-94cc5618-4b98-498d-a588-ca803d316dfd.txn new file mode 100644 index 0000000000000000000000000000000000000000..7f1699baacdf6153ba05ad497e808ed8a545dabd Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/13-94cc5618-4b98-498d-a588-ca803d316dfd.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/14-e7a45889-d809-498c-83f7-68594384a636.txn b/.lancedb/model1_fixed.lance/_transactions/14-e7a45889-d809-498c-83f7-68594384a636.txn new file mode 100644 index 0000000000000000000000000000000000000000..df1c4738146e2e69dcef72ee56af59787366a85c Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/14-e7a45889-d809-498c-83f7-68594384a636.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/15-8d13d72e-c4ba-4fa5-8e3d-b40f0837c8ea.txn b/.lancedb/model1_fixed.lance/_transactions/15-8d13d72e-c4ba-4fa5-8e3d-b40f0837c8ea.txn new file mode 100644 index 0000000000000000000000000000000000000000..db9949d214ce4fef735841f8d4dee33325e8f788 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/15-8d13d72e-c4ba-4fa5-8e3d-b40f0837c8ea.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/16-e83f15e1-5663-4e2f-8ef9-a07bf1b867cb.txn b/.lancedb/model1_fixed.lance/_transactions/16-e83f15e1-5663-4e2f-8ef9-a07bf1b867cb.txn new file mode 100644 index 0000000000000000000000000000000000000000..49e153abd47b645c8555bbcb7e18ee9609afc43d Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/16-e83f15e1-5663-4e2f-8ef9-a07bf1b867cb.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/17-5cb2032a-1b4d-48cd-8492-f8e17eaa0112.txn b/.lancedb/model1_fixed.lance/_transactions/17-5cb2032a-1b4d-48cd-8492-f8e17eaa0112.txn new file mode 100644 index 0000000000000000000000000000000000000000..ae174ae9fc1491f80c7f9d4c5112c7ccaf4fbb5d Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/17-5cb2032a-1b4d-48cd-8492-f8e17eaa0112.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/18-621f16a3-ca0d-4274-bd08-8c7836098059.txn b/.lancedb/model1_fixed.lance/_transactions/18-621f16a3-ca0d-4274-bd08-8c7836098059.txn new file mode 100644 index 0000000000000000000000000000000000000000..de0581a0ede10fdb9533d29bf778c6ccdb38b13a Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/18-621f16a3-ca0d-4274-bd08-8c7836098059.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/19-498b40c4-7979-4408-9f92-2c4b55ff1116.txn b/.lancedb/model1_fixed.lance/_transactions/19-498b40c4-7979-4408-9f92-2c4b55ff1116.txn new file mode 100644 index 0000000000000000000000000000000000000000..41164a951f81b11614e188aeb4b2245cbe29a6cb Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/19-498b40c4-7979-4408-9f92-2c4b55ff1116.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/2-83a6fc76-8e1b-4561-82d9-8d099069ab23.txn b/.lancedb/model1_fixed.lance/_transactions/2-83a6fc76-8e1b-4561-82d9-8d099069ab23.txn new file mode 100644 index 0000000000000000000000000000000000000000..16a3d88cd761e038187e2ad311bfa0a540e4ce07 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/2-83a6fc76-8e1b-4561-82d9-8d099069ab23.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/20-06934645-ff50-4ef7-a98a-cf4cac824f56.txn b/.lancedb/model1_fixed.lance/_transactions/20-06934645-ff50-4ef7-a98a-cf4cac824f56.txn new file mode 100644 index 0000000000000000000000000000000000000000..c9b1d61b7531ae4162f22c0961f825230146376b Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/20-06934645-ff50-4ef7-a98a-cf4cac824f56.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/21-99c341a7-2763-4321-b5e3-488611fc00b6.txn b/.lancedb/model1_fixed.lance/_transactions/21-99c341a7-2763-4321-b5e3-488611fc00b6.txn new file mode 100644 index 0000000000000000000000000000000000000000..3aa6b02720335f704690575da40daf2b16356b22 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/21-99c341a7-2763-4321-b5e3-488611fc00b6.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/22-22c179d6-0030-47e3-98ed-48ce13ff0bc5.txn b/.lancedb/model1_fixed.lance/_transactions/22-22c179d6-0030-47e3-98ed-48ce13ff0bc5.txn new file mode 100644 index 0000000000000000000000000000000000000000..e996d78ce7d03861e783b339f8073c2354c4234a Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/22-22c179d6-0030-47e3-98ed-48ce13ff0bc5.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/23-0baa10b4-2410-48b4-a3b1-f16c758da076.txn b/.lancedb/model1_fixed.lance/_transactions/23-0baa10b4-2410-48b4-a3b1-f16c758da076.txn new file mode 100644 index 0000000000000000000000000000000000000000..38abcf9b333a7ae40b4634d86c8d26dc5c48cc22 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/23-0baa10b4-2410-48b4-a3b1-f16c758da076.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/24-856a71e2-54d5-41ed-bc1e-fe8963fe2912.txn b/.lancedb/model1_fixed.lance/_transactions/24-856a71e2-54d5-41ed-bc1e-fe8963fe2912.txn new file mode 100644 index 0000000000000000000000000000000000000000..bf7d1d2f9565f7c3286ed6d8c0dd34f1f1c17077 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/24-856a71e2-54d5-41ed-bc1e-fe8963fe2912.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/25-49bf907f-4029-424c-bf66-1b9900dbf393.txn b/.lancedb/model1_fixed.lance/_transactions/25-49bf907f-4029-424c-bf66-1b9900dbf393.txn new file mode 100644 index 0000000000000000000000000000000000000000..7c898f7d59e95fd6155e2205d34f65a8e900a718 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/25-49bf907f-4029-424c-bf66-1b9900dbf393.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/26-15769fd6-ccbe-40f2-b1a4-c85ed8b83feb.txn b/.lancedb/model1_fixed.lance/_transactions/26-15769fd6-ccbe-40f2-b1a4-c85ed8b83feb.txn new file mode 100644 index 0000000000000000000000000000000000000000..b1ac9d7e4e994ddeccb33a2b8b8eccdd0dd7df15 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/26-15769fd6-ccbe-40f2-b1a4-c85ed8b83feb.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/27-e4041544-f578-4e0f-b62a-84889443b1d7.txn b/.lancedb/model1_fixed.lance/_transactions/27-e4041544-f578-4e0f-b62a-84889443b1d7.txn new file mode 100644 index 0000000000000000000000000000000000000000..a0eb07dff04f336c27627069f7572c24b74df2bf Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/27-e4041544-f578-4e0f-b62a-84889443b1d7.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/28-a1b6c288-acd4-4e8e-a231-4b28eff7c098.txn b/.lancedb/model1_fixed.lance/_transactions/28-a1b6c288-acd4-4e8e-a231-4b28eff7c098.txn new file mode 100644 index 0000000000000000000000000000000000000000..92c686f12005b0487e781017b943733a22be75e3 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/28-a1b6c288-acd4-4e8e-a231-4b28eff7c098.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/29-3ed0ad81-0468-44bd-8cfc-9d9dc34e2259.txn b/.lancedb/model1_fixed.lance/_transactions/29-3ed0ad81-0468-44bd-8cfc-9d9dc34e2259.txn new file mode 100644 index 0000000000000000000000000000000000000000..47341028acf6fa7c2c80f30f03e189ade0303bfb Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/29-3ed0ad81-0468-44bd-8cfc-9d9dc34e2259.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/3-90534772-1cd0-4a23-b258-cd835e2de65a.txn b/.lancedb/model1_fixed.lance/_transactions/3-90534772-1cd0-4a23-b258-cd835e2de65a.txn new file mode 100644 index 0000000000000000000000000000000000000000..6b86199741d2de1075e4465085f4e0eedb508306 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/3-90534772-1cd0-4a23-b258-cd835e2de65a.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/30-26420bf1-9a55-43b6-a916-7861259517d6.txn b/.lancedb/model1_fixed.lance/_transactions/30-26420bf1-9a55-43b6-a916-7861259517d6.txn new file mode 100644 index 0000000000000000000000000000000000000000..fd4bb83eb25800c14d75f6a39f3f00f9ff69d4d6 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/30-26420bf1-9a55-43b6-a916-7861259517d6.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/31-734e852b-9897-47d5-982e-b6f67562543f.txn b/.lancedb/model1_fixed.lance/_transactions/31-734e852b-9897-47d5-982e-b6f67562543f.txn new file mode 100644 index 0000000000000000000000000000000000000000..2ce0944dfc2188aebad6447afe5699d4bfec8cf6 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/31-734e852b-9897-47d5-982e-b6f67562543f.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/32-c2ad38b9-3f37-41ac-87e0-299a7c5d21c9.txn b/.lancedb/model1_fixed.lance/_transactions/32-c2ad38b9-3f37-41ac-87e0-299a7c5d21c9.txn new file mode 100644 index 0000000000000000000000000000000000000000..03cfe82d4bdfe243571e558b0ff9b20913659b0d Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/32-c2ad38b9-3f37-41ac-87e0-299a7c5d21c9.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/33-09bde3cf-4e75-44c2-9ead-87d91e1ecc15.txn b/.lancedb/model1_fixed.lance/_transactions/33-09bde3cf-4e75-44c2-9ead-87d91e1ecc15.txn new file mode 100644 index 0000000000000000000000000000000000000000..9f11962c54a63ee51d3ce852b3f6e01f6903951e Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/33-09bde3cf-4e75-44c2-9ead-87d91e1ecc15.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/34-a493cf8a-f042-491d-90b7-44b10872b7ca.txn b/.lancedb/model1_fixed.lance/_transactions/34-a493cf8a-f042-491d-90b7-44b10872b7ca.txn new file mode 100644 index 0000000000000000000000000000000000000000..d55a8472fecd8cb80ea4ae0bc32cebef3a4a90a1 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/34-a493cf8a-f042-491d-90b7-44b10872b7ca.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/35-20b5e628-c9ff-4170-ad02-a088be6a760d.txn b/.lancedb/model1_fixed.lance/_transactions/35-20b5e628-c9ff-4170-ad02-a088be6a760d.txn new file mode 100644 index 0000000000000000000000000000000000000000..802aaea90755b7839323f1a34707a92a895b2434 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/35-20b5e628-c9ff-4170-ad02-a088be6a760d.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/36-a90e2e0d-4d23-4757-964f-7020d92bc4ac.txn b/.lancedb/model1_fixed.lance/_transactions/36-a90e2e0d-4d23-4757-964f-7020d92bc4ac.txn new file mode 100644 index 0000000000000000000000000000000000000000..0952b08675e9f6bf8cafa43e3d5b65c15ed06207 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/36-a90e2e0d-4d23-4757-964f-7020d92bc4ac.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/37-ee77517b-cb11-43ae-bdd7-bae53fe78074.txn b/.lancedb/model1_fixed.lance/_transactions/37-ee77517b-cb11-43ae-bdd7-bae53fe78074.txn new file mode 100644 index 0000000000000000000000000000000000000000..3eff9a54508a78011e6e6da602dfd658c6ad56ba Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/37-ee77517b-cb11-43ae-bdd7-bae53fe78074.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/38-577eb53c-66f3-494b-b6fd-b51a25d21af0.txn b/.lancedb/model1_fixed.lance/_transactions/38-577eb53c-66f3-494b-b6fd-b51a25d21af0.txn new file mode 100644 index 0000000000000000000000000000000000000000..0550ef64b297c635fd55f80e97833ad31dbb077a Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/38-577eb53c-66f3-494b-b6fd-b51a25d21af0.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/39-067bc589-cce4-4e90-927f-f8d7f9477669.txn b/.lancedb/model1_fixed.lance/_transactions/39-067bc589-cce4-4e90-927f-f8d7f9477669.txn new file mode 100644 index 0000000000000000000000000000000000000000..c29e9d9ccca47668b8f5680d261632d977ac67c8 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/39-067bc589-cce4-4e90-927f-f8d7f9477669.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/4-abbee7ea-d1d5-4ea7-acda-52cb3e15263f.txn b/.lancedb/model1_fixed.lance/_transactions/4-abbee7ea-d1d5-4ea7-acda-52cb3e15263f.txn new file mode 100644 index 0000000000000000000000000000000000000000..903f167b5d87290c03d081cd5f49635668ee5ef3 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/4-abbee7ea-d1d5-4ea7-acda-52cb3e15263f.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/40-7bcb47bf-eb7c-4d03-9f2a-c462da336d59.txn b/.lancedb/model1_fixed.lance/_transactions/40-7bcb47bf-eb7c-4d03-9f2a-c462da336d59.txn new file mode 100644 index 0000000000000000000000000000000000000000..890da5b8524839785083233191c5f4066571449e Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/40-7bcb47bf-eb7c-4d03-9f2a-c462da336d59.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/41-e2254ba3-45dd-41df-bccc-2494b91fd5f0.txn b/.lancedb/model1_fixed.lance/_transactions/41-e2254ba3-45dd-41df-bccc-2494b91fd5f0.txn new file mode 100644 index 0000000000000000000000000000000000000000..d9542c856b42e22b0eb8acd948357d4a7de84213 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/41-e2254ba3-45dd-41df-bccc-2494b91fd5f0.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/42-373fa3e1-afb6-416b-9968-9e7c1f4e0366.txn b/.lancedb/model1_fixed.lance/_transactions/42-373fa3e1-afb6-416b-9968-9e7c1f4e0366.txn new file mode 100644 index 0000000000000000000000000000000000000000..5fe7c8ee34e15330fb28b26d53e11b2736d7583b Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/42-373fa3e1-afb6-416b-9968-9e7c1f4e0366.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/43-22a5da69-2198-40c1-a053-ef7e1334ed05.txn b/.lancedb/model1_fixed.lance/_transactions/43-22a5da69-2198-40c1-a053-ef7e1334ed05.txn new file mode 100644 index 0000000000000000000000000000000000000000..3dc531f0fab5753d1b4c01d3a430449145bbbbc5 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/43-22a5da69-2198-40c1-a053-ef7e1334ed05.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/44-f12f6b50-8f74-4f8f-8629-0870dfd5955c.txn b/.lancedb/model1_fixed.lance/_transactions/44-f12f6b50-8f74-4f8f-8629-0870dfd5955c.txn new file mode 100644 index 0000000000000000000000000000000000000000..fbc57bfdc5ccf68587274de49d3e81a281a15cfd Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/44-f12f6b50-8f74-4f8f-8629-0870dfd5955c.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/45-065799de-d90b-48b9-a1b1-99f0baffd0c6.txn b/.lancedb/model1_fixed.lance/_transactions/45-065799de-d90b-48b9-a1b1-99f0baffd0c6.txn new file mode 100644 index 0000000000000000000000000000000000000000..b6f8b21dc74df846fc8698361724fbe77cb0f2a8 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/45-065799de-d90b-48b9-a1b1-99f0baffd0c6.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/46-c1fc1ade-9d7e-48d1-bfc7-adb730d1a8fd.txn b/.lancedb/model1_fixed.lance/_transactions/46-c1fc1ade-9d7e-48d1-bfc7-adb730d1a8fd.txn new file mode 100644 index 0000000000000000000000000000000000000000..f1d9c57538f01fd1f599a48e052bf889f960d42f Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/46-c1fc1ade-9d7e-48d1-bfc7-adb730d1a8fd.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/47-99cabc87-f5f1-4fcf-9570-d117f10c62f4.txn b/.lancedb/model1_fixed.lance/_transactions/47-99cabc87-f5f1-4fcf-9570-d117f10c62f4.txn new file mode 100644 index 0000000000000000000000000000000000000000..59876489158812d791e79dc1831cc74000879291 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/47-99cabc87-f5f1-4fcf-9570-d117f10c62f4.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/48-bde790b3-e086-4e99-9fa8-19aa72f3e0e3.txn b/.lancedb/model1_fixed.lance/_transactions/48-bde790b3-e086-4e99-9fa8-19aa72f3e0e3.txn new file mode 100644 index 0000000000000000000000000000000000000000..28f5831986ce6a097d9888b1b0aa866d983151fb Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/48-bde790b3-e086-4e99-9fa8-19aa72f3e0e3.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/49-10da3fb7-bd60-4073-9744-25b96e77da4b.txn b/.lancedb/model1_fixed.lance/_transactions/49-10da3fb7-bd60-4073-9744-25b96e77da4b.txn new file mode 100644 index 0000000000000000000000000000000000000000..f9033e6f95ad617c6888860d552435c66f8f3f54 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/49-10da3fb7-bd60-4073-9744-25b96e77da4b.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/5-a1f0522c-8b30-498d-b55d-e4adbb8086ac.txn b/.lancedb/model1_fixed.lance/_transactions/5-a1f0522c-8b30-498d-b55d-e4adbb8086ac.txn new file mode 100644 index 0000000000000000000000000000000000000000..5cec3efcdded0455cce9cacda8c67bc4e93f768e Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/5-a1f0522c-8b30-498d-b55d-e4adbb8086ac.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/50-6dfb19d2-3ea9-47c9-8d84-a63158c7534f.txn b/.lancedb/model1_fixed.lance/_transactions/50-6dfb19d2-3ea9-47c9-8d84-a63158c7534f.txn new file mode 100644 index 0000000000000000000000000000000000000000..2405324a3e02cbeb11518faec847af3fb65b4d3c Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/50-6dfb19d2-3ea9-47c9-8d84-a63158c7534f.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/51-107024d0-6a89-4efe-95a5-9c9f120aa483.txn b/.lancedb/model1_fixed.lance/_transactions/51-107024d0-6a89-4efe-95a5-9c9f120aa483.txn new file mode 100644 index 0000000000000000000000000000000000000000..747969e74bc68282e84e75182f564a9f4ba67da6 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/51-107024d0-6a89-4efe-95a5-9c9f120aa483.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/52-24239910-c4ba-47a6-ac9d-ce28f10543f8.txn b/.lancedb/model1_fixed.lance/_transactions/52-24239910-c4ba-47a6-ac9d-ce28f10543f8.txn new file mode 100644 index 0000000000000000000000000000000000000000..3ac987b5464f3ec3d3044f146d1ec3841d6cdc5b Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/52-24239910-c4ba-47a6-ac9d-ce28f10543f8.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/53-48d86c43-61eb-42d2-a79a-c01bda44614c.txn b/.lancedb/model1_fixed.lance/_transactions/53-48d86c43-61eb-42d2-a79a-c01bda44614c.txn new file mode 100644 index 0000000000000000000000000000000000000000..59940b9720acbbb4c22152e168f0a640414750e4 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/53-48d86c43-61eb-42d2-a79a-c01bda44614c.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/54-ed6c064b-063e-44ef-a019-c7178350ad53.txn b/.lancedb/model1_fixed.lance/_transactions/54-ed6c064b-063e-44ef-a019-c7178350ad53.txn new file mode 100644 index 0000000000000000000000000000000000000000..543443e80c9715fc24518142ed787eddba731554 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/54-ed6c064b-063e-44ef-a019-c7178350ad53.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/55-5b489b35-b787-4fff-bc79-85b6da25659c.txn b/.lancedb/model1_fixed.lance/_transactions/55-5b489b35-b787-4fff-bc79-85b6da25659c.txn new file mode 100644 index 0000000000000000000000000000000000000000..ba15233e24fa06be0b973a1f08759d3053483fdc Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/55-5b489b35-b787-4fff-bc79-85b6da25659c.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/56-f38c83db-94ec-4eb9-990a-7ee5193e296d.txn b/.lancedb/model1_fixed.lance/_transactions/56-f38c83db-94ec-4eb9-990a-7ee5193e296d.txn new file mode 100644 index 0000000000000000000000000000000000000000..f9e4380196797c2997d5597b0bd51aabe9e032d3 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/56-f38c83db-94ec-4eb9-990a-7ee5193e296d.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/57-b55bd261-72e7-4407-aeb0-f4319c72865d.txn b/.lancedb/model1_fixed.lance/_transactions/57-b55bd261-72e7-4407-aeb0-f4319c72865d.txn new file mode 100644 index 0000000000000000000000000000000000000000..d2d80628cc3de16da19b7a1ccb8be31b66d485fe Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/57-b55bd261-72e7-4407-aeb0-f4319c72865d.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/58-a104b845-a3b9-4d92-9a91-7781cb862200.txn b/.lancedb/model1_fixed.lance/_transactions/58-a104b845-a3b9-4d92-9a91-7781cb862200.txn new file mode 100644 index 0000000000000000000000000000000000000000..37f9c8423b4e481c03bd3fd3cf106e8d582d2074 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/58-a104b845-a3b9-4d92-9a91-7781cb862200.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/59-0272e3bf-cb32-4c1a-a6e0-4db7d9d61e03.txn b/.lancedb/model1_fixed.lance/_transactions/59-0272e3bf-cb32-4c1a-a6e0-4db7d9d61e03.txn new file mode 100644 index 0000000000000000000000000000000000000000..0540034a74b47434ccbcdbd3bbfde234531b1c2a Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/59-0272e3bf-cb32-4c1a-a6e0-4db7d9d61e03.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/6-28b14d6d-5b10-4dc2-b6db-216a908c8991.txn b/.lancedb/model1_fixed.lance/_transactions/6-28b14d6d-5b10-4dc2-b6db-216a908c8991.txn new file mode 100644 index 0000000000000000000000000000000000000000..689a18f25041f4303b6b158375cbb578edefef0f Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/6-28b14d6d-5b10-4dc2-b6db-216a908c8991.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/60-31ddf154-c8cb-406e-8576-f7826dfdf8f9.txn b/.lancedb/model1_fixed.lance/_transactions/60-31ddf154-c8cb-406e-8576-f7826dfdf8f9.txn new file mode 100644 index 0000000000000000000000000000000000000000..5bec4967b47b98863f4101c6efeda82da55b079b Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/60-31ddf154-c8cb-406e-8576-f7826dfdf8f9.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/61-e324eae7-75ef-4dbf-93d6-2048154195a6.txn b/.lancedb/model1_fixed.lance/_transactions/61-e324eae7-75ef-4dbf-93d6-2048154195a6.txn new file mode 100644 index 0000000000000000000000000000000000000000..fa669df3d97b860f354fc792a8ad0f13b3247170 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/61-e324eae7-75ef-4dbf-93d6-2048154195a6.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/62-ef64d750-1701-4023-8975-ef64dcd8b0ce.txn b/.lancedb/model1_fixed.lance/_transactions/62-ef64d750-1701-4023-8975-ef64dcd8b0ce.txn new file mode 100644 index 0000000000000000000000000000000000000000..7a69e69f056e87af4503736f8ebb7710d1fd7a71 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/62-ef64d750-1701-4023-8975-ef64dcd8b0ce.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/63-ee999767-243d-40e6-8bf2-b496e97ebcd7.txn b/.lancedb/model1_fixed.lance/_transactions/63-ee999767-243d-40e6-8bf2-b496e97ebcd7.txn new file mode 100644 index 0000000000000000000000000000000000000000..16e2d8afbb34b7c96518b20cb77c9966d866b292 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/63-ee999767-243d-40e6-8bf2-b496e97ebcd7.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/64-7a297e75-25ba-4075-9caf-0581542c0277.txn b/.lancedb/model1_fixed.lance/_transactions/64-7a297e75-25ba-4075-9caf-0581542c0277.txn new file mode 100644 index 0000000000000000000000000000000000000000..dc0207a8b03c2ee0bb905cd9c18cc5946baa2793 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/64-7a297e75-25ba-4075-9caf-0581542c0277.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/65-cf8d14c5-2c37-46cf-a41c-934fbfab6b15.txn b/.lancedb/model1_fixed.lance/_transactions/65-cf8d14c5-2c37-46cf-a41c-934fbfab6b15.txn new file mode 100644 index 0000000000000000000000000000000000000000..5962cf4b3d48a3936b4e8fa46227c5fcb09b0a25 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/65-cf8d14c5-2c37-46cf-a41c-934fbfab6b15.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/66-10eb11e4-1dc6-433c-8997-0e48cba97655.txn b/.lancedb/model1_fixed.lance/_transactions/66-10eb11e4-1dc6-433c-8997-0e48cba97655.txn new file mode 100644 index 0000000000000000000000000000000000000000..e152c81eeb0b00e5a5df69fecfa3e979dfb44d5d Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/66-10eb11e4-1dc6-433c-8997-0e48cba97655.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/67-bf5acebf-1a3e-41d2-8b62-3e367968cbc4.txn b/.lancedb/model1_fixed.lance/_transactions/67-bf5acebf-1a3e-41d2-8b62-3e367968cbc4.txn new file mode 100644 index 0000000000000000000000000000000000000000..8418054540f0e44afbb15a014d70067cf06798a7 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/67-bf5acebf-1a3e-41d2-8b62-3e367968cbc4.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/68-568a994f-20a2-4d34-a240-3c941e89de3a.txn b/.lancedb/model1_fixed.lance/_transactions/68-568a994f-20a2-4d34-a240-3c941e89de3a.txn new file mode 100644 index 0000000000000000000000000000000000000000..6b5f670b45171b6753b7d35571863bc84e3bebb8 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/68-568a994f-20a2-4d34-a240-3c941e89de3a.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/69-07230566-572a-4856-82df-2074717a63a3.txn b/.lancedb/model1_fixed.lance/_transactions/69-07230566-572a-4856-82df-2074717a63a3.txn new file mode 100644 index 0000000000000000000000000000000000000000..9fc63f143a23389b77e688240d61e38721e336fd Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/69-07230566-572a-4856-82df-2074717a63a3.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/7-c89411d8-1492-4f09-84a1-b9d0ac22fbdf.txn b/.lancedb/model1_fixed.lance/_transactions/7-c89411d8-1492-4f09-84a1-b9d0ac22fbdf.txn new file mode 100644 index 0000000000000000000000000000000000000000..65573683b2c62a2ab72d6425a1abf1db9e923d4e Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/7-c89411d8-1492-4f09-84a1-b9d0ac22fbdf.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/70-ca49882b-b720-47f9-bae7-fe3b01e3f4ec.txn b/.lancedb/model1_fixed.lance/_transactions/70-ca49882b-b720-47f9-bae7-fe3b01e3f4ec.txn new file mode 100644 index 0000000000000000000000000000000000000000..667626b60eb2cfbf55aa41bd9b7677fff28a88aa Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/70-ca49882b-b720-47f9-bae7-fe3b01e3f4ec.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/71-0e1b49c9-9dc2-4b1f-92fa-cfbed5048793.txn b/.lancedb/model1_fixed.lance/_transactions/71-0e1b49c9-9dc2-4b1f-92fa-cfbed5048793.txn new file mode 100644 index 0000000000000000000000000000000000000000..72b3d75bf83e496ea8fd25ef7b8ff42f86c8c05c Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/71-0e1b49c9-9dc2-4b1f-92fa-cfbed5048793.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/72-36c675a4-f2bb-44e2-8481-22a4b31145bd.txn b/.lancedb/model1_fixed.lance/_transactions/72-36c675a4-f2bb-44e2-8481-22a4b31145bd.txn new file mode 100644 index 0000000000000000000000000000000000000000..dc4d14c8db9fcadd836e2edfd70142a2d7bf99d0 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/72-36c675a4-f2bb-44e2-8481-22a4b31145bd.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/73-762d6f9c-9ce7-4f24-8823-a3268f58eafb.txn b/.lancedb/model1_fixed.lance/_transactions/73-762d6f9c-9ce7-4f24-8823-a3268f58eafb.txn new file mode 100644 index 0000000000000000000000000000000000000000..36996290c5355c10d9db2285b3871e68b7970419 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/73-762d6f9c-9ce7-4f24-8823-a3268f58eafb.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/74-b5017a34-be63-4325-aa62-816f3471976e.txn b/.lancedb/model1_fixed.lance/_transactions/74-b5017a34-be63-4325-aa62-816f3471976e.txn new file mode 100644 index 0000000000000000000000000000000000000000..36ee32efb960ecaebc010fb4d55dca792b58ef43 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/74-b5017a34-be63-4325-aa62-816f3471976e.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/75-cf4c3ef7-b1be-4f15-80a3-7c1b65950da5.txn b/.lancedb/model1_fixed.lance/_transactions/75-cf4c3ef7-b1be-4f15-80a3-7c1b65950da5.txn new file mode 100644 index 0000000000000000000000000000000000000000..a7f0df5da8b1af3eed9f18a40030483a92259fee Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/75-cf4c3ef7-b1be-4f15-80a3-7c1b65950da5.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/76-0f2622e7-c573-4232-8d79-e7320f3a602c.txn b/.lancedb/model1_fixed.lance/_transactions/76-0f2622e7-c573-4232-8d79-e7320f3a602c.txn new file mode 100644 index 0000000000000000000000000000000000000000..6b471b979923ca3121e1bd122305c6b085f1afc2 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/76-0f2622e7-c573-4232-8d79-e7320f3a602c.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/77-5da0e873-6b58-413d-9b2f-dbcd3e9d605e.txn b/.lancedb/model1_fixed.lance/_transactions/77-5da0e873-6b58-413d-9b2f-dbcd3e9d605e.txn new file mode 100644 index 0000000000000000000000000000000000000000..49dd500530674c58ff20998660ff0c6b0d457df4 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/77-5da0e873-6b58-413d-9b2f-dbcd3e9d605e.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/78-eb54cbd6-48f6-49e8-b171-f90f6ed630a2.txn b/.lancedb/model1_fixed.lance/_transactions/78-eb54cbd6-48f6-49e8-b171-f90f6ed630a2.txn new file mode 100644 index 0000000000000000000000000000000000000000..78962e11c140e78e76a9da690055655f9c9e4f05 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/78-eb54cbd6-48f6-49e8-b171-f90f6ed630a2.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/79-86642220-5fba-4661-b01c-834cb9f5d4b9.txn b/.lancedb/model1_fixed.lance/_transactions/79-86642220-5fba-4661-b01c-834cb9f5d4b9.txn new file mode 100644 index 0000000000000000000000000000000000000000..80f6f7f89264e7b17834be5204962946fd91b64f Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/79-86642220-5fba-4661-b01c-834cb9f5d4b9.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/8-16cab04e-19c6-46da-9ae5-71f19edfe786.txn b/.lancedb/model1_fixed.lance/_transactions/8-16cab04e-19c6-46da-9ae5-71f19edfe786.txn new file mode 100644 index 0000000000000000000000000000000000000000..b750b55ed2a684fdb4fb61d30ffa40386eb31739 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/8-16cab04e-19c6-46da-9ae5-71f19edfe786.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/80-df746d17-3802-4760-9694-01c270c9e776.txn b/.lancedb/model1_fixed.lance/_transactions/80-df746d17-3802-4760-9694-01c270c9e776.txn new file mode 100644 index 0000000000000000000000000000000000000000..a65ab85ed4016a44372136e15edccc3f0909cefc Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/80-df746d17-3802-4760-9694-01c270c9e776.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/81-6b07b0e5-5d89-4aa7-a34d-7fbd0815b5a1.txn b/.lancedb/model1_fixed.lance/_transactions/81-6b07b0e5-5d89-4aa7-a34d-7fbd0815b5a1.txn new file mode 100644 index 0000000000000000000000000000000000000000..ba284072e7916c2c69db0d11fb580672f389eb95 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/81-6b07b0e5-5d89-4aa7-a34d-7fbd0815b5a1.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/82-6e3adb17-3377-45dd-b109-0403e8fc4cf5.txn b/.lancedb/model1_fixed.lance/_transactions/82-6e3adb17-3377-45dd-b109-0403e8fc4cf5.txn new file mode 100644 index 0000000000000000000000000000000000000000..2e0db06a6b57e48c77e3c281776e7c8c6e41cf2b Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/82-6e3adb17-3377-45dd-b109-0403e8fc4cf5.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/83-8f8f9de7-4274-48b5-a9c3-8c0f4dfc8bb8.txn b/.lancedb/model1_fixed.lance/_transactions/83-8f8f9de7-4274-48b5-a9c3-8c0f4dfc8bb8.txn new file mode 100644 index 0000000000000000000000000000000000000000..9633887e40af73fb2be11cbcc709b1f517ef8519 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/83-8f8f9de7-4274-48b5-a9c3-8c0f4dfc8bb8.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/84-6478baa4-6285-4d30-81ea-818de0c75f41.txn b/.lancedb/model1_fixed.lance/_transactions/84-6478baa4-6285-4d30-81ea-818de0c75f41.txn new file mode 100644 index 0000000000000000000000000000000000000000..36e89f287d9b155ee94e6d893f64d6ea2a4ad76c Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/84-6478baa4-6285-4d30-81ea-818de0c75f41.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/85-d9a17a3a-bf79-478b-be24-03c8876f2540.txn b/.lancedb/model1_fixed.lance/_transactions/85-d9a17a3a-bf79-478b-be24-03c8876f2540.txn new file mode 100644 index 0000000000000000000000000000000000000000..4b55f16986347cd4bf811dd1dca439445776607d Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/85-d9a17a3a-bf79-478b-be24-03c8876f2540.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/86-77a28939-95b7-46e5-b252-ff84f2317185.txn b/.lancedb/model1_fixed.lance/_transactions/86-77a28939-95b7-46e5-b252-ff84f2317185.txn new file mode 100644 index 0000000000000000000000000000000000000000..b4bd7a24ff1963d7cc7601477a17ed70c0b6cc96 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/86-77a28939-95b7-46e5-b252-ff84f2317185.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/87-079e313f-84cb-4c9e-ad12-54d127733dda.txn b/.lancedb/model1_fixed.lance/_transactions/87-079e313f-84cb-4c9e-ad12-54d127733dda.txn new file mode 100644 index 0000000000000000000000000000000000000000..c91577540a23c6497c69fb4a2727890399c7deb5 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/87-079e313f-84cb-4c9e-ad12-54d127733dda.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/88-58f02408-e3b4-45b1-9811-0cda4bdef531.txn b/.lancedb/model1_fixed.lance/_transactions/88-58f02408-e3b4-45b1-9811-0cda4bdef531.txn new file mode 100644 index 0000000000000000000000000000000000000000..024189a865a625e50f6f8245891b7573430cfd15 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/88-58f02408-e3b4-45b1-9811-0cda4bdef531.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/89-c870205e-a3c5-408e-8204-db63d9684e6a.txn b/.lancedb/model1_fixed.lance/_transactions/89-c870205e-a3c5-408e-8204-db63d9684e6a.txn new file mode 100644 index 0000000000000000000000000000000000000000..614b990a46310310aadac9b01e55fc539051d351 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/89-c870205e-a3c5-408e-8204-db63d9684e6a.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/9-ff712526-71bb-415a-9e41-b8278fca3ef1.txn b/.lancedb/model1_fixed.lance/_transactions/9-ff712526-71bb-415a-9e41-b8278fca3ef1.txn new file mode 100644 index 0000000000000000000000000000000000000000..2b24ea00f12fe3540b743da50cace70d19a21ae9 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/9-ff712526-71bb-415a-9e41-b8278fca3ef1.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/90-eeb9e23d-b574-44b3-98be-2517fc70e4b6.txn b/.lancedb/model1_fixed.lance/_transactions/90-eeb9e23d-b574-44b3-98be-2517fc70e4b6.txn new file mode 100644 index 0000000000000000000000000000000000000000..553d8cd7da831065e5b4be05d872365f4c2fac38 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/90-eeb9e23d-b574-44b3-98be-2517fc70e4b6.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/91-e850cd4a-7c83-48ca-8cf9-099befd5c32b.txn b/.lancedb/model1_fixed.lance/_transactions/91-e850cd4a-7c83-48ca-8cf9-099befd5c32b.txn new file mode 100644 index 0000000000000000000000000000000000000000..caa1c1b058ba31b90ac31f1aa7b139cde93322a4 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/91-e850cd4a-7c83-48ca-8cf9-099befd5c32b.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/92-080464b6-2ac0-4bd4-9964-e51fff290561.txn b/.lancedb/model1_fixed.lance/_transactions/92-080464b6-2ac0-4bd4-9964-e51fff290561.txn new file mode 100644 index 0000000000000000000000000000000000000000..dbbee649888085da7763f88bf57d902e7e5a2b12 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/92-080464b6-2ac0-4bd4-9964-e51fff290561.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/93-ee75bf05-7753-44fc-8d36-7e1a81b11ee2.txn b/.lancedb/model1_fixed.lance/_transactions/93-ee75bf05-7753-44fc-8d36-7e1a81b11ee2.txn new file mode 100644 index 0000000000000000000000000000000000000000..d1d823f4d34a653be420f12a514a85b249a0b979 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/93-ee75bf05-7753-44fc-8d36-7e1a81b11ee2.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/94-684a6305-c0f6-41a4-86de-9a1d03fb388b.txn b/.lancedb/model1_fixed.lance/_transactions/94-684a6305-c0f6-41a4-86de-9a1d03fb388b.txn new file mode 100644 index 0000000000000000000000000000000000000000..14fbb219f18b9be42a95cf337f06337b79e0f3a2 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/94-684a6305-c0f6-41a4-86de-9a1d03fb388b.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/95-a69200b4-18dd-4536-a446-3709b67900ec.txn b/.lancedb/model1_fixed.lance/_transactions/95-a69200b4-18dd-4536-a446-3709b67900ec.txn new file mode 100644 index 0000000000000000000000000000000000000000..14fe91c573a86297782639baef8d43ee78c9c7b9 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/95-a69200b4-18dd-4536-a446-3709b67900ec.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/96-218e9ef4-56c2-4d20-b5ad-56dd98ffd153.txn b/.lancedb/model1_fixed.lance/_transactions/96-218e9ef4-56c2-4d20-b5ad-56dd98ffd153.txn new file mode 100644 index 0000000000000000000000000000000000000000..49dfda20da6fff3bc9e00a1f4d8128154b1639fa Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/96-218e9ef4-56c2-4d20-b5ad-56dd98ffd153.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/97-93556346-a910-465f-b0a2-1ed686d9b661.txn b/.lancedb/model1_fixed.lance/_transactions/97-93556346-a910-465f-b0a2-1ed686d9b661.txn new file mode 100644 index 0000000000000000000000000000000000000000..da97c75aac15fa7334fb5066da0db3396517ae48 Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/97-93556346-a910-465f-b0a2-1ed686d9b661.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/98-df2ece44-a442-43f7-9d61-9ff7d4f1ee37.txn b/.lancedb/model1_fixed.lance/_transactions/98-df2ece44-a442-43f7-9d61-9ff7d4f1ee37.txn new file mode 100644 index 0000000000000000000000000000000000000000..55209376eab91b9ddea94fc0c5db9246a6b94f5a Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/98-df2ece44-a442-43f7-9d61-9ff7d4f1ee37.txn differ diff --git a/.lancedb/model1_fixed.lance/_transactions/99-bfc76eb2-b6c7-4f1a-82bb-e75da991679a.txn b/.lancedb/model1_fixed.lance/_transactions/99-bfc76eb2-b6c7-4f1a-82bb-e75da991679a.txn new file mode 100644 index 0000000000000000000000000000000000000000..aa961d013a34cf08d4b6e8d89703d59b8e260e2c Binary files /dev/null and b/.lancedb/model1_fixed.lance/_transactions/99-bfc76eb2-b6c7-4f1a-82bb-e75da991679a.txn differ diff --git a/.lancedb/model1_fixed.lance/data/0236f563-d18d-4f37-99e7-70818c416ac6.lance b/.lancedb/model1_fixed.lance/data/0236f563-d18d-4f37-99e7-70818c416ac6.lance new file mode 100644 index 0000000000000000000000000000000000000000..9a35c6265972de4e2beb557d803a6aa569af1566 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/0236f563-d18d-4f37-99e7-70818c416ac6.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ea518c0af21c52d338a543f19fbd53c5398a388c9306822fca5baa98d02f2c0a +size 67008 diff --git a/.lancedb/model1_fixed.lance/data/023d07be-aca0-45f3-b5a3-6ab93efe774d.lance b/.lancedb/model1_fixed.lance/data/023d07be-aca0-45f3-b5a3-6ab93efe774d.lance new file mode 100644 index 0000000000000000000000000000000000000000..2aab7ec59520f2008bcbd1cb57c69a3e3215dd29 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/023d07be-aca0-45f3-b5a3-6ab93efe774d.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0ea64bf5545f41b8e5c07a7ed0193ff9bd457cb2a052cc11847bfd44d84de7fd +size 66699 diff --git a/.lancedb/model1_fixed.lance/data/08628c90-269a-4b93-b7d2-0bda22c6e45e.lance b/.lancedb/model1_fixed.lance/data/08628c90-269a-4b93-b7d2-0bda22c6e45e.lance new file mode 100644 index 0000000000000000000000000000000000000000..7123859fa359ad6a7ee8ba6a3f7babcd4805ccea --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/08628c90-269a-4b93-b7d2-0bda22c6e45e.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:44467de17a1fb5e53dbfc338e2f59969f3512a112a73193a52697a721a03f4b8 +size 70445 diff --git a/.lancedb/model1_fixed.lance/data/0aa332a5-d933-4b1e-86d7-fefcd2268b36.lance b/.lancedb/model1_fixed.lance/data/0aa332a5-d933-4b1e-86d7-fefcd2268b36.lance new file mode 100644 index 0000000000000000000000000000000000000000..f2aba0c8f28c957b01c57a79f33a4caa8ae7627f --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/0aa332a5-d933-4b1e-86d7-fefcd2268b36.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:10aad4dc84c3ab418969af972fc63a84a8d3726f2d45f0390bac3ef673800d13 +size 66786 diff --git a/.lancedb/model1_fixed.lance/data/10ea440e-c02e-4040-9cc5-fed8374efa5a.lance b/.lancedb/model1_fixed.lance/data/10ea440e-c02e-4040-9cc5-fed8374efa5a.lance new file mode 100644 index 0000000000000000000000000000000000000000..e83acb795ce21a8ddad1df1df2ea8270d9b2f8b4 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/10ea440e-c02e-4040-9cc5-fed8374efa5a.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6c95ec42f313600bb5d29d3aa253db543e5f1e5cad014f8ab1b20b33c20ea5f9 +size 73283 diff --git a/.lancedb/model1_fixed.lance/data/120a635e-c8d4-4b20-88ac-295387d74662.lance b/.lancedb/model1_fixed.lance/data/120a635e-c8d4-4b20-88ac-295387d74662.lance new file mode 100644 index 0000000000000000000000000000000000000000..f2ae32638cd73677deb6c5b19ca4125a21c84019 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/120a635e-c8d4-4b20-88ac-295387d74662.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8132798ca4b1c9b2766f093139b709c27cf75da164b9705b7b83bdd3cb7bf2f1 +size 71061 diff --git a/.lancedb/model1_fixed.lance/data/143a63e8-a472-49d7-ab9c-258ff82f8dbf.lance b/.lancedb/model1_fixed.lance/data/143a63e8-a472-49d7-ab9c-258ff82f8dbf.lance new file mode 100644 index 0000000000000000000000000000000000000000..09a96685da51c6bb6b0dff96d65bf9ece37ffedf --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/143a63e8-a472-49d7-ab9c-258ff82f8dbf.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3b4c54af071de51de8a14926240fd46529ac2157b24613480943a8894faa88f6 +size 64599 diff --git a/.lancedb/model1_fixed.lance/data/176fedd7-96f4-4f61-b153-d611d681313c.lance b/.lancedb/model1_fixed.lance/data/176fedd7-96f4-4f61-b153-d611d681313c.lance new file mode 100644 index 0000000000000000000000000000000000000000..12c9c7481d417ad25cde4cc5fe2b8fa51ab4ce04 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/176fedd7-96f4-4f61-b153-d611d681313c.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b761710ead08fa40e95bb73253cace0a7c6a986dbc3ba39fd831d6b12deb4952 +size 80634 diff --git a/.lancedb/model1_fixed.lance/data/1936098e-dc85-486c-842b-d736d37b785d.lance b/.lancedb/model1_fixed.lance/data/1936098e-dc85-486c-842b-d736d37b785d.lance new file mode 100644 index 0000000000000000000000000000000000000000..ad198693831a679225b4de944ed8bf9666ebf8b9 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/1936098e-dc85-486c-842b-d736d37b785d.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a49a0d19947f9e0c00acccd5adb8364fd3ca24a70fdf54d53a05d4a19dadcc73 +size 72854 diff --git a/.lancedb/model1_fixed.lance/data/207ab593-3007-4332-95cc-2622f4e7de16.lance b/.lancedb/model1_fixed.lance/data/207ab593-3007-4332-95cc-2622f4e7de16.lance new file mode 100644 index 0000000000000000000000000000000000000000..162ff9557e3c06c8abe752fc2a5e3bf3adc5ef6e --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/207ab593-3007-4332-95cc-2622f4e7de16.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0c85be31b061bbbcb329530bc3015e931add7e4a13190592bbc05b5de01724cb +size 69416 diff --git a/.lancedb/model1_fixed.lance/data/233d8295-49f4-463a-9b87-f52ca6db0fa6.lance b/.lancedb/model1_fixed.lance/data/233d8295-49f4-463a-9b87-f52ca6db0fa6.lance new file mode 100644 index 0000000000000000000000000000000000000000..d52b75242fe0367ac29c41840fcfc793c1aa5d74 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/233d8295-49f4-463a-9b87-f52ca6db0fa6.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e3329f1632de1d3a65922dc49720de15f6e86f338d66e44d10689201fe83d42b +size 75312 diff --git a/.lancedb/model1_fixed.lance/data/24eb51a6-9f19-43a4-bc66-aa5af34aba8b.lance b/.lancedb/model1_fixed.lance/data/24eb51a6-9f19-43a4-bc66-aa5af34aba8b.lance new file mode 100644 index 0000000000000000000000000000000000000000..e40e9a843ff3f1644c9a5d0ba54f2fb2be89fe18 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/24eb51a6-9f19-43a4-bc66-aa5af34aba8b.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b380796b033ceea1a20da63c0866d2a0ca3e370b65a28f5b06c65f1de602980c +size 66395 diff --git a/.lancedb/model1_fixed.lance/data/287c2895-7ca8-4a70-a321-d758c0a66429.lance b/.lancedb/model1_fixed.lance/data/287c2895-7ca8-4a70-a321-d758c0a66429.lance new file mode 100644 index 0000000000000000000000000000000000000000..531d501cf8a5dd78e4857c7a64916a4e0e58c8f2 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/287c2895-7ca8-4a70-a321-d758c0a66429.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bc813885323761e4cb2ee2fec122c420e99d77dda6f9bf94a1b36e425335b0a3 +size 70764 diff --git a/.lancedb/model1_fixed.lance/data/2922cf95-932d-4819-9080-66e8a80f1ec2.lance b/.lancedb/model1_fixed.lance/data/2922cf95-932d-4819-9080-66e8a80f1ec2.lance new file mode 100644 index 0000000000000000000000000000000000000000..b54559690b3052b5f307f516226174e864ccf1f1 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/2922cf95-932d-4819-9080-66e8a80f1ec2.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a6f9c67ea4a548b9570c55f9a9e2e8386ec6a05d4f2a978a661c8a3f82759a27 +size 69983 diff --git a/.lancedb/model1_fixed.lance/data/2951d56b-9f68-43ac-a555-7341d5bc8a7b.lance b/.lancedb/model1_fixed.lance/data/2951d56b-9f68-43ac-a555-7341d5bc8a7b.lance new file mode 100644 index 0000000000000000000000000000000000000000..134d4de38e66e8ec63480cb87b695542e06ad9f7 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/2951d56b-9f68-43ac-a555-7341d5bc8a7b.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3a2eebe41ce14b25818d5a1e7633a5554bdef95ae19580fe148ec62f31cb5079 +size 67102 diff --git a/.lancedb/model1_fixed.lance/data/2ab0a661-7092-4fa6-b40d-dcca2e3dbc62.lance b/.lancedb/model1_fixed.lance/data/2ab0a661-7092-4fa6-b40d-dcca2e3dbc62.lance new file mode 100644 index 0000000000000000000000000000000000000000..913cdfae868625e5ef2da69518426de2525e5053 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/2ab0a661-7092-4fa6-b40d-dcca2e3dbc62.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b23dad2cc3dd443d05daf841a55aa114068c3c42d59196f769c9fb122e4c6239 +size 72162 diff --git a/.lancedb/model1_fixed.lance/data/2b36abb4-2626-42fd-a289-68c0a2fda21b.lance b/.lancedb/model1_fixed.lance/data/2b36abb4-2626-42fd-a289-68c0a2fda21b.lance new file mode 100644 index 0000000000000000000000000000000000000000..1a0afc55a1c513755c501ae10d722dfaab457d55 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/2b36abb4-2626-42fd-a289-68c0a2fda21b.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:55abf9b0845af6496d8439203294769dbd68ec515e8f663b9595815458ed39f7 +size 65274 diff --git a/.lancedb/model1_fixed.lance/data/2c3af81b-0064-40fe-be4a-ad70cc23d6ed.lance b/.lancedb/model1_fixed.lance/data/2c3af81b-0064-40fe-be4a-ad70cc23d6ed.lance new file mode 100644 index 0000000000000000000000000000000000000000..d7012ab0d11d305ed84acf7f6cff7d19f52a1c80 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/2c3af81b-0064-40fe-be4a-ad70cc23d6ed.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cb051c67d6a8b21e2b094688fef6395c78f5363c6c4c53b4e599240425003d42 +size 68270 diff --git a/.lancedb/model1_fixed.lance/data/2e25d17b-39cb-4a94-b4bd-9ef9bea704e1.lance b/.lancedb/model1_fixed.lance/data/2e25d17b-39cb-4a94-b4bd-9ef9bea704e1.lance new file mode 100644 index 0000000000000000000000000000000000000000..f0cebb439c3ec38ac8c7e266134dea3225583b06 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/2e25d17b-39cb-4a94-b4bd-9ef9bea704e1.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:48dd3f45c85751c0e05a50297e9dbf838a65ba35c1e131b5694e65932e514e36 +size 68970 diff --git a/.lancedb/model1_fixed.lance/data/32b4e656-bdcc-4925-a3b5-6fb31420dd71.lance b/.lancedb/model1_fixed.lance/data/32b4e656-bdcc-4925-a3b5-6fb31420dd71.lance new file mode 100644 index 0000000000000000000000000000000000000000..19f9816b696fd0acda2bfba137a453258787a503 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/32b4e656-bdcc-4925-a3b5-6fb31420dd71.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d4cf2965ad2f6c2a7eb86e2e06b5609a2860c3af4a360d1cfb07981e7218beaf +size 69806 diff --git a/.lancedb/model1_fixed.lance/data/33ec7545-1c26-48cb-8c94-a4d627342d66.lance b/.lancedb/model1_fixed.lance/data/33ec7545-1c26-48cb-8c94-a4d627342d66.lance new file mode 100644 index 0000000000000000000000000000000000000000..959876423ad2c2c2f557a4671c9713fe4b164bde --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/33ec7545-1c26-48cb-8c94-a4d627342d66.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3af230d12e8a91008cbaa1a417601b2bf959e0eb5265618188d6f21448c328b9 +size 70836 diff --git a/.lancedb/model1_fixed.lance/data/34a25056-f54a-4d88-9ac1-f13836e89117.lance b/.lancedb/model1_fixed.lance/data/34a25056-f54a-4d88-9ac1-f13836e89117.lance new file mode 100644 index 0000000000000000000000000000000000000000..e9b468a5a14c16d9a484a78fa2d24360ca01f304 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/34a25056-f54a-4d88-9ac1-f13836e89117.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:52f2a4ba64cc49164a0c34fd006ddd0410711d2dc18ba887587dec37f715207d +size 70476 diff --git a/.lancedb/model1_fixed.lance/data/3984cfe8-f50f-4f88-9bf3-52f594d748e6.lance b/.lancedb/model1_fixed.lance/data/3984cfe8-f50f-4f88-9bf3-52f594d748e6.lance new file mode 100644 index 0000000000000000000000000000000000000000..ffc09a5717923ba92283440bc4cce04bd215db13 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/3984cfe8-f50f-4f88-9bf3-52f594d748e6.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:de8ea8a5854751fc738906a98ad7be7619d8346659df848f156d2f229b1d8531 +size 71637 diff --git a/.lancedb/model1_fixed.lance/data/3a370707-ce6d-4057-b447-64720840fad4.lance b/.lancedb/model1_fixed.lance/data/3a370707-ce6d-4057-b447-64720840fad4.lance new file mode 100644 index 0000000000000000000000000000000000000000..aa2cbb8acd2aca02b3240426c423a7c7de8d40fc --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/3a370707-ce6d-4057-b447-64720840fad4.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6430044457bc03948cb82b2b0942f032a18db6e17662cd3aff75f2e813548e47 +size 64961 diff --git a/.lancedb/model1_fixed.lance/data/3c2ea04e-c53b-41ac-a2fc-26556eb25a30.lance b/.lancedb/model1_fixed.lance/data/3c2ea04e-c53b-41ac-a2fc-26556eb25a30.lance new file mode 100644 index 0000000000000000000000000000000000000000..50924fa2bbb4f186e85ea78b626f67850995cf16 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/3c2ea04e-c53b-41ac-a2fc-26556eb25a30.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7b6c867084d6de8cd9f443cfc50071216c7b517e7998570e79a6c12f0133f6b3 +size 69069 diff --git a/.lancedb/model1_fixed.lance/data/3cd7e631-9fe6-4bee-bf7a-c3f85f588ecc.lance b/.lancedb/model1_fixed.lance/data/3cd7e631-9fe6-4bee-bf7a-c3f85f588ecc.lance new file mode 100644 index 0000000000000000000000000000000000000000..aa22d0428fdb172c96071ce2b7a3a0eba4cf4a6a --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/3cd7e631-9fe6-4bee-bf7a-c3f85f588ecc.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:864f19168942ab308d3c3f0a52a688eb401186b61b647b353e76ecd7037d5a50 +size 63982 diff --git a/.lancedb/model1_fixed.lance/data/4052c149-286f-426b-87ee-d65399484fc7.lance b/.lancedb/model1_fixed.lance/data/4052c149-286f-426b-87ee-d65399484fc7.lance new file mode 100644 index 0000000000000000000000000000000000000000..2a5d08029dde36ac47a8f1adcb399c26c262cc66 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/4052c149-286f-426b-87ee-d65399484fc7.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d13f12bac2aba0dadd3a017c7d659e458106cdee26bbce396c6851f99ce2a2af +size 65433 diff --git a/.lancedb/model1_fixed.lance/data/42d1d9af-51bf-437e-9bf2-34f77a7efd97.lance b/.lancedb/model1_fixed.lance/data/42d1d9af-51bf-437e-9bf2-34f77a7efd97.lance new file mode 100644 index 0000000000000000000000000000000000000000..d3e7ce770ec0b2a4c5e3678c576b55a38e4f8f4f --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/42d1d9af-51bf-437e-9bf2-34f77a7efd97.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:53ee90a0aa246d91efd1981ef59ee1d1fc76042f4c339f6dbf6a8d016328006e +size 69001 diff --git a/.lancedb/model1_fixed.lance/data/4502aa2e-7969-4eec-ab55-4ffba0fe5246.lance b/.lancedb/model1_fixed.lance/data/4502aa2e-7969-4eec-ab55-4ffba0fe5246.lance new file mode 100644 index 0000000000000000000000000000000000000000..4bb491af5beed63e6c0ff6fcba2be3630b3737de --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/4502aa2e-7969-4eec-ab55-4ffba0fe5246.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b22e52994db921aa29e54f9b3269957fa37267555d11977aeabe28c444bcc557 +size 65882 diff --git a/.lancedb/model1_fixed.lance/data/461b541d-cc8d-4e4d-9ae6-058ff8a65bb5.lance b/.lancedb/model1_fixed.lance/data/461b541d-cc8d-4e4d-9ae6-058ff8a65bb5.lance new file mode 100644 index 0000000000000000000000000000000000000000..492364164f70833c96df9ceb29b4742eee1df7b7 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/461b541d-cc8d-4e4d-9ae6-058ff8a65bb5.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b3a72a21f06d9fb98d3768d4570104db885ef0c51e3b6aecef12e30e6b6c1762 +size 73413 diff --git a/.lancedb/model1_fixed.lance/data/46557cb7-fa7c-4f56-82fa-169e929bed1f.lance b/.lancedb/model1_fixed.lance/data/46557cb7-fa7c-4f56-82fa-169e929bed1f.lance new file mode 100644 index 0000000000000000000000000000000000000000..f0d1674d4ffce4702f9302063b43a46bb324627b --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/46557cb7-fa7c-4f56-82fa-169e929bed1f.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5ae7b10cccb2320862fbe5e2d56d726f4769cd490c9283a11b944da3f5289bc7 +size 73897 diff --git a/.lancedb/model1_fixed.lance/data/4718b33f-a079-4b03-bced-9a6779f186f3.lance b/.lancedb/model1_fixed.lance/data/4718b33f-a079-4b03-bced-9a6779f186f3.lance new file mode 100644 index 0000000000000000000000000000000000000000..7b29353293ba2708497af40f15d015fc1bb2d7e2 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/4718b33f-a079-4b03-bced-9a6779f186f3.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8c678c08c604b434c887a34c121acd39844430f2ff95c79ee17e00f72c5a91bc +size 69702 diff --git a/.lancedb/model1_fixed.lance/data/4a777bfd-a405-41a1-85bd-a4bac513ec77.lance b/.lancedb/model1_fixed.lance/data/4a777bfd-a405-41a1-85bd-a4bac513ec77.lance new file mode 100644 index 0000000000000000000000000000000000000000..d9c1cae659695270c9a83645478be5ce21d721a6 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/4a777bfd-a405-41a1-85bd-a4bac513ec77.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2380c2d7cff37cb7e6fe22f2189a7fe89e0f2b36697ef35602b8dee82d988518 +size 68401 diff --git a/.lancedb/model1_fixed.lance/data/4bc456af-451e-4e87-af13-9e5f9ea6f3f7.lance b/.lancedb/model1_fixed.lance/data/4bc456af-451e-4e87-af13-9e5f9ea6f3f7.lance new file mode 100644 index 0000000000000000000000000000000000000000..f0eef05e144c7a58c1b151bb19dd83bfafeaf76d --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/4bc456af-451e-4e87-af13-9e5f9ea6f3f7.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:106aecc306ed224c6c152028c400d653a5e08608ac3a78bfce751202c41f73a8 +size 79068 diff --git a/.lancedb/model1_fixed.lance/data/4e9ff796-b0f6-4cf1-98c0-8e0a457c4937.lance b/.lancedb/model1_fixed.lance/data/4e9ff796-b0f6-4cf1-98c0-8e0a457c4937.lance new file mode 100644 index 0000000000000000000000000000000000000000..0519b30eec8cf5e069b73874abe3f92409782a66 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/4e9ff796-b0f6-4cf1-98c0-8e0a457c4937.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1a1b8a16cdf3ecb1f0c5d38552aad4609e752021259e3a9687c1b8d7244245ab +size 74854 diff --git a/.lancedb/model1_fixed.lance/data/50a3ed1a-88a0-4645-b38b-73d05661490b.lance b/.lancedb/model1_fixed.lance/data/50a3ed1a-88a0-4645-b38b-73d05661490b.lance new file mode 100644 index 0000000000000000000000000000000000000000..bb3c1186ea5dd34f5cf6aa1065b799b56fca3790 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/50a3ed1a-88a0-4645-b38b-73d05661490b.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c4f97c94abcd15803e88288e82bc941a322040f141efac0b93b54e8503be714e +size 70547 diff --git a/.lancedb/model1_fixed.lance/data/50c89209-097f-4672-838e-a0f7ca44c2c7.lance b/.lancedb/model1_fixed.lance/data/50c89209-097f-4672-838e-a0f7ca44c2c7.lance new file mode 100644 index 0000000000000000000000000000000000000000..29f651966386c986a67dda27d8519f4f60c81911 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/50c89209-097f-4672-838e-a0f7ca44c2c7.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4c88c53428752f970e9693f47b798567d6867fd05a4f5672f22f6092d38e758 +size 77737 diff --git a/.lancedb/model1_fixed.lance/data/50ce8f14-52c7-492e-93f6-a4e83e2b00eb.lance b/.lancedb/model1_fixed.lance/data/50ce8f14-52c7-492e-93f6-a4e83e2b00eb.lance new file mode 100644 index 0000000000000000000000000000000000000000..8507d393ab4c18414895c9833b7ee5fbfe3ff3de --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/50ce8f14-52c7-492e-93f6-a4e83e2b00eb.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0a2be8760e2712a727b632db5df66bf49c980f97a6365803b88809498e9b2cef +size 68035 diff --git a/.lancedb/model1_fixed.lance/data/5a93ffaa-e9ad-421a-8dc6-bb0ed9fc7775.lance b/.lancedb/model1_fixed.lance/data/5a93ffaa-e9ad-421a-8dc6-bb0ed9fc7775.lance new file mode 100644 index 0000000000000000000000000000000000000000..a8a4755c34b8568eae9e4d3de8c1f22c41147ed1 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/5a93ffaa-e9ad-421a-8dc6-bb0ed9fc7775.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5cfbea7d74c7634cf2731b70a05a27cf3f1084d5da4552180ed148ddb0cc25bf +size 74066 diff --git a/.lancedb/model1_fixed.lance/data/5d464c59-d1e0-460e-bcaa-2b71ae24ea13.lance b/.lancedb/model1_fixed.lance/data/5d464c59-d1e0-460e-bcaa-2b71ae24ea13.lance new file mode 100644 index 0000000000000000000000000000000000000000..ca72d8b823da23c7c3c679977b0a03dda4d3dfee --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/5d464c59-d1e0-460e-bcaa-2b71ae24ea13.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:49ae2084ea9ca7e69dcc5b22da14e4d71d12fe4bf8f88e3eb2a1e2a3168ed232 +size 79800 diff --git a/.lancedb/model1_fixed.lance/data/5d62ce2b-8ff3-4b53-a465-25f4d5624277.lance b/.lancedb/model1_fixed.lance/data/5d62ce2b-8ff3-4b53-a465-25f4d5624277.lance new file mode 100644 index 0000000000000000000000000000000000000000..32e886c854c66967263b6bef54fd9a7539073aa6 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/5d62ce2b-8ff3-4b53-a465-25f4d5624277.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:35486826e8cd2bb1b6a7baaa7772321e971265d64d76067ce414e218546942e4 +size 72547 diff --git a/.lancedb/model1_fixed.lance/data/5efd598d-f6d7-4cec-9e87-d2e781e10c8f.lance b/.lancedb/model1_fixed.lance/data/5efd598d-f6d7-4cec-9e87-d2e781e10c8f.lance new file mode 100644 index 0000000000000000000000000000000000000000..1ca58f80740775e95b0a94c01220954cca5a12ee --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/5efd598d-f6d7-4cec-9e87-d2e781e10c8f.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:622cd836faed637e9fb7227a88ad1804272a6fbcf05fd1c85835f9d0fc40d805 +size 71493 diff --git a/.lancedb/model1_fixed.lance/data/60f4a9a9-795d-4fac-9639-756c0d809502.lance b/.lancedb/model1_fixed.lance/data/60f4a9a9-795d-4fac-9639-756c0d809502.lance new file mode 100644 index 0000000000000000000000000000000000000000..66a1d5639480c07d52149ad419e15351c340a7df --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/60f4a9a9-795d-4fac-9639-756c0d809502.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cce55aeb0debb040f76ef8cf33f58a937b08a3fc6836589300e3c82ee65255ec +size 67717 diff --git a/.lancedb/model1_fixed.lance/data/619cb327-01b7-4bef-9010-3b07f3e55070.lance b/.lancedb/model1_fixed.lance/data/619cb327-01b7-4bef-9010-3b07f3e55070.lance new file mode 100644 index 0000000000000000000000000000000000000000..4405713f2cd6e8aac830ccf4c41ed3c6479cb3d3 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/619cb327-01b7-4bef-9010-3b07f3e55070.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:efabacf394b67b3e2755f24f448b5472b3858156d2a1e2a818c04f824a275d69 +size 75657 diff --git a/.lancedb/model1_fixed.lance/data/649e391e-3f50-4260-b139-05cb7f9f5c2c.lance b/.lancedb/model1_fixed.lance/data/649e391e-3f50-4260-b139-05cb7f9f5c2c.lance new file mode 100644 index 0000000000000000000000000000000000000000..36362e9854f6eae1ff5b30b4a47f99dc7105f6fb --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/649e391e-3f50-4260-b139-05cb7f9f5c2c.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:12f1b18924e72b910a5b3b42dea6ca913d8a10b20f888d30cc59dd8eea7bcdca +size 66961 diff --git a/.lancedb/model1_fixed.lance/data/67204198-39e5-4a38-b955-6bc059b1dc3e.lance b/.lancedb/model1_fixed.lance/data/67204198-39e5-4a38-b955-6bc059b1dc3e.lance new file mode 100644 index 0000000000000000000000000000000000000000..6bac4e63bad23d486b227aae5ef6e774c2e02f7f --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/67204198-39e5-4a38-b955-6bc059b1dc3e.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c71573ede83ac577f85c6cc18c5d0882c6984a9ccb1d435e5b5526cc66bae47d +size 75255 diff --git a/.lancedb/model1_fixed.lance/data/677919af-5e0f-43f8-b961-5ff54dc8693a.lance b/.lancedb/model1_fixed.lance/data/677919af-5e0f-43f8-b961-5ff54dc8693a.lance new file mode 100644 index 0000000000000000000000000000000000000000..3fd43788e7c91a701f36cfddbd8b877eba0bddf8 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/677919af-5e0f-43f8-b961-5ff54dc8693a.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:80e9d9c9d321261127d025ea2df86f64606293dc8de8f17529f34a74200079e3 +size 70290 diff --git a/.lancedb/model1_fixed.lance/data/6ab209be-5ced-43b0-87a7-0191b90d2371.lance b/.lancedb/model1_fixed.lance/data/6ab209be-5ced-43b0-87a7-0191b90d2371.lance new file mode 100644 index 0000000000000000000000000000000000000000..abe9e182b7c4842a3998f515915afb373daf6520 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/6ab209be-5ced-43b0-87a7-0191b90d2371.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8c6e0dc68ef12c9857690a672255240a7a7317b3bf450a00656ad002da9427ea +size 83983 diff --git a/.lancedb/model1_fixed.lance/data/6b3ae8f2-4334-41b5-93e2-b8ff85b1c27b.lance b/.lancedb/model1_fixed.lance/data/6b3ae8f2-4334-41b5-93e2-b8ff85b1c27b.lance new file mode 100644 index 0000000000000000000000000000000000000000..4856f5b4c44c27c2ef30bc4d3bf67ae6c60d310d --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/6b3ae8f2-4334-41b5-93e2-b8ff85b1c27b.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cf395c888c60818dd0e29baedd7d63dcf56ad327321e6188bad43ec53fa139b3 +size 72092 diff --git a/.lancedb/model1_fixed.lance/data/6f30dd78-2c78-4281-8f87-4dd7e294d548.lance b/.lancedb/model1_fixed.lance/data/6f30dd78-2c78-4281-8f87-4dd7e294d548.lance new file mode 100644 index 0000000000000000000000000000000000000000..45042ed8f7aa65635d2dd5c5e75246afe874acae --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/6f30dd78-2c78-4281-8f87-4dd7e294d548.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ab5567b8f8a45271241afbf93e1e31e425c8a52ecaa72f18e6176faf847701c4 +size 76108 diff --git a/.lancedb/model1_fixed.lance/data/71a26789-a082-4562-9244-7715aede643d.lance b/.lancedb/model1_fixed.lance/data/71a26789-a082-4562-9244-7715aede643d.lance new file mode 100644 index 0000000000000000000000000000000000000000..263f11fc51cd501a9e7098f79c16a0098e178161 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/71a26789-a082-4562-9244-7715aede643d.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6ff7c62a827aa75a64f88bcecdfe291a82e11b6c2fc423e011e2da0f4c48fcea +size 73077 diff --git a/.lancedb/model1_fixed.lance/data/71cb81cc-73c2-4dca-aff1-5830ac441d80.lance b/.lancedb/model1_fixed.lance/data/71cb81cc-73c2-4dca-aff1-5830ac441d80.lance new file mode 100644 index 0000000000000000000000000000000000000000..a30cb8f86a4c9e69295a2499347e50dccc3a2a5c --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/71cb81cc-73c2-4dca-aff1-5830ac441d80.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a060e172a85f8b497221d9c74aa66424045b9f988da22a60c2c4e8130b193213 +size 70526 diff --git a/.lancedb/model1_fixed.lance/data/732b8bb1-f2fc-42b4-b3d1-3a830cc672bc.lance b/.lancedb/model1_fixed.lance/data/732b8bb1-f2fc-42b4-b3d1-3a830cc672bc.lance new file mode 100644 index 0000000000000000000000000000000000000000..59b2cca3cb07735939fde143ea5808a4ebd16a10 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/732b8bb1-f2fc-42b4-b3d1-3a830cc672bc.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cc4e65ff4dbf5404db807310f76007bb28274352733b76b703c951a1ccdb01f1 +size 73635 diff --git a/.lancedb/model1_fixed.lance/data/793c9b4f-803a-4da7-8389-f6dd29282a1f.lance b/.lancedb/model1_fixed.lance/data/793c9b4f-803a-4da7-8389-f6dd29282a1f.lance new file mode 100644 index 0000000000000000000000000000000000000000..f9df5fecc8d137c28ea07d6da29bd4bcc0ba8b84 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/793c9b4f-803a-4da7-8389-f6dd29282a1f.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:65306910d23a32d197843f32b94b33d13e5914cbe21ba09a079de820d9af8aec +size 76183 diff --git a/.lancedb/model1_fixed.lance/data/7eb5754c-b13d-49fc-9b44-7a1e23bdf273.lance b/.lancedb/model1_fixed.lance/data/7eb5754c-b13d-49fc-9b44-7a1e23bdf273.lance new file mode 100644 index 0000000000000000000000000000000000000000..1623f82ad88c95a602435895bb99bbcf1afd994b --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/7eb5754c-b13d-49fc-9b44-7a1e23bdf273.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fc82192c4be50c838534fa68ab8dde35b03105b21e5d5b27a7e0be07193fc1d2 +size 75067 diff --git a/.lancedb/model1_fixed.lance/data/7f29b1b7-264e-4ade-86cd-b6258a004592.lance b/.lancedb/model1_fixed.lance/data/7f29b1b7-264e-4ade-86cd-b6258a004592.lance new file mode 100644 index 0000000000000000000000000000000000000000..abf65791fa7d95de675d8e66c6f7201b10562979 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/7f29b1b7-264e-4ade-86cd-b6258a004592.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:68d332b7ac05895f2401ebe472645a8369565f505e93c104ec39805510548ae5 +size 73895 diff --git a/.lancedb/model1_fixed.lance/data/802a9bf2-8cbb-4a94-9a4f-8d1a1f6a1c63.lance b/.lancedb/model1_fixed.lance/data/802a9bf2-8cbb-4a94-9a4f-8d1a1f6a1c63.lance new file mode 100644 index 0000000000000000000000000000000000000000..eb13ee72d7b0c30a1d2d30196541914deeb202d7 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/802a9bf2-8cbb-4a94-9a4f-8d1a1f6a1c63.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e3dcde3b96eee29bc60fccf6df51ff97bfec394f272d94e72031d8954dacff02 +size 71535 diff --git a/.lancedb/model1_fixed.lance/data/80a302b4-22aa-494c-97eb-3ae75f571ee7.lance b/.lancedb/model1_fixed.lance/data/80a302b4-22aa-494c-97eb-3ae75f571ee7.lance new file mode 100644 index 0000000000000000000000000000000000000000..38371d58477bdcd3697113758663d8a9bc181c69 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/80a302b4-22aa-494c-97eb-3ae75f571ee7.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:52afb1de4686e99e1ef9a2d83f147ad5cea0e5b53c38e98214fa3c27424875f5 +size 75369 diff --git a/.lancedb/model1_fixed.lance/data/83b3717e-1ba4-4968-9aa4-d657304432c6.lance b/.lancedb/model1_fixed.lance/data/83b3717e-1ba4-4968-9aa4-d657304432c6.lance new file mode 100644 index 0000000000000000000000000000000000000000..6737bc7bbf442a81ec09c84569e8d86b81b42ca9 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/83b3717e-1ba4-4968-9aa4-d657304432c6.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fb688e1c33094c6c1608524520a68c8da89710ac65277d72d673893664a869d4 +size 69441 diff --git a/.lancedb/model1_fixed.lance/data/843372d8-d5ce-4289-96d6-c8e8501ab567.lance b/.lancedb/model1_fixed.lance/data/843372d8-d5ce-4289-96d6-c8e8501ab567.lance new file mode 100644 index 0000000000000000000000000000000000000000..9e1f0b29167301c90acce43e69b8737dda11a91b --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/843372d8-d5ce-4289-96d6-c8e8501ab567.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:961b739b93338f67d742ed5ed4f6e9b28a9d9221aafd64c9dc1ec1a70041d0f0 +size 69992 diff --git a/.lancedb/model1_fixed.lance/data/8849f964-a048-4605-9d14-d3fc94ec9fb7.lance b/.lancedb/model1_fixed.lance/data/8849f964-a048-4605-9d14-d3fc94ec9fb7.lance new file mode 100644 index 0000000000000000000000000000000000000000..6eaefafcd4a8a245a3d2958e757749d42c485e2d --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/8849f964-a048-4605-9d14-d3fc94ec9fb7.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d35be1e5c8927d8515fb0bbea68662c7a870752947a2b8f32da90a254f3522e5 +size 68984 diff --git a/.lancedb/model1_fixed.lance/data/889f59dd-7d72-49f5-8314-693aa0e8d220.lance b/.lancedb/model1_fixed.lance/data/889f59dd-7d72-49f5-8314-693aa0e8d220.lance new file mode 100644 index 0000000000000000000000000000000000000000..bb76aa37f2649b59698e97bafb91ea26afd338b9 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/889f59dd-7d72-49f5-8314-693aa0e8d220.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c2d096ca34701a73bdaaed30533b3adf57f6d8025cd61fc19223eb03698f6e47 +size 71592 diff --git a/.lancedb/model1_fixed.lance/data/8ecfe69f-241f-4d04-920c-b9745febace4.lance b/.lancedb/model1_fixed.lance/data/8ecfe69f-241f-4d04-920c-b9745febace4.lance new file mode 100644 index 0000000000000000000000000000000000000000..090e7a923634c16e96fc6748c34fedefb5f495f6 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/8ecfe69f-241f-4d04-920c-b9745febace4.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:eb748fae9a23156890a32e9163a09856d6d3448269f3a78d90c6de54383ba951 +size 72117 diff --git a/.lancedb/model1_fixed.lance/data/9010a388-d95f-4407-96e6-10fb14bfc9a9.lance b/.lancedb/model1_fixed.lance/data/9010a388-d95f-4407-96e6-10fb14bfc9a9.lance new file mode 100644 index 0000000000000000000000000000000000000000..e30ee5690aff996a853d12ac135a9c4aa5d52d84 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/9010a388-d95f-4407-96e6-10fb14bfc9a9.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:15dc98df88914a741fdb37c20e092247d16d606faeaf53c982aecfc8d9159287 +size 67110 diff --git a/.lancedb/model1_fixed.lance/data/91490928-6f3d-400a-8b7d-b3387c7d35e0.lance b/.lancedb/model1_fixed.lance/data/91490928-6f3d-400a-8b7d-b3387c7d35e0.lance new file mode 100644 index 0000000000000000000000000000000000000000..36460c8188d7f2217fc231241ff1b33b693a5f65 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/91490928-6f3d-400a-8b7d-b3387c7d35e0.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f6cc4589811a000930b44af96a0ec5b275ef8545a521fbe8b93936da56dd0c09 +size 68353 diff --git a/.lancedb/model1_fixed.lance/data/91add2eb-85c3-4ee7-8410-265f625e022d.lance b/.lancedb/model1_fixed.lance/data/91add2eb-85c3-4ee7-8410-265f625e022d.lance new file mode 100644 index 0000000000000000000000000000000000000000..b338b3e1438f603a23629ad1e82e60e307f775a0 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/91add2eb-85c3-4ee7-8410-265f625e022d.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:178b5e47378893f047347a54d353109192df57d39f445b79a027c4a1025c91d6 +size 73498 diff --git a/.lancedb/model1_fixed.lance/data/9a15c96d-226d-44db-b1b1-7e75026917e7.lance b/.lancedb/model1_fixed.lance/data/9a15c96d-226d-44db-b1b1-7e75026917e7.lance new file mode 100644 index 0000000000000000000000000000000000000000..cfefee94030a4f29aeefbb6a97eaa52eed7794ce --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/9a15c96d-226d-44db-b1b1-7e75026917e7.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5073485f505aac6f90d117405430330986fe1d075fb89e1d806a63f6fe986b45 +size 68694 diff --git a/.lancedb/model1_fixed.lance/data/9a6a4c70-a1b9-4ba9-8cb3-62b23ffe9d33.lance b/.lancedb/model1_fixed.lance/data/9a6a4c70-a1b9-4ba9-8cb3-62b23ffe9d33.lance new file mode 100644 index 0000000000000000000000000000000000000000..98bd30065d48aa2a778df3162f9a478a71a81f05 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/9a6a4c70-a1b9-4ba9-8cb3-62b23ffe9d33.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2625cfe67edd6de9c8150a5df0558d5548d70649a5956c0f73918e46abb031e8 +size 69892 diff --git a/.lancedb/model1_fixed.lance/data/9b0a8b73-29b9-4e65-ad33-079ce73bc29e.lance b/.lancedb/model1_fixed.lance/data/9b0a8b73-29b9-4e65-ad33-079ce73bc29e.lance new file mode 100644 index 0000000000000000000000000000000000000000..053ec272c45168c573d1d027c2806fe0b6ecc9e0 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/9b0a8b73-29b9-4e65-ad33-079ce73bc29e.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:17200d645987c03600e3c660296f4ec502ae8b4e30b42a7a2e0f4bcba5f865b6 +size 68204 diff --git a/.lancedb/model1_fixed.lance/data/9ce75d02-c33c-4731-a90d-fb6e07ffe56f.lance b/.lancedb/model1_fixed.lance/data/9ce75d02-c33c-4731-a90d-fb6e07ffe56f.lance new file mode 100644 index 0000000000000000000000000000000000000000..821d4e6e6b65a4ed45828f9ef4e83bbee0dde654 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/9ce75d02-c33c-4731-a90d-fb6e07ffe56f.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a9e6f6415a599adea32ea7d31c4077dc3956659f0cb7b2acc5b2ceccafcde07b +size 67993 diff --git a/.lancedb/model1_fixed.lance/data/a0408e63-6075-4e78-847c-05a5c76c19d0.lance b/.lancedb/model1_fixed.lance/data/a0408e63-6075-4e78-847c-05a5c76c19d0.lance new file mode 100644 index 0000000000000000000000000000000000000000..55e85ce1a770f5e2b24436f156047d1f0e2eb76e --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/a0408e63-6075-4e78-847c-05a5c76c19d0.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c1496690757265fe20c7a95074c5214fec59c200fda1b86c2edb1dd34dea5cfc +size 74998 diff --git a/.lancedb/model1_fixed.lance/data/a1171de3-c776-4d74-b10c-a4161a9c3781.lance b/.lancedb/model1_fixed.lance/data/a1171de3-c776-4d74-b10c-a4161a9c3781.lance new file mode 100644 index 0000000000000000000000000000000000000000..7f6983ba75960047b39766da743528105673d9ad --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/a1171de3-c776-4d74-b10c-a4161a9c3781.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5bf4be7505c46ce83d37761fa58b5abd8e06038b5bc27897a67c21d12202e009 +size 67805 diff --git a/.lancedb/model1_fixed.lance/data/a1ad99c8-41bc-42d9-b65b-9f210b91a8d5.lance b/.lancedb/model1_fixed.lance/data/a1ad99c8-41bc-42d9-b65b-9f210b91a8d5.lance new file mode 100644 index 0000000000000000000000000000000000000000..0ae529150531f03111c35edcfcf0297e4b107898 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/a1ad99c8-41bc-42d9-b65b-9f210b91a8d5.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e438602e0240aa4f8f47161d2ebf1fc05dfee44b29dab4303a8fbaf478895d23 +size 17631 diff --git a/.lancedb/model1_fixed.lance/data/a6b1f8b5-fbbf-41be-bbb4-bcc8c7081000.lance b/.lancedb/model1_fixed.lance/data/a6b1f8b5-fbbf-41be-bbb4-bcc8c7081000.lance new file mode 100644 index 0000000000000000000000000000000000000000..b9899b1312af8c9a19b299efa90e32695743a1c0 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/a6b1f8b5-fbbf-41be-bbb4-bcc8c7081000.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3969cdfb9e3a159e9d55eefef881753944fd4f31d7ade4254259d438ba5bf2a1 +size 67099 diff --git a/.lancedb/model1_fixed.lance/data/a6fb4d2e-d476-4cc2-825b-be8f78489b82.lance b/.lancedb/model1_fixed.lance/data/a6fb4d2e-d476-4cc2-825b-be8f78489b82.lance new file mode 100644 index 0000000000000000000000000000000000000000..15e05dd32b15d5c0f7283b13b1c22d95ecc535e1 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/a6fb4d2e-d476-4cc2-825b-be8f78489b82.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:996a19efdefc115311bffad28f1f758a4d88113c6863c0f44fb39edb0c7b584d +size 70719 diff --git a/.lancedb/model1_fixed.lance/data/a8508f12-bc8d-4303-b6f7-c017db432b4a.lance b/.lancedb/model1_fixed.lance/data/a8508f12-bc8d-4303-b6f7-c017db432b4a.lance new file mode 100644 index 0000000000000000000000000000000000000000..0f48d4bc7c9eba48086b0293ddd8911bc9215e71 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/a8508f12-bc8d-4303-b6f7-c017db432b4a.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b8324099909dc6480c81388114d7f42415dd91b67b45a110d349dce03ace9f6b +size 69380 diff --git a/.lancedb/model1_fixed.lance/data/aa446c9d-7b26-46b8-bde4-028110005708.lance b/.lancedb/model1_fixed.lance/data/aa446c9d-7b26-46b8-bde4-028110005708.lance new file mode 100644 index 0000000000000000000000000000000000000000..39b3f02abfdcc991db421d10c0d24d6d01d3dabc --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/aa446c9d-7b26-46b8-bde4-028110005708.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:30920402e5f5fcff6fa17b924ce4712f542bb4bf3c95672b56a2894ea5ec9adb +size 68911 diff --git a/.lancedb/model1_fixed.lance/data/aa692b9f-3c3a-471e-b35f-537c6413479b.lance b/.lancedb/model1_fixed.lance/data/aa692b9f-3c3a-471e-b35f-537c6413479b.lance new file mode 100644 index 0000000000000000000000000000000000000000..49ea11872491c9baf9b2828b32a9590bcb9ce17b --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/aa692b9f-3c3a-471e-b35f-537c6413479b.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:78c388b8e649755d5e863f7de57fe723c76d0dbbc24ad2fde5861d303d9ab4ca +size 65483 diff --git a/.lancedb/model1_fixed.lance/data/ac65019b-5f59-4065-a807-ee5a7b5b9482.lance b/.lancedb/model1_fixed.lance/data/ac65019b-5f59-4065-a807-ee5a7b5b9482.lance new file mode 100644 index 0000000000000000000000000000000000000000..3e8721564560927446bd6ed605c147443289b2f2 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/ac65019b-5f59-4065-a807-ee5a7b5b9482.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cc09ab64e3a280ac07e4708f23e8c9d87218decc21f21dbeacbfd59d6f9323cb +size 71281 diff --git a/.lancedb/model1_fixed.lance/data/afab1856-a576-4659-b911-e4542e60d171.lance b/.lancedb/model1_fixed.lance/data/afab1856-a576-4659-b911-e4542e60d171.lance new file mode 100644 index 0000000000000000000000000000000000000000..71637432920d5057f62bdcd90d5fbed1706bfa67 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/afab1856-a576-4659-b911-e4542e60d171.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e5670bf8ec91bd1b1f23d6d9687993dc8e4f430d170af8526e88f74eff35ef6d +size 68000 diff --git a/.lancedb/model1_fixed.lance/data/b04f96d1-2b9b-4b5e-b71b-d32f4768f7b3.lance b/.lancedb/model1_fixed.lance/data/b04f96d1-2b9b-4b5e-b71b-d32f4768f7b3.lance new file mode 100644 index 0000000000000000000000000000000000000000..2b87f662b72b5ddeace207cd26857fa47ee6f525 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/b04f96d1-2b9b-4b5e-b71b-d32f4768f7b3.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2821860ba111b35e952982cc841cbedb2fb6b9c083256ebb615250fcb542ceac +size 66090 diff --git a/.lancedb/model1_fixed.lance/data/b2cad6e2-1eb1-42e5-abeb-8eac09908e8e.lance b/.lancedb/model1_fixed.lance/data/b2cad6e2-1eb1-42e5-abeb-8eac09908e8e.lance new file mode 100644 index 0000000000000000000000000000000000000000..e55433c62e669796fd50d6764b329dbd1d95253e --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/b2cad6e2-1eb1-42e5-abeb-8eac09908e8e.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:28da3572b6699c1f289eb78dc40855bcb1f498019d2caaba16f697de7a70abec +size 71086 diff --git a/.lancedb/model1_fixed.lance/data/b48e6035-f932-4304-a18c-872644202cb3.lance b/.lancedb/model1_fixed.lance/data/b48e6035-f932-4304-a18c-872644202cb3.lance new file mode 100644 index 0000000000000000000000000000000000000000..cd8610ec7fa00ce4db38efc58167eaac9a27d80f --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/b48e6035-f932-4304-a18c-872644202cb3.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:350963b5eb4561111294bb9cc81d997d4271f5db12f32b2cdd22a9155c3f2840 +size 74313 diff --git a/.lancedb/model1_fixed.lance/data/b4db39b7-3f79-402a-a305-902b1c742ce2.lance b/.lancedb/model1_fixed.lance/data/b4db39b7-3f79-402a-a305-902b1c742ce2.lance new file mode 100644 index 0000000000000000000000000000000000000000..e8922b651c70484e425bdadc8af71161cbb70490 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/b4db39b7-3f79-402a-a305-902b1c742ce2.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e01c4bed976a42cdf0e672ba2e760193437c6e9f839ddbf61ec3466f0c347e98 +size 70699 diff --git a/.lancedb/model1_fixed.lance/data/b5ab4462-3c2b-49bb-89ea-e178ef061fcf.lance b/.lancedb/model1_fixed.lance/data/b5ab4462-3c2b-49bb-89ea-e178ef061fcf.lance new file mode 100644 index 0000000000000000000000000000000000000000..2f414ed80db25c87570587a5a9c90e68e50b6420 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/b5ab4462-3c2b-49bb-89ea-e178ef061fcf.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9c707c24859e6e5961372b02940c4bbfec6b34edd6814e242765a4b01fa112a1 +size 75644 diff --git a/.lancedb/model1_fixed.lance/data/b9956365-9b56-4568-96d0-7e9f878e0be8.lance b/.lancedb/model1_fixed.lance/data/b9956365-9b56-4568-96d0-7e9f878e0be8.lance new file mode 100644 index 0000000000000000000000000000000000000000..b414cdeed32b8bd0dd70c116c05a95e0824f4c5b --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/b9956365-9b56-4568-96d0-7e9f878e0be8.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aee53234317db238fe2c931c031757df405065eefc1347d85ce01b3863850e5f +size 65466 diff --git a/.lancedb/model1_fixed.lance/data/bc6003bb-bb71-461f-a78a-01b61b4dbd72.lance b/.lancedb/model1_fixed.lance/data/bc6003bb-bb71-461f-a78a-01b61b4dbd72.lance new file mode 100644 index 0000000000000000000000000000000000000000..43ff5678cd3f6d188b346c46fd85b7dbf60f9265 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/bc6003bb-bb71-461f-a78a-01b61b4dbd72.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ee08ba90f847b07549fb07f25425c59c91b090d38484141f01a55805dd5a5fa1 +size 75408 diff --git a/.lancedb/model1_fixed.lance/data/bff672ed-f219-41cb-9564-4b99e756975f.lance b/.lancedb/model1_fixed.lance/data/bff672ed-f219-41cb-9564-4b99e756975f.lance new file mode 100644 index 0000000000000000000000000000000000000000..e8cc7caaab156f39de4670bc4225cf2743bdc165 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/bff672ed-f219-41cb-9564-4b99e756975f.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:289cc87120dbb64f82f5c3046b6f79af50df702690ee52d34a45c0e51f35ffef +size 67979 diff --git a/.lancedb/model1_fixed.lance/data/c3350a29-d0e1-41bb-acaa-5524aa363d69.lance b/.lancedb/model1_fixed.lance/data/c3350a29-d0e1-41bb-acaa-5524aa363d69.lance new file mode 100644 index 0000000000000000000000000000000000000000..567d7d63d9a26b5d67c99f0744f990a95cb46ab9 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/c3350a29-d0e1-41bb-acaa-5524aa363d69.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:315f2b0d4cdc03a5e224ee76c228a52942a49c0446bde6ceb032f59000a4f2e5 +size 71507 diff --git a/.lancedb/model1_fixed.lance/data/c34fe883-e62a-4a93-bd4f-1b6a7b854318.lance b/.lancedb/model1_fixed.lance/data/c34fe883-e62a-4a93-bd4f-1b6a7b854318.lance new file mode 100644 index 0000000000000000000000000000000000000000..7901aaa94cd743bee00589e8e8e65821d6829580 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/c34fe883-e62a-4a93-bd4f-1b6a7b854318.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ef5de7fc64de19ce59e7afd4b8360fd0eafaba6ec9c6efd3a647a099fb67ccd1 +size 69862 diff --git a/.lancedb/model1_fixed.lance/data/c4781648-387f-4618-b4e8-d8fb379276e0.lance b/.lancedb/model1_fixed.lance/data/c4781648-387f-4618-b4e8-d8fb379276e0.lance new file mode 100644 index 0000000000000000000000000000000000000000..e5ab978a889874017402cb163300e40fc7147790 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/c4781648-387f-4618-b4e8-d8fb379276e0.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d5ec00b4b76023e1acb919b072b9dda35bb3f192088bd9fe64c3efaa4fc9446d +size 71610 diff --git a/.lancedb/model1_fixed.lance/data/c654add8-49fc-495b-b509-92c6fa6f339f.lance b/.lancedb/model1_fixed.lance/data/c654add8-49fc-495b-b509-92c6fa6f339f.lance new file mode 100644 index 0000000000000000000000000000000000000000..0388f6c32e99446eb66d5357c288ee98e8b44d6e --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/c654add8-49fc-495b-b509-92c6fa6f339f.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3002f58972fa5ea8cb9cf1cc04727970f7568483632d35829dd4592277f49424 +size 60942 diff --git a/.lancedb/model1_fixed.lance/data/c71d56c6-d004-4295-b13f-dc89afded639.lance b/.lancedb/model1_fixed.lance/data/c71d56c6-d004-4295-b13f-dc89afded639.lance new file mode 100644 index 0000000000000000000000000000000000000000..697022d5e7e2679a3bc2526183918e0224574858 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/c71d56c6-d004-4295-b13f-dc89afded639.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f5858a7179a6055df34e144cb90cbd0a1a25ab17bc8d5729afa70f7f7d0975a3 +size 73240 diff --git a/.lancedb/model1_fixed.lance/data/c809f477-7d70-4b82-b9ed-2bff9cf9a8a5.lance b/.lancedb/model1_fixed.lance/data/c809f477-7d70-4b82-b9ed-2bff9cf9a8a5.lance new file mode 100644 index 0000000000000000000000000000000000000000..477f2fb4b489ae3afc1f02c769689a50a4bec18f --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/c809f477-7d70-4b82-b9ed-2bff9cf9a8a5.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c6f3f967c77d08f1944353fa7660b120b809bce94c2c7946dbc9ca6083f5f451 +size 68510 diff --git a/.lancedb/model1_fixed.lance/data/c8e26cce-385a-484b-9bbd-27e4f930f376.lance b/.lancedb/model1_fixed.lance/data/c8e26cce-385a-484b-9bbd-27e4f930f376.lance new file mode 100644 index 0000000000000000000000000000000000000000..4da14c3f28106c81b89a7d2d8b5255833cd2861e --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/c8e26cce-385a-484b-9bbd-27e4f930f376.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4fa9c362701737471acd7d45b5a1d293e98ec89ba9f3ad725abd48d8e1565b8 +size 68721 diff --git a/.lancedb/model1_fixed.lance/data/c9c1ed88-f2d7-4749-8867-7d057c159055.lance b/.lancedb/model1_fixed.lance/data/c9c1ed88-f2d7-4749-8867-7d057c159055.lance new file mode 100644 index 0000000000000000000000000000000000000000..b9fecb0e5e6cccaf4d12540ff482b6e951f69c6a --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/c9c1ed88-f2d7-4749-8867-7d057c159055.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d9d9864f030b424f7bef169f3d11151ce250f78661edcb78f1b7a0954da57ab3 +size 66874 diff --git a/.lancedb/model1_fixed.lance/data/caeaa499-30c1-4fb6-952a-afb2fb04bc1d.lance b/.lancedb/model1_fixed.lance/data/caeaa499-30c1-4fb6-952a-afb2fb04bc1d.lance new file mode 100644 index 0000000000000000000000000000000000000000..d089688bd9b0d077f305329dee226d762b765599 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/caeaa499-30c1-4fb6-952a-afb2fb04bc1d.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bda63a3b23c56ba8d73c1a7de59fe947da6d2671c7ed8d6da45a44eaa42e5679 +size 66011 diff --git a/.lancedb/model1_fixed.lance/data/cb8ed26d-637f-4a5b-8992-2d08da15a89d.lance b/.lancedb/model1_fixed.lance/data/cb8ed26d-637f-4a5b-8992-2d08da15a89d.lance new file mode 100644 index 0000000000000000000000000000000000000000..2b86c99de23564be34f0956ccf037132e3947a06 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/cb8ed26d-637f-4a5b-8992-2d08da15a89d.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:460ea6bd833c4ebfb74480c012725ef0ec20bccbb22877f343bacbad94b2315b +size 69710 diff --git a/.lancedb/model1_fixed.lance/data/ccf5a3f9-5154-4bc4-b20c-b45689d210be.lance b/.lancedb/model1_fixed.lance/data/ccf5a3f9-5154-4bc4-b20c-b45689d210be.lance new file mode 100644 index 0000000000000000000000000000000000000000..c2c46686aae15113ee928c02f64c6ef567e8fbcb --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/ccf5a3f9-5154-4bc4-b20c-b45689d210be.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:668172380ba2cbb9890a0fed1f656bd2f13002b45147a015539afc04a7e36158 +size 72013 diff --git a/.lancedb/model1_fixed.lance/data/cf0ca7bb-8158-4fc5-931d-1c7b802ab3c1.lance b/.lancedb/model1_fixed.lance/data/cf0ca7bb-8158-4fc5-931d-1c7b802ab3c1.lance new file mode 100644 index 0000000000000000000000000000000000000000..47bfbb10f456e7ea417a0f3619ca27599566786b --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/cf0ca7bb-8158-4fc5-931d-1c7b802ab3c1.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89ce880b4ef0762d9914c32dcebea3c22666d36163b2494b00ce3983a88139fb +size 68109 diff --git a/.lancedb/model1_fixed.lance/data/cf4ffa50-a71b-4602-a140-12acabda491b.lance b/.lancedb/model1_fixed.lance/data/cf4ffa50-a71b-4602-a140-12acabda491b.lance new file mode 100644 index 0000000000000000000000000000000000000000..6bee5d37f7140e5abd328722663aa2fc13700960 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/cf4ffa50-a71b-4602-a140-12acabda491b.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c98dbea34e82094727b6c8b43d28e3cb606d8987edeef3ff6c23a667b25814e8 +size 78692 diff --git a/.lancedb/model1_fixed.lance/data/cfd970ca-cf95-4781-8a33-894028be98a0.lance b/.lancedb/model1_fixed.lance/data/cfd970ca-cf95-4781-8a33-894028be98a0.lance new file mode 100644 index 0000000000000000000000000000000000000000..658e20ca8e4af88c8a60936b4f107e80ef2461de --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/cfd970ca-cf95-4781-8a33-894028be98a0.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7e2c2820af91f4483403f8515ea43ff0b811391aa0d0a9b47ac751e10c66c590 +size 69224 diff --git a/.lancedb/model1_fixed.lance/data/d1dd23c8-2951-4d2c-b45a-92b66f68013a.lance b/.lancedb/model1_fixed.lance/data/d1dd23c8-2951-4d2c-b45a-92b66f68013a.lance new file mode 100644 index 0000000000000000000000000000000000000000..2b4b3e08b32ae869d77d634c9403c0c2ad59ff8e --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/d1dd23c8-2951-4d2c-b45a-92b66f68013a.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f46d2da722c4864228fc39013bff93540b1d1ba3625d6ef33570a418fd3ca4ab +size 65256 diff --git a/.lancedb/model1_fixed.lance/data/d3b30b6c-a34f-49ac-b225-d03cfa2a6632.lance b/.lancedb/model1_fixed.lance/data/d3b30b6c-a34f-49ac-b225-d03cfa2a6632.lance new file mode 100644 index 0000000000000000000000000000000000000000..4423c475a6bebc5e7a4c86644af287858ea93080 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/d3b30b6c-a34f-49ac-b225-d03cfa2a6632.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fc98969671a17ea177cec5831832021d2cd5b0f26a9a2f3c23eb1519f11c2787 +size 67607 diff --git a/.lancedb/model1_fixed.lance/data/d445c93d-ba7c-48c1-8fa0-88e022a18165.lance b/.lancedb/model1_fixed.lance/data/d445c93d-ba7c-48c1-8fa0-88e022a18165.lance new file mode 100644 index 0000000000000000000000000000000000000000..10ceed77de2f31dd1c0ad7b21389f6adb62f4ea4 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/d445c93d-ba7c-48c1-8fa0-88e022a18165.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:61be8e219b80f9b826620d4c240c7998ea60ccd026659f1e42abe288e8fd864a +size 66429 diff --git a/.lancedb/model1_fixed.lance/data/d8129d48-3932-478f-8ef8-75d3b567d39a.lance b/.lancedb/model1_fixed.lance/data/d8129d48-3932-478f-8ef8-75d3b567d39a.lance new file mode 100644 index 0000000000000000000000000000000000000000..a7036020a6d7853aa5f3b8d57d7f2b03c9d44b6f --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/d8129d48-3932-478f-8ef8-75d3b567d39a.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:70e69347b582c1f8beef3ed2d3bea931501f96c6c80341387fb3e61c70a8b0a5 +size 62740 diff --git a/.lancedb/model1_fixed.lance/data/da1b6387-9614-4f12-b39b-2764a926e8bf.lance b/.lancedb/model1_fixed.lance/data/da1b6387-9614-4f12-b39b-2764a926e8bf.lance new file mode 100644 index 0000000000000000000000000000000000000000..e37a871fc0f1c0b5762825b670de584ceea157f2 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/da1b6387-9614-4f12-b39b-2764a926e8bf.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7bfc745bca5e0773cb9800c0e51b292b137a68b68210da02331835b49a09ac0b +size 69767 diff --git a/.lancedb/model1_fixed.lance/data/da8a5f57-9ba6-49db-a1fa-9fa3568fbcf4.lance b/.lancedb/model1_fixed.lance/data/da8a5f57-9ba6-49db-a1fa-9fa3568fbcf4.lance new file mode 100644 index 0000000000000000000000000000000000000000..824c39e2425165bf5a0638ab2c948487555c37ae --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/da8a5f57-9ba6-49db-a1fa-9fa3568fbcf4.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aea1b39237fcb6dd11e9279134df3d0477bcac6c3fadd4904e2c94144618a524 +size 68852 diff --git a/.lancedb/model1_fixed.lance/data/dbb0f714-4647-4269-8ff0-b6db68a0eaee.lance b/.lancedb/model1_fixed.lance/data/dbb0f714-4647-4269-8ff0-b6db68a0eaee.lance new file mode 100644 index 0000000000000000000000000000000000000000..b6d974b8deac7408e6e3714a5d9669e5463c8c2a --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/dbb0f714-4647-4269-8ff0-b6db68a0eaee.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c81bf8db79c126a6ce36512d38ef8c266b87060bd03b7f709f75f7dfe7246bca +size 70602 diff --git a/.lancedb/model1_fixed.lance/data/dc2bef7f-363a-4b33-860d-5e5f6ef7421e.lance b/.lancedb/model1_fixed.lance/data/dc2bef7f-363a-4b33-860d-5e5f6ef7421e.lance new file mode 100644 index 0000000000000000000000000000000000000000..d067046827b9832919bf990f8eea33c3a7173812 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/dc2bef7f-363a-4b33-860d-5e5f6ef7421e.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8fde2d2f11f72b71a9a1e8eeb2d2e93481e15734f0cd241afd032352798aedca +size 80885 diff --git a/.lancedb/model1_fixed.lance/data/e10e2c0d-ddd8-4f00-b450-4e580b081c2c.lance b/.lancedb/model1_fixed.lance/data/e10e2c0d-ddd8-4f00-b450-4e580b081c2c.lance new file mode 100644 index 0000000000000000000000000000000000000000..0ef2a00cad4ab83c290e8aeeb74b477fc3b9d247 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/e10e2c0d-ddd8-4f00-b450-4e580b081c2c.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b911d033ec12ca24c9c63619b9f2807cca1443fbabecefd5ff24ff3c01856963 +size 64430 diff --git a/.lancedb/model1_fixed.lance/data/eb71cd1a-de1b-447a-a524-5ee8de6f0a8d.lance b/.lancedb/model1_fixed.lance/data/eb71cd1a-de1b-447a-a524-5ee8de6f0a8d.lance new file mode 100644 index 0000000000000000000000000000000000000000..56dc0a6f6a6ed106f679a9715c0e8468fa92856d --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/eb71cd1a-de1b-447a-a524-5ee8de6f0a8d.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5f6091138130c390114b9112ccee6b2af4265ae36ec35cc49814e9fa591abe2f +size 71444 diff --git a/.lancedb/model1_fixed.lance/data/ef7d25fc-74ad-46b0-a088-c3997ff0126b.lance b/.lancedb/model1_fixed.lance/data/ef7d25fc-74ad-46b0-a088-c3997ff0126b.lance new file mode 100644 index 0000000000000000000000000000000000000000..dc43a80be7247cd7c1553e21424783e07a75ed1e --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/ef7d25fc-74ad-46b0-a088-c3997ff0126b.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:825b7b62259f11aa04647fb9b6a2123c3d2ac66fdc904f309ea8f7860715b7aa +size 67238 diff --git a/.lancedb/model1_fixed.lance/data/f05f5cc4-c4f6-4121-8778-d871601bb248.lance b/.lancedb/model1_fixed.lance/data/f05f5cc4-c4f6-4121-8778-d871601bb248.lance new file mode 100644 index 0000000000000000000000000000000000000000..eb8628f301497d67e186aa5e4d2734ddfba58a52 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/f05f5cc4-c4f6-4121-8778-d871601bb248.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:edecd337918e8424d0e093c4487159875462cd6e71c99e82363623e6d8afdf2e +size 66950 diff --git a/.lancedb/model1_fixed.lance/data/f096c38c-400d-4eb8-9e9c-5acb45a5b807.lance b/.lancedb/model1_fixed.lance/data/f096c38c-400d-4eb8-9e9c-5acb45a5b807.lance new file mode 100644 index 0000000000000000000000000000000000000000..7e49a65e2056e94862a8e082c625963a6794f07c --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/f096c38c-400d-4eb8-9e9c-5acb45a5b807.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1bfa1351eae6303fd705a3276e7dd3d832beb4f88173016ac52e11af3dacdbbf +size 75155 diff --git a/.lancedb/model1_fixed.lance/data/f19f0429-5830-468c-9fe7-c614e71a5f45.lance b/.lancedb/model1_fixed.lance/data/f19f0429-5830-468c-9fe7-c614e71a5f45.lance new file mode 100644 index 0000000000000000000000000000000000000000..fb1527160c366be78e347a65177c50f35865cde9 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/f19f0429-5830-468c-9fe7-c614e71a5f45.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:eb6ec52985fef699be65a3ed442d88169ea75f9eae35e364915586c65c6242cf +size 67639 diff --git a/.lancedb/model1_fixed.lance/data/f1d4ebc7-55c3-4b18-9504-cd96cc6bb014.lance b/.lancedb/model1_fixed.lance/data/f1d4ebc7-55c3-4b18-9504-cd96cc6bb014.lance new file mode 100644 index 0000000000000000000000000000000000000000..94c718b77a2ba9161df4ecb5414e478cb099e73c --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/f1d4ebc7-55c3-4b18-9504-cd96cc6bb014.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d5d84b5c0b687cfe38edb3fcbe51d209a375f5d04365929b3a59de97e5431e0f +size 69518 diff --git a/.lancedb/model1_fixed.lance/data/f32c168b-f475-4d86-9bf5-207c2a0ca22a.lance b/.lancedb/model1_fixed.lance/data/f32c168b-f475-4d86-9bf5-207c2a0ca22a.lance new file mode 100644 index 0000000000000000000000000000000000000000..e32619e9a9e99ed9de693ef5d4358cd7fb072774 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/f32c168b-f475-4d86-9bf5-207c2a0ca22a.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5dd47fbd27ec3c4066c349e8caaf0b27807f7afb9a0b68bae8120de4bb5c03a4 +size 75499 diff --git a/.lancedb/model1_fixed.lance/data/f3f304ef-d524-42ab-97cf-367d56c8909a.lance b/.lancedb/model1_fixed.lance/data/f3f304ef-d524-42ab-97cf-367d56c8909a.lance new file mode 100644 index 0000000000000000000000000000000000000000..cc8e578afef52049866bd5995b8c48e1c1abd315 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/f3f304ef-d524-42ab-97cf-367d56c8909a.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2e4ddefad84f79bea18d0d5782375a1c9049cb0b6f7c5335fa520c762ac0d85d +size 76279 diff --git a/.lancedb/model1_fixed.lance/data/f57eb9ef-69d9-4fee-a63c-56808df543e5.lance b/.lancedb/model1_fixed.lance/data/f57eb9ef-69d9-4fee-a63c-56808df543e5.lance new file mode 100644 index 0000000000000000000000000000000000000000..5aecf4efc29fa6a111d806b66059033fd89e02a2 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/f57eb9ef-69d9-4fee-a63c-56808df543e5.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:85c29039d6cfbd36ae7a3e7b58e59c3f88fc9779c8633a99e15720179981f6ca +size 69465 diff --git a/.lancedb/model1_fixed.lance/data/f5a4def2-dcad-4d6e-bdef-89ea346ad2f9.lance b/.lancedb/model1_fixed.lance/data/f5a4def2-dcad-4d6e-bdef-89ea346ad2f9.lance new file mode 100644 index 0000000000000000000000000000000000000000..683980097f9ba3008682f0c36dd2b38a26996e51 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/f5a4def2-dcad-4d6e-bdef-89ea346ad2f9.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:155fe8423e4a9de9ec0a296ba5bb6db65bab43ee35cbe1f810aaa50ed5242cee +size 71628 diff --git a/.lancedb/model1_fixed.lance/data/f6bd3719-ee16-4756-ab78-cc9e0dc5e838.lance b/.lancedb/model1_fixed.lance/data/f6bd3719-ee16-4756-ab78-cc9e0dc5e838.lance new file mode 100644 index 0000000000000000000000000000000000000000..59347d02023c2205da9597a48625d43309bf125f --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/f6bd3719-ee16-4756-ab78-cc9e0dc5e838.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b992aa93ec9fab51d4ca663ef421b04a05a3612d490c00ab6d5347ff8956d6bb +size 69981 diff --git a/.lancedb/model1_fixed.lance/data/fb0a260d-8a4b-4a59-aec8-df37f7190dec.lance b/.lancedb/model1_fixed.lance/data/fb0a260d-8a4b-4a59-aec8-df37f7190dec.lance new file mode 100644 index 0000000000000000000000000000000000000000..2f846baa44245b113e91e8faf3521ec49009cad2 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/fb0a260d-8a4b-4a59-aec8-df37f7190dec.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:05eb812dd06bbd5427df761601afa5c67a25f94e3dfc4142dc59a9b4c40a76f1 +size 69312 diff --git a/.lancedb/model1_fixed.lance/data/fc5ca0bf-0cf1-40fe-9a0d-9802c7f01941.lance b/.lancedb/model1_fixed.lance/data/fc5ca0bf-0cf1-40fe-9a0d-9802c7f01941.lance new file mode 100644 index 0000000000000000000000000000000000000000..e09b22f1026de2fcbe1761c70777f6b1fb5d300d --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/fc5ca0bf-0cf1-40fe-9a0d-9802c7f01941.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:614fb27367544bf83b20e5b102c8a1ffc7029da530ea307c5c97b280115e7207 +size 74979 diff --git a/.lancedb/model1_fixed.lance/data/fcb544d3-71aa-4323-b940-a8207194077e.lance b/.lancedb/model1_fixed.lance/data/fcb544d3-71aa-4323-b940-a8207194077e.lance new file mode 100644 index 0000000000000000000000000000000000000000..ce4ddfcef48e50429fe0746e23011a825c725631 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/fcb544d3-71aa-4323-b940-a8207194077e.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:84d2dac0f1cf04b1e20853ea3d661f64b2bd84665a0d0f4e3b09969b09cc1d7d +size 74789 diff --git a/.lancedb/model1_fixed.lance/data/fd02a3c6-63b7-4497-817c-aa472d1257ec.lance b/.lancedb/model1_fixed.lance/data/fd02a3c6-63b7-4497-817c-aa472d1257ec.lance new file mode 100644 index 0000000000000000000000000000000000000000..c82c03f1ae58bd3e8b5554f74fea7b91a1164a36 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/fd02a3c6-63b7-4497-817c-aa472d1257ec.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:53b53a4aca310aad21d2424638a60a0dd6cbf845f80a07d38b4909b7f10494ce +size 69576 diff --git a/.lancedb/model1_fixed.lance/data/fefaac08-0a30-424c-98a6-ea62ccc31fc1.lance b/.lancedb/model1_fixed.lance/data/fefaac08-0a30-424c-98a6-ea62ccc31fc1.lance new file mode 100644 index 0000000000000000000000000000000000000000..f4dd8eb7bc542ce6983b547fc5255cfbac24bb06 --- /dev/null +++ b/.lancedb/model1_fixed.lance/data/fefaac08-0a30-424c-98a6-ea62ccc31fc1.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:65f0b683c2d503092ca8f29bad7606674c15f31f5340b8c1174e07514d439ece +size 75031 diff --git a/.lancedb/model2_fixed.lance/_indices/08fb936e-0ad7-43c6-a23b-7a14dff46c92/index.idx b/.lancedb/model2_fixed.lance/_indices/08fb936e-0ad7-43c6-a23b-7a14dff46c92/index.idx new file mode 100644 index 0000000000000000000000000000000000000000..a46a71fbcd7062ba8a428cf60af36c2a21af39ca --- /dev/null +++ b/.lancedb/model2_fixed.lance/_indices/08fb936e-0ad7-43c6-a23b-7a14dff46c92/index.idx @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:58c3561543bf06fd902551a1372a985a5f611dbc734e355f3dd5b500f8ba4bae +size 2465067 diff --git a/.lancedb/model2_fixed.lance/_transactions/0-f0d81612-4f43-4070-81ad-180a5550aa70.txn b/.lancedb/model2_fixed.lance/_transactions/0-f0d81612-4f43-4070-81ad-180a5550aa70.txn new file mode 100644 index 0000000000000000000000000000000000000000..2fd630bf3f93930a0e00ed1cf209ba418f1eb3d2 --- /dev/null +++ b/.lancedb/model2_fixed.lance/_transactions/0-f0d81612-4f43-4070-81ad-180a5550aa70.txn @@ -0,0 +1 @@ +$f0d81612-4f43-4070-81ad-180a5550aa70²V3vector ÿÿÿÿÿÿÿÿÿ*fixed_size_list:float:102408text ÿÿÿÿÿÿÿÿÿ*string08 \ No newline at end of file diff --git a/.lancedb/model2_fixed.lance/_transactions/1-2adc2827-4ff7-4dca-a04d-622c18272e3e.txn b/.lancedb/model2_fixed.lance/_transactions/1-2adc2827-4ff7-4dca-a04d-622c18272e3e.txn new file mode 100644 index 0000000000000000000000000000000000000000..cce8920e85419c66cb358b7e5e4ffcfaa75315c9 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/1-2adc2827-4ff7-4dca-a04d-622c18272e3e.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/10-d4ecb86e-a4fe-4946-b832-5c5ce91d3925.txn b/.lancedb/model2_fixed.lance/_transactions/10-d4ecb86e-a4fe-4946-b832-5c5ce91d3925.txn new file mode 100644 index 0000000000000000000000000000000000000000..b8c114b05596fad1e23dfe8179c7e0a2e5552d8b Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/10-d4ecb86e-a4fe-4946-b832-5c5ce91d3925.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/11-c171eb9b-b867-41a9-956e-9a94a8a8a0cc.txn b/.lancedb/model2_fixed.lance/_transactions/11-c171eb9b-b867-41a9-956e-9a94a8a8a0cc.txn new file mode 100644 index 0000000000000000000000000000000000000000..1e64a6b566cad435bbbe8cec2c49a3997d67d928 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/11-c171eb9b-b867-41a9-956e-9a94a8a8a0cc.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/12-f97a00a6-1335-43bc-9aad-392d96c01566.txn b/.lancedb/model2_fixed.lance/_transactions/12-f97a00a6-1335-43bc-9aad-392d96c01566.txn new file mode 100644 index 0000000000000000000000000000000000000000..b9d3f7854333d1b61d40287e64a5ce050af0b280 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/12-f97a00a6-1335-43bc-9aad-392d96c01566.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/13-064bf244-6c0c-4bec-a912-c9a8729c14e4.txn b/.lancedb/model2_fixed.lance/_transactions/13-064bf244-6c0c-4bec-a912-c9a8729c14e4.txn new file mode 100644 index 0000000000000000000000000000000000000000..076cd196d93ae458f2e12766a80eed58a1e13e5a Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/13-064bf244-6c0c-4bec-a912-c9a8729c14e4.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/14-3fcf6348-0884-433f-8ccd-878c7e3c0c60.txn b/.lancedb/model2_fixed.lance/_transactions/14-3fcf6348-0884-433f-8ccd-878c7e3c0c60.txn new file mode 100644 index 0000000000000000000000000000000000000000..8359dc9d32f29e3548f5efc5122cead0c61f11dd Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/14-3fcf6348-0884-433f-8ccd-878c7e3c0c60.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/15-4e90313a-6015-4461-b0ee-8dfedbb22d74.txn b/.lancedb/model2_fixed.lance/_transactions/15-4e90313a-6015-4461-b0ee-8dfedbb22d74.txn new file mode 100644 index 0000000000000000000000000000000000000000..9aef83a8c0bc6ceb6f7c7974dede68dadde38361 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/15-4e90313a-6015-4461-b0ee-8dfedbb22d74.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/16-d26686f1-9c56-41f3-883d-9dbcb60a226c.txn b/.lancedb/model2_fixed.lance/_transactions/16-d26686f1-9c56-41f3-883d-9dbcb60a226c.txn new file mode 100644 index 0000000000000000000000000000000000000000..b195d32688a25eaf6d34b3083529c0317e9a82e3 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/16-d26686f1-9c56-41f3-883d-9dbcb60a226c.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/17-13aeb23e-1bb8-4b00-96f9-728ef322ec0c.txn b/.lancedb/model2_fixed.lance/_transactions/17-13aeb23e-1bb8-4b00-96f9-728ef322ec0c.txn new file mode 100644 index 0000000000000000000000000000000000000000..4f24b408d0f4e8607a8b864ea385eff607406db9 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/17-13aeb23e-1bb8-4b00-96f9-728ef322ec0c.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/18-cea7bf3f-121c-4321-8c76-10c78048b82f.txn b/.lancedb/model2_fixed.lance/_transactions/18-cea7bf3f-121c-4321-8c76-10c78048b82f.txn new file mode 100644 index 0000000000000000000000000000000000000000..392e3e0c55d7bb68961bdb0824edbd77370a2805 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/18-cea7bf3f-121c-4321-8c76-10c78048b82f.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/19-5674d17a-69fd-4efe-9068-38eb29b3971f.txn b/.lancedb/model2_fixed.lance/_transactions/19-5674d17a-69fd-4efe-9068-38eb29b3971f.txn new file mode 100644 index 0000000000000000000000000000000000000000..e098a108a4e914ded9e80ff58e1f275d7967d1d3 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/19-5674d17a-69fd-4efe-9068-38eb29b3971f.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/2-d77a7756-e318-4394-8e91-b3d85393ea42.txn b/.lancedb/model2_fixed.lance/_transactions/2-d77a7756-e318-4394-8e91-b3d85393ea42.txn new file mode 100644 index 0000000000000000000000000000000000000000..c5ade51c14ed05d6c474dc51fdc44d53fe4b910d Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/2-d77a7756-e318-4394-8e91-b3d85393ea42.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/20-9cd01007-0051-40f0-b2b8-50aad684ead7.txn b/.lancedb/model2_fixed.lance/_transactions/20-9cd01007-0051-40f0-b2b8-50aad684ead7.txn new file mode 100644 index 0000000000000000000000000000000000000000..e0cf9d794fc41e0b438ceaeebde89decfd1c38a6 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/20-9cd01007-0051-40f0-b2b8-50aad684ead7.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/21-c5d35c0c-e5e7-4f83-941b-fe58b2924c6a.txn b/.lancedb/model2_fixed.lance/_transactions/21-c5d35c0c-e5e7-4f83-941b-fe58b2924c6a.txn new file mode 100644 index 0000000000000000000000000000000000000000..b4e71e4b3e542336462c5445fdcdf2b5ce7f4a21 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/21-c5d35c0c-e5e7-4f83-941b-fe58b2924c6a.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/22-bd3cc570-f7bb-4087-90e2-d95b7c9ec56f.txn b/.lancedb/model2_fixed.lance/_transactions/22-bd3cc570-f7bb-4087-90e2-d95b7c9ec56f.txn new file mode 100644 index 0000000000000000000000000000000000000000..7443a3ae911d8640a0270a29c85c0885dc00bb9e Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/22-bd3cc570-f7bb-4087-90e2-d95b7c9ec56f.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/23-ff0a43ff-c113-408a-afbb-340e6faaa8f1.txn b/.lancedb/model2_fixed.lance/_transactions/23-ff0a43ff-c113-408a-afbb-340e6faaa8f1.txn new file mode 100644 index 0000000000000000000000000000000000000000..44edf626ebe54d93b0374f1aa209114977f48c7e Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/23-ff0a43ff-c113-408a-afbb-340e6faaa8f1.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/24-431e3571-792a-43bb-8f16-215f13c6ab7c.txn b/.lancedb/model2_fixed.lance/_transactions/24-431e3571-792a-43bb-8f16-215f13c6ab7c.txn new file mode 100644 index 0000000000000000000000000000000000000000..e8d27b4e34855ff998884e5bee476ad695630b58 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/24-431e3571-792a-43bb-8f16-215f13c6ab7c.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/25-c7a1379b-7048-4f75-9e4a-6186eed9749b.txn b/.lancedb/model2_fixed.lance/_transactions/25-c7a1379b-7048-4f75-9e4a-6186eed9749b.txn new file mode 100644 index 0000000000000000000000000000000000000000..c40014eb380923a7ef0e9f9b745eb77cf312972e Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/25-c7a1379b-7048-4f75-9e4a-6186eed9749b.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/26-264550d9-6424-4a9d-be6c-85d2aedfd57c.txn b/.lancedb/model2_fixed.lance/_transactions/26-264550d9-6424-4a9d-be6c-85d2aedfd57c.txn new file mode 100644 index 0000000000000000000000000000000000000000..3ca9650ed1db5a03f507c483a22b9ab87db9d547 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/26-264550d9-6424-4a9d-be6c-85d2aedfd57c.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/27-122558a2-1bcd-4a57-bc74-2ee9c34cdfe1.txn b/.lancedb/model2_fixed.lance/_transactions/27-122558a2-1bcd-4a57-bc74-2ee9c34cdfe1.txn new file mode 100644 index 0000000000000000000000000000000000000000..83605212182bb7f8f6960632a0bfc48c5ac26575 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/27-122558a2-1bcd-4a57-bc74-2ee9c34cdfe1.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/28-5b48f79f-8d5a-45b9-82f8-e78a0edf50b4.txn b/.lancedb/model2_fixed.lance/_transactions/28-5b48f79f-8d5a-45b9-82f8-e78a0edf50b4.txn new file mode 100644 index 0000000000000000000000000000000000000000..9be05e7fba8a8cea7797cc650df56511d6ef3423 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/28-5b48f79f-8d5a-45b9-82f8-e78a0edf50b4.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/29-bea9f2f0-be37-46e4-ac85-0f9fa1ef8b5b.txn b/.lancedb/model2_fixed.lance/_transactions/29-bea9f2f0-be37-46e4-ac85-0f9fa1ef8b5b.txn new file mode 100644 index 0000000000000000000000000000000000000000..47345a8f9b74278e795b4a09812d3d2ff40f77a1 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/29-bea9f2f0-be37-46e4-ac85-0f9fa1ef8b5b.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/3-57a56a7f-1132-4e74-a5e0-c074fa9f35c9.txn b/.lancedb/model2_fixed.lance/_transactions/3-57a56a7f-1132-4e74-a5e0-c074fa9f35c9.txn new file mode 100644 index 0000000000000000000000000000000000000000..c709b7f300a278f9b4ae25a8a973471654d64a5d Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/3-57a56a7f-1132-4e74-a5e0-c074fa9f35c9.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/30-8a9d40bc-8ced-473f-8b47-0672ad9fd42b.txn b/.lancedb/model2_fixed.lance/_transactions/30-8a9d40bc-8ced-473f-8b47-0672ad9fd42b.txn new file mode 100644 index 0000000000000000000000000000000000000000..4795016d69b6eb4b81d4b415748cfa405e6e4369 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/30-8a9d40bc-8ced-473f-8b47-0672ad9fd42b.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/31-91be0c46-4b5a-4387-b2de-b355b64dcc94.txn b/.lancedb/model2_fixed.lance/_transactions/31-91be0c46-4b5a-4387-b2de-b355b64dcc94.txn new file mode 100644 index 0000000000000000000000000000000000000000..e5626f4e7c453df3e3a09a176e8744bc52ed204f Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/31-91be0c46-4b5a-4387-b2de-b355b64dcc94.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/32-bebd8a09-0db3-4240-b34c-d97e83af1dcb.txn b/.lancedb/model2_fixed.lance/_transactions/32-bebd8a09-0db3-4240-b34c-d97e83af1dcb.txn new file mode 100644 index 0000000000000000000000000000000000000000..ecd5fa47db41d6ed4b21d7177bb5fb0bcc327eb0 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/32-bebd8a09-0db3-4240-b34c-d97e83af1dcb.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/33-a0bd2901-855d-4c62-934a-80a23d4005df.txn b/.lancedb/model2_fixed.lance/_transactions/33-a0bd2901-855d-4c62-934a-80a23d4005df.txn new file mode 100644 index 0000000000000000000000000000000000000000..b331d2fbb195fb4343806566c243eace9b41812e Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/33-a0bd2901-855d-4c62-934a-80a23d4005df.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/34-11f713d3-cf64-4dee-a477-8bd0974233c0.txn b/.lancedb/model2_fixed.lance/_transactions/34-11f713d3-cf64-4dee-a477-8bd0974233c0.txn new file mode 100644 index 0000000000000000000000000000000000000000..89165b3331e7a18b294932449dddeedbb1f547e0 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/34-11f713d3-cf64-4dee-a477-8bd0974233c0.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/35-572a3b76-5ae3-4493-8032-d9bfad287c70.txn b/.lancedb/model2_fixed.lance/_transactions/35-572a3b76-5ae3-4493-8032-d9bfad287c70.txn new file mode 100644 index 0000000000000000000000000000000000000000..75f585b268c885270bfe5d1bcf1b44ae358f25f5 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/35-572a3b76-5ae3-4493-8032-d9bfad287c70.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/36-99495fee-c757-44fb-b86a-d00cd4fbca9f.txn b/.lancedb/model2_fixed.lance/_transactions/36-99495fee-c757-44fb-b86a-d00cd4fbca9f.txn new file mode 100644 index 0000000000000000000000000000000000000000..717ce678f1d9e4447337b1d951688970cc07e169 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/36-99495fee-c757-44fb-b86a-d00cd4fbca9f.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/37-5956fc67-b403-4174-907a-1b12e0765d3a.txn b/.lancedb/model2_fixed.lance/_transactions/37-5956fc67-b403-4174-907a-1b12e0765d3a.txn new file mode 100644 index 0000000000000000000000000000000000000000..1f823e3ed876d9977dd4d5b510f148db650d02f7 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/37-5956fc67-b403-4174-907a-1b12e0765d3a.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/38-89ab4c24-6111-46ef-864f-b908fcf5bffd.txn b/.lancedb/model2_fixed.lance/_transactions/38-89ab4c24-6111-46ef-864f-b908fcf5bffd.txn new file mode 100644 index 0000000000000000000000000000000000000000..68e9b0c08ba4ce000c795d6540a6b2adccd0c969 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/38-89ab4c24-6111-46ef-864f-b908fcf5bffd.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/39-ed99c46b-aa9e-4f4d-8168-fed47cf19053.txn b/.lancedb/model2_fixed.lance/_transactions/39-ed99c46b-aa9e-4f4d-8168-fed47cf19053.txn new file mode 100644 index 0000000000000000000000000000000000000000..48e6757f339b43a3f0c2d13e3cdd47ffb37e718a Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/39-ed99c46b-aa9e-4f4d-8168-fed47cf19053.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/4-46939059-bca0-4cb8-85b4-40f273010672.txn b/.lancedb/model2_fixed.lance/_transactions/4-46939059-bca0-4cb8-85b4-40f273010672.txn new file mode 100644 index 0000000000000000000000000000000000000000..9403f517d542ec74cd156cd1cf8bcd63ba667bcc Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/4-46939059-bca0-4cb8-85b4-40f273010672.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/40-e7989ba0-7c18-4ec4-8df0-a5cbbb5e786c.txn b/.lancedb/model2_fixed.lance/_transactions/40-e7989ba0-7c18-4ec4-8df0-a5cbbb5e786c.txn new file mode 100644 index 0000000000000000000000000000000000000000..1ac4d4ab9a0c89b4d32fa83d14d64ab4aede5094 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/40-e7989ba0-7c18-4ec4-8df0-a5cbbb5e786c.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/41-d47ac13e-b25f-44d6-b72a-ada8c1bc1739.txn b/.lancedb/model2_fixed.lance/_transactions/41-d47ac13e-b25f-44d6-b72a-ada8c1bc1739.txn new file mode 100644 index 0000000000000000000000000000000000000000..7323938aafe9d73d615a52564e81b853aae0afa4 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/41-d47ac13e-b25f-44d6-b72a-ada8c1bc1739.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/42-2deb46fb-6dd9-4fd4-847c-9bb51759b5c5.txn b/.lancedb/model2_fixed.lance/_transactions/42-2deb46fb-6dd9-4fd4-847c-9bb51759b5c5.txn new file mode 100644 index 0000000000000000000000000000000000000000..cb1a3483a190cc74071f216b915963cc72ffb379 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/42-2deb46fb-6dd9-4fd4-847c-9bb51759b5c5.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/43-76871754-dfac-4929-a76f-86d7b5736e66.txn b/.lancedb/model2_fixed.lance/_transactions/43-76871754-dfac-4929-a76f-86d7b5736e66.txn new file mode 100644 index 0000000000000000000000000000000000000000..61231c4e75c25dc3821921e1fd7727bb0f443d95 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/43-76871754-dfac-4929-a76f-86d7b5736e66.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/44-e3b8317a-2ec7-4162-ae3e-35c45ac2b0da.txn b/.lancedb/model2_fixed.lance/_transactions/44-e3b8317a-2ec7-4162-ae3e-35c45ac2b0da.txn new file mode 100644 index 0000000000000000000000000000000000000000..dab9a55e47d8050cf5170a5086e64b423e3e754e Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/44-e3b8317a-2ec7-4162-ae3e-35c45ac2b0da.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/45-450be708-2830-4413-ae53-167f14e038b3.txn b/.lancedb/model2_fixed.lance/_transactions/45-450be708-2830-4413-ae53-167f14e038b3.txn new file mode 100644 index 0000000000000000000000000000000000000000..3362b46b362cdedbb7b85c9df3196c205ed57c47 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/45-450be708-2830-4413-ae53-167f14e038b3.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/46-6ff36b10-7c1e-4d6d-a9b8-483ecd5e7b2d.txn b/.lancedb/model2_fixed.lance/_transactions/46-6ff36b10-7c1e-4d6d-a9b8-483ecd5e7b2d.txn new file mode 100644 index 0000000000000000000000000000000000000000..0861fdff420dce3601cf7a0defe84e79dd9085c4 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/46-6ff36b10-7c1e-4d6d-a9b8-483ecd5e7b2d.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/47-ba2ccc2b-ba05-42e9-a94f-d286206ce4e1.txn b/.lancedb/model2_fixed.lance/_transactions/47-ba2ccc2b-ba05-42e9-a94f-d286206ce4e1.txn new file mode 100644 index 0000000000000000000000000000000000000000..03854d5fbc5ce09337a62654df5d6ce8d3b3d9f3 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/47-ba2ccc2b-ba05-42e9-a94f-d286206ce4e1.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/48-37830432-f985-43df-97cf-406e9ecb0fa3.txn b/.lancedb/model2_fixed.lance/_transactions/48-37830432-f985-43df-97cf-406e9ecb0fa3.txn new file mode 100644 index 0000000000000000000000000000000000000000..6e9156203a30e4caaa3ddde9b8ccac2ee63ba265 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/48-37830432-f985-43df-97cf-406e9ecb0fa3.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/49-ab53b621-2ddf-4bcb-bd0b-bc1a038c760f.txn b/.lancedb/model2_fixed.lance/_transactions/49-ab53b621-2ddf-4bcb-bd0b-bc1a038c760f.txn new file mode 100644 index 0000000000000000000000000000000000000000..b4b093c23e57dacdbb04062f202fd3c347efdf10 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/49-ab53b621-2ddf-4bcb-bd0b-bc1a038c760f.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/5-e4907c5a-c28e-420b-8984-c5b0d175d0c7.txn b/.lancedb/model2_fixed.lance/_transactions/5-e4907c5a-c28e-420b-8984-c5b0d175d0c7.txn new file mode 100644 index 0000000000000000000000000000000000000000..8917ea27a0c73318d4f2f2084cd6a2602b6fbb69 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/5-e4907c5a-c28e-420b-8984-c5b0d175d0c7.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/50-0f24bb4d-d143-4c1d-aec9-378e1ded98e4.txn b/.lancedb/model2_fixed.lance/_transactions/50-0f24bb4d-d143-4c1d-aec9-378e1ded98e4.txn new file mode 100644 index 0000000000000000000000000000000000000000..27c649da72d4d724783bff638fc938288c7dda45 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/50-0f24bb4d-d143-4c1d-aec9-378e1ded98e4.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/51-a3ac1efd-77fd-416c-b2a5-c77fa92cf865.txn b/.lancedb/model2_fixed.lance/_transactions/51-a3ac1efd-77fd-416c-b2a5-c77fa92cf865.txn new file mode 100644 index 0000000000000000000000000000000000000000..a8ba42d00b9a402e4e40196c3ebed8da888ca6b6 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/51-a3ac1efd-77fd-416c-b2a5-c77fa92cf865.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/52-6252e633-deb9-4c80-a762-eb07b287df5f.txn b/.lancedb/model2_fixed.lance/_transactions/52-6252e633-deb9-4c80-a762-eb07b287df5f.txn new file mode 100644 index 0000000000000000000000000000000000000000..960ecdc80ba49bfad105b6b6f66c769130f35ea7 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/52-6252e633-deb9-4c80-a762-eb07b287df5f.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/53-9e559939-870f-44fe-a573-d1686e46c122.txn b/.lancedb/model2_fixed.lance/_transactions/53-9e559939-870f-44fe-a573-d1686e46c122.txn new file mode 100644 index 0000000000000000000000000000000000000000..c114a48ab96157f9e46ac13863c6de9c4b93bd4e Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/53-9e559939-870f-44fe-a573-d1686e46c122.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/54-51f835a6-44c9-4774-918e-ac922fb6aa6f.txn b/.lancedb/model2_fixed.lance/_transactions/54-51f835a6-44c9-4774-918e-ac922fb6aa6f.txn new file mode 100644 index 0000000000000000000000000000000000000000..429fc3bc24a33446f12a48d8a388547ce6219aa7 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/54-51f835a6-44c9-4774-918e-ac922fb6aa6f.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/55-3cd2de4e-c144-49e0-b36d-3a42c3a31421.txn b/.lancedb/model2_fixed.lance/_transactions/55-3cd2de4e-c144-49e0-b36d-3a42c3a31421.txn new file mode 100644 index 0000000000000000000000000000000000000000..f1e8d6497e3f2f5f45e6b3459b5e02a4330e3bee Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/55-3cd2de4e-c144-49e0-b36d-3a42c3a31421.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/56-16c06f70-e806-452d-afd0-033e2a886d36.txn b/.lancedb/model2_fixed.lance/_transactions/56-16c06f70-e806-452d-afd0-033e2a886d36.txn new file mode 100644 index 0000000000000000000000000000000000000000..fdcc169be9a80dae5514e0bda03f0fd0f3ba5d39 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/56-16c06f70-e806-452d-afd0-033e2a886d36.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/57-f98fc71f-dcf0-4c40-ace5-09d9b8fc9b65.txn b/.lancedb/model2_fixed.lance/_transactions/57-f98fc71f-dcf0-4c40-ace5-09d9b8fc9b65.txn new file mode 100644 index 0000000000000000000000000000000000000000..5649af9bec0bbd5c2b502ec33393a3bd4c6f7598 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/57-f98fc71f-dcf0-4c40-ace5-09d9b8fc9b65.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/58-33111a43-05cc-4fcf-b5f6-4bcd79721a16.txn b/.lancedb/model2_fixed.lance/_transactions/58-33111a43-05cc-4fcf-b5f6-4bcd79721a16.txn new file mode 100644 index 0000000000000000000000000000000000000000..993ab99720ba15a70ddaee2f863358982fb6fed9 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/58-33111a43-05cc-4fcf-b5f6-4bcd79721a16.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/59-671e0bd9-bf61-4b5e-a7c9-fa650a8d38c3.txn b/.lancedb/model2_fixed.lance/_transactions/59-671e0bd9-bf61-4b5e-a7c9-fa650a8d38c3.txn new file mode 100644 index 0000000000000000000000000000000000000000..9a16a4f423113b53f72dc13806914f4ee54ee668 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/59-671e0bd9-bf61-4b5e-a7c9-fa650a8d38c3.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/6-3b5e33cf-9ce8-4a01-aed1-bd7c9283b8b4.txn b/.lancedb/model2_fixed.lance/_transactions/6-3b5e33cf-9ce8-4a01-aed1-bd7c9283b8b4.txn new file mode 100644 index 0000000000000000000000000000000000000000..c3238ae727f35be15e04df754bbfa2abca3a37ae Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/6-3b5e33cf-9ce8-4a01-aed1-bd7c9283b8b4.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/60-26c0d403-baff-481d-9088-cd1db84a42db.txn b/.lancedb/model2_fixed.lance/_transactions/60-26c0d403-baff-481d-9088-cd1db84a42db.txn new file mode 100644 index 0000000000000000000000000000000000000000..68fab9edc8a081f137dcc9e271ebf239fe1e39c9 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/60-26c0d403-baff-481d-9088-cd1db84a42db.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/61-5573ae6e-22ee-4599-8be8-93a48ab55824.txn b/.lancedb/model2_fixed.lance/_transactions/61-5573ae6e-22ee-4599-8be8-93a48ab55824.txn new file mode 100644 index 0000000000000000000000000000000000000000..9c45350e97851c4d6763a763af52991702d9e65b Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/61-5573ae6e-22ee-4599-8be8-93a48ab55824.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/62-9714e52e-d079-4bc6-b52c-262578ea0cb0.txn b/.lancedb/model2_fixed.lance/_transactions/62-9714e52e-d079-4bc6-b52c-262578ea0cb0.txn new file mode 100644 index 0000000000000000000000000000000000000000..4de49af891d73617983b61b5d39ee033dbba2b18 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/62-9714e52e-d079-4bc6-b52c-262578ea0cb0.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/63-4f97eeeb-dad7-4398-bde3-e235e5f675d6.txn b/.lancedb/model2_fixed.lance/_transactions/63-4f97eeeb-dad7-4398-bde3-e235e5f675d6.txn new file mode 100644 index 0000000000000000000000000000000000000000..d1456ba5e6b71ac4262ec128281d8c36ee9de61e Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/63-4f97eeeb-dad7-4398-bde3-e235e5f675d6.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/64-1dd358ff-c42e-49ec-80d2-958fc28c807f.txn b/.lancedb/model2_fixed.lance/_transactions/64-1dd358ff-c42e-49ec-80d2-958fc28c807f.txn new file mode 100644 index 0000000000000000000000000000000000000000..3ceebd7332bcde72c180dcb2754afb2b7ae2f937 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/64-1dd358ff-c42e-49ec-80d2-958fc28c807f.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/65-4a105a73-4f42-4c09-8433-80cff77859d4.txn b/.lancedb/model2_fixed.lance/_transactions/65-4a105a73-4f42-4c09-8433-80cff77859d4.txn new file mode 100644 index 0000000000000000000000000000000000000000..87124a383dd336659348759a26a5ce3f629d0b59 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/65-4a105a73-4f42-4c09-8433-80cff77859d4.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/66-949564c2-9cc5-4eba-809c-001e21d4a204.txn b/.lancedb/model2_fixed.lance/_transactions/66-949564c2-9cc5-4eba-809c-001e21d4a204.txn new file mode 100644 index 0000000000000000000000000000000000000000..ebba4bcc197ae98b37d68553f57e47c9efc1c278 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/66-949564c2-9cc5-4eba-809c-001e21d4a204.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/67-62252bb1-9574-435e-912b-6f17a2769a1e.txn b/.lancedb/model2_fixed.lance/_transactions/67-62252bb1-9574-435e-912b-6f17a2769a1e.txn new file mode 100644 index 0000000000000000000000000000000000000000..e8bb3a08feace40c2b1748a2f23b230743ac3528 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/67-62252bb1-9574-435e-912b-6f17a2769a1e.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/68-6879c928-0b9d-4b31-b6be-ed6f437703df.txn b/.lancedb/model2_fixed.lance/_transactions/68-6879c928-0b9d-4b31-b6be-ed6f437703df.txn new file mode 100644 index 0000000000000000000000000000000000000000..bd75d9d2954493d9a0efd45fc6126cd05ff26d67 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/68-6879c928-0b9d-4b31-b6be-ed6f437703df.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/69-9bd3009c-404c-43a8-a7d2-90123ce6c93e.txn b/.lancedb/model2_fixed.lance/_transactions/69-9bd3009c-404c-43a8-a7d2-90123ce6c93e.txn new file mode 100644 index 0000000000000000000000000000000000000000..cd4f2bfa940b4192cf22046e5e7e4b69c7b8cb10 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/69-9bd3009c-404c-43a8-a7d2-90123ce6c93e.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/7-820b6c85-9f1b-45b6-8dea-adf46ee3aaae.txn b/.lancedb/model2_fixed.lance/_transactions/7-820b6c85-9f1b-45b6-8dea-adf46ee3aaae.txn new file mode 100644 index 0000000000000000000000000000000000000000..801c38cc315cce73feac86778c821cecbebb98f0 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/7-820b6c85-9f1b-45b6-8dea-adf46ee3aaae.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/70-a9bee1d8-03ea-48a2-b868-cf43308d033a.txn b/.lancedb/model2_fixed.lance/_transactions/70-a9bee1d8-03ea-48a2-b868-cf43308d033a.txn new file mode 100644 index 0000000000000000000000000000000000000000..3741e38f8fccfc705e7ef1db86c65e02c087d069 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/70-a9bee1d8-03ea-48a2-b868-cf43308d033a.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/71-8ef1146f-2f59-47e6-892b-e79c0e7fb21b.txn b/.lancedb/model2_fixed.lance/_transactions/71-8ef1146f-2f59-47e6-892b-e79c0e7fb21b.txn new file mode 100644 index 0000000000000000000000000000000000000000..f6af011de34a180499d5632d9d42d9c80061c5c9 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/71-8ef1146f-2f59-47e6-892b-e79c0e7fb21b.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/72-ad8f7151-068c-4720-922f-0e6656144949.txn b/.lancedb/model2_fixed.lance/_transactions/72-ad8f7151-068c-4720-922f-0e6656144949.txn new file mode 100644 index 0000000000000000000000000000000000000000..02c763322bac37a72719279564dcea9ff26fd9ab Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/72-ad8f7151-068c-4720-922f-0e6656144949.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/73-e5db18bf-eff1-4bf8-9167-0917562f95be.txn b/.lancedb/model2_fixed.lance/_transactions/73-e5db18bf-eff1-4bf8-9167-0917562f95be.txn new file mode 100644 index 0000000000000000000000000000000000000000..f8fcbc09b763217af100d7152a9f0ceb1dca809a Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/73-e5db18bf-eff1-4bf8-9167-0917562f95be.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/74-c21db710-2890-4379-ae61-49a8eb5c6151.txn b/.lancedb/model2_fixed.lance/_transactions/74-c21db710-2890-4379-ae61-49a8eb5c6151.txn new file mode 100644 index 0000000000000000000000000000000000000000..c441b6340e2dc57d45ef8ea9f5bc875ae96b2a8b Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/74-c21db710-2890-4379-ae61-49a8eb5c6151.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/75-5712a435-664c-4099-be6d-2f8dce10158a.txn b/.lancedb/model2_fixed.lance/_transactions/75-5712a435-664c-4099-be6d-2f8dce10158a.txn new file mode 100644 index 0000000000000000000000000000000000000000..1bc8911dd685d98e3b40d3ee59cadf45e6ac30e4 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/75-5712a435-664c-4099-be6d-2f8dce10158a.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/76-a1626360-c3a4-4fc3-a6dd-135407428403.txn b/.lancedb/model2_fixed.lance/_transactions/76-a1626360-c3a4-4fc3-a6dd-135407428403.txn new file mode 100644 index 0000000000000000000000000000000000000000..c39058f5141425763f36bb3a4aed4d241663e0ab Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/76-a1626360-c3a4-4fc3-a6dd-135407428403.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/77-ce8a742b-eaea-48b8-b0d7-65d10be8c6ae.txn b/.lancedb/model2_fixed.lance/_transactions/77-ce8a742b-eaea-48b8-b0d7-65d10be8c6ae.txn new file mode 100644 index 0000000000000000000000000000000000000000..740a1c5001749c928704e826c40dec37638a048d Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/77-ce8a742b-eaea-48b8-b0d7-65d10be8c6ae.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/78-4b58b4b5-ac71-4ad6-888f-17d877a8a7c5.txn b/.lancedb/model2_fixed.lance/_transactions/78-4b58b4b5-ac71-4ad6-888f-17d877a8a7c5.txn new file mode 100644 index 0000000000000000000000000000000000000000..9d729ea49fa45046195f97506dbfecee23f8686f Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/78-4b58b4b5-ac71-4ad6-888f-17d877a8a7c5.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/79-701437d3-a483-4587-8105-8947216695ae.txn b/.lancedb/model2_fixed.lance/_transactions/79-701437d3-a483-4587-8105-8947216695ae.txn new file mode 100644 index 0000000000000000000000000000000000000000..33d687a71d682d6e7d69bdc0bf39746e668ad827 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/79-701437d3-a483-4587-8105-8947216695ae.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/8-e038279b-3b85-4ad4-8225-cf3d057ce122.txn b/.lancedb/model2_fixed.lance/_transactions/8-e038279b-3b85-4ad4-8225-cf3d057ce122.txn new file mode 100644 index 0000000000000000000000000000000000000000..283fdfe967f94ed26297ccb6d1a2166edf53a676 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/8-e038279b-3b85-4ad4-8225-cf3d057ce122.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/80-26fee38c-9612-4fbb-837f-c35cc618c27a.txn b/.lancedb/model2_fixed.lance/_transactions/80-26fee38c-9612-4fbb-837f-c35cc618c27a.txn new file mode 100644 index 0000000000000000000000000000000000000000..9f5446a51d08beac2dcf2c7165272db2a28d1bc4 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/80-26fee38c-9612-4fbb-837f-c35cc618c27a.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/81-1677e1fa-846c-4c79-9fcb-2ca29d486173.txn b/.lancedb/model2_fixed.lance/_transactions/81-1677e1fa-846c-4c79-9fcb-2ca29d486173.txn new file mode 100644 index 0000000000000000000000000000000000000000..53e453e2fe4286c025e7f44e5d3db1916b45dbe6 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/81-1677e1fa-846c-4c79-9fcb-2ca29d486173.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/82-0f10a87f-9f6d-4655-a91e-7b348c9eeb41.txn b/.lancedb/model2_fixed.lance/_transactions/82-0f10a87f-9f6d-4655-a91e-7b348c9eeb41.txn new file mode 100644 index 0000000000000000000000000000000000000000..0a8f5f46fdc908eb1ea31be9f2d0be0e3505e798 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/82-0f10a87f-9f6d-4655-a91e-7b348c9eeb41.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/83-459dd684-ab5a-4eb4-a8c3-a496d08e237d.txn b/.lancedb/model2_fixed.lance/_transactions/83-459dd684-ab5a-4eb4-a8c3-a496d08e237d.txn new file mode 100644 index 0000000000000000000000000000000000000000..674002ba9ba0441fa4ee481f96f209255ddab1f8 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/83-459dd684-ab5a-4eb4-a8c3-a496d08e237d.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/84-59be1f3e-2ee3-4d7d-bc0e-e67c98051c60.txn b/.lancedb/model2_fixed.lance/_transactions/84-59be1f3e-2ee3-4d7d-bc0e-e67c98051c60.txn new file mode 100644 index 0000000000000000000000000000000000000000..8e11d17cbde5b3f0abe28195e78b567352761993 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/84-59be1f3e-2ee3-4d7d-bc0e-e67c98051c60.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/85-8826bf81-5bb3-4e52-a428-2e6b653bae23.txn b/.lancedb/model2_fixed.lance/_transactions/85-8826bf81-5bb3-4e52-a428-2e6b653bae23.txn new file mode 100644 index 0000000000000000000000000000000000000000..3c8481b4a14dc51ce447e7b875cfe3d78205effb Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/85-8826bf81-5bb3-4e52-a428-2e6b653bae23.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/86-9db8fba0-bc56-4927-9b37-04d185ffc43f.txn b/.lancedb/model2_fixed.lance/_transactions/86-9db8fba0-bc56-4927-9b37-04d185ffc43f.txn new file mode 100644 index 0000000000000000000000000000000000000000..9356b8b10e33e9327a21df05a8b9a2ab67be9e7a Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/86-9db8fba0-bc56-4927-9b37-04d185ffc43f.txn differ diff --git a/.lancedb/model2_fixed.lance/_transactions/9-f332414c-a0c1-40fc-aa25-998e15aab59b.txn b/.lancedb/model2_fixed.lance/_transactions/9-f332414c-a0c1-40fc-aa25-998e15aab59b.txn new file mode 100644 index 0000000000000000000000000000000000000000..6c60f376007183a116b67be8c97e992d9d8c3104 Binary files /dev/null and b/.lancedb/model2_fixed.lance/_transactions/9-f332414c-a0c1-40fc-aa25-998e15aab59b.txn differ diff --git a/.lancedb/model2_fixed.lance/data/01cef012-f105-4a8b-a1fb-752faf8f42d4.lance b/.lancedb/model2_fixed.lance/data/01cef012-f105-4a8b-a1fb-752faf8f42d4.lance new file mode 100644 index 0000000000000000000000000000000000000000..5b72839ed92250e3ce659efaf7cd3e9ec723f716 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/01cef012-f105-4a8b-a1fb-752faf8f42d4.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:461e8b0fb1eeb6c20e7998fe84943f9d82c05b6c3ad14e2e0ad80b4b0d2f7e3d +size 169608 diff --git a/.lancedb/model2_fixed.lance/data/044f0ec8-0fe1-4125-936d-58a80f5d5420.lance b/.lancedb/model2_fixed.lance/data/044f0ec8-0fe1-4125-936d-58a80f5d5420.lance new file mode 100644 index 0000000000000000000000000000000000000000..9af1e31c51801a340e7f835402525e47f7b9ab76 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/044f0ec8-0fe1-4125-936d-58a80f5d5420.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f8845972f005504a9eb32d24cfb74d911eb5a4a5ee077da80a4abc1a2e909ed6 +size 160372 diff --git a/.lancedb/model2_fixed.lance/data/05473457-76c8-4b85-b96c-561dc2ea15b1.lance b/.lancedb/model2_fixed.lance/data/05473457-76c8-4b85-b96c-561dc2ea15b1.lance new file mode 100644 index 0000000000000000000000000000000000000000..f2d880c64579900584a39986c72fd9f403592d70 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/05473457-76c8-4b85-b96c-561dc2ea15b1.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6dfa189ad631f2d42454b93b7016070158c9cfd0565b8903541e0ef9ba2f2224 +size 160436 diff --git a/.lancedb/model2_fixed.lance/data/0751f89b-3208-4faf-a7ac-0b7b6c65a162.lance b/.lancedb/model2_fixed.lance/data/0751f89b-3208-4faf-a7ac-0b7b6c65a162.lance new file mode 100644 index 0000000000000000000000000000000000000000..790e45b7d361bf5d170a7ca61b3104077d2309b1 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/0751f89b-3208-4faf-a7ac-0b7b6c65a162.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fb6a3990ca364d639441b33c6160046376d6cd46ae86ad39e0b6c4ca14d71c75 +size 46867 diff --git a/.lancedb/model2_fixed.lance/data/0e78e35f-062d-4c93-bc95-6b7674b2d591.lance b/.lancedb/model2_fixed.lance/data/0e78e35f-062d-4c93-bc95-6b7674b2d591.lance new file mode 100644 index 0000000000000000000000000000000000000000..624da12218891fd6618bb371daf90d0178fb7137 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/0e78e35f-062d-4c93-bc95-6b7674b2d591.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dbc1789abdb2862ab8b381f0550299fa0ae3f8a6a35c90af49837a619584539c +size 158917 diff --git a/.lancedb/model2_fixed.lance/data/10d6eb55-219c-4d13-9871-ef67e1e70227.lance b/.lancedb/model2_fixed.lance/data/10d6eb55-219c-4d13-9871-ef67e1e70227.lance new file mode 100644 index 0000000000000000000000000000000000000000..86f7077c1d9f63cd5af99399d56d0b1e2fb86b89 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/10d6eb55-219c-4d13-9871-ef67e1e70227.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2e96549ba0d89eb0241e2c3ab226e7d2c552b58662697aabd6279f7929a716ec +size 162947 diff --git a/.lancedb/model2_fixed.lance/data/12d0b8d6-3f91-4591-903f-976ea16bc33e.lance b/.lancedb/model2_fixed.lance/data/12d0b8d6-3f91-4591-903f-976ea16bc33e.lance new file mode 100644 index 0000000000000000000000000000000000000000..67cfacaaca8556ddf5874f4abd1e91672ea7c134 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/12d0b8d6-3f91-4591-903f-976ea16bc33e.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ed98c74774af92cb14d4ab0f30f6a9784423ec7d94f05f1dd315b599487c0742 +size 157649 diff --git a/.lancedb/model2_fixed.lance/data/183e2eef-3f64-42fd-8632-e2567091d076.lance b/.lancedb/model2_fixed.lance/data/183e2eef-3f64-42fd-8632-e2567091d076.lance new file mode 100644 index 0000000000000000000000000000000000000000..a078027fc3e07c82b25a94f6edd3f08014f40cc7 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/183e2eef-3f64-42fd-8632-e2567091d076.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9410d1b5448e6933dd36e5dcd17ba13c98831e144c14ea0021b9672d6eb006f4 +size 158196 diff --git a/.lancedb/model2_fixed.lance/data/18f4e862-8d9b-411c-b7e4-ec6f26bb40a7.lance b/.lancedb/model2_fixed.lance/data/18f4e862-8d9b-411c-b7e4-ec6f26bb40a7.lance new file mode 100644 index 0000000000000000000000000000000000000000..18e149a7ac6c1e17efa9671e12a1d7fe96c01218 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/18f4e862-8d9b-411c-b7e4-ec6f26bb40a7.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ed0fa435c960ba26e24a8747c8e7393acaa5a2a860d45bc2bbe0e9736b9e82ec +size 161702 diff --git a/.lancedb/model2_fixed.lance/data/224f1dab-0bf8-43c7-ba0d-ac8765bc2e4b.lance b/.lancedb/model2_fixed.lance/data/224f1dab-0bf8-43c7-ba0d-ac8765bc2e4b.lance new file mode 100644 index 0000000000000000000000000000000000000000..81482c073ba9cd03e706ea16300f28be5c92e4f3 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/224f1dab-0bf8-43c7-ba0d-ac8765bc2e4b.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:04ec89b104527cdd58cc007375d7e31eddfc057a4b9088c77b33bcfb334bd01d +size 165093 diff --git a/.lancedb/model2_fixed.lance/data/22f740bf-34d2-448e-9052-5b00a23e5c9c.lance b/.lancedb/model2_fixed.lance/data/22f740bf-34d2-448e-9052-5b00a23e5c9c.lance new file mode 100644 index 0000000000000000000000000000000000000000..7963ece1494131e1f6b952a4e5b7ee9320d4ed30 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/22f740bf-34d2-448e-9052-5b00a23e5c9c.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8dc77adb904cd5c9703758d3a911860572d28808459290e3a8e2a434d832e456 +size 164259 diff --git a/.lancedb/model2_fixed.lance/data/2423771b-94d2-4c85-8ba1-14dd885af074.lance b/.lancedb/model2_fixed.lance/data/2423771b-94d2-4c85-8ba1-14dd885af074.lance new file mode 100644 index 0000000000000000000000000000000000000000..85a5820fd59e414bff40a344f13c4e9d9e0c11d4 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/2423771b-94d2-4c85-8ba1-14dd885af074.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:85dfcb96b5c5382ee79f871f0e2ad4874fa8c7a1f65dd8e4b8552777a7cec7d9 +size 168966 diff --git a/.lancedb/model2_fixed.lance/data/28c79a56-d307-4aa0-a2f9-59a1c1b9c144.lance b/.lancedb/model2_fixed.lance/data/28c79a56-d307-4aa0-a2f9-59a1c1b9c144.lance new file mode 100644 index 0000000000000000000000000000000000000000..303947f8a77ba4c7c3915a09a8fe19139861c897 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/28c79a56-d307-4aa0-a2f9-59a1c1b9c144.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b272087c36996461ca33d65f53a58ee5e9eba50042f869bddab5940ee24902e6 +size 165231 diff --git a/.lancedb/model2_fixed.lance/data/2a5f5543-8015-4c07-8d2b-142a6c5bf181.lance b/.lancedb/model2_fixed.lance/data/2a5f5543-8015-4c07-8d2b-142a6c5bf181.lance new file mode 100644 index 0000000000000000000000000000000000000000..752f456cea9b415e6f1a285ed351e70acb363c13 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/2a5f5543-8015-4c07-8d2b-142a6c5bf181.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a365cfdd81af8213d10cf222481e507fe0c196ff1389c22e6f6431867902d507 +size 162482 diff --git a/.lancedb/model2_fixed.lance/data/2cb28a5a-f1bf-4488-a45d-a7837bfdb5a5.lance b/.lancedb/model2_fixed.lance/data/2cb28a5a-f1bf-4488-a45d-a7837bfdb5a5.lance new file mode 100644 index 0000000000000000000000000000000000000000..aa7dc6185309747af73e333f6264b71cb7e32fc5 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/2cb28a5a-f1bf-4488-a45d-a7837bfdb5a5.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e5c4e16c2c7f3e84b88b4d4fce1789403efd862abc417083d8e419875cc7ca9c +size 164369 diff --git a/.lancedb/model2_fixed.lance/data/37cec7ca-48f2-4d68-b11c-306ca7aed2c5.lance b/.lancedb/model2_fixed.lance/data/37cec7ca-48f2-4d68-b11c-306ca7aed2c5.lance new file mode 100644 index 0000000000000000000000000000000000000000..78f3a4f9965d38e55bf418598a779032baa9e4e5 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/37cec7ca-48f2-4d68-b11c-306ca7aed2c5.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:76d5332cf3c45a935465a0a5849af91b7ed1c179caadb9327faee2f3ac9f5a81 +size 164893 diff --git a/.lancedb/model2_fixed.lance/data/3a5552e3-1e5f-48ae-ba48-afc4f8e27ec1.lance b/.lancedb/model2_fixed.lance/data/3a5552e3-1e5f-48ae-ba48-afc4f8e27ec1.lance new file mode 100644 index 0000000000000000000000000000000000000000..e1dde1952116267518f0b4bbfc8877dc060eda13 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/3a5552e3-1e5f-48ae-ba48-afc4f8e27ec1.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:726a435aee8fbcaaaa293d6064cd716d7e1b70a28bccb899fd7fc64ae80de88f +size 169060 diff --git a/.lancedb/model2_fixed.lance/data/3ef67558-4cee-4b0a-af90-c6378f589233.lance b/.lancedb/model2_fixed.lance/data/3ef67558-4cee-4b0a-af90-c6378f589233.lance new file mode 100644 index 0000000000000000000000000000000000000000..584042c0c49fd3092daba6e00c269652796258f4 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/3ef67558-4cee-4b0a-af90-c6378f589233.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:893dfd80f81a23b235c357916bc8620d3dad166456b2288198fdf3154c15cbfe +size 166026 diff --git a/.lancedb/model2_fixed.lance/data/40625c41-aa73-4576-914e-10b386bd8508.lance b/.lancedb/model2_fixed.lance/data/40625c41-aa73-4576-914e-10b386bd8508.lance new file mode 100644 index 0000000000000000000000000000000000000000..e166eead58108d54b8a5ed0942ddc8f5e22412e8 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/40625c41-aa73-4576-914e-10b386bd8508.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3ac77e413b9dcf5a8cf5e86ba1e1dabb1a49f35659a3997ce9315b7ca1368906 +size 155990 diff --git a/.lancedb/model2_fixed.lance/data/4092ea21-35ff-406f-9353-815d971b4c90.lance b/.lancedb/model2_fixed.lance/data/4092ea21-35ff-406f-9353-815d971b4c90.lance new file mode 100644 index 0000000000000000000000000000000000000000..d2cf005ea6b7bcbd6c971dabfbd0da68c5d325ec --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/4092ea21-35ff-406f-9353-815d971b4c90.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:93f61411902468fbc54a42e2e58c267ebe10464e734368992f11cb05716b3f7f +size 162078 diff --git a/.lancedb/model2_fixed.lance/data/41bc08b4-0434-490c-a2d5-1c66cf2d06a7.lance b/.lancedb/model2_fixed.lance/data/41bc08b4-0434-490c-a2d5-1c66cf2d06a7.lance new file mode 100644 index 0000000000000000000000000000000000000000..4aea7cf8a1f0acd28813784ad5d1f0994f4f4145 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/41bc08b4-0434-490c-a2d5-1c66cf2d06a7.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e5bba337996a1ccb2541ac558a56015266f40950d9024a5c64414b554937c821 +size 165368 diff --git a/.lancedb/model2_fixed.lance/data/47c6509f-c1cf-4fc8-a3f6-3327d328ffe7.lance b/.lancedb/model2_fixed.lance/data/47c6509f-c1cf-4fc8-a3f6-3327d328ffe7.lance new file mode 100644 index 0000000000000000000000000000000000000000..7803ec365335ad5e7e49dff28be0084900f9880d --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/47c6509f-c1cf-4fc8-a3f6-3327d328ffe7.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fee3d252bd1d62a812cadd2642a37a24367f8c16ed977f04bc386e7f74d9cc26 +size 163396 diff --git a/.lancedb/model2_fixed.lance/data/4bd9c8eb-1134-46e6-b614-926b81548bf6.lance b/.lancedb/model2_fixed.lance/data/4bd9c8eb-1134-46e6-b614-926b81548bf6.lance new file mode 100644 index 0000000000000000000000000000000000000000..00809a762ae50aa9bf4f43ec8f47fbf671fbf773 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/4bd9c8eb-1134-46e6-b614-926b81548bf6.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8171afb5850429e0161de64dbf7beb2569e924fc3e52d3016dc7ac7cf514d91c +size 159633 diff --git a/.lancedb/model2_fixed.lance/data/4deb4ae6-f954-445e-bc88-f1fc185a3d15.lance b/.lancedb/model2_fixed.lance/data/4deb4ae6-f954-445e-bc88-f1fc185a3d15.lance new file mode 100644 index 0000000000000000000000000000000000000000..044cc48a0fff448ef0abfd74aba215b93f4291ec --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/4deb4ae6-f954-445e-bc88-f1fc185a3d15.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:60585b6d533c31284562ec0edf5036d2aa25b1792a12407b3e3fbecb068de29a +size 162618 diff --git a/.lancedb/model2_fixed.lance/data/4e14363b-eaaa-48a1-9c61-97a43eca9759.lance b/.lancedb/model2_fixed.lance/data/4e14363b-eaaa-48a1-9c61-97a43eca9759.lance new file mode 100644 index 0000000000000000000000000000000000000000..df66c142f7d246cb2b8b74cdcf3e7a0e29d6dce1 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/4e14363b-eaaa-48a1-9c61-97a43eca9759.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:26b6471eaf6c1864e92bbe81c798d55e371bbb64cb87f857fac353e56ba2e794 +size 161008 diff --git a/.lancedb/model2_fixed.lance/data/4f4c9813-e7ea-48fc-b42f-cf3d5de01e0c.lance b/.lancedb/model2_fixed.lance/data/4f4c9813-e7ea-48fc-b42f-cf3d5de01e0c.lance new file mode 100644 index 0000000000000000000000000000000000000000..c9fc9bfe02607f5d89dee3527a0185ab92367a4e --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/4f4c9813-e7ea-48fc-b42f-cf3d5de01e0c.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d2f4718bf651008798c3fde9d85b0141ed03658dae793a3cdf27b0b22f51ad98 +size 156767 diff --git a/.lancedb/model2_fixed.lance/data/50100a27-245e-4296-80f3-dcec414ae28f.lance b/.lancedb/model2_fixed.lance/data/50100a27-245e-4296-80f3-dcec414ae28f.lance new file mode 100644 index 0000000000000000000000000000000000000000..0faa01f28541e05eb081065b4283d683b95d31db --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/50100a27-245e-4296-80f3-dcec414ae28f.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aed01ca0a58595e0a7cd7597d4fe5b2b8d8edfc9b0fda19e5ab446f814cf1897 +size 168482 diff --git a/.lancedb/model2_fixed.lance/data/5045d097-13ef-40f3-b720-d7751d158876.lance b/.lancedb/model2_fixed.lance/data/5045d097-13ef-40f3-b720-d7751d158876.lance new file mode 100644 index 0000000000000000000000000000000000000000..2a093d737330510d23cfd685f5b13081b2bad797 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/5045d097-13ef-40f3-b720-d7751d158876.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ecbcb43311bfa45f08917b32a7108b6b9e1084b65a41f32b866bd306b6555013 +size 164232 diff --git a/.lancedb/model2_fixed.lance/data/51df9218-33cb-4cb5-b602-421dfc04e464.lance b/.lancedb/model2_fixed.lance/data/51df9218-33cb-4cb5-b602-421dfc04e464.lance new file mode 100644 index 0000000000000000000000000000000000000000..083f3f15a34ae1f749c51a614ceb50326598e4b0 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/51df9218-33cb-4cb5-b602-421dfc04e464.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8decbcc2998c9026dc011d74e6fc30f7be664ffd823e5f936e9a822a63731786 +size 162087 diff --git a/.lancedb/model2_fixed.lance/data/530ebc9e-ec98-4826-ab07-aa42bdb2ebcc.lance b/.lancedb/model2_fixed.lance/data/530ebc9e-ec98-4826-ab07-aa42bdb2ebcc.lance new file mode 100644 index 0000000000000000000000000000000000000000..4eed1351f98c83d8478980c522e994383c9c9e59 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/530ebc9e-ec98-4826-ab07-aa42bdb2ebcc.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7a72135ccb5e2f6bde4c88101b3689a3fa5ce8d61aec6fa78974a5db800a08eb +size 166399 diff --git a/.lancedb/model2_fixed.lance/data/5476c0c5-d10a-4362-b8d2-468454adc00b.lance b/.lancedb/model2_fixed.lance/data/5476c0c5-d10a-4362-b8d2-468454adc00b.lance new file mode 100644 index 0000000000000000000000000000000000000000..940c6ba69a809a67e48bc63fe7bd1325ef8eca62 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/5476c0c5-d10a-4362-b8d2-468454adc00b.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:836bf5ca8e1a534f10126542e03080a9c4956205fc9ec45b3792361b4f080534 +size 159670 diff --git a/.lancedb/model2_fixed.lance/data/55fd1b61-2d53-47de-b69f-3da298662441.lance b/.lancedb/model2_fixed.lance/data/55fd1b61-2d53-47de-b69f-3da298662441.lance new file mode 100644 index 0000000000000000000000000000000000000000..890084866757de7276acb53af36190392ed35021 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/55fd1b61-2d53-47de-b69f-3da298662441.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b4165498ea502d01d892176274b71116cd231998a695e474e5a08deca552874f +size 160783 diff --git a/.lancedb/model2_fixed.lance/data/573dd9e5-6b7d-4ad3-9d60-d9c7afb8b6b9.lance b/.lancedb/model2_fixed.lance/data/573dd9e5-6b7d-4ad3-9d60-d9c7afb8b6b9.lance new file mode 100644 index 0000000000000000000000000000000000000000..32f7f46e2acd18a454fb2ae90011bada090e93de --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/573dd9e5-6b7d-4ad3-9d60-d9c7afb8b6b9.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7e99270e6f8b938a2f6f34beb03f41aa4af32d927dd01865965108d4d3f1be73 +size 158418 diff --git a/.lancedb/model2_fixed.lance/data/5c94eff1-005e-4fe9-a40a-17aed2d79946.lance b/.lancedb/model2_fixed.lance/data/5c94eff1-005e-4fe9-a40a-17aed2d79946.lance new file mode 100644 index 0000000000000000000000000000000000000000..ae752d5a6d51b97e429104f76a201332d8c464d2 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/5c94eff1-005e-4fe9-a40a-17aed2d79946.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3bb6d32de2d8f2da6a3d1f50d171a8aae305546fc00989996d9f0856c3e385cf +size 166833 diff --git a/.lancedb/model2_fixed.lance/data/5f0f288c-58dc-46d5-8962-082795c602e8.lance b/.lancedb/model2_fixed.lance/data/5f0f288c-58dc-46d5-8962-082795c602e8.lance new file mode 100644 index 0000000000000000000000000000000000000000..3219cfc02e209f8f1a528fbf80df3a0b32b699f6 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/5f0f288c-58dc-46d5-8962-082795c602e8.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f8fe307bb7c1208db629a96fc2bd6223e196a8eb09f3cfee4df6052f78708571 +size 163998 diff --git a/.lancedb/model2_fixed.lance/data/6634c95d-e5d0-44f9-8cc2-857d2d82e6d6.lance b/.lancedb/model2_fixed.lance/data/6634c95d-e5d0-44f9-8cc2-857d2d82e6d6.lance new file mode 100644 index 0000000000000000000000000000000000000000..44f13a5b17ff0daaf089f44b97493ef7d47e181c --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/6634c95d-e5d0-44f9-8cc2-857d2d82e6d6.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:21c1fbd02d70a9dbc465fc78636a24bafab99f7704a5b56e760e1e7b1fb4e100 +size 164639 diff --git a/.lancedb/model2_fixed.lance/data/67a6f288-2196-4c0d-ab64-b05395fac0dd.lance b/.lancedb/model2_fixed.lance/data/67a6f288-2196-4c0d-ab64-b05395fac0dd.lance new file mode 100644 index 0000000000000000000000000000000000000000..2d8d08760f91c59968bff7e5ab232899c1c7a8b4 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/67a6f288-2196-4c0d-ab64-b05395fac0dd.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:19227ece30d14658b3f4fa9eda492c2c37f751dff4ec4f2a29c48aa326a1f132 +size 167982 diff --git a/.lancedb/model2_fixed.lance/data/6b7b6410-5088-4e94-ba9f-ebd7804d40c5.lance b/.lancedb/model2_fixed.lance/data/6b7b6410-5088-4e94-ba9f-ebd7804d40c5.lance new file mode 100644 index 0000000000000000000000000000000000000000..09ee474c6e40d1906e73d51997d4393d0cadcbbf --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/6b7b6410-5088-4e94-ba9f-ebd7804d40c5.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:92ff36ac15ef7feeaf4f774185bc244193d7483b5322efe809cae60917988f75 +size 167499 diff --git a/.lancedb/model2_fixed.lance/data/6f96a677-c7f2-4c54-b87a-9cce48311f54.lance b/.lancedb/model2_fixed.lance/data/6f96a677-c7f2-4c54-b87a-9cce48311f54.lance new file mode 100644 index 0000000000000000000000000000000000000000..38db920e9773b6ed01183162b0f6f6175eddbc55 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/6f96a677-c7f2-4c54-b87a-9cce48311f54.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:93556d86959c0307bbb3651c7ccbfd50114b9fb9c2df32b63c86b22fb387b5d8 +size 167142 diff --git a/.lancedb/model2_fixed.lance/data/7034efda-baf6-490b-9bad-b4b3718e8107.lance b/.lancedb/model2_fixed.lance/data/7034efda-baf6-490b-9bad-b4b3718e8107.lance new file mode 100644 index 0000000000000000000000000000000000000000..d098edfc2907618b8a35f45c11257c474ba01560 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/7034efda-baf6-490b-9bad-b4b3718e8107.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:64489b281036634c15944819d8f91f9852fa4178ffd5395d88e38ad37cdd4811 +size 160283 diff --git a/.lancedb/model2_fixed.lance/data/7390a8fd-17ce-4a31-8578-1fd31d95abb8.lance b/.lancedb/model2_fixed.lance/data/7390a8fd-17ce-4a31-8578-1fd31d95abb8.lance new file mode 100644 index 0000000000000000000000000000000000000000..8aa20c7f931731bc5d02bad2bfbc795e6fc5be93 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/7390a8fd-17ce-4a31-8578-1fd31d95abb8.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3a2b8e73a00fc6ef490ea793c717647ed721e6c6a59b57632ce4d7937061d09d +size 167618 diff --git a/.lancedb/model2_fixed.lance/data/739babcf-a885-40f8-8a80-898d1363cc08.lance b/.lancedb/model2_fixed.lance/data/739babcf-a885-40f8-8a80-898d1363cc08.lance new file mode 100644 index 0000000000000000000000000000000000000000..c2cc8ba78c787729a0bf40df09040f8d8603d823 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/739babcf-a885-40f8-8a80-898d1363cc08.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4b5c9ee06230436630dafb553c9acede7bfff1b56920c8d28771265962813cb +size 176083 diff --git a/.lancedb/model2_fixed.lance/data/74894780-4f9e-4832-a4c8-1b479f1a26f3.lance b/.lancedb/model2_fixed.lance/data/74894780-4f9e-4832-a4c8-1b479f1a26f3.lance new file mode 100644 index 0000000000000000000000000000000000000000..c55d5a675b1404054f78c36fce8552448f3c5b95 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/74894780-4f9e-4832-a4c8-1b479f1a26f3.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9aedb21f6e855ac8fd12b4e1caad24223c65e8e0db22826c277998c7c0298fb5 +size 162930 diff --git a/.lancedb/model2_fixed.lance/data/7776ce94-b062-43bb-8a0b-18717f5edab4.lance b/.lancedb/model2_fixed.lance/data/7776ce94-b062-43bb-8a0b-18717f5edab4.lance new file mode 100644 index 0000000000000000000000000000000000000000..ebaffded3f7378974d0ae20c723f1bf82d8a0abd --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/7776ce94-b062-43bb-8a0b-18717f5edab4.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:26c2d38d68f58d97135c023cc609a3079531d046c58de6beb5df4c1f683786a6 +size 161322 diff --git a/.lancedb/model2_fixed.lance/data/7bfb05ea-a973-4c8c-a645-08a76d1539e8.lance b/.lancedb/model2_fixed.lance/data/7bfb05ea-a973-4c8c-a645-08a76d1539e8.lance new file mode 100644 index 0000000000000000000000000000000000000000..4ea56cb7dadc6d507021ac10cf510db2e1a9d1d7 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/7bfb05ea-a973-4c8c-a645-08a76d1539e8.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:345a21fb59d4b28947997eee342f34a11f1f020d3ee8349502c5960da2bb805f +size 163614 diff --git a/.lancedb/model2_fixed.lance/data/7fe1c43e-867b-44b2-a017-58bf0472a2fd.lance b/.lancedb/model2_fixed.lance/data/7fe1c43e-867b-44b2-a017-58bf0472a2fd.lance new file mode 100644 index 0000000000000000000000000000000000000000..14844fcd7eff7e4b9b912aef2c949b73356b23f8 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/7fe1c43e-867b-44b2-a017-58bf0472a2fd.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:203b46d0e6cd90f61b24f9ea95b5729b4c4a0256b722336da586ef20f97fe27e +size 158079 diff --git a/.lancedb/model2_fixed.lance/data/83b4f65b-f860-49b6-a077-4728243530f7.lance b/.lancedb/model2_fixed.lance/data/83b4f65b-f860-49b6-a077-4728243530f7.lance new file mode 100644 index 0000000000000000000000000000000000000000..00096130a5eb71bd3c03ed5015af9365f3cd7906 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/83b4f65b-f860-49b6-a077-4728243530f7.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f894e5491c65154656bb29d247791e9ae5eeec48f37c4041f59e52808ac378ad +size 167885 diff --git a/.lancedb/model2_fixed.lance/data/83cf507f-ee59-4cf6-8e9c-71a3562543b7.lance b/.lancedb/model2_fixed.lance/data/83cf507f-ee59-4cf6-8e9c-71a3562543b7.lance new file mode 100644 index 0000000000000000000000000000000000000000..5398cc06127955c7ba7e3dfc3bedb2b4ddf7bc63 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/83cf507f-ee59-4cf6-8e9c-71a3562543b7.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6dbd939048ccf7c353f1a2dad992ea95b25899ae99d6cd4b0ec5da5dfc30c87f +size 158396 diff --git a/.lancedb/model2_fixed.lance/data/8514c953-6f28-47f0-9199-c3b2956d9d7f.lance b/.lancedb/model2_fixed.lance/data/8514c953-6f28-47f0-9199-c3b2956d9d7f.lance new file mode 100644 index 0000000000000000000000000000000000000000..243bcacbc4ca98961778b1966751dac6cf83790e --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/8514c953-6f28-47f0-9199-c3b2956d9d7f.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:130f27945561ac1847368246cce89230e2b64dc41e35f10d243d8da49c619edd +size 157477 diff --git a/.lancedb/model2_fixed.lance/data/89ce1258-bea8-42b4-9271-2f41bb5461b5.lance b/.lancedb/model2_fixed.lance/data/89ce1258-bea8-42b4-9271-2f41bb5461b5.lance new file mode 100644 index 0000000000000000000000000000000000000000..fc1be0ce4c8448c4e23ecac5a01ae5a54858a6e6 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/89ce1258-bea8-42b4-9271-2f41bb5461b5.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:35b3b518762f3b71cfaf9248db4166569affc39880ce96359ac79279a522c8a2 +size 164381 diff --git a/.lancedb/model2_fixed.lance/data/8b40e7b8-443d-4ae3-992c-0dec68973ce4.lance b/.lancedb/model2_fixed.lance/data/8b40e7b8-443d-4ae3-992c-0dec68973ce4.lance new file mode 100644 index 0000000000000000000000000000000000000000..4fe1276fbdc298c4307d551960d2e68e38464582 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/8b40e7b8-443d-4ae3-992c-0dec68973ce4.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:30bdd2dc08abdf18e244a0adf3c49dbe63c3d6457355bd282244dead36977904 +size 163290 diff --git a/.lancedb/model2_fixed.lance/data/93db4b58-36cd-4ffe-aa78-9ca8ebf91894.lance b/.lancedb/model2_fixed.lance/data/93db4b58-36cd-4ffe-aa78-9ca8ebf91894.lance new file mode 100644 index 0000000000000000000000000000000000000000..a361b0c63933929311518f222302b1aa431c8e01 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/93db4b58-36cd-4ffe-aa78-9ca8ebf91894.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d16aa7e174dca6077c8fde57ad53710fc5b0e18b442f3e7fd443a8e58b4cf5e3 +size 163355 diff --git a/.lancedb/model2_fixed.lance/data/9a98bd97-5bc6-407f-b5f7-6e5fdcb5188b.lance b/.lancedb/model2_fixed.lance/data/9a98bd97-5bc6-407f-b5f7-6e5fdcb5188b.lance new file mode 100644 index 0000000000000000000000000000000000000000..e5f953511339b9ab97cbd4b3f6b84cdb5ed52d1b --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/9a98bd97-5bc6-407f-b5f7-6e5fdcb5188b.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cdfa2372c33f7756f086cd044b32efeebce1aee67925b385fa9a2419d59ee48c +size 168003 diff --git a/.lancedb/model2_fixed.lance/data/9f87e728-0e77-4496-a94a-b7d30c09ea1d.lance b/.lancedb/model2_fixed.lance/data/9f87e728-0e77-4496-a94a-b7d30c09ea1d.lance new file mode 100644 index 0000000000000000000000000000000000000000..41a37327e2e5b9c7d267a396eba45425e9528670 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/9f87e728-0e77-4496-a94a-b7d30c09ea1d.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3c37cc55db50b83a742f58036f8f6d6ee4a62dd66d812723cd04d684e7508425 +size 161586 diff --git a/.lancedb/model2_fixed.lance/data/a1d39316-a11b-4448-b1e6-901c3de5b2a7.lance b/.lancedb/model2_fixed.lance/data/a1d39316-a11b-4448-b1e6-901c3de5b2a7.lance new file mode 100644 index 0000000000000000000000000000000000000000..28fdcfd5abf97683fab98b467ef6b120950129cd --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/a1d39316-a11b-4448-b1e6-901c3de5b2a7.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4d60b751a37f5284806a6552215b50a1959f18545cb0e9fad3b134d1064ed520 +size 161447 diff --git a/.lancedb/model2_fixed.lance/data/a1fb2f57-3302-4ee4-96d3-7bf0a1bae7d0.lance b/.lancedb/model2_fixed.lance/data/a1fb2f57-3302-4ee4-96d3-7bf0a1bae7d0.lance new file mode 100644 index 0000000000000000000000000000000000000000..ac062e00b739bedadbdde5986fef4412fdfd93e3 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/a1fb2f57-3302-4ee4-96d3-7bf0a1bae7d0.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d9680345eea6d20d72bcc2ba326d2a1a04f2d09626d159b18145ca759dde7e0b +size 156677 diff --git a/.lancedb/model2_fixed.lance/data/a2a1b901-7e1c-4dc6-836c-e5dff366732b.lance b/.lancedb/model2_fixed.lance/data/a2a1b901-7e1c-4dc6-836c-e5dff366732b.lance new file mode 100644 index 0000000000000000000000000000000000000000..463f659bf21ac07975a2384a909d307f5a5d41b8 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/a2a1b901-7e1c-4dc6-836c-e5dff366732b.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f861ae144608df2c09e4ed45ced91435e61731146de2596c35aab37b24912729 +size 164008 diff --git a/.lancedb/model2_fixed.lance/data/a4f9dcd8-d1d1-4c5d-8736-e34ac5133df3.lance b/.lancedb/model2_fixed.lance/data/a4f9dcd8-d1d1-4c5d-8736-e34ac5133df3.lance new file mode 100644 index 0000000000000000000000000000000000000000..cbbf7a2d3a2c89ac101cab629c91889e1ab34e20 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/a4f9dcd8-d1d1-4c5d-8736-e34ac5133df3.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b8611c104d8cf8b82b518a031efcb562a894fb72bf6eb30d384df804d18d9e7e +size 164461 diff --git a/.lancedb/model2_fixed.lance/data/a613c46c-4ebd-475c-9d1c-71e5b1f6d11f.lance b/.lancedb/model2_fixed.lance/data/a613c46c-4ebd-475c-9d1c-71e5b1f6d11f.lance new file mode 100644 index 0000000000000000000000000000000000000000..a245c1a679c01a2a6cce885fe2050889653603e6 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/a613c46c-4ebd-475c-9d1c-71e5b1f6d11f.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:947e20dfd8b3c68cbf1cdc2da78d3610e2846b2dc2ee171490fe67e72df2b01b +size 163546 diff --git a/.lancedb/model2_fixed.lance/data/a93dc834-ce05-4cfa-952e-42f4625c1ed5.lance b/.lancedb/model2_fixed.lance/data/a93dc834-ce05-4cfa-952e-42f4625c1ed5.lance new file mode 100644 index 0000000000000000000000000000000000000000..78c30f53c9d631c52481941a0b00da77c6231484 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/a93dc834-ce05-4cfa-952e-42f4625c1ed5.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d6766cc900db33276e849731d411e2ccee2c6800df9aad60ed0daa74fec76630 +size 159184 diff --git a/.lancedb/model2_fixed.lance/data/aa217f85-e61d-4bf6-8cf6-938e9ee1e250.lance b/.lancedb/model2_fixed.lance/data/aa217f85-e61d-4bf6-8cf6-938e9ee1e250.lance new file mode 100644 index 0000000000000000000000000000000000000000..a0dfb13c3b11dffc9d0d109945609427b3a52fb0 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/aa217f85-e61d-4bf6-8cf6-938e9ee1e250.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a48ed03433d143ee88a394f67b2f0619d6e4e894ed65be792a6563f4199cc9c5 +size 159745 diff --git a/.lancedb/model2_fixed.lance/data/ae6e0214-1f0d-4c4c-9845-cc6047395694.lance b/.lancedb/model2_fixed.lance/data/ae6e0214-1f0d-4c4c-9845-cc6047395694.lance new file mode 100644 index 0000000000000000000000000000000000000000..2e3aceb9ad8a8763a70fc3609a5d8f603c072da4 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/ae6e0214-1f0d-4c4c-9845-cc6047395694.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d18f73706e73315c6cc3080b406f982e227fff1bf9013af46689bb11163a6cc3 +size 168430 diff --git a/.lancedb/model2_fixed.lance/data/afe0dbb1-a5a5-41a0-91a5-18ed41e3a1d5.lance b/.lancedb/model2_fixed.lance/data/afe0dbb1-a5a5-41a0-91a5-18ed41e3a1d5.lance new file mode 100644 index 0000000000000000000000000000000000000000..99e20fd414a7441756ffd02b61a2df9321c83226 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/afe0dbb1-a5a5-41a0-91a5-18ed41e3a1d5.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ea9533abcd958738c06dfb9d3ac45d27c073fdbb16705b9b7b3942bbfe09a9c4 +size 163626 diff --git a/.lancedb/model2_fixed.lance/data/b00a2d8a-7bd9-4082-86c6-33e2684ed94e.lance b/.lancedb/model2_fixed.lance/data/b00a2d8a-7bd9-4082-86c6-33e2684ed94e.lance new file mode 100644 index 0000000000000000000000000000000000000000..19d8420a0762211da159fa214c07d066da3f6819 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/b00a2d8a-7bd9-4082-86c6-33e2684ed94e.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:29f67bd2820e324e5e94143878c0a23a884dc2f9e7ba91410f8a3cc8ef5e91e2 +size 158663 diff --git a/.lancedb/model2_fixed.lance/data/b0bb1a51-3731-4f1b-9b2d-bcff0a30dd39.lance b/.lancedb/model2_fixed.lance/data/b0bb1a51-3731-4f1b-9b2d-bcff0a30dd39.lance new file mode 100644 index 0000000000000000000000000000000000000000..ff0ca64d15fafad21bd0d335cecbcd1c152bed67 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/b0bb1a51-3731-4f1b-9b2d-bcff0a30dd39.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ab88f4ee3322062611bfb4aa3277678ede497638f06d325d0ea39555854bdaa2 +size 157484 diff --git a/.lancedb/model2_fixed.lance/data/b5142bf4-89c0-4a02-a97d-95e4613ec100.lance b/.lancedb/model2_fixed.lance/data/b5142bf4-89c0-4a02-a97d-95e4613ec100.lance new file mode 100644 index 0000000000000000000000000000000000000000..b7add66fd0f98bd33af52926df5d6e1062ed1bc6 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/b5142bf4-89c0-4a02-a97d-95e4613ec100.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4eedc0dd9d383147701329c8141707d6fc5f22b7b7d59a7de2b2154445816ece +size 159984 diff --git a/.lancedb/model2_fixed.lance/data/bb22023a-8045-4c63-a6e4-4158e60e431e.lance b/.lancedb/model2_fixed.lance/data/bb22023a-8045-4c63-a6e4-4158e60e431e.lance new file mode 100644 index 0000000000000000000000000000000000000000..b9a330c2654372386b9236085f513be39f7f3d65 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/bb22023a-8045-4c63-a6e4-4158e60e431e.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b503f6a76a146346f1db0c880ab94e32c4ec7ea612a7f162643438c454d140f9 +size 157447 diff --git a/.lancedb/model2_fixed.lance/data/c335902f-698c-4c8e-a456-990ecaff1eba.lance b/.lancedb/model2_fixed.lance/data/c335902f-698c-4c8e-a456-990ecaff1eba.lance new file mode 100644 index 0000000000000000000000000000000000000000..1d7d9027291b21698c3a99e1946e788bc2808f13 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/c335902f-698c-4c8e-a456-990ecaff1eba.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:21dd004b704e90e708b01c5e3d84c4502b9fb74a79e82fa7309f7665d09ebaac +size 159490 diff --git a/.lancedb/model2_fixed.lance/data/c8923668-31fa-4d20-b9d8-f70bc0d5c90b.lance b/.lancedb/model2_fixed.lance/data/c8923668-31fa-4d20-b9d8-f70bc0d5c90b.lance new file mode 100644 index 0000000000000000000000000000000000000000..1ad3f10d7edc0e063843273812b2b7ca4f71a317 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/c8923668-31fa-4d20-b9d8-f70bc0d5c90b.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a3ddcc5a44c5c14dff4eea3b360321ad1ee6dddc4844a7ebca9982fa5101c1f8 +size 169727 diff --git a/.lancedb/model2_fixed.lance/data/c97a4969-8445-455d-8602-9a9409295866.lance b/.lancedb/model2_fixed.lance/data/c97a4969-8445-455d-8602-9a9409295866.lance new file mode 100644 index 0000000000000000000000000000000000000000..969cbebd25c484d3b2f44c2de81e6e2aed83f9d2 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/c97a4969-8445-455d-8602-9a9409295866.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c6ccfb81a19a7d9dea5e3ea234e341c6ae71ba23fb52f39c235c0db26d12dfaa +size 156823 diff --git a/.lancedb/model2_fixed.lance/data/ce120fb4-bc1a-4b1e-a098-af04fff63951.lance b/.lancedb/model2_fixed.lance/data/ce120fb4-bc1a-4b1e-a098-af04fff63951.lance new file mode 100644 index 0000000000000000000000000000000000000000..29b1a1474b74d9848f7f7e2b8c5eff26908ff196 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/ce120fb4-bc1a-4b1e-a098-af04fff63951.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:76ae44cbee7c9cf50ed87144a6ba043053aab7904de2c7af355077ba317b466f +size 159197 diff --git a/.lancedb/model2_fixed.lance/data/d250ca21-0ade-4f8d-9199-29b50bc93fb2.lance b/.lancedb/model2_fixed.lance/data/d250ca21-0ade-4f8d-9199-29b50bc93fb2.lance new file mode 100644 index 0000000000000000000000000000000000000000..82a94f2c46a72706045c7033bde6e80641ee8b34 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/d250ca21-0ade-4f8d-9199-29b50bc93fb2.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:933d7a932c908894917fbfec9e5a84dc906c61fa2f5f8a37fb02c500a93420a0 +size 182856 diff --git a/.lancedb/model2_fixed.lance/data/d2dde8a9-e90e-495a-bb72-691c99d81c6e.lance b/.lancedb/model2_fixed.lance/data/d2dde8a9-e90e-495a-bb72-691c99d81c6e.lance new file mode 100644 index 0000000000000000000000000000000000000000..f1677b4c26fb327bc7dae2661eb774571bfb506d --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/d2dde8a9-e90e-495a-bb72-691c99d81c6e.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5352b6bc405d7a2b3b1991d0df36eb833461ec3a0853ccc7bdf49f23ec295670 +size 163234 diff --git a/.lancedb/model2_fixed.lance/data/d9c91c31-3849-4951-aa22-736f1cc656eb.lance b/.lancedb/model2_fixed.lance/data/d9c91c31-3849-4951-aa22-736f1cc656eb.lance new file mode 100644 index 0000000000000000000000000000000000000000..cc8c198bda42cb1057300d45cdcefa7edf093892 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/d9c91c31-3849-4951-aa22-736f1cc656eb.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a1500a2f88ba417fdb0025ab6cc51d1baf4270ed0fe837162bd9f7a9b5c2cd9f +size 155946 diff --git a/.lancedb/model2_fixed.lance/data/dd56eb1f-9151-45fc-af7b-d3969427b91a.lance b/.lancedb/model2_fixed.lance/data/dd56eb1f-9151-45fc-af7b-d3969427b91a.lance new file mode 100644 index 0000000000000000000000000000000000000000..0054dea8b61df027c4e05b55457ae58bc8b17218 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/dd56eb1f-9151-45fc-af7b-d3969427b91a.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f3277a692b9252f53d22a0335f05726a90ff0c5e06fdc4eb7662f8ba9dc587cd +size 161449 diff --git a/.lancedb/model2_fixed.lance/data/e3ead8c2-5c25-47a6-a380-0a6c6d3f97eb.lance b/.lancedb/model2_fixed.lance/data/e3ead8c2-5c25-47a6-a380-0a6c6d3f97eb.lance new file mode 100644 index 0000000000000000000000000000000000000000..16ff9d36e66d9598616f798f7d6736623a7f3e02 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/e3ead8c2-5c25-47a6-a380-0a6c6d3f97eb.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e7aa2a9e426f5c813d9a115e285ed34e1f20ec07f9a67bd77a27dd9add38af29 +size 163217 diff --git a/.lancedb/model2_fixed.lance/data/e7aa8fc2-c62f-4999-b6ac-839f1717ea7c.lance b/.lancedb/model2_fixed.lance/data/e7aa8fc2-c62f-4999-b6ac-839f1717ea7c.lance new file mode 100644 index 0000000000000000000000000000000000000000..211640acebe3708ca7a21cf3393c19672d09db54 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/e7aa8fc2-c62f-4999-b6ac-839f1717ea7c.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d62bf890b818329148355788074c1a8cc5a7fa629b09f5164ddbd70769566328 +size 163470 diff --git a/.lancedb/model2_fixed.lance/data/e9e19be1-ed24-46ec-a6ac-030e95eeabd1.lance b/.lancedb/model2_fixed.lance/data/e9e19be1-ed24-46ec-a6ac-030e95eeabd1.lance new file mode 100644 index 0000000000000000000000000000000000000000..2a87e6a30dc8042770fb0529359b5ae963c7589e --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/e9e19be1-ed24-46ec-a6ac-030e95eeabd1.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dccb8620c87f490b5444cb738ef1f168d242c8689bdb3d5681dcae11d7b10f98 +size 161202 diff --git a/.lancedb/model2_fixed.lance/data/f34074d8-65f7-48fe-b162-1fed368c9178.lance b/.lancedb/model2_fixed.lance/data/f34074d8-65f7-48fe-b162-1fed368c9178.lance new file mode 100644 index 0000000000000000000000000000000000000000..19e527aa4f26a7dc6724abfcb1948154b4291982 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/f34074d8-65f7-48fe-b162-1fed368c9178.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:058f0e376196a8661a1295f6a2c35b7aa5d6e5f8b88d968b7dbf8aea523bb78c +size 168893 diff --git a/.lancedb/model2_fixed.lance/data/f5d8d4c3-c6b0-4aaf-a944-f4a825b039d9.lance b/.lancedb/model2_fixed.lance/data/f5d8d4c3-c6b0-4aaf-a944-f4a825b039d9.lance new file mode 100644 index 0000000000000000000000000000000000000000..db06ca6b4f4f5465e6deae75c6baf89aaa5f959f --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/f5d8d4c3-c6b0-4aaf-a944-f4a825b039d9.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:351047e8a88c21b81fc3f37948887ca79fbdddf9ec81e855f58fcb6214488f2b +size 169824 diff --git a/.lancedb/model2_fixed.lance/data/f86677a4-8dab-463a-a51d-93c1b7bc2c7a.lance b/.lancedb/model2_fixed.lance/data/f86677a4-8dab-463a-a51d-93c1b7bc2c7a.lance new file mode 100644 index 0000000000000000000000000000000000000000..3cdb1f4de8b65e3da1f54b9a33eff2df010f83a1 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/f86677a4-8dab-463a-a51d-93c1b7bc2c7a.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2c6e0ea55159780d090061d3ed9504cc588393a4cf1f126d833cd0f494d6d6c1 +size 161641 diff --git a/.lancedb/model2_fixed.lance/data/f8e5e605-2bc9-4fa2-8216-110b6441847f.lance b/.lancedb/model2_fixed.lance/data/f8e5e605-2bc9-4fa2-8216-110b6441847f.lance new file mode 100644 index 0000000000000000000000000000000000000000..c30ff692ffa1b1e1cef32b8a45271481a7a55405 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/f8e5e605-2bc9-4fa2-8216-110b6441847f.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ca15443a4a3f2fe679b230400c29fbda0e6527dfd6cb698b09a5a2a3e5c07fbf +size 161598 diff --git a/.lancedb/model2_fixed.lance/data/f9a4ce3c-be06-4251-9bc3-e59254f8691e.lance b/.lancedb/model2_fixed.lance/data/f9a4ce3c-be06-4251-9bc3-e59254f8691e.lance new file mode 100644 index 0000000000000000000000000000000000000000..42364527023891b8f4167de69ca1c5ad4d3152a7 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/f9a4ce3c-be06-4251-9bc3-e59254f8691e.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3d646574cec39ca443cd2766b8e98a6ceb767ba661a81e5cdc05bd6970f47143 +size 162351 diff --git a/.lancedb/model2_fixed.lance/data/fb229c76-2591-4fe0-ad38-72c29d8e1353.lance b/.lancedb/model2_fixed.lance/data/fb229c76-2591-4fe0-ad38-72c29d8e1353.lance new file mode 100644 index 0000000000000000000000000000000000000000..f329113534e4f59b31b2ba17cc178619f5ef0fc3 --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/fb229c76-2591-4fe0-ad38-72c29d8e1353.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:73917330e67f089c17cb87a124ebd0f50ba4606a24105339aabcd4332f556191 +size 160374 diff --git a/.lancedb/model2_fixed.lance/data/fbe9cf1b-6096-45ae-88ca-bc425a8ab633.lance b/.lancedb/model2_fixed.lance/data/fbe9cf1b-6096-45ae-88ca-bc425a8ab633.lance new file mode 100644 index 0000000000000000000000000000000000000000..2fa76372426ebef7d20b1127d292c0bbd4671dcb --- /dev/null +++ b/.lancedb/model2_fixed.lance/data/fbe9cf1b-6096-45ae-88ca-bc425a8ab633.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fc9b1648c455562360063823051f3be883deca3da1261152e98e1f33c4310703 +size 160540 diff --git a/.lancedb/model3_fixed.lance/_indices/b875f5df-9571-488d-8e81-5844dd99faf9/index.idx b/.lancedb/model3_fixed.lance/_indices/b875f5df-9571-488d-8e81-5844dd99faf9/index.idx new file mode 100644 index 0000000000000000000000000000000000000000..5443ed35bb453ea3e5f2365418b20907f3b933a9 --- /dev/null +++ b/.lancedb/model3_fixed.lance/_indices/b875f5df-9571-488d-8e81-5844dd99faf9/index.idx @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1f66ee59d47b330f314fe1c2571373284c0f5c3050b0e4490b1d075ba7840a3d +size 3265152 diff --git a/.lancedb/model3_fixed.lance/_transactions/0-f9a2885d-bd7d-42ec-a710-609db4ff1eca.txn b/.lancedb/model3_fixed.lance/_transactions/0-f9a2885d-bd7d-42ec-a710-609db4ff1eca.txn new file mode 100644 index 0000000000000000000000000000000000000000..fc99939c8dcb2af00295a6812187bfb42d6f4c8e --- /dev/null +++ b/.lancedb/model3_fixed.lance/_transactions/0-f9a2885d-bd7d-42ec-a710-609db4ff1eca.txn @@ -0,0 +1 @@ +$f9a2885d-bd7d-42ec-a710-609db4ff1eca²V3vector ÿÿÿÿÿÿÿÿÿ*fixed_size_list:float:153608text ÿÿÿÿÿÿÿÿÿ*string08 \ No newline at end of file diff --git a/.lancedb/model3_fixed.lance/_transactions/1-229f1a48-40d8-4eeb-b256-a6941093f010.txn b/.lancedb/model3_fixed.lance/_transactions/1-229f1a48-40d8-4eeb-b256-a6941093f010.txn new file mode 100644 index 0000000000000000000000000000000000000000..13439fac3e64f5db24c548beb9d015f952a57d0a Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/1-229f1a48-40d8-4eeb-b256-a6941093f010.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/10-cd9304cf-8774-4904-b26a-d3386237f76a.txn b/.lancedb/model3_fixed.lance/_transactions/10-cd9304cf-8774-4904-b26a-d3386237f76a.txn new file mode 100644 index 0000000000000000000000000000000000000000..75a5b80baf29c38f3cc8e73d9ea27989dd11557f Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/10-cd9304cf-8774-4904-b26a-d3386237f76a.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/11-095db9cc-8ed7-44ce-ba8a-57b235ff5c8b.txn b/.lancedb/model3_fixed.lance/_transactions/11-095db9cc-8ed7-44ce-ba8a-57b235ff5c8b.txn new file mode 100644 index 0000000000000000000000000000000000000000..f19938af427e3bfd5a06533a51661157cd45b131 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/11-095db9cc-8ed7-44ce-ba8a-57b235ff5c8b.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/12-f26e7ed5-d106-42d3-82ca-4ba3b488812e.txn b/.lancedb/model3_fixed.lance/_transactions/12-f26e7ed5-d106-42d3-82ca-4ba3b488812e.txn new file mode 100644 index 0000000000000000000000000000000000000000..e612db09627a36ec899b3dd68ebae89ad7aa5eae Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/12-f26e7ed5-d106-42d3-82ca-4ba3b488812e.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/13-389298bf-0302-4d8b-9398-606a96588c22.txn b/.lancedb/model3_fixed.lance/_transactions/13-389298bf-0302-4d8b-9398-606a96588c22.txn new file mode 100644 index 0000000000000000000000000000000000000000..29a6a050a8e48fccda25fd3920cdc5c945b35adc Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/13-389298bf-0302-4d8b-9398-606a96588c22.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/14-edf3bab6-345c-4038-8734-43b6528113ab.txn b/.lancedb/model3_fixed.lance/_transactions/14-edf3bab6-345c-4038-8734-43b6528113ab.txn new file mode 100644 index 0000000000000000000000000000000000000000..b65198a158a1e2397a3e171fc693ae41d9f5b9d5 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/14-edf3bab6-345c-4038-8734-43b6528113ab.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/15-25083f6f-6b0c-458e-8554-33bf8be4222c.txn b/.lancedb/model3_fixed.lance/_transactions/15-25083f6f-6b0c-458e-8554-33bf8be4222c.txn new file mode 100644 index 0000000000000000000000000000000000000000..c5ba4c45ee560d1883bdbc142d6ecae825df8a47 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/15-25083f6f-6b0c-458e-8554-33bf8be4222c.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/16-095221db-5950-449d-bffa-99b61749e70d.txn b/.lancedb/model3_fixed.lance/_transactions/16-095221db-5950-449d-bffa-99b61749e70d.txn new file mode 100644 index 0000000000000000000000000000000000000000..1a7dccec7b72c1743b746c9d29f9af02b567abdb Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/16-095221db-5950-449d-bffa-99b61749e70d.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/17-d128fcae-41bf-4391-b275-e10660734fb7.txn b/.lancedb/model3_fixed.lance/_transactions/17-d128fcae-41bf-4391-b275-e10660734fb7.txn new file mode 100644 index 0000000000000000000000000000000000000000..c3aed787ab59cdc2000284d53dc3b5c550ca3139 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/17-d128fcae-41bf-4391-b275-e10660734fb7.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/18-b96e1f65-a4bb-4d85-a7e7-6469c9dff2ae.txn b/.lancedb/model3_fixed.lance/_transactions/18-b96e1f65-a4bb-4d85-a7e7-6469c9dff2ae.txn new file mode 100644 index 0000000000000000000000000000000000000000..08c090424546607e4c3c339109e45e92af2245a1 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/18-b96e1f65-a4bb-4d85-a7e7-6469c9dff2ae.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/19-92639e98-f3d0-4188-a1df-df2795689dae.txn b/.lancedb/model3_fixed.lance/_transactions/19-92639e98-f3d0-4188-a1df-df2795689dae.txn new file mode 100644 index 0000000000000000000000000000000000000000..73fbec5921cc21e8eff9e7569e4743972f60ac19 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/19-92639e98-f3d0-4188-a1df-df2795689dae.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/2-0d2bc581-9c9b-4cc7-85db-89383fd44721.txn b/.lancedb/model3_fixed.lance/_transactions/2-0d2bc581-9c9b-4cc7-85db-89383fd44721.txn new file mode 100644 index 0000000000000000000000000000000000000000..e963100e4d95e6043cb30b3d052b9a75b58d9728 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/2-0d2bc581-9c9b-4cc7-85db-89383fd44721.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/20-175dc643-32c0-44ce-b913-88edf381f924.txn b/.lancedb/model3_fixed.lance/_transactions/20-175dc643-32c0-44ce-b913-88edf381f924.txn new file mode 100644 index 0000000000000000000000000000000000000000..f53d6228dbd870f8451ca0f2ae3221084884363f Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/20-175dc643-32c0-44ce-b913-88edf381f924.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/21-16297c9a-9801-405b-844b-ba672c1edcf5.txn b/.lancedb/model3_fixed.lance/_transactions/21-16297c9a-9801-405b-844b-ba672c1edcf5.txn new file mode 100644 index 0000000000000000000000000000000000000000..6655080df7f84e55757f76772eb5988df29be37c Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/21-16297c9a-9801-405b-844b-ba672c1edcf5.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/22-bea2518d-8111-4974-938e-06039618c487.txn b/.lancedb/model3_fixed.lance/_transactions/22-bea2518d-8111-4974-938e-06039618c487.txn new file mode 100644 index 0000000000000000000000000000000000000000..bac0434d9a91947047004b91b743922d40e21dca Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/22-bea2518d-8111-4974-938e-06039618c487.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/23-d9909cd4-1911-4a2c-adcb-8040def61c21.txn b/.lancedb/model3_fixed.lance/_transactions/23-d9909cd4-1911-4a2c-adcb-8040def61c21.txn new file mode 100644 index 0000000000000000000000000000000000000000..a63a5923cae90f9415f703d6ed5f04f722351719 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/23-d9909cd4-1911-4a2c-adcb-8040def61c21.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/24-aaeceb09-2972-4e78-a6a2-c32745b5b9af.txn b/.lancedb/model3_fixed.lance/_transactions/24-aaeceb09-2972-4e78-a6a2-c32745b5b9af.txn new file mode 100644 index 0000000000000000000000000000000000000000..551f152b160e62c4e9b7e0fdc1607319a5765311 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/24-aaeceb09-2972-4e78-a6a2-c32745b5b9af.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/25-415b2e61-c8b3-4c3a-a434-8b9c1c0b1f6b.txn b/.lancedb/model3_fixed.lance/_transactions/25-415b2e61-c8b3-4c3a-a434-8b9c1c0b1f6b.txn new file mode 100644 index 0000000000000000000000000000000000000000..c7f344838c9e8ad00ab8130a4cbdbd349de85212 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/25-415b2e61-c8b3-4c3a-a434-8b9c1c0b1f6b.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/26-d4d84f4c-3e78-4237-a52c-964e2c21b9e9.txn b/.lancedb/model3_fixed.lance/_transactions/26-d4d84f4c-3e78-4237-a52c-964e2c21b9e9.txn new file mode 100644 index 0000000000000000000000000000000000000000..cab7d6811b45d7471aa0b4104bbd3755e20f6b7a Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/26-d4d84f4c-3e78-4237-a52c-964e2c21b9e9.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/27-1ad00283-49a2-4140-ae64-ffbd1901c2d4.txn b/.lancedb/model3_fixed.lance/_transactions/27-1ad00283-49a2-4140-ae64-ffbd1901c2d4.txn new file mode 100644 index 0000000000000000000000000000000000000000..958f18e80d3ccf1fb76e6215fd1ba1136a655dbd Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/27-1ad00283-49a2-4140-ae64-ffbd1901c2d4.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/28-5e1ddea7-8ed5-4f6e-a161-2d3b2a31dc34.txn b/.lancedb/model3_fixed.lance/_transactions/28-5e1ddea7-8ed5-4f6e-a161-2d3b2a31dc34.txn new file mode 100644 index 0000000000000000000000000000000000000000..44e0508960672162ad7fd976119c092c4b3bf814 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/28-5e1ddea7-8ed5-4f6e-a161-2d3b2a31dc34.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/29-360e5e95-4fbe-43cc-af8d-48115dd7e04c.txn b/.lancedb/model3_fixed.lance/_transactions/29-360e5e95-4fbe-43cc-af8d-48115dd7e04c.txn new file mode 100644 index 0000000000000000000000000000000000000000..0a9aee58e0276984ca21b6ed9f7bb4c4b4c9d1b3 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/29-360e5e95-4fbe-43cc-af8d-48115dd7e04c.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/3-9964f0fe-e1a9-40cc-ab1a-fd2e6da4c1d2.txn b/.lancedb/model3_fixed.lance/_transactions/3-9964f0fe-e1a9-40cc-ab1a-fd2e6da4c1d2.txn new file mode 100644 index 0000000000000000000000000000000000000000..942c2a0dab6e1fe50567b991333980cd7d503d06 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/3-9964f0fe-e1a9-40cc-ab1a-fd2e6da4c1d2.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/4-86ff8a7a-234d-4730-8912-de4e2c3aafc3.txn b/.lancedb/model3_fixed.lance/_transactions/4-86ff8a7a-234d-4730-8912-de4e2c3aafc3.txn new file mode 100644 index 0000000000000000000000000000000000000000..6762db7516240a5ae8097394588239fa61cdb959 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/4-86ff8a7a-234d-4730-8912-de4e2c3aafc3.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/5-d6bb690d-113b-4d1b-9203-092b894d1569.txn b/.lancedb/model3_fixed.lance/_transactions/5-d6bb690d-113b-4d1b-9203-092b894d1569.txn new file mode 100644 index 0000000000000000000000000000000000000000..c8d5101e1d579f8294090f7fe9b09831335a1cf6 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/5-d6bb690d-113b-4d1b-9203-092b894d1569.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/6-1ccbe5f4-b4b7-49a8-8d83-6501ab3a5daa.txn b/.lancedb/model3_fixed.lance/_transactions/6-1ccbe5f4-b4b7-49a8-8d83-6501ab3a5daa.txn new file mode 100644 index 0000000000000000000000000000000000000000..8422e5a3525e0c0d7a1f68cb5c0427ba9381d0e1 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/6-1ccbe5f4-b4b7-49a8-8d83-6501ab3a5daa.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/7-461828da-cc2d-4155-94e5-d247704ba743.txn b/.lancedb/model3_fixed.lance/_transactions/7-461828da-cc2d-4155-94e5-d247704ba743.txn new file mode 100644 index 0000000000000000000000000000000000000000..7c3856ddadef56e3953521bd51922fdefb17e6d0 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/7-461828da-cc2d-4155-94e5-d247704ba743.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/8-f11c092f-06eb-48af-a3a1-bce5e993b551.txn b/.lancedb/model3_fixed.lance/_transactions/8-f11c092f-06eb-48af-a3a1-bce5e993b551.txn new file mode 100644 index 0000000000000000000000000000000000000000..f37cf300f9097ad78270bcff1fd571d6b0d62ed2 Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/8-f11c092f-06eb-48af-a3a1-bce5e993b551.txn differ diff --git a/.lancedb/model3_fixed.lance/_transactions/9-4dc5eb9a-be01-480d-92c0-3cbab6bf146b.txn b/.lancedb/model3_fixed.lance/_transactions/9-4dc5eb9a-be01-480d-92c0-3cbab6bf146b.txn new file mode 100644 index 0000000000000000000000000000000000000000..0c096bfd7526b1baa31bd219e72e16dc53dd431e Binary files /dev/null and b/.lancedb/model3_fixed.lance/_transactions/9-4dc5eb9a-be01-480d-92c0-3cbab6bf146b.txn differ diff --git a/.lancedb/model3_fixed.lance/data/051f523b-013f-4a7c-820f-7eb825c8fc6e.lance b/.lancedb/model3_fixed.lance/data/051f523b-013f-4a7c-820f-7eb825c8fc6e.lance new file mode 100644 index 0000000000000000000000000000000000000000..2c8aa2a452cf9f46d9e0aeb7a9de4fefcb154f8f --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/051f523b-013f-4a7c-820f-7eb825c8fc6e.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:00efabc9b0545250bdadb48c5e028617ecfc17ca5a25bbcb491c858ed40b8486 +size 297252 diff --git a/.lancedb/model3_fixed.lance/data/2748964f-c3fe-4484-9d44-32d330f2bed5.lance b/.lancedb/model3_fixed.lance/data/2748964f-c3fe-4484-9d44-32d330f2bed5.lance new file mode 100644 index 0000000000000000000000000000000000000000..2f200069d39cd14064cd25434e3b25395751ea6c --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/2748964f-c3fe-4484-9d44-32d330f2bed5.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1dd6a89ce1237015cc6b66682fb5a28d8cfa993f755d8838eb01ef1ccfdd2ae2 +size 308266 diff --git a/.lancedb/model3_fixed.lance/data/2f15a41f-aece-4aae-aaac-4782361d15b7.lance b/.lancedb/model3_fixed.lance/data/2f15a41f-aece-4aae-aaac-4782361d15b7.lance new file mode 100644 index 0000000000000000000000000000000000000000..9e70ba3ded6c3689cc3dd7dd1556decd7659c48d --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/2f15a41f-aece-4aae-aaac-4782361d15b7.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a1e1ee44cc234908f8dbe20e226ccef7351b221ee146944736492667d0d88f72 +size 307020 diff --git a/.lancedb/model3_fixed.lance/data/35c51ba4-8e4e-42a0-8204-d3f7779f00e6.lance b/.lancedb/model3_fixed.lance/data/35c51ba4-8e4e-42a0-8204-d3f7779f00e6.lance new file mode 100644 index 0000000000000000000000000000000000000000..f343d62cde9dc5d9f6c99030bc55e27da72f1e3d --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/35c51ba4-8e4e-42a0-8204-d3f7779f00e6.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b0fcede1c15b51ff1d018f1ca86998391b6cd0b998d2c203d785f448b208e3cd +size 289779 diff --git a/.lancedb/model3_fixed.lance/data/3b6268f8-55ed-4204-b969-8f4db11beea1.lance b/.lancedb/model3_fixed.lance/data/3b6268f8-55ed-4204-b969-8f4db11beea1.lance new file mode 100644 index 0000000000000000000000000000000000000000..3cd4af02c1f5a24c29aa80710288d2aa7478e23d --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/3b6268f8-55ed-4204-b969-8f4db11beea1.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c9b9d7baa45f2fa824d41c189e9925b5253bb89782f7731fe8b99ff16823ebe0 +size 296285 diff --git a/.lancedb/model3_fixed.lance/data/475c1989-0f1a-46a8-8454-511236597135.lance b/.lancedb/model3_fixed.lance/data/475c1989-0f1a-46a8-8454-511236597135.lance new file mode 100644 index 0000000000000000000000000000000000000000..6f5b516db7df8951e68ac1c862723041220cbae7 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/475c1989-0f1a-46a8-8454-511236597135.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9be7c3ed0aee21bed50a85c0b17402bae8a6daa9c0724f3c4ff218d32d226331 +size 303734 diff --git a/.lancedb/model3_fixed.lance/data/48080818-7c5f-49cf-8a42-b036aa9e5ac3.lance b/.lancedb/model3_fixed.lance/data/48080818-7c5f-49cf-8a42-b036aa9e5ac3.lance new file mode 100644 index 0000000000000000000000000000000000000000..ed6ba60807d283fbf93b7536a558c558510fd660 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/48080818-7c5f-49cf-8a42-b036aa9e5ac3.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:69521f91011b0f64e9ac63ca616444344945372329599d63b570d02a5ad02248 +size 296131 diff --git a/.lancedb/model3_fixed.lance/data/5312f201-1221-482a-9e4a-7764b7490088.lance b/.lancedb/model3_fixed.lance/data/5312f201-1221-482a-9e4a-7764b7490088.lance new file mode 100644 index 0000000000000000000000000000000000000000..47c35b1903acbb2afa5407c3b088123357711afa --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/5312f201-1221-482a-9e4a-7764b7490088.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:36d65f96c7d113384ad1a0dc08a59aa5c4faae2084022de25dba50e83dbe3f55 +size 294400 diff --git a/.lancedb/model3_fixed.lance/data/625f549f-ec2b-4d8c-9585-60777a9736ad.lance b/.lancedb/model3_fixed.lance/data/625f549f-ec2b-4d8c-9585-60777a9736ad.lance new file mode 100644 index 0000000000000000000000000000000000000000..8be7096a9302c50537c98c415f0ddd599b75d3f9 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/625f549f-ec2b-4d8c-9585-60777a9736ad.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3a280f44560b221ed512a86d7b183c705e93a7e0f801afa726a32e0b42811608 +size 295413 diff --git a/.lancedb/model3_fixed.lance/data/637c5d89-4641-4e86-8ecd-e44da395b418.lance b/.lancedb/model3_fixed.lance/data/637c5d89-4641-4e86-8ecd-e44da395b418.lance new file mode 100644 index 0000000000000000000000000000000000000000..566efbecd81b1b24b769f6ccdd4487852e701029 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/637c5d89-4641-4e86-8ecd-e44da395b418.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:218202b7e7bd8951985420523ad0a5a260082e858532f624e418c98d45ab7846 +size 299604 diff --git a/.lancedb/model3_fixed.lance/data/67f89c33-802b-439c-ac4a-5c7bed36ad68.lance b/.lancedb/model3_fixed.lance/data/67f89c33-802b-439c-ac4a-5c7bed36ad68.lance new file mode 100644 index 0000000000000000000000000000000000000000..090df32e5c5718b2212be32ccd5123abfe141206 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/67f89c33-802b-439c-ac4a-5c7bed36ad68.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9aa39258846f687338a536b9f7546c6a1c495233e84a7aeee6b966f80efefc12 +size 286528 diff --git a/.lancedb/model3_fixed.lance/data/6b3d89bf-310c-49a5-b63d-6e70ac1aa966.lance b/.lancedb/model3_fixed.lance/data/6b3d89bf-310c-49a5-b63d-6e70ac1aa966.lance new file mode 100644 index 0000000000000000000000000000000000000000..354238a01e2e8dbeac351160026a327957fd948e --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/6b3d89bf-310c-49a5-b63d-6e70ac1aa966.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5ac584ecbb056e986a101fa43e4fe3adf415d39b4068ce3b7b5d7c2f8e088892 +size 288082 diff --git a/.lancedb/model3_fixed.lance/data/704945f8-f889-4b90-ac5f-c06c676920a6.lance b/.lancedb/model3_fixed.lance/data/704945f8-f889-4b90-ac5f-c06c676920a6.lance new file mode 100644 index 0000000000000000000000000000000000000000..0646c656431ad62ed798f878241a7560d4c1c0ae --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/704945f8-f889-4b90-ac5f-c06c676920a6.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:992bc6dbe4dbaf4bc202bf4494e47bbcbc620be086c858a2c187526e269f10db +size 293214 diff --git a/.lancedb/model3_fixed.lance/data/87693f0c-3640-4dd4-a5ba-a5937693ac06.lance b/.lancedb/model3_fixed.lance/data/87693f0c-3640-4dd4-a5ba-a5937693ac06.lance new file mode 100644 index 0000000000000000000000000000000000000000..869de3026f5e2f08b1358ad105fb328e7d9109a4 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/87693f0c-3640-4dd4-a5ba-a5937693ac06.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:681889e7d9d263688dd336b221b39227cff4d488e3ee49fcba3fd3b0ae26decd +size 293579 diff --git a/.lancedb/model3_fixed.lance/data/8c0fa0f9-e26f-4b6f-985b-cb9043f9243f.lance b/.lancedb/model3_fixed.lance/data/8c0fa0f9-e26f-4b6f-985b-cb9043f9243f.lance new file mode 100644 index 0000000000000000000000000000000000000000..4147203a8353d4f647d80304f24ddac41e4e5042 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/8c0fa0f9-e26f-4b6f-985b-cb9043f9243f.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:aa2c5bdf5d89bf84184351ffd939b1c180fbef7f84bb835d8df8ad7e8ce28a1d +size 292686 diff --git a/.lancedb/model3_fixed.lance/data/93d778af-ffc8-4347-8d2a-ea19cdd94835.lance b/.lancedb/model3_fixed.lance/data/93d778af-ffc8-4347-8d2a-ea19cdd94835.lance new file mode 100644 index 0000000000000000000000000000000000000000..df6791faeefc3c93dc68e8cbfa18ece6d7db3b84 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/93d778af-ffc8-4347-8d2a-ea19cdd94835.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6a0265b14f5a63ff749ce45594a236c8471831f69ec20825c2dce1b19b232fd4 +size 289104 diff --git a/.lancedb/model3_fixed.lance/data/94611ffc-e182-447c-9949-d88a71f61da0.lance b/.lancedb/model3_fixed.lance/data/94611ffc-e182-447c-9949-d88a71f61da0.lance new file mode 100644 index 0000000000000000000000000000000000000000..f6d66848eb5c0588f006b1df6310229b540c2b69 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/94611ffc-e182-447c-9949-d88a71f61da0.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e16f010824cc59401fbf2e454005890e05d14d0e1786d4a66343755a56d055ad +size 288502 diff --git a/.lancedb/model3_fixed.lance/data/946bfb0a-38db-4485-b0b6-04325da3556c.lance b/.lancedb/model3_fixed.lance/data/946bfb0a-38db-4485-b0b6-04325da3556c.lance new file mode 100644 index 0000000000000000000000000000000000000000..68feea8215bfa97e0c92eacff7b4da679caa55b9 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/946bfb0a-38db-4485-b0b6-04325da3556c.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f74db7ced1e131c1f65c5eb5be693ca784370b24caccc70c05e2bfb6a8b6638f +size 285333 diff --git a/.lancedb/model3_fixed.lance/data/98fc4df8-3245-494f-b56a-a27568259e01.lance b/.lancedb/model3_fixed.lance/data/98fc4df8-3245-494f-b56a-a27568259e01.lance new file mode 100644 index 0000000000000000000000000000000000000000..54ff8d8f0cbd81a3d2f3e0f33b0b7030d8ad4b37 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/98fc4df8-3245-494f-b56a-a27568259e01.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a5245c2315db732e31858729da405ff940b3ca50b54f4d9bfdc1d12f49185b6c +size 291001 diff --git a/.lancedb/model3_fixed.lance/data/acf6594c-7ff3-4894-b9f6-603e850ed0f4.lance b/.lancedb/model3_fixed.lance/data/acf6594c-7ff3-4894-b9f6-603e850ed0f4.lance new file mode 100644 index 0000000000000000000000000000000000000000..b895ed5bee3e88d8d15f012332e41e13486af3a6 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/acf6594c-7ff3-4894-b9f6-603e850ed0f4.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e67de0b2c7259c54e8e6f72523c66e4035566c75d96ddad476180514fea442f1 +size 293556 diff --git a/.lancedb/model3_fixed.lance/data/b5993424-a12e-472d-8612-933c57ff76a8.lance b/.lancedb/model3_fixed.lance/data/b5993424-a12e-472d-8612-933c57ff76a8.lance new file mode 100644 index 0000000000000000000000000000000000000000..569b81f41f163f18d8baeb1c483225b8b20f6d7f --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/b5993424-a12e-472d-8612-933c57ff76a8.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:06b3557010da5c41f855ff9d78095507659aea8bd1d4385e8dedfddcc89db5ee +size 280046 diff --git a/.lancedb/model3_fixed.lance/data/ce18ae5c-2542-4b75-aaa6-a7098dc501ae.lance b/.lancedb/model3_fixed.lance/data/ce18ae5c-2542-4b75-aaa6-a7098dc501ae.lance new file mode 100644 index 0000000000000000000000000000000000000000..7730c82286d3f0be6082657d872fc440ff6bdc1d --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/ce18ae5c-2542-4b75-aaa6-a7098dc501ae.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:42788d78137c94a07d25148f706381253525730b92cb87fffe3375fd719eb60f +size 51558 diff --git a/.lancedb/model3_fixed.lance/data/d77840ce-eb32-444c-8b3f-0f9eb8926093.lance b/.lancedb/model3_fixed.lance/data/d77840ce-eb32-444c-8b3f-0f9eb8926093.lance new file mode 100644 index 0000000000000000000000000000000000000000..751cdd9a7c34df264d4e3f4be2bbd0b6f7041e7a --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/d77840ce-eb32-444c-8b3f-0f9eb8926093.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:238e2b7b1ca0752cbb5f8ccb18ab334b4109ea135b2be0d087b31fc7f1214993 +size 293974 diff --git a/.lancedb/model3_fixed.lance/data/e2919293-c1f4-44d3-af32-47ae7ed2dced.lance b/.lancedb/model3_fixed.lance/data/e2919293-c1f4-44d3-af32-47ae7ed2dced.lance new file mode 100644 index 0000000000000000000000000000000000000000..58c740032b88df860a94cd1b6c4e11e7d9e63d26 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/e2919293-c1f4-44d3-af32-47ae7ed2dced.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d80eb23099dd975450dafb419187ef65d4c4c0cd22ca9830a3c2681d80099fa8 +size 300405 diff --git a/.lancedb/model3_fixed.lance/data/e7e5b9a1-649b-4979-99c0-5044560f750f.lance b/.lancedb/model3_fixed.lance/data/e7e5b9a1-649b-4979-99c0-5044560f750f.lance new file mode 100644 index 0000000000000000000000000000000000000000..9097c83bbe3c5e82af90f62c2e95b21213a15282 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/e7e5b9a1-649b-4979-99c0-5044560f750f.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:75f2fefaba7ca0f53e78d4e475936085106f9443eba9d4dba620be0ffec649d3 +size 286015 diff --git a/.lancedb/model3_fixed.lance/data/e99be02c-0556-4925-a200-3f2fd64a3959.lance b/.lancedb/model3_fixed.lance/data/e99be02c-0556-4925-a200-3f2fd64a3959.lance new file mode 100644 index 0000000000000000000000000000000000000000..d9de2b23382071961ade9b50bf1196bb13d6c22e --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/e99be02c-0556-4925-a200-3f2fd64a3959.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e5b4069e0c17b8d2e2be00a5fffa495bbe43eb480f24b3043942fda77b0fd781 +size 297486 diff --git a/.lancedb/model3_fixed.lance/data/f0c6c3d1-a85d-44ad-af28-2abfb8dc5fd3.lance b/.lancedb/model3_fixed.lance/data/f0c6c3d1-a85d-44ad-af28-2abfb8dc5fd3.lance new file mode 100644 index 0000000000000000000000000000000000000000..5c49ee48d11fe69cde0d6c4978e5b73b75152716 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/f0c6c3d1-a85d-44ad-af28-2abfb8dc5fd3.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ab1a1f6d7d32346cf529d3491ad6b3cd1ab5299e652d774736396e24af507a3c +size 303530 diff --git a/.lancedb/model3_fixed.lance/data/f6bccba1-4521-4f7c-bd09-01e5f17b426b.lance b/.lancedb/model3_fixed.lance/data/f6bccba1-4521-4f7c-bd09-01e5f17b426b.lance new file mode 100644 index 0000000000000000000000000000000000000000..6335d373f9d32c2012ce049b40ab316cffefcd31 --- /dev/null +++ b/.lancedb/model3_fixed.lance/data/f6bccba1-4521-4f7c-bd09-01e5f17b426b.lance @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3c7b3564cacce1a8d8512f5f8c43351bb848216b76d520ee780348e80c381fe1 +size 301242 diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/__config.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/__config.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..95f895a67fd3a3a6af48cced964a63da4368646f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/__config.txt_chunk_0.txt @@ -0,0 +1,13 @@ +docstyle-ignore +INSTALL_CONTENT = """ +Transformers installation +! pip install transformers datasets evaluate accelerate +To install from source instead of the last release, comment the command above and uncomment the following one. +! pip install git+https://github.com/huggingface/transformers.git +""" +notebook_first_cells = [{"type": "code", "content": INSTALL_CONTENT}] +black_avoid_patterns = { + "{processor_class}": "FakeProcessorClass", + "{model_class}": "FakeModelClass", + "{object_class}": "FakeObjectClass", +} \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/__redirects.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/__redirects.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..9db31a9a52f2452f6a899eb981c042cc6ec8d396 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/__redirects.txt_chunk_0.txt @@ -0,0 +1,4 @@ +Optimizing inference +perf_infer_gpu_many: perf_infer_gpu_one +transformers_agents: agents +quantization: quantization/overview \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..a759c806f48a84ce1d82568f742bb5517913367e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_0.txt @@ -0,0 +1,52 @@ +sections: +local: index + title: 🤗 Transformers +local: quicktour + title: Quick tour +local: installation + title: Installation + title: Get started +sections: +local: pipeline_tutorial + title: Run inference with pipelines +local: autoclass_tutorial + title: Write portable code with AutoClass +local: preprocessing + title: Preprocess data +local: training + title: Fine-tune a pretrained model +local: run_scripts + title: Train with a script +local: accelerate + title: Set up distributed training with 🤗 Accelerate +local: peft + title: Load and train adapters with 🤗 PEFT +local: model_sharing + title: Share your model +local: agents + title: Agents +local: llm_tutorial + title: Generation with LLMs +local: conversations + title: Chatting with Transformers + title: Tutorials +sections: +isExpanded: false + sections: +local: tasks/sequence_classification + title: Text classification +local: tasks/token_classification + title: Token classification +local: tasks/question_answering + title: Question answering +local: tasks/language_modeling + title: Causal language modeling +local: tasks/masked_language_modeling + title: Masked language modeling +local: tasks/translation + title: Translation +local: tasks/summarization + title: Summarization +local: tasks/multiple_choice + title: Multiple choice +title: Natural Language Processing \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..5ed5a06e6455ac11e0a651d7dbb328a22562699c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_1.txt @@ -0,0 +1,33 @@ +isExpanded: false + sections: +local: tasks/audio_classification + title: Audio classification +local: tasks/asr + title: Automatic speech recognition +title: Audio + +isExpanded: false + sections: +local: tasks/image_classification + title: Image classification +local: tasks/semantic_segmentation + title: Image segmentation +local: tasks/video_classification + title: Video classification +local: tasks/object_detection + title: Object detection +local: tasks/zero_shot_object_detection + title: Zero-shot object detection +local: tasks/zero_shot_image_classification + title: Zero-shot image classification +local: tasks/monocular_depth_estimation + title: Depth estimation +local: tasks/image_to_image + title: Image-to-Image +local: tasks/image_feature_extraction + title: Image Feature Extraction +local: tasks/mask_generation + title: Mask Generation +local: tasks/knowledge_distillation_for_image_classification + title: Knowledge Distillation for Computer Vision +title: Computer Vision \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..62ca84936ea883b80eb703c824686b6ddc756887 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_2.txt @@ -0,0 +1,26 @@ +isExpanded: false + sections: +local: tasks/image_captioning + title: Image captioning +local: tasks/document_question_answering + title: Document Question Answering +local: tasks/visual_question_answering + title: Visual Question Answering +local: tasks/text-to-speech + title: Text to speech +title: Multimodal + +isExpanded: false + sections: +local: generation_strategies + title: Customize the generation strategy +title: Generation + +isExpanded: false + sections: +local: tasks/idefics + title: Image tasks with IDEFICS +local: tasks/prompting + title: LLM prompting guide +title: Prompting + title: Task Guides \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..ba169428031d3bcf0c37756c289c2242371cde64 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_3.txt @@ -0,0 +1,81 @@ +sections: +local: fast_tokenizers + title: Use fast tokenizers from 🤗 Tokenizers +local: multilingual + title: Run inference with multilingual models +local: create_a_model + title: Use model-specific APIs +local: custom_models + title: Share a custom model +local: chat_templating + title: Templates for chat models +local: trainer + title: Trainer +local: sagemaker + title: Run training on Amazon SageMaker +local: serialization + title: Export to ONNX +local: tflite + title: Export to TFLite +local: torchscript + title: Export to TorchScript +local: benchmarks + title: Benchmarks +local: notebooks + title: Notebooks with examples +local: community + title: Community resources +local: troubleshooting + title: Troubleshoot +local: gguf + title: Interoperability with GGUF files + title: Developer guides +sections: +local: quantization/overview + title: Getting started +local: quantization/bitsandbytes + title: bitsandbytes +local: quantization/gptq + title: GPTQ +local: quantization/awq + title: AWQ +local: quantization/aqlm + title: AQLM +local: quantization/quanto + title: Quanto +local: quantization/eetq + title: EETQ +local: quantization/hqq + title: HQQ +local: quantization/optimum + title: Optimum +local: quantization/contribute + title: Contribute new quantization method + title: Quantization Methods +sections: +local: performance + title: Overview +local: llm_optims + title: LLM inference optimization +sections: +local: perf_train_gpu_one + title: Methods and tools for efficient training on a single GPU +local: perf_train_gpu_many + title: Multiple GPUs and parallelism +local: fsdp + title: Fully Sharded Data Parallel +local: deepspeed + title: DeepSpeed +local: perf_train_cpu + title: Efficient training on CPU +local: perf_train_cpu_many + title: Distributed CPU training +local: perf_train_tpu_tf + title: Training on TPU with TensorFlow +local: perf_train_special + title: PyTorch training on Apple silicon +local: perf_hardware + title: Custom hardware for training +local: hpo_train + title: Hyperparameter Search using Trainer API +title: Efficient training techniques \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..5b1bf36552ea906765ee60621f660b8cba2f3ac1 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_4.txt @@ -0,0 +1,6 @@ +sections: +local: perf_infer_cpu + title: CPU inference +local: perf_infer_gpu_one + title: GPU inference +title: Optimizing inference \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..ef73cd7ce1d71ee625d51ea96e98eb2376891251 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_5.txt @@ -0,0 +1,94 @@ +local: big_models + title: Instantiate a big model +local: debugging + title: Debugging +local: tf_xla + title: XLA Integration for TensorFlow Models +local: perf_torch_compile + title: Optimize inference using torch.compile() + title: Performance and scalability +sections: +local: contributing + title: How to contribute to 🤗 Transformers? +local: add_new_model + title: How to add a model to 🤗 Transformers? +local: add_new_pipeline + title: How to add a pipeline to 🤗 Transformers? +local: testing + title: Testing +local: pr_checks + title: Checks on a Pull Request + title: Contribute +sections: +local: philosophy + title: Philosophy +local: glossary + title: Glossary +local: task_summary + title: What 🤗 Transformers can do +local: tasks_explained + title: How 🤗 Transformers solve tasks +local: model_summary + title: The Transformer model family +local: tokenizer_summary + title: Summary of the tokenizers +local: attention + title: Attention mechanisms +local: pad_truncation + title: Padding and truncation +local: bertology + title: BERTology +local: perplexity + title: Perplexity of fixed-length models +local: pipeline_webserver + title: Pipelines for webserver inference +local: model_memory_anatomy + title: Model training anatomy +local: llm_tutorial_optimization + title: Getting the most out of LLMs + title: Conceptual guides +sections: +sections: +local: main_classes/agent + title: Agents and Tools +local: model_doc/auto + title: Auto Classes +local: main_classes/backbones + title: Backbones +local: main_classes/callback + title: Callbacks +local: main_classes/configuration + title: Configuration +local: main_classes/data_collator + title: Data Collator +local: main_classes/keras_callbacks + title: Keras callbacks +local: main_classes/logging + title: Logging +local: main_classes/model + title: Models +local: main_classes/text_generation + title: Text Generation +local: main_classes/onnx + title: ONNX +local: main_classes/optimizer_schedules + title: Optimization +local: main_classes/output + title: Model outputs +local: main_classes/pipelines + title: Pipelines +local: main_classes/processors + title: Processors +local: main_classes/quantization + title: Quantization +local: main_classes/tokenizer + title: Tokenizer +local: main_classes/trainer + title: Trainer +local: main_classes/deepspeed + title: DeepSpeed +local: main_classes/feature_extractor + title: Feature Extractor +local: main_classes/image_processor + title: Image Processor +title: Main Classes \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..a8dcfe9867ed00f5778d4b77bc2b95b65314c6cf --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_6.txt @@ -0,0 +1,582 @@ +sections: +isExpanded: false + sections: +local: model_doc/albert + title: ALBERT +local: model_doc/bart + title: BART +local: model_doc/barthez + title: BARThez +local: model_doc/bartpho + title: BARTpho +local: model_doc/bert + title: BERT +local: model_doc/bert-generation + title: BertGeneration +local: model_doc/bert-japanese + title: BertJapanese +local: model_doc/bertweet + title: Bertweet +local: model_doc/big_bird + title: BigBird +local: model_doc/bigbird_pegasus + title: BigBirdPegasus +local: model_doc/biogpt + title: BioGpt +local: model_doc/blenderbot + title: Blenderbot +local: model_doc/blenderbot-small + title: Blenderbot Small +local: model_doc/bloom + title: BLOOM +local: model_doc/bort + title: BORT +local: model_doc/byt5 + title: ByT5 +local: model_doc/camembert + title: CamemBERT +local: model_doc/canine + title: CANINE +local: model_doc/codegen + title: CodeGen +local: model_doc/code_llama + title: CodeLlama +local: model_doc/cohere + title: Cohere +local: model_doc/convbert + title: ConvBERT +local: model_doc/cpm + title: CPM +local: model_doc/cpmant + title: CPMANT +local: model_doc/ctrl + title: CTRL +local: model_doc/dbrx + title: DBRX +local: model_doc/deberta + title: DeBERTa +local: model_doc/deberta-v2 + title: DeBERTa-v2 +local: model_doc/dialogpt + title: DialoGPT +local: model_doc/distilbert + title: DistilBERT +local: model_doc/dpr + title: DPR +local: model_doc/electra + title: ELECTRA +local: model_doc/encoder-decoder + title: Encoder Decoder Models +local: model_doc/ernie + title: ERNIE +local: model_doc/ernie_m + title: ErnieM +local: model_doc/esm + title: ESM +local: model_doc/falcon + title: Falcon +local: model_doc/fastspeech2_conformer + title: FastSpeech2Conformer +local: model_doc/flan-t5 + title: FLAN-T5 +local: model_doc/flan-ul2 + title: FLAN-UL2 +local: model_doc/flaubert + title: FlauBERT +local: model_doc/fnet + title: FNet +local: model_doc/fsmt + title: FSMT +local: model_doc/funnel + title: Funnel Transformer +local: model_doc/fuyu + title: Fuyu +local: model_doc/gemma + title: Gemma +local: model_doc/openai-gpt + title: GPT +local: model_doc/gpt_neo + title: GPT Neo +local: model_doc/gpt_neox + title: GPT NeoX +local: model_doc/gpt_neox_japanese + title: GPT NeoX Japanese +local: model_doc/gptj + title: GPT-J +local: model_doc/gpt2 + title: GPT2 +local: model_doc/gpt_bigcode + title: GPTBigCode +local: model_doc/gptsan-japanese + title: GPTSAN Japanese +local: model_doc/gpt-sw3 + title: GPTSw3 +local: model_doc/herbert + title: HerBERT +local: model_doc/ibert + title: I-BERT +local: model_doc/jamba + title: Jamba +local: model_doc/jetmoe + title: JetMoe +local: model_doc/jukebox + title: Jukebox +local: model_doc/led + title: LED +local: model_doc/llama + title: LLaMA +local: model_doc/llama2 + title: Llama2 +local: model_doc/llama3 + title: Llama3 +local: model_doc/longformer + title: Longformer +local: model_doc/longt5 + title: LongT5 +local: model_doc/luke + title: LUKE +local: model_doc/m2m_100 + title: M2M100 +local: model_doc/madlad-400 + title: MADLAD-400 +local: model_doc/mamba + title: Mamba +local: model_doc/marian + title: MarianMT +local: model_doc/markuplm + title: MarkupLM +local: model_doc/mbart + title: MBart and MBart-50 +local: model_doc/mega + title: MEGA +local: model_doc/megatron-bert + title: MegatronBERT +local: model_doc/megatron_gpt2 + title: MegatronGPT2 +local: model_doc/mistral + title: Mistral +local: model_doc/mixtral + title: Mixtral +local: model_doc/mluke + title: mLUKE +local: model_doc/mobilebert + title: MobileBERT +local: model_doc/mpnet + title: MPNet +local: model_doc/mpt + title: MPT +local: model_doc/mra + title: MRA +local: model_doc/mt5 + title: MT5 +local: model_doc/mvp + title: MVP +local: model_doc/nezha + title: NEZHA +local: model_doc/nllb + title: NLLB +local: model_doc/nllb-moe + title: NLLB-MoE +local: model_doc/nystromformer + title: Nyströmformer +local: model_doc/olmo + title: OLMo +local: model_doc/open-llama + title: Open-Llama +local: model_doc/opt + title: OPT +local: model_doc/pegasus + title: Pegasus +local: model_doc/pegasus_x + title: PEGASUS-X +local: model_doc/persimmon + title: Persimmon +local: model_doc/phi + title: Phi +local: model_doc/phi3 + title: Phi-3 +local: model_doc/phobert + title: PhoBERT +local: model_doc/plbart + title: PLBart +local: model_doc/prophetnet + title: ProphetNet +local: model_doc/qdqbert + title: QDQBert +local: model_doc/qwen2 + title: Qwen2 +local: model_doc/qwen2_moe + title: Qwen2MoE +local: model_doc/rag + title: RAG +local: model_doc/realm + title: REALM +local: model_doc/recurrent_gemma + title: RecurrentGemma +local: model_doc/reformer + title: Reformer +local: model_doc/rembert + title: RemBERT +local: model_doc/retribert + title: RetriBERT +local: model_doc/roberta + title: RoBERTa +local: model_doc/roberta-prelayernorm + title: RoBERTa-PreLayerNorm +local: model_doc/roc_bert + title: RoCBert +local: model_doc/roformer + title: RoFormer +local: model_doc/rwkv + title: RWKV +local: model_doc/splinter + title: Splinter +local: model_doc/squeezebert + title: SqueezeBERT +local: model_doc/stablelm + title: StableLm +local: model_doc/starcoder2 + title: Starcoder2 +local: model_doc/switch_transformers + title: SwitchTransformers +local: model_doc/t5 + title: T5 +local: model_doc/t5v1.1 + title: T5v1.1 +local: model_doc/tapex + title: TAPEX +local: model_doc/transfo-xl + title: Transformer XL +local: model_doc/ul2 + title: UL2 +local: model_doc/umt5 + title: UMT5 +local: model_doc/xmod + title: X-MOD +local: model_doc/xglm + title: XGLM +local: model_doc/xlm + title: XLM +local: model_doc/xlm-prophetnet + title: XLM-ProphetNet +local: model_doc/xlm-roberta + title: XLM-RoBERTa +local: model_doc/xlm-roberta-xl + title: XLM-RoBERTa-XL +local: model_doc/xlm-v + title: XLM-V +local: model_doc/xlnet + title: XLNet +local: model_doc/yoso + title: YOSO + title: Text models +isExpanded: false + sections: +local: model_doc/beit + title: BEiT +local: model_doc/bit + title: BiT +local: model_doc/conditional_detr + title: Conditional DETR +local: model_doc/convnext + title: ConvNeXT +local: model_doc/convnextv2 + title: ConvNeXTV2 +local: model_doc/cvt + title: CvT +local: model_doc/deformable_detr + title: Deformable DETR +local: model_doc/deit + title: DeiT +local: model_doc/depth_anything + title: Depth Anything +local: model_doc/deta + title: DETA +local: model_doc/detr + title: DETR +local: model_doc/dinat + title: DiNAT +local: model_doc/dinov2 + title: DINOV2 +local: model_doc/dit + title: DiT +local: model_doc/dpt + title: DPT +local: model_doc/efficientformer + title: EfficientFormer +local: model_doc/efficientnet + title: EfficientNet +local: model_doc/focalnet + title: FocalNet +local: model_doc/glpn + title: GLPN +local: model_doc/imagegpt + title: ImageGPT +local: model_doc/levit + title: LeViT +local: model_doc/mask2former + title: Mask2Former +local: model_doc/maskformer + title: MaskFormer +local: model_doc/mobilenet_v1 + title: MobileNetV1 +local: model_doc/mobilenet_v2 + title: MobileNetV2 +local: model_doc/mobilevit + title: MobileViT +local: model_doc/mobilevitv2 + title: MobileViTV2 +local: model_doc/nat + title: NAT +local: model_doc/poolformer + title: PoolFormer +local: model_doc/pvt + title: Pyramid Vision Transformer (PVT) +local: model_doc/pvt_v2 + title: Pyramid Vision Transformer v2 (PVTv2) +local: model_doc/regnet + title: RegNet +local: model_doc/resnet + title: ResNet +local: model_doc/rt_detr + title: RT-DETR +local: model_doc/segformer + title: SegFormer +local: model_doc/seggpt + title: SegGpt +local: model_doc/superpoint + title: SuperPoint +local: model_doc/swiftformer + title: SwiftFormer +local: model_doc/swin + title: Swin Transformer +local: model_doc/swinv2 + title: Swin Transformer V2 +local: model_doc/swin2sr + title: Swin2SR +local: model_doc/table-transformer + title: Table Transformer +local: model_doc/upernet + title: UperNet +local: model_doc/van + title: VAN +local: model_doc/vit + title: Vision Transformer (ViT) +local: model_doc/vit_hybrid + title: ViT Hybrid +local: model_doc/vitdet + title: ViTDet +local: model_doc/vit_mae + title: ViTMAE +local: model_doc/vitmatte + title: ViTMatte +local: model_doc/vit_msn + title: ViTMSN +local: model_doc/yolos + title: YOLOS + title: Vision models +isExpanded: false + sections: +local: model_doc/audio-spectrogram-transformer + title: Audio Spectrogram Transformer +local: model_doc/bark + title: Bark +local: model_doc/clap + title: CLAP +local: model_doc/encodec + title: EnCodec +local: model_doc/hubert + title: Hubert +local: model_doc/mctct + title: MCTCT +local: model_doc/mms + title: MMS +local: model_doc/musicgen + title: MusicGen +local: model_doc/musicgen_melody + title: MusicGen Melody +local: model_doc/pop2piano + title: Pop2Piano +local: model_doc/seamless_m4t + title: Seamless-M4T +local: model_doc/seamless_m4t_v2 + title: SeamlessM4T-v2 +local: model_doc/sew + title: SEW +local: model_doc/sew-d + title: SEW-D +local: model_doc/speech_to_text + title: Speech2Text +local: model_doc/speech_to_text_2 + title: Speech2Text2 +local: model_doc/speecht5 + title: SpeechT5 +local: model_doc/unispeech + title: UniSpeech +local: model_doc/unispeech-sat + title: UniSpeech-SAT +local: model_doc/univnet + title: UnivNet +local: model_doc/vits + title: VITS +local: model_doc/wav2vec2 + title: Wav2Vec2 +local: model_doc/wav2vec2-bert + title: Wav2Vec2-BERT +local: model_doc/wav2vec2-conformer + title: Wav2Vec2-Conformer +local: model_doc/wav2vec2_phoneme + title: Wav2Vec2Phoneme +local: model_doc/wavlm + title: WavLM +local: model_doc/whisper + title: Whisper +local: model_doc/xls_r + title: XLS-R +local: model_doc/xlsr_wav2vec2 + title: XLSR-Wav2Vec2 + title: Audio models +isExpanded: false + sections: +local: model_doc/timesformer + title: TimeSformer +local: model_doc/videomae + title: VideoMAE +local: model_doc/vivit + title: ViViT + title: Video models +isExpanded: false + sections: +local: model_doc/align + title: ALIGN +local: model_doc/altclip + title: AltCLIP +local: model_doc/blip + title: BLIP +local: model_doc/blip-2 + title: BLIP-2 +local: model_doc/bridgetower + title: BridgeTower +local: model_doc/bros + title: BROS +local: model_doc/chinese_clip + title: Chinese-CLIP +local: model_doc/clip + title: CLIP +local: model_doc/clipseg + title: CLIPSeg +local: model_doc/clvp + title: CLVP +local: model_doc/data2vec + title: Data2Vec +local: model_doc/deplot + title: DePlot +local: model_doc/donut + title: Donut +local: model_doc/flava + title: FLAVA +local: model_doc/git + title: GIT +local: model_doc/grounding-dino + title: Grounding DINO +local: model_doc/groupvit + title: GroupViT +local: model_doc/idefics + title: IDEFICS +local: model_doc/idefics2 + title: Idefics2 +local: model_doc/instructblip + title: InstructBLIP +local: model_doc/kosmos-2 + title: KOSMOS-2 +local: model_doc/layoutlm + title: LayoutLM +local: model_doc/layoutlmv2 + title: LayoutLMV2 +local: model_doc/layoutlmv3 + title: LayoutLMV3 +local: model_doc/layoutxlm + title: LayoutXLM +local: model_doc/lilt + title: LiLT +local: model_doc/llava + title: Llava +local: model_doc/llava_next + title: LLaVA-NeXT +local: model_doc/lxmert + title: LXMERT +local: model_doc/matcha + title: MatCha +local: model_doc/mgp-str + title: MGP-STR +local: model_doc/nougat + title: Nougat +local: model_doc/oneformer + title: OneFormer +local: model_doc/owlvit + title: OWL-ViT +local: model_doc/owlv2 + title: OWLv2 +local: model_doc/paligemma + title: PaliGemma +local: model_doc/perceiver + title: Perceiver +local: model_doc/pix2struct + title: Pix2Struct +local: model_doc/sam + title: Segment Anything +local: model_doc/siglip + title: SigLIP +local: model_doc/speech-encoder-decoder + title: Speech Encoder Decoder Models +local: model_doc/tapas + title: TAPAS +local: model_doc/trocr + title: TrOCR +local: model_doc/tvlt + title: TVLT +local: model_doc/tvp + title: TVP +local: model_doc/udop + title: UDOP +local: model_doc/video_llava + title: VideoLlava +local: model_doc/vilt + title: ViLT +local: model_doc/vipllava + title: VipLlava +local: model_doc/vision-encoder-decoder + title: Vision Encoder Decoder Models +local: model_doc/vision-text-dual-encoder + title: Vision Text Dual Encoder +local: model_doc/visual_bert + title: VisualBERT +local: model_doc/xclip + title: X-CLIP + title: Multimodal models +isExpanded: false + sections: +local: model_doc/decision_transformer + title: Decision Transformer +local: model_doc/trajectory_transformer + title: Trajectory Transformer + title: Reinforcement learning models +isExpanded: false + sections: +local: model_doc/autoformer + title: Autoformer +local: model_doc/informer + title: Informer +local: model_doc/patchtsmixer + title: PatchTSMixer +local: model_doc/patchtst + title: PatchTST +local: model_doc/time_series_transformer + title: Time Series Transformer + title: Time series models +isExpanded: false + sections: +local: model_doc/graphormer + title: Graphormer + title: Graph models +title: Models \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..35252b2045d5bfe855a960ff58367079d9597519 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/__toctree.txt_chunk_7.txt @@ -0,0 +1,21 @@ +sections: +local: internal/modeling_utils + title: Custom Layers and Utilities +local: internal/pipelines_utils + title: Utilities for pipelines +local: internal/tokenization_utils + title: Utilities for Tokenizers +local: internal/trainer_utils + title: Utilities for Trainer +local: internal/generation_utils + title: Utilities for Generation +local: internal/image_processing_utils + title: Utilities for Image Processors +local: internal/audio_utils + title: Utilities for Audio processing +local: internal/file_utils + title: General Utilities +local: internal/time_series_utils + title: Utilities for Time Series +title: Internal Helpers + title: API \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_accelerate.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_accelerate.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..9b6b42653c39b53712ce73d30061530f50b7af73 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_accelerate.txt_chunk_0.txt @@ -0,0 +1,10 @@ +Distributed training with 🤗 Accelerate +As models get bigger, parallelism has emerged as a strategy for training larger models on limited hardware and accelerating training speed by several orders of magnitude. At Hugging Face, we created the 🤗 Accelerate library to help users easily train a 🤗 Transformers model on any type of distributed setup, whether it is multiple GPU's on one machine or multiple GPU's across several machines. In this tutorial, learn how to customize your native PyTorch training loop to enable training in a distributed environment. +Setup +Get started by installing 🤗 Accelerate: + +pip install accelerate +Then import and create an [~accelerate.Accelerator] object. The [~accelerate.Accelerator] will automatically detect your type of distributed setup and initialize all the necessary components for training. You don't need to explicitly place your model on a device. + +from accelerate import Accelerator +accelerator = Accelerator() \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_accelerate.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_accelerate.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..566b9d1c222238b058f8c10128443cb29dd6c33c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_accelerate.txt_chunk_1.txt @@ -0,0 +1,25 @@ +from accelerate import Accelerator +accelerator = Accelerator() + +Prepare to accelerate +The next step is to pass all the relevant training objects to the [~accelerate.Accelerator.prepare] method. This includes your training and evaluation DataLoaders, a model and an optimizer: + +train_dataloader, eval_dataloader, model, optimizer = accelerator.prepare( + train_dataloader, eval_dataloader, model, optimizer + ) + +Backward +The last addition is to replace the typical loss.backward() in your training loop with 🤗 Accelerate's [~accelerate.Accelerator.backward]method: + +for epoch in range(num_epochs): + for batch in train_dataloader: + outputs = model(**batch) + loss = outputs.loss + accelerator.backward(loss) + + optimizer.step() + lr_scheduler.step() + optimizer.zero_grad() + progress_bar.update(1) + +As you can see in the following code, you only need to add four additional lines of code to your training loop to enable distributed training! \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_accelerate.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_accelerate.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..bfa54163b21ff1cb1289ed523fd6448f77b87843 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_accelerate.txt_chunk_2.txt @@ -0,0 +1,32 @@ ++ from accelerate import Accelerator + from transformers import AdamW, AutoModelForSequenceClassification, get_scheduler + +accelerator = Accelerator() + +model = AutoModelForSequenceClassification.from_pretrained(checkpoint, num_labels=2) + optimizer = AdamW(model.parameters(), lr=3e-5) + +device = torch.device("cuda") if torch.cuda.is_available() else torch.device("cpu") + +model.to(device) + +train_dataloader, eval_dataloader, model, optimizer = accelerator.prepare( + +train_dataloader, eval_dataloader, model, optimizer +) + +num_epochs = 3 + num_training_steps = num_epochs * len(train_dataloader) + lr_scheduler = get_scheduler( + "linear", + optimizer=optimizer, + num_warmup_steps=0, + num_training_steps=num_training_steps + ) +progress_bar = tqdm(range(num_training_steps)) +model.train() + for epoch in range(num_epochs): + for batch in train_dataloader: + + outputs = model(**batch) + loss = outputs.loss \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_accelerate.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_accelerate.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..df5a7d38372480e54c7c52a79cd00cde94680f55 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_accelerate.txt_chunk_3.txt @@ -0,0 +1,25 @@ +outputs = model(**batch) + loss = outputs.loss + ++ accelerator.backward(loss) + optimizer.step() + lr_scheduler.step() + optimizer.zero_grad() + progress_bar.update(1) + +Train +Once you've added the relevant lines of code, launch your training in a script or a notebook like Colaboratory. +Train with a script +If you are running your training from a script, run the following command to create and save a configuration file: + +accelerate config +Then launch your training with: + +accelerate launch train.py +Train with a notebook +🤗 Accelerate can also run in a notebook if you're planning on using Colaboratory's TPUs. Wrap all the code responsible for training in a function, and pass it to [~accelerate.notebook_launcher]: + +from accelerate import notebook_launcher +notebook_launcher(training_function) + +For more information about 🤗 Accelerate and its rich features, refer to the documentation. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..8cc85a9b1886af385707cd83b37f2e01cd845658 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_0.txt @@ -0,0 +1,8 @@ +How to add a model to 🤗 Transformers? +The 🤗 Transformers library is often able to offer new models thanks to community contributors. But this can be a challenging project and requires an in-depth knowledge of the 🤗 Transformers library and the model to implement. At Hugging Face, we're trying to empower more of the community to actively add models and we've put together this guide to walk you through the process of adding a PyTorch model (make sure you have PyTorch installed). +Along the way, you'll: + +get insights into open-source best practices +understand the design principles behind one of the most popular deep learning libraries +learn how to efficiently test large models +learn how to integrate Python utilities like black, ruff, and make fix-copies to ensure clean and readable code \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..484e1231382dd428d33942196e782a49453e9a7e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_1.txt @@ -0,0 +1,9 @@ +A Hugging Face team member will be available to help you along the way so you'll never be alone. 🤗 â¤ï¸ +To get started, open a New model addition issue for the model you want to see in 🤗 Transformers. If you're not especially picky about contributing a specific model, you can filter by the New model label to see if there are any unclaimed model requests and work on it. +Once you've opened a new model request, the first step is to get familiar with 🤗 Transformers if you aren't already! +General overview of 🤗 Transformers +First, you should get a general overview of 🤗 Transformers. 🤗 Transformers is a very opinionated library, so there is a +chance that you don't agree with some of the library's philosophies or design choices. From our experience, however, we +found that the fundamental design choices and philosophies of the library are crucial to efficiently scale 🤗 +Transformers while keeping maintenance costs at a reasonable level. +A good first starting point to better understand the library is to read the documentation of our philosophy. As a result of our way of working, there are some choices that we try to apply to all models: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_10.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_10.txt new file mode 100644 index 0000000000000000000000000000000000000000..933ac76a61ec85eb5027851124bd0a7b0ee8f317 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_10.txt @@ -0,0 +1,22 @@ +Fork the repository by clicking on the ‘Fork' button on the + repository's page. This creates a copy of the code under your GitHub user account. + +Clone your transformers fork to your local disk, and add the base repository as a remote: + + git clone https://github.com/[your Github handle]/transformers.git + cd transformers + git remote add upstream https://github.com/huggingface/transformers.git + +Set up a development environment, for instance by running the following command: + + python -m venv .env + source .env/bin/activate + pip install -e ".[dev]" +Depending on your OS, and since the number of optional dependencies of Transformers is growing, you might get a + failure with this command. If that's the case make sure to install the Deep Learning framework you are working with + (PyTorch, TensorFlow and/or Flax) then do: + + pip install -e ".[quality]" +which should be enough for most use cases. You can then return to the parent directory + + cd .. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_11.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_11.txt new file mode 100644 index 0000000000000000000000000000000000000000..ad0e40b009a08bb7c60dce16fdf3475f00bd32a1 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_11.txt @@ -0,0 +1,8 @@ +cd .. + +We recommend adding the PyTorch version of brand_new_bert to Transformers. To install PyTorch, please follow the + instructions on https://pytorch.org/get-started/locally/. + +Note: You don't need to have CUDA installed. Making the new model work on CPU is sufficient. + +To port brand_new_bert, you will also need access to its original repository: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_12.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_12.txt new file mode 100644 index 0000000000000000000000000000000000000000..29b2f4f10b938e7fc9b0360358d4292701c6fcff --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_12.txt @@ -0,0 +1,15 @@ +git clone https://github.com/org_that_created_brand_new_bert_org/brand_new_bert.git + cd brand_new_bert + pip install -e . +Now you have set up a development environment to port brand_new_bert to 🤗 Transformers. +3.-4. Run a pretrained checkpoint using the original repository +At first, you will work on the original brand_new_bert repository. Often, the original implementation is very +“researchyâ€. Meaning that documentation might be lacking and the code can be difficult to understand. But this should +be exactly your motivation to reimplement brand_new_bert. At Hugging Face, one of our main goals is to make people +stand on the shoulders of giants which translates here very well into taking a working model and rewriting it to make +it as accessible, user-friendly, and beautiful as possible. This is the number-one motivation to re-implement +models into 🤗 Transformers - trying to make complex new NLP technology accessible to everybody. +You should start thereby by diving into the original repository. +Successfully running the official pretrained model in the original repository is often the most difficult step. +From our experience, it is very important to spend some time getting familiar with the original code-base. You need to +figure out the following: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_13.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_13.txt new file mode 100644 index 0000000000000000000000000000000000000000..9f20d287766056852dfb969286983fc1c4184cc6 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_13.txt @@ -0,0 +1,10 @@ +Where to find the pretrained weights? +How to load the pretrained weights into the corresponding model? +How to run the tokenizer independently from the model? +Trace one forward pass so that you know which classes and functions are required for a simple forward pass. Usually, + you only have to reimplement those functions. +Be able to locate the important components of the model: Where is the model's class? Are there model sub-classes, + e.g. EncoderModel, DecoderModel? Where is the self-attention layer? Are there multiple different attention layers, + e.g. self-attention, cross-attention? +How can you debug the model in the original environment of the repo? Do you have to add print statements, can you + work with an interactive debugger like ipdb, or should you use an efficient IDE to debug the model, like PyCharm? \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_14.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_14.txt new file mode 100644 index 0000000000000000000000000000000000000000..7fabaa8bbc79d722e8fe859ab4cc8723e2b352da --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_14.txt @@ -0,0 +1,10 @@ +It is very important that before you start the porting process, you can efficiently debug code in the original +repository! Also, remember that you are working with an open-source library, so do not hesitate to open an issue, or +even a pull request in the original repository. The maintainers of this repository are most likely very happy about +someone looking into their code! +At this point, it is really up to you which debugging environment and strategy you prefer to use to debug the original +model. We strongly advise against setting up a costly GPU environment, but simply work on a CPU both when starting to +dive into the original repository and also when starting to write the 🤗 Transformers implementation of the model. Only +at the very end, when the model has already been successfully ported to 🤗 Transformers, one should verify that the +model also works as expected on GPU. +In general, there are two possible debugging environments for running the original model \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_15.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_15.txt new file mode 100644 index 0000000000000000000000000000000000000000..9d1e1a793c3e21b19c2462d36264d2282d6a0cc3 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_15.txt @@ -0,0 +1,2 @@ +Jupyter notebooks / google colab +Local python scripts. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_16.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_16.txt new file mode 100644 index 0000000000000000000000000000000000000000..f8d1b23eeb1e195abdb01c059400c3c77107de05 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_16.txt @@ -0,0 +1,15 @@ +Jupyter notebooks have the advantage that they allow for cell-by-cell execution which can be helpful to better split +logical components from one another and to have faster debugging cycles as intermediate results can be stored. Also, +notebooks are often easier to share with other contributors, which might be very helpful if you want to ask the Hugging +Face team for help. If you are familiar with Jupyter notebooks, we strongly recommend you work with them. +The obvious disadvantage of Jupyter notebooks is that if you are not used to working with them you will have to spend +some time adjusting to the new programming environment and you might not be able to use your known debugging tools +anymore, like ipdb. +For each code-base, a good first step is always to load a small pretrained checkpoint and to be able to reproduce a +single forward pass using a dummy integer vector of input IDs as an input. Such a script could look like this (in +pseudocode): +python +model = BrandNewBertModel.load_pretrained_checkpoint("/path/to/checkpoint/") +input_ids = [0, 4, 5, 2, 3, 7, 9] # vector of input ids +original_output = model.predict(input_ids) +Next, regarding the debugging strategy, there are generally a few from which to choose from: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_17.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_17.txt new file mode 100644 index 0000000000000000000000000000000000000000..745098f22204ea5eb682d58e4b6a443fc50b063e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_17.txt @@ -0,0 +1,10 @@ +Decompose the original model into many small testable components and run a forward pass on each of those for + verification +Decompose the original model only into the original tokenizer and the original model, run a forward pass on + those, and use intermediate print statements or breakpoints for verification + +Again, it is up to you which strategy to choose. Often, one or the other is advantageous depending on the original code +base. +If the original code-base allows you to decompose the model into smaller sub-components, e.g. if the original +code-base can easily be run in eager mode, it is usually worth the effort to do so. There are some important advantages +to taking the more difficult road in the beginning: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_18.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_18.txt new file mode 100644 index 0000000000000000000000000000000000000000..48a37ccdfaaae0c0cf4a79270e576753cccdb0cc --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_18.txt @@ -0,0 +1,9 @@ +at a later stage when comparing the original model to the Hugging Face implementation, you can verify automatically + for each component individually that the corresponding component of the 🤗 Transformers implementation matches instead + of relying on visual comparison via print statements +it can give you some rope to decompose the big problem of porting a model into smaller problems of just porting + individual components and thus structure your work better +separating the model into logical meaningful components will help you to get a better overview of the model's design + and thus to better understand the model +at a later stage those component-by-component tests help you to ensure that no regression occurs as you continue + changing your code \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_19.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_19.txt new file mode 100644 index 0000000000000000000000000000000000000000..1e5d1418d0d9f6cbc8d0436a61408643f7e0808e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_19.txt @@ -0,0 +1,11 @@ +Lysandre's integration checks for ELECTRA +gives a nice example of how this can be done. +However, if the original code-base is very complex or only allows intermediate components to be run in a compiled mode, +it might be too time-consuming or even impossible to separate the model into smaller testable sub-components. A good +example is T5's MeshTensorFlow library which is +very complex and does not offer a simple way to decompose the model into its sub-components. For such libraries, one +often relies on verifying print statements. +No matter which strategy you choose, the recommended procedure is often the same that you should start to debug the +starting layers first and the ending layers last. +It is recommended that you retrieve the output, either by print statements or sub-component functions, of the following +layers in the following order: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..a95879fc026b8b3f0f40630a8b0070eb76b57449 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_2.txt @@ -0,0 +1,4 @@ +Composition is generally favored over-abstraction +Duplicating code is not always bad if it strongly improves the readability or accessibility of a model +Model files are as self-contained as possible so that when you read the code of a specific model, you ideally only + have to look into the respective modeling_.py file. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_20.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_20.txt new file mode 100644 index 0000000000000000000000000000000000000000..e247cdf911320cd7966f9bcc2d1e551ae439b77a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_20.txt @@ -0,0 +1,6 @@ +Retrieve the input IDs passed to the model +Retrieve the word embeddings +Retrieve the input of the first Transformer layer +Retrieve the output of the first Transformer layer +Retrieve the output of the following n - 1 Transformer layers +Retrieve the output of the whole BrandNewBert Model \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_21.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_21.txt new file mode 100644 index 0000000000000000000000000000000000000000..6b77bd4cdc24e12f013eba4b5c9b3f3be639013e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_21.txt @@ -0,0 +1,18 @@ +Input IDs should thereby consists of an array of integers, e.g. input_ids = [0, 4, 4, 3, 2, 4, 1, 7, 19] +The outputs of the following layers often consist of multi-dimensional float arrays and can look like this: +[[ + [-0.1465, -0.6501, 0.1993, , 0.1451, 0.3430, 0.6024], + [-0.4417, -0.5920, 0.3450, , -0.3062, 0.6182, 0.7132], + [-0.5009, -0.7122, 0.4548, , -0.3662, 0.6091, 0.7648], + , + [-0.5613, -0.6332, 0.4324, , -0.3792, 0.7372, 0.9288], + [-0.5416, -0.6345, 0.4180, , -0.3564, 0.6992, 0.9191], + [-0.5334, -0.6403, 0.4271, , -0.3339, 0.6533, 0.8694]]], +We expect that every model added to 🤗 Transformers passes a couple of integration tests, meaning that the original +model and the reimplemented version in 🤗 Transformers have to give the exact same output up to a precision of 0.001! +Since it is normal that the exact same model written in different libraries can give a slightly different output +depending on the library framework, we accept an error tolerance of 1e-3 (0.001). It is not enough if the model gives +nearly the same output, they have to be almost identical. Therefore, you will certainly compare the intermediate +outputs of the 🤗 Transformers version multiple times against the intermediate outputs of the original implementation of +brand_new_bert in which case an efficient debugging environment of the original repository is absolutely +important. Here is some advice to make your debugging environment as efficient as possible. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_22.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_22.txt new file mode 100644 index 0000000000000000000000000000000000000000..87115ff8fda47a77407d2f8e60e519ed9958896e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_22.txt @@ -0,0 +1,23 @@ +Find the best way of debugging intermediate results. Is the original repository written in PyTorch? Then you should + probably take the time to write a longer script that decomposes the original model into smaller sub-components to + retrieve intermediate values. Is the original repository written in Tensorflow 1? Then you might have to rely on + TensorFlow print operations like tf.print to output + intermediate values. Is the original repository written in Jax? Then make sure that the model is not jitted when + running the forward pass, e.g. check-out this link. +Use the smallest pretrained checkpoint you can find. The smaller the checkpoint, the faster your debug cycle + becomes. It is not efficient if your pretrained model is so big that your forward pass takes more than 10 seconds. + In case only very large checkpoints are available, it might make more sense to create a dummy model in the new + environment with randomly initialized weights and save those weights for comparison with the 🤗 Transformers version + of your model +Make sure you are using the easiest way of calling a forward pass in the original repository. Ideally, you want to + find the function in the original repository that only calls a single forward pass, i.e. that is often called + predict, evaluate, forward or __call__. You don't want to debug a function that calls forward + multiple times, e.g. to generate text, like autoregressive_sample, generate. +Try to separate the tokenization from the model's forward pass. If the original repository shows examples where + you have to input a string, then try to find out where in the forward call the string input is changed to input ids + and start from this point. This might mean that you have to possibly write a small script yourself or change the + original code so that you can directly input the ids instead of an input string. +Make sure that the model in your debugging setup is not in training mode, which often causes the model to yield + random outputs due to multiple dropout layers in the model. Make sure that the forward pass in your debugging + environment is deterministic so that the dropout layers are not used. Or use transformers.utils.set_seed + if the old and new implementations are in the same framework. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_23.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_23.txt new file mode 100644 index 0000000000000000000000000000000000000000..a8e7e44cc1c452dc16a29212b8b6573630e2e637 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_23.txt @@ -0,0 +1,10 @@ +The following section gives you more specific details/tips on how you can do this for brand_new_bert. +5.-14. Port BrandNewBert to 🤗 Transformers +Next, you can finally start adding new code to 🤗 Transformers. Go into the clone of your 🤗 Transformers' fork: + +cd transformers +In the special case that you are adding a model whose architecture exactly matches the model architecture of an +existing model you only have to add a conversion script as described in this section. +In this case, you can just re-use the whole model architecture of the already existing model. +Otherwise, let's start generating a new model. We recommend using the following script to add a model starting from +an existing model: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_24.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_24.txt new file mode 100644 index 0000000000000000000000000000000000000000..23a4f37cc7235b192dd8fed2bae50f5b662bb0aa --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_24.txt @@ -0,0 +1,25 @@ +transformers-cli add-new-model-like +You will be prompted with a questionnaire to fill in the basic information of your model. +Open a Pull Request on the main huggingface/transformers repo +Before starting to adapt the automatically generated code, now is the time to open a “Work in progress (WIP)†pull +request, e.g. “[WIP] Add brand_new_bertâ€, in 🤗 Transformers so that you and the Hugging Face team can work +side-by-side on integrating the model into 🤗 Transformers. +You should do the following: + +Create a branch with a descriptive name from your main branch + + git checkout -b add_brand_new_bert + +Commit the automatically generated code: + + git add . + git commit + +Fetch and rebase to current main + + git fetch upstream + git rebase upstream/main + +Push the changes to your account using: + + git push -u origin a-descriptive-name-for-my-changes \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_25.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_25.txt new file mode 100644 index 0000000000000000000000000000000000000000..b818c1ce7e642f448436a0351cbb26884c7e07f0 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_25.txt @@ -0,0 +1,13 @@ +Push the changes to your account using: + + git push -u origin a-descriptive-name-for-my-changes + +Once you are satisfied, go to the webpage of your fork on GitHub. Click on “Pull requestâ€. Make sure to add the + GitHub handle of some members of the Hugging Face team as reviewers, so that the Hugging Face team gets notified for + future changes. + +Change the PR into a draft by clicking on “Convert to draft†on the right of the GitHub pull request web page. + +In the following, whenever you have made some progress, don't forget to commit your work and push it to your account so +that it shows in the pull request. Additionally, you should make sure to update your work with the current main from +time to time by doing: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_26.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_26.txt new file mode 100644 index 0000000000000000000000000000000000000000..f9e07b2ba7566c7579c52390f1f01b011177f17e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_26.txt @@ -0,0 +1,33 @@ +git fetch upstream +git merge upstream/main +In general, all questions you might have regarding the model or your implementation should be asked in your PR and +discussed/solved in the PR. This way, the Hugging Face team will always be notified when you are committing new code or +if you have a question. It is often very helpful to point the Hugging Face team to your added code so that the Hugging +Face team can efficiently understand your problem or question. +To do so, you can go to the “Files changed†tab where you see all of your changes, go to a line regarding which you +want to ask a question, and click on the “+†symbol to add a comment. Whenever a question or problem has been solved, +you can click on the “Resolve†button of the created comment. +In the same way, the Hugging Face team will open comments when reviewing your code. We recommend asking most questions +on GitHub on your PR. For some very general questions that are not very useful for the public, feel free to ping the +Hugging Face team by Slack or email. +5. Adapt the generated models code for brand_new_bert +At first, we will focus only on the model itself and not care about the tokenizer. All the relevant code should be +found in the generated files src/transformers/models/brand_new_bert/modeling_brand_new_bert.py and +src/transformers/models/brand_new_bert/configuration_brand_new_bert.py. +Now you can finally start coding :). The generated code in +src/transformers/models/brand_new_bert/modeling_brand_new_bert.py will either have the same architecture as BERT if +it's an encoder-only model or BART if it's an encoder-decoder model. At this point, you should remind yourself what +you've learned in the beginning about the theoretical aspects of the model: How is the model different from BERT or +BART?". Implement those changes which often means changing the self-attention layer, the order of the normalization +layer, etc… Again, it is often useful to look at the similar architecture of already existing models in Transformers to +get a better feeling of how your model should be implemented. +Note that at this point, you don't have to be very sure that your code is fully correct or clean. Rather, it is +advised to add a first unclean, copy-pasted version of the original code to +src/transformers/models/brand_new_bert/modeling_brand_new_bert.py until you feel like all the necessary code is +added. From our experience, it is much more efficient to quickly add a first version of the required code and +improve/correct the code iteratively with the conversion script as described in the next section. The only thing that +has to work at this point is that you can instantiate the 🤗 Transformers implementation of brand_new_bert, i.e. the +following command should work: +thon +from transformers import BrandNewBertModel, BrandNewBertConfig +model = BrandNewBertModel(BrandNewBertConfig()) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_27.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_27.txt new file mode 100644 index 0000000000000000000000000000000000000000..5f48ff253e575d5bc4a801e1508ea063bc784ad1 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_27.txt @@ -0,0 +1,45 @@ +The above command will create a model according to the default parameters as defined in BrandNewBertConfig() with +random weights, thus making sure that the init() methods of all components works. +Note that all random initialization should happen in the _init_weights method of your BrandnewBertPreTrainedModel +class. It should initialize all leaf modules depending on the variables of the config. Here is an example with the +BERT _init_weights method: +py +def _init_weights(self, module): + """Initialize the weights""" + if isinstance(module, nn.Linear): + module.weight.data.normal_(mean=0.0, std=self.config.initializer_range) + if module.bias is not None: + module.bias.data.zero_() + elif isinstance(module, nn.Embedding): + module.weight.data.normal_(mean=0.0, std=self.config.initializer_range) + if module.padding_idx is not None: + module.weight.data[module.padding_idx].zero_() + elif isinstance(module, nn.LayerNorm): + module.bias.data.zero_() + module.weight.data.fill_(1.0) +You can have some more custom schemes if you need a special initialization for some modules. For instance, in +Wav2Vec2ForPreTraining, the last two linear layers need to have the initialization of the regular PyTorch nn.Linear +but all the other ones should use an initialization as above. This is coded like this: +py +def _init_weights(self, module): + """Initialize the weights""" + if isinstance(module, Wav2Vec2ForPreTraining): + module.project_hid.reset_parameters() + module.project_q.reset_parameters() + module.project_hid._is_hf_initialized = True + module.project_q._is_hf_initialized = True + elif isinstance(module, nn.Linear): + module.weight.data.normal_(mean=0.0, std=self.config.initializer_range) + if module.bias is not None: + module.bias.data.zero_() +The _is_hf_initialized flag is internally used to make sure we only initialize a submodule once. By setting it to +True for module.project_q and module.project_hid, we make sure the custom initialization we did is not overridden later on, +the _init_weights function won't be applied to them. +6. Write a conversion script +Next, you should write a conversion script that lets you convert the checkpoint you used to debug brand_new_bert in +the original repository to a checkpoint compatible with your just created 🤗 Transformers implementation of +brand_new_bert. It is not advised to write the conversion script from scratch, but rather to look through already +existing conversion scripts in 🤗 Transformers for one that has been used to convert a similar model that was written in +the same framework as brand_new_bert. Usually, it is enough to copy an already existing conversion script and +slightly adapt it for your use case. Don't hesitate to ask the Hugging Face team to point you to a similar already +existing conversion script for your model. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_28.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_28.txt new file mode 100644 index 0000000000000000000000000000000000000000..0a27078e43cf8c6af55b47adcfd5564e1f2f1c26 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_28.txt @@ -0,0 +1,20 @@ +If you are porting a model from TensorFlow to PyTorch, a good starting point might be BERT's conversion script here +If you are porting a model from PyTorch to PyTorch, a good starting point might be BART's conversion script here + +In the following, we'll quickly explain how PyTorch models store layer weights and define layer names. In PyTorch, the +name of a layer is defined by the name of the class attribute you give the layer. Let's define a dummy model in +PyTorch, called SimpleModel as follows: +thon +from torch import nn +class SimpleModel(nn.Module): + def init(self): + super().init() + self.dense = nn.Linear(10, 10) + self.intermediate = nn.Linear(10, 10) + self.layer_norm = nn.LayerNorm(10) + +Now we can create an instance of this model definition which will fill all weights: dense, intermediate, +layer_norm with random weights. We can print the model to see its architecture +thon +model = SimpleModel() +print(model) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_29.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_29.txt new file mode 100644 index 0000000000000000000000000000000000000000..8de4ff60acd06e61f39ea95a022d4e93648011bf --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_29.txt @@ -0,0 +1,40 @@ +This will print out the following: +SimpleModel( + (dense): Linear(in_features=10, out_features=10, bias=True) + (intermediate): Linear(in_features=10, out_features=10, bias=True) + (layer_norm): LayerNorm((10,), eps=1e-05, elementwise_affine=True) +) +We can see that the layer names are defined by the name of the class attribute in PyTorch. You can print out the weight +values of a specific layer: +python +print(model.dense.weight.data) +to see that the weights were randomly initialized +tensor([[-0.0818, 0.2207, -0.0749, -0.0030, 0.0045, -0.1569, -0.1598, 0.0212, + -0.2077, 0.2157], + [ 0.1044, 0.0201, 0.0990, 0.2482, 0.3116, 0.2509, 0.2866, -0.2190, + 0.2166, -0.0212], + [-0.2000, 0.1107, -0.1999, -0.3119, 0.1559, 0.0993, 0.1776, -0.1950, + -0.1023, -0.0447], + [-0.0888, -0.1092, 0.2281, 0.0336, 0.1817, -0.0115, 0.2096, 0.1415, + -0.1876, -0.2467], + [ 0.2208, -0.2352, -0.1426, -0.2636, -0.2889, -0.2061, -0.2849, -0.0465, + 0.2577, 0.0402], + [ 0.1502, 0.2465, 0.2566, 0.0693, 0.2352, -0.0530, 0.1859, -0.0604, + 0.2132, 0.1680], + [ 0.1733, -0.2407, -0.1721, 0.1484, 0.0358, -0.0633, -0.0721, -0.0090, + 0.2707, -0.2509], + [-0.1173, 0.1561, 0.2945, 0.0595, -0.1996, 0.2988, -0.0802, 0.0407, + 0.1829, -0.1568], + [-0.1164, -0.2228, -0.0403, 0.0428, 0.1339, 0.0047, 0.1967, 0.2923, + 0.0333, -0.0536], + [-0.1492, -0.1616, 0.1057, 0.1950, -0.2807, -0.2710, -0.1586, 0.0739, + 0.2220, 0.2358]]). +In the conversion script, you should fill those randomly initialized weights with the exact weights of the +corresponding layer in the checkpoint. E.g. +thon +retrieve matching layer weights, e.g. by +recursive algorithm +layer_name = "dense" +pretrained_weight = array_of_dense_layer +model_pointer = getattr(model, "dense") +model_pointer.weight.data = torch.from_numpy(pretrained_weight) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..f722b1a916b0963330511ac7ed47bde54f497e1e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_3.txt @@ -0,0 +1,9 @@ +In our opinion, the library's code is not just a means to provide a product, e.g. the ability to use BERT for +inference, but also as the very product that we want to improve. Hence, when adding a model, the user is not only the +person who will use your model, but also everybody who will read, try to understand, and possibly tweak your code. +With this in mind, let's go a bit deeper into the general library design. +Overview of models +To successfully add a model, it is important to understand the interaction between your model and its config, +[PreTrainedModel], and [PretrainedConfig]. For exemplary purposes, we will +call the model to be added to 🤗 Transformers BrandNewBert. +Let's take a look: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_30.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_30.txt new file mode 100644 index 0000000000000000000000000000000000000000..74b59316bfe03cdf94f26611a88794afd8719e5c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_30.txt @@ -0,0 +1,47 @@ +While doing so, you must verify that each randomly initialized weight of your PyTorch model and its corresponding +pretrained checkpoint weight exactly match in both shape and name. To do so, it is necessary to add assert +statements for the shape and print out the names of the checkpoints weights. E.g. you should add statements like: +python +assert ( + model_pointer.weight.shape == pretrained_weight.shape +), f"Pointer shape of random weight {model_pointer.shape} and array shape of checkpoint weight {pretrained_weight.shape} mismatched" +Besides, you should also print out the names of both weights to make sure they match, e.g. +python +logger.info(f"Initialize PyTorch weight {layer_name} from {pretrained_weight.name}") +If either the shape or the name doesn't match, you probably assigned the wrong checkpoint weight to a randomly +initialized layer of the 🤗 Transformers implementation. +An incorrect shape is most likely due to an incorrect setting of the config parameters in BrandNewBertConfig() that +do not exactly match those that were used for the checkpoint you want to convert. However, it could also be that +PyTorch's implementation of a layer requires the weight to be transposed beforehand. +Finally, you should also check that all required weights are initialized and print out all checkpoint weights that +were not used for initialization to make sure the model is correctly converted. It is completely normal, that the +conversion trials fail with either a wrong shape statement or a wrong name assignment. This is most likely because either +you used incorrect parameters in BrandNewBertConfig(), have a wrong architecture in the 🤗 Transformers +implementation, you have a bug in the init() functions of one of the components of the 🤗 Transformers +implementation or you need to transpose one of the checkpoint weights. +This step should be iterated with the previous step until all weights of the checkpoint are correctly loaded in the +Transformers model. Having correctly loaded the checkpoint into the 🤗 Transformers implementation, you can then save +the model under a folder of your choice /path/to/converted/checkpoint/folder that should then contain both a +pytorch_model.bin file and a config.json file: +python +model.save_pretrained("/path/to/converted/checkpoint/folder") +7. Implement the forward pass +Having managed to correctly load the pretrained weights into the 🤗 Transformers implementation, you should now make +sure that the forward pass is correctly implemented. In Get familiar with the original repository, you have already created a script that runs a forward +pass of the model using the original repository. Now you should write an analogous script using the 🤗 Transformers +implementation instead of the original one. It should look as follows: +python +model = BrandNewBertModel.from_pretrained("/path/to/converted/checkpoint/folder") +input_ids = [0, 4, 4, 3, 2, 4, 1, 7, 19] +output = model(input_ids).last_hidden_states +It is very likely that the 🤗 Transformers implementation and the original model implementation don't give the exact +same output the very first time or that the forward pass throws an error. Don't be disappointed - it's expected! First, +you should make sure that the forward pass doesn't throw any errors. It often happens that the wrong dimensions are +used leading to a Dimensionality mismatch error or that the wrong data type object is used, e.g. torch.long +instead of torch.float32. Don't hesitate to ask the Hugging Face team for help, if you don't manage to solve +certain errors. +The final part to make sure the 🤗 Transformers implementation works correctly is to ensure that the outputs are +equivalent to a precision of 1e-3. First, you should ensure that the output shapes are identical, i.e. +outputs.shape should yield the same value for the script of the 🤗 Transformers implementation and the original +implementation. Next, you should make sure that the output values are identical as well. This one of the most difficult +parts of adding a new model. Common mistakes why the outputs are not identical are: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_31.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_31.txt new file mode 100644 index 0000000000000000000000000000000000000000..b27d65bbcf76b98951f9deee7af51e7517828688 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_31.txt @@ -0,0 +1,5 @@ +Some layers were not added, i.e. an activation layer was not added, or the residual connection was forgotten +The word embedding matrix was not tied +The wrong positional embeddings are used because the original implementation uses on offset +Dropout is applied during the forward pass. To fix this make sure model.training is False and that no dropout + layer is falsely activated during the forward pass, i.e. pass self.training to PyTorch's functional dropout \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_32.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_32.txt new file mode 100644 index 0000000000000000000000000000000000000000..27be1a13c321d7e5cbec242fedba30ca984d7e9f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_32.txt @@ -0,0 +1,19 @@ +The best way to fix the problem is usually to look at the forward pass of the original implementation and the 🤗 +Transformers implementation side-by-side and check if there are any differences. Ideally, you should debug/print out +intermediate outputs of both implementations of the forward pass to find the exact position in the network where the 🤗 +Transformers implementation shows a different output than the original implementation. First, make sure that the +hard-coded input_ids in both scripts are identical. Next, verify that the outputs of the first transformation of +the input_ids (usually the word embeddings) are identical. And then work your way up to the very last layer of the +network. At some point, you will notice a difference between the two implementations, which should point you to the bug +in the 🤗 Transformers implementation. From our experience, a simple and efficient way is to add many print statements +in both the original implementation and 🤗 Transformers implementation, at the same positions in the network +respectively, and to successively remove print statements showing the same values for intermediate presentations. +When you're confident that both implementations yield the same output, verify the outputs with +torch.allclose(original_output, output, atol=1e-3), you're done with the most difficult part! Congratulations - the +work left to be done should be a cakewalk 😊. +8. Adding all necessary model tests +At this point, you have successfully added a new model. However, it is very much possible that the model does not yet +fully comply with the required design. To make sure, the implementation is fully compatible with 🤗 Transformers, all +common tests should pass. The Cookiecutter should have automatically added a test file for your model, probably under +the same tests/models/brand_new_bert/test_modeling_brand_new_bert.py. Run this test file to verify that all common +tests pass: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_33.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_33.txt new file mode 100644 index 0000000000000000000000000000000000000000..602b70fd3150d1a13a43f594b58190aa4a5c2d57 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_33.txt @@ -0,0 +1,14 @@ +pytest tests/models/brand_new_bert/test_modeling_brand_new_bert.py +Having fixed all common tests, it is now crucial to ensure that all the nice work you have done is well tested, so that + +a) The community can easily understand your work by looking at specific tests of brand_new_bert +b) Future changes to your model will not break any important feature of the model. + +At first, integration tests should be added. Those integration tests essentially do the same as the debugging scripts +you used earlier to implement the model to 🤗 Transformers. A template of those model tests has already added by the +Cookiecutter, called BrandNewBertModelIntegrationTests and only has to be filled out by you. To ensure that those +tests are passing, run + +RUN_SLOW=1 pytest -sv tests/models/brand_new_bert/test_modeling_brand_new_bert.py::BrandNewBertModelIntegrationTests + +In case you are using Windows, you should replace RUN_SLOW=1 with SET RUN_SLOW=1 \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_34.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_34.txt new file mode 100644 index 0000000000000000000000000000000000000000..c763562302db4aed0a6914d55f94b5904192709f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_34.txt @@ -0,0 +1,9 @@ +In case you are using Windows, you should replace RUN_SLOW=1 with SET RUN_SLOW=1 + +Second, all features that are special to brand_new_bert should be tested additionally in a separate test under +BrandNewBertModelTester/BrandNewBertModelTest. This part is often forgotten but is extremely useful in two +ways: + +It helps to transfer the knowledge you have acquired during the model addition to the community by showing how the + special features of brand_new_bert should work. +Future contributors can quickly test changes to the model by running those special tests. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_35.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_35.txt new file mode 100644 index 0000000000000000000000000000000000000000..49a2ec48f4969cd7df85efede4346b0db135d271 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_35.txt @@ -0,0 +1,20 @@ +9. Implement the tokenizer +Next, we should add the tokenizer of brand_new_bert. Usually, the tokenizer is equivalent to or very similar to an +already existing tokenizer of 🤗 Transformers. +It is very important to find/extract the original tokenizer file and to manage to load this file into the 🤗 +Transformers' implementation of the tokenizer. +To ensure that the tokenizer works correctly, it is recommended to first create a script in the original repository +that inputs a string and returns the input_ids. It could look similar to this (in pseudo-code): +python +input_str = "This is a long example input string containing special characters .$?-, numbers 2872 234 12 and words." +model = BrandNewBertModel.load_pretrained_checkpoint("/path/to/checkpoint/") +input_ids = model.tokenize(input_str) +You might have to take a deeper look again into the original repository to find the correct tokenizer function or you +might even have to do changes to your clone of the original repository to only output the input_ids. Having written +a functional tokenization script that uses the original repository, an analogous script for 🤗 Transformers should be +created. It should look similar to this: +thon +from transformers import BrandNewBertTokenizer +input_str = "This is a long example input string containing special characters .$?-, numbers 2872 234 12 and words." +tokenizer = BrandNewBertTokenizer.from_pretrained("/path/to/tokenizer/folder/") +input_ids = tokenizer(input_str).input_ids \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_36.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_36.txt new file mode 100644 index 0000000000000000000000000000000000000000..e19a4dc3b405a4ca18e271b6e4cc916b291d1d71 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_36.txt @@ -0,0 +1,28 @@ +When both input_ids yield the same values, as a final step a tokenizer test file should also be added. +Analogous to the modeling test files of brand_new_bert, the tokenization test files of brand_new_bert should +contain a couple of hard-coded integration tests. +10. Run End-to-end integration tests +Having added the tokenizer, you should also add a couple of end-to-end integration tests using both the model and the +tokenizer to tests/models/brand_new_bert/test_modeling_brand_new_bert.py in 🤗 Transformers. +Such a test should show on a meaningful +text-to-text sample that the 🤗 Transformers implementation works as expected. A meaningful text-to-text sample can +include e.g. a source-to-target-translation pair, an article-to-summary pair, a question-to-answer pair, etc… If none +of the ported checkpoints has been fine-tuned on a downstream task it is enough to simply rely on the model tests. In a +final step to ensure that the model is fully functional, it is advised that you also run all tests on GPU. It can +happen that you forgot to add some .to(self.device) statements to internal tensors of the model, which in such a +test would show in an error. In case you have no access to a GPU, the Hugging Face team can take care of running those +tests for you. +11. Add Docstring +Now, all the necessary functionality for brand_new_bert is added - you're almost done! The only thing left to add is +a nice docstring and a doc page. The Cookiecutter should have added a template file called +docs/source/model_doc/brand_new_bert.md that you should fill out. Users of your model will usually first look at +this page before using your model. Hence, the documentation must be understandable and concise. It is very useful for +the community to add some Tips to show how the model should be used. Don't hesitate to ping the Hugging Face team +regarding the docstrings. +Next, make sure that the docstring added to src/transformers/models/brand_new_bert/modeling_brand_new_bert.py is +correct and included all necessary inputs and outputs. We have a detailed guide about writing documentation and our docstring format here. It is always good to remind oneself that documentation should +be treated at least as carefully as the code in 🤗 Transformers since the documentation is usually the first contact +point of the community with the model. +Code refactor +Great, now you have added all the necessary code for brand_new_bert. At this point, you should correct some potential +incorrect code style by running: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_37.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_37.txt new file mode 100644 index 0000000000000000000000000000000000000000..36aaca74c9a9d4fb82967a311e0a3d8456afac41 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_37.txt @@ -0,0 +1,2 @@ +make style +and verify that your coding style passes the quality check: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_38.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_38.txt new file mode 100644 index 0000000000000000000000000000000000000000..4012228a96c8f3ac4c88879dfca41308d80fc529 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_38.txt @@ -0,0 +1,16 @@ +make quality +There are a couple of other very strict design tests in 🤗 Transformers that might still be failing, which shows up in +the tests of your pull request. This is often because of some missing information in the docstring or some incorrect +naming. The Hugging Face team will surely help you if you're stuck here. +Lastly, it is always a good idea to refactor one's code after having ensured that the code works correctly. With all +tests passing, now it's a good time to go over the added code again and do some refactoring. +You have now finished the coding part, congratulation! 🎉 You are Awesome! 😎 +12. Upload the models to the model hub +In this final part, you should convert and upload all checkpoints to the model hub and add a model card for each +uploaded model checkpoint. You can get familiar with the hub functionalities by reading our Model sharing and uploading Page. You should work alongside the Hugging Face team here to decide on a fitting name for each +checkpoint and to get the required access rights to be able to upload the model under the author's organization of +brand_new_bert. The push_to_hub method, present in all models in transformers, is a quick and efficient way to push your checkpoint to the hub. A little snippet is pasted below: +thon +brand_new_bert.push_to_hub("brand_new_bert") +Uncomment the following line to push to an organization. +brand_new_bert.push_to_hub("/brand_new_bert") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_39.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_39.txt new file mode 100644 index 0000000000000000000000000000000000000000..a2ad34860e79565120fc7a3849922f7ada8b1ee0 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_39.txt @@ -0,0 +1,18 @@ +It is worth spending some time to create fitting model cards for each checkpoint. The model cards should highlight the +specific characteristics of this particular checkpoint, e.g. On which dataset was the checkpoint +pretrained/fine-tuned on? On what down-stream task should the model be used? And also include some code on how to +correctly use the model. +13. (Optional) Add notebook +It is very helpful to add a notebook that showcases in-detail how brand_new_bert can be used for inference and/or +fine-tuned on a downstream task. This is not mandatory to merge your PR, but very useful for the community. +14. Submit your finished PR +You're done programming now and can move to the last step, which is getting your PR merged into main. Usually, the +Hugging Face team should have helped you already at this point, but it is worth taking some time to give your finished +PR a nice description and eventually add comments to your code, if you want to point out certain design choices to your +reviewer. +Share your work!! +Now, it's time to get some credit from the community for your work! Having completed a model addition is a major +contribution to Transformers and the whole NLP community. Your code and the ported pre-trained models will certainly be +used by hundreds and possibly even thousands of developers and researchers. You should be proud of your work and share +your achievements with the community. +You have made another model that is super easy to access for everyone in the community! 🤯 \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..afa322fb2194a9be0f00d78062a08488a7466834 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_4.txt @@ -0,0 +1,25 @@ +As you can see, we do make use of inheritance in 🤗 Transformers, but we keep the level of abstraction to an absolute +minimum. There are never more than two levels of abstraction for any model in the library. BrandNewBertModel +inherits from BrandNewBertPreTrainedModel which in turn inherits from [PreTrainedModel] and +that's it. As a general rule, we want to make sure that a new model only depends on +[PreTrainedModel]. The important functionalities that are automatically provided to every new +model are [~PreTrainedModel.from_pretrained] and +[~PreTrainedModel.save_pretrained], which are used for serialization and deserialization. All of the +other important functionalities, such as BrandNewBertModel.forward should be completely defined in the new +modeling_brand_new_bert.py script. Next, we want to make sure that a model with a specific head layer, such as +BrandNewBertForMaskedLM does not inherit from BrandNewBertModel, but rather uses BrandNewBertModel +as a component that can be called in its forward pass to keep the level of abstraction low. Every new model requires a +configuration class, called BrandNewBertConfig. This configuration is always stored as an attribute in +[PreTrainedModel], and thus can be accessed via the config attribute for all classes +inheriting from BrandNewBertPreTrainedModel: +python +model = BrandNewBertModel.from_pretrained("brandy/brand_new_bert") +model.config # model has access to its config +Similar to the model, the configuration inherits basic serialization and deserialization functionalities from +[PretrainedConfig]. Note that the configuration and the model are always serialized into two +different formats - the model to a pytorch_model.bin file and the configuration to a config.json file. Calling +the model's [~PreTrainedModel.save_pretrained] will automatically call +the config's [~PretrainedConfig.save_pretrained], so that both model and configuration are saved. +Code style +When coding your new model, keep in mind that Transformers is an opinionated library and we have a few quirks of our +own regarding how code should be written :-) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..bbb8f39667c465de9c86f84ca94c2b48bdafeb91 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_5.txt @@ -0,0 +1,12 @@ +The forward pass of your model should be fully written in the modeling file while being fully independent of other + models in the library. If you want to reuse a block from another model, copy the code and paste it with a + # Copied from comment on top (see here + for a good example and there for more documentation on Copied from). +The code should be fully understandable, even by a non-native English speaker. This means you should pick + descriptive variable names and avoid abbreviations. As an example, activation is preferred to act. + One-letter variable names are strongly discouraged unless it's an index in a for loop. +More generally we prefer longer explicit code to short magical one. +Avoid subclassing nn.Sequential in PyTorch but subclass nn.Module and write the forward pass, so that anyone + using your code can quickly debug it by adding print statements or breaking points. +Your function signature should be type-annotated. For the rest, good variable names are way more readable and + understandable than type annotations. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..0065d2aea0303fcb6a5291bae1c155fe8cc4a2b6 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_6.txt @@ -0,0 +1,10 @@ +Overview of tokenizers +Not quite ready yet :-( This section will be added soon! +Step-by-step recipe to add a model to 🤗 Transformers +Everyone has different preferences of how to port a model so it can be very helpful for you to take a look at summaries +of how other contributors ported models to Hugging Face. Here is a list of community blog posts on how to port a model: + +Porting GPT2 Model by Thomas +Porting WMT19 MT Model by Stas + +From experience, we can tell you that the most important things to keep in mind when adding a model are: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..1ce6aa0a48017d3ba7273e472428b85ac76baa2f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_7.txt @@ -0,0 +1,11 @@ +Don't reinvent the wheel! Most parts of the code you will add for the new 🤗 Transformers model already exist + somewhere in 🤗 Transformers. Take some time to find similar, already existing models and tokenizers you can copy + from. grep and rg are your + friends. Note that it might very well happen that your model's tokenizer is based on one model implementation, and + your model's modeling code on another one. E.g. FSMT's modeling code is based on BART, while FSMT's tokenizer code + is based on XLM. +It's more of an engineering challenge than a scientific challenge. You should spend more time creating an + efficient debugging environment rather than trying to understand all theoretical aspects of the model in the paper. +Ask for help, when you're stuck! Models are the core component of 🤗 Transformers so we at Hugging Face are more + than happy to help you at every step to add your model. Don't hesitate to ask if you notice you are not making + progress. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..5e212dc19838c72351aad509acd57d394dcaccb8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_8.txt @@ -0,0 +1,28 @@ +In the following, we try to give you a general recipe that we found most useful when porting a model to 🤗 Transformers. +The following list is a summary of everything that has to be done to add a model and can be used by you as a To-Do +List: +☠(Optional) Understood the model's theoretical aspects +☠Prepared 🤗 Transformers dev environment +☠Set up debugging environment of the original repository +☠Created script that successfully runs the forward() pass using the original repository and checkpoint +☠Successfully added the model skeleton to 🤗 Transformers +☠Successfully converted original checkpoint to 🤗 Transformers checkpoint +☠Successfully ran forward() pass in 🤗 Transformers that gives identical output to original checkpoint +☠Finished model tests in 🤗 Transformers +☠Successfully added tokenizer in 🤗 Transformers +☠Run end-to-end integration tests +☠Finished docs +☠Uploaded model weights to the Hub +☠Submitted the pull request +☠(Optional) Added a demo notebook +To begin with, we usually recommend starting by getting a good theoretical understanding of BrandNewBert. However, +if you prefer to understand the theoretical aspects of the model on-the-job, then it is totally fine to directly dive +into the BrandNewBert's code-base. This option might suit you better if your engineering skills are better than +your theoretical skill, if you have trouble understanding BrandNewBert's paper, or if you just enjoy programming +much more than reading scientific papers. +1. (Optional) Theoretical aspects of BrandNewBert +You should take some time to read BrandNewBert's paper, if such descriptive work exists. There might be large +sections of the paper that are difficult to understand. If this is the case, this is fine - don't worry! The goal is +not to get a deep theoretical understanding of the paper, but to extract the necessary information required to +effectively re-implement the model in 🤗 Transformers. That being said, you don't have to spend too much time on the +theoretical aspects, but rather focus on the practical ones, namely: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..c1b6f52649494931a3da25bdcfcd56a30d0f62f3 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_model.txt_chunk_9.txt @@ -0,0 +1,14 @@ +What type of model is brand_new_bert? BERT-like encoder-only model? GPT2-like decoder-only model? BART-like + encoder-decoder model? Look at the model_summary if you're not familiar with the differences between those. +What are the applications of brand_new_bert? Text classification? Text generation? Seq2Seq tasks, e.g., + summarization? +What is the novel feature of the model that makes it different from BERT/GPT-2/BART? +Which of the already existing 🤗 Transformers models is most + similar to brand_new_bert? +What type of tokenizer is used? A sentencepiece tokenizer? Word piece tokenizer? Is it the same tokenizer as used + for BERT or BART? + +After you feel like you have gotten a good overview of the architecture of the model, you might want to write to the +Hugging Face team with any questions you might have. This might include questions regarding the model's architecture, +its attention layer, etc. We will be more than happy to help you. +2. Next prepare your environment \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..40b0e609826a1e69acd42713f96100f485638087 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_0.txt @@ -0,0 +1,22 @@ +How to create a custom pipeline? +In this guide, we will see how to create a custom pipeline and share it on the Hub or add it to the +🤗 Transformers library. +First and foremost, you need to decide the raw entries the pipeline will be able to take. It can be strings, raw bytes, +dictionaries or whatever seems to be the most likely desired input. Try to keep these inputs as pure Python as possible +as it makes compatibility easier (even through other languages via JSON). Those will be the inputs of the +pipeline (preprocess). +Then define the outputs. Same policy as the inputs. The simpler, the better. Those will be the outputs of +postprocess method. +Start by inheriting the base class Pipeline with the 4 methods needed to implement preprocess, +_forward, postprocess, and _sanitize_parameters. +thon +from transformers import Pipeline +class MyPipeline(Pipeline): + def _sanitize_parameters(self, **kwargs): + preprocess_kwargs = {} + if "maybe_arg" in kwargs: + preprocess_kwargs["maybe_arg"] = kwargs["maybe_arg"] + return preprocess_kwargs, {}, {} +def preprocess(self, inputs, maybe_arg=2): + model_input = Tensor(inputs["input_ids"]) + return {"model_input": model_input} \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..9f54053e3be62402fe4d0fcbd25225a4ce153db1 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_1.txt @@ -0,0 +1,9 @@ +def _forward(self, model_inputs): + # model_inputs == {"model_input": model_input} + outputs = self.model(**model_inputs) + # Maybe {"logits": Tensor()} + return outputs + +def postprocess(self, model_outputs): + best_class = model_outputs["logits"].softmax(-1) + return best_class \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_10.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_10.txt new file mode 100644 index 0000000000000000000000000000000000000000..16faf10f85f4000a834d9c588d1001b2446302c8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_10.txt @@ -0,0 +1,10 @@ +test_small_model_pt : Define 1 small model for this pipeline (doesn't matter if the results don't make sense) + and test the pipeline outputs. The results should be the same as test_small_model_tf. +test_small_model_tf : Define 1 small model for this pipeline (doesn't matter if the results don't make sense) + and test the pipeline outputs. The results should be the same as test_small_model_pt. +test_large_model_pt (optional): Tests the pipeline on a real pipeline where the results are supposed to + make sense. These tests are slow and should be marked as such. Here the goal is to showcase the pipeline and to make + sure there is no drift in future releases. +test_large_model_tf (optional): Tests the pipeline on a real pipeline where the results are supposed to + make sense. These tests are slow and should be marked as such. Here the goal is to showcase the pipeline and to make + sure there is no drift in future releases. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..1182fd437b4c36851d84e0591bb6969920ec5b29 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_2.txt @@ -0,0 +1,16 @@ +The structure of this breakdown is to support relatively seamless support for CPU/GPU, while supporting doing +pre/postprocessing on the CPU on different threads +preprocess will take the originally defined inputs, and turn them into something feedable to the model. It might +contain more information and is usually a Dict. +_forward is the implementation detail and is not meant to be called directly. forward is the preferred +called method as it contains safeguards to make sure everything is working on the expected device. If anything is +linked to a real model it belongs in the _forward method, anything else is in the preprocess/postprocess. +postprocess methods will take the output of _forward and turn it into the final output that was decided +earlier. +_sanitize_parameters exists to allow users to pass any parameters whenever they wish, be it at initialization +time pipeline(., maybe_arg=4) or at call time pipe = pipeline(); output = pipe(., maybe_arg=4). +The returns of _sanitize_parameters are the 3 dicts of kwargs that will be passed directly to preprocess, +_forward, and postprocess. Don't fill anything if the caller didn't call with any extra parameter. That +allows to keep the default arguments in the function definition which is always more "natural". +A classic example would be a top_k argument in the post processing in classification tasks. +thon \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..9b90c712d7422d55359fd2c719f889c9d61e480f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_3.txt @@ -0,0 +1,22 @@ +pipe = pipeline("my-new-task") +pipe("This is a test") +[{"label": "1-star", "score": 0.8}, {"label": "2-star", "score": 0.1}, {"label": "3-star", "score": 0.05} +{"label": "4-star", "score": 0.025}, {"label": "5-star", "score": 0.025}] +pipe("This is a test", top_k=2) +[{"label": "1-star", "score": 0.8}, {"label": "2-star", "score": 0.1}] + +In order to achieve that, we'll update our postprocess method with a default parameter to 5. and edit +_sanitize_parameters to allow this new parameter. +thon +def postprocess(self, model_outputs, top_k=5): + best_class = model_outputs["logits"].softmax(-1) + # Add logic to handle top_k + return best_class +def _sanitize_parameters(self, **kwargs): + preprocess_kwargs = {} + if "maybe_arg" in kwargs: + preprocess_kwargs["maybe_arg"] = kwargs["maybe_arg"] +postprocess_kwargs = {} +if "top_k" in kwargs: + postprocess_kwargs["top_k"] = kwargs["top_k"] +return preprocess_kwargs, {}, postprocess_kwargs \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..e7fa7cae03e5706a3e6fc766898c95f5c6b44720 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_4.txt @@ -0,0 +1,12 @@ +Try to keep the inputs/outputs very simple and ideally JSON-serializable as it makes the pipeline usage very easy +without requiring users to understand new kinds of objects. It's also relatively common to support many different types +of arguments for ease of use (audio files, which can be filenames, URLs or pure bytes) +Adding it to the list of supported tasks +To register your new-task to the list of supported tasks, you have to add it to the PIPELINE_REGISTRY: +thon +from transformers.pipelines import PIPELINE_REGISTRY +PIPELINE_REGISTRY.register_pipeline( + "new-task", + pipeline_class=MyPipeline, + pt_model=AutoModelForSequenceClassification, +) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..4933b98f96054a82250b03e0320d5f9221875c9d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_5.txt @@ -0,0 +1,12 @@ +You can specify a default model if you want, in which case it should come with a specific revision (which can be the name of a branch or a commit hash, here we took "abcdef") as well as the type: +python +PIPELINE_REGISTRY.register_pipeline( + "new-task", + pipeline_class=MyPipeline, + pt_model=AutoModelForSequenceClassification, + default={"pt": ("user/awesome_model", "abcdef")}, + type="text", # current support type: text, audio, image, multimodal +) +Share your pipeline on the Hub +To share your custom pipeline on the Hub, you just have to save the custom code of your Pipeline subclass in a +python file. For instance, let's say we want to use a custom pipeline for sentence pair classification like this: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..611086557394c22f11071e5fdb3b9dc544f4ff10 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_6.txt @@ -0,0 +1,21 @@ +import numpy as np +from transformers import Pipeline +def softmax(outputs): + maxes = np.max(outputs, axis=-1, keepdims=True) + shifted_exp = np.exp(outputs - maxes) + return shifted_exp / shifted_exp.sum(axis=-1, keepdims=True) +class PairClassificationPipeline(Pipeline): + def _sanitize_parameters(self, **kwargs): + preprocess_kwargs = {} + if "second_text" in kwargs: + preprocess_kwargs["second_text"] = kwargs["second_text"] + return preprocess_kwargs, {}, {} +def preprocess(self, text, second_text=None): + return self.tokenizer(text, text_pair=second_text, return_tensors=self.framework) + +def _forward(self, model_inputs): + return self.model(**model_inputs) + +def postprocess(self, model_outputs): + logits = model_outputs.logits[0].numpy() + probabilities = softmax(logits) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..fa4b9e7c493891fab6884d4c02b2e1a802f09db8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_7.txt @@ -0,0 +1,18 @@ +best_class = np.argmax(probabilities) + label = self.model.config.id2label[best_class] + score = probabilities[best_class].item() + logits = logits.tolist() + return {"label": label, "score": score, "logits": logits} + +The implementation is framework agnostic, and will work for PyTorch and TensorFlow models. If we have saved this in +a file named pair_classification.py, we can then import it and register it like this: + +from pair_classification import PairClassificationPipeline +from transformers.pipelines import PIPELINE_REGISTRY +from transformers import AutoModelForSequenceClassification, TFAutoModelForSequenceClassification +PIPELINE_REGISTRY.register_pipeline( + "pair-classification", + pipeline_class=PairClassificationPipeline, + pt_model=AutoModelForSequenceClassification, + tf_model=TFAutoModelForSequenceClassification, +) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..bfdd72a30b70fcfd7d672ae7fe1562b128f436c4 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_8.txt @@ -0,0 +1,16 @@ +Once this is done, we can use it with a pretrained model. For instance sgugger/finetuned-bert-mrpc has been +fine-tuned on the MRPC dataset, which classifies pairs of sentences as paraphrases or not. + +from transformers import pipeline +classifier = pipeline("pair-classification", model="sgugger/finetuned-bert-mrpc") + +Then we can share it on the Hub by using the push_to_hub method: +py +classifier.push_to_hub("test-dynamic-pipeline") +This will copy the file where you defined PairClassificationPipeline inside the folder "test-dynamic-pipeline", +along with saving the model and tokenizer of the pipeline, before pushing everything into the repository +{your_username}/test-dynamic-pipeline. After that, anyone can use it as long as they provide the option +trust_remote_code=True: + +from transformers import pipeline +classifier = pipeline(model="{your_username}/test-dynamic-pipeline", trust_remote_code=True) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..246ec11c37958abd40727071e4b3eb28d8e6e184 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_add_new_pipeline.txt_chunk_9.txt @@ -0,0 +1,11 @@ +Add the pipeline to 🤗 Transformers +If you want to contribute your pipeline to 🤗 Transformers, you will need to add a new module in the pipelines submodule +with the code of your pipeline, then add it to the list of tasks defined in pipelines/__init__.py. +Then you will need to add tests. Create a new file tests/test_pipelines_MY_PIPELINE.py with examples of the other tests. +The run_pipeline_test function will be very generic and run on small random models on every possible +architecture as defined by model_mapping and tf_model_mapping. +This is very important to test future compatibility, meaning if someone adds a new model for +XXXForQuestionAnswering then the pipeline test will attempt to run on it. Because the models are random it's +impossible to check for actual values, that's why there is a helper ANY that will simply attempt to match the +output of the pipeline TYPE. +You also need to implement 2 (ideally 4) tests. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..1644ec24586d165086fb3e22fcc0b0b731f5fb0f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_0.txt @@ -0,0 +1,18 @@ +Agents and tools +[[open-in-colab]] +What is an agent? +Large Language Models (LLMs) trained to perform causal language modeling can tackle a wide range of tasks, but they often struggle with basic tasks like logic, calculation, and search. When prompted in domains in which they do not perform well, they often fail to generate the answer we expect them to. +One approach to overcome this weakness is to create an agent. +An agent is a system that uses an LLM as its engine, and it has access to functions called tools. +These tools are functions for performing a task, and they contain all necessary description for the agent to properly use them. +The agent can be programmed to: +- devise a series of actions/tools and run them all at once like the [CodeAgent] for example +- plan and execute actions/tools one by one and wait for the outcome of each action before launching the next one like the [ReactJsonAgent] for example +Types of agents +Code agent +This agent has a planning step, then generates python code to execute all its actions at once. It natively handles different input and output types for its tools, thus it is the recommended choice for multimodal tasks. +React agents +This is the go-to agent to solve reasoning tasks, since the ReAct framework (Yao et al., 2022) makes it really efficient to think on the basis of its previous observations. +We implement two versions of ReactJsonAgent: +- [ReactJsonAgent] generates tool calls as a JSON in its output. +- [ReactCodeAgent] is a new type of ReactJsonAgent that generates its tool calls as blobs of code, which works really well for LLMs that have strong coding performance. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..cd8e89e7f6700e532d708cc3478cc2ad07bef300 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_1.txt @@ -0,0 +1,17 @@ +[!TIP] +Read Open-source LLMs as LangChain Agents blog post to learn more the ReAct agent. + +For example, here is how a ReAct agent would work its way through the following question. +3 + +agent.run( + "How many more blocks (also denoted as layers) in BERT base encoder than the encoder from the architecture proposed in Attention is All You Need?", + ) +=====New task===== +How many more blocks (also denoted as layers) in BERT base encoder than the encoder from the architecture proposed in Attention is All You Need? +====Agent is executing the code below: +bert_blocks = search(query="number of blocks in BERT base encoder") +print("BERT blocks:", bert_blocks) +==== +Print outputs: +BERT blocks: twelve encoder blocks \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_10.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_10.txt new file mode 100644 index 0000000000000000000000000000000000000000..8149e717d759f1435d51106d6c3efe70facdc287 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_10.txt @@ -0,0 +1,11 @@ +The system prompt includes: +- An introduction that explains how the agent should behave and what tools are. +- A description of all the tools that is defined by a <> token that is dynamically replaced at runtime with the tools defined/chosen by the user. + - The tool description comes from the tool attributes, name, description, inputs and output_type, and a simple jinja2 template that you can refine. +- The expected output format. +You could improve the system prompt, for example, by adding an explanation of the output format. +For maximum flexibility, you can overwrite the whole system prompt template by passing your custom prompt as an argument to the system_prompt parameter. +thon +from transformers import ReactJsonAgent +from transformers.agents import PythonInterpreterTool +agent = ReactJsonAgent(tools=[PythonInterpreterTool()], system_prompt="{your_custom_prompt}") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_11.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_11.txt new file mode 100644 index 0000000000000000000000000000000000000000..93f44193993a08b35dc269a70764e01f8a39525c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_11.txt @@ -0,0 +1,10 @@ +[!WARNING] +Please make sure to define the <> string somewhere in the template so the agent is aware +of the available tools. + +Tools +A tool is an atomic function to be used by an agent. +You can for instance check the [PythonInterpreterTool]: it has a name, a description, input descriptions, an output type, and a __call__ method to perform the action. +When the agent is initialized, the tool attributes are used to generate a tool description which is baked into the agent's system prompt. This lets the agent know which tools it can use and why. +Default toolbox +Transformers comes with a default toolbox for empowering agents, that you can add to your agent upon initialization with argument add_base_tools = True: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_12.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_12.txt new file mode 100644 index 0000000000000000000000000000000000000000..e4b191ae9b6f8ae83b3c4bf89b4ab4f6a2f17fc3 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_12.txt @@ -0,0 +1,12 @@ +Document question answering: given a document (such as a PDF) in image format, answer a question on this document (Donut) +Image question answering: given an image, answer a question on this image (VILT) +Speech to text: given an audio recording of a person talking, transcribe the speech into text (Whisper) +Text to speech: convert text to speech (SpeechT5) +Translation: translates a given sentence from source language to target language. +Python code interpreter: runs your the LLM generated Python code in a secure environment. This tool will only be added to [ReactJsonAgent] if you use add_base_tools=True, since code-based tools can already execute Python code + +You can manually use a tool by calling the [load_tool] function and a task to perform. +thon +from transformers import load_tool +tool = load_tool("text-to-speech") +audio = tool("This is a text to speech tool") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_13.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_13.txt new file mode 100644 index 0000000000000000000000000000000000000000..14104fb8dcdc5571453a4ac6ee7cb92de1517b5d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_13.txt @@ -0,0 +1,9 @@ +Create a new tool +You can create your own tool for use cases not covered by the default tools from Hugging Face. +For example, let's create a tool that returns the most downloaded model for a given task from the Hub. +You'll start with the code below. +thon +from huggingface_hub import list_models +task = "text-classification" +model = next(iter(list_models(filter=task, sort="downloads", direction=-1))) +print(model.id) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_14.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_14.txt new file mode 100644 index 0000000000000000000000000000000000000000..ae2423dcb6eae50d3637860a174d22bc0658bc97 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_14.txt @@ -0,0 +1,23 @@ +This code can be converted into a class that inherits from the [Tool] superclass. +The custom tool needs: +- An attribute name, which corresponds to the name of the tool itself. The name usually describes what the tool does. Since the code returns the model with the most downloads for a task, let's name is model_download_counter. +- An attribute description is used to populate the agent's system prompt. +- An inputs attribute, which is a dictionary with keys "type" and "description". It contains information that helps the Python interpreter make educated choices about the input. +- An output_type attribute, which specifies the output type. +- A forward method which contains the inference code to be executed. +thon +from transformers import Tool +from huggingface_hub import list_models +class HFModelDownloadsTool(Tool): + name = "model_download_counter" + description = ( + "This is a tool that returns the most downloaded model of a given task on the Hugging Face Hub. " + "It returns the name of the checkpoint." + ) +inputs = { + "task": { + "type": "text", + "description": "the task category (such as text-classification, depth-estimation, etc)", + } +} +output_type = "text" \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_15.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_15.txt new file mode 100644 index 0000000000000000000000000000000000000000..955d84186a290df0383a2c288a315a344b5c6f7c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_15.txt @@ -0,0 +1,8 @@ +def forward(self, task: str): + model = next(iter(list_models(filter=task, sort="downloads", direction=-1))) + return model.id + +Now that the custom HfModelDownloadsTool class is ready, you can save it to a file named model_downloads.py and import it for use. +thon +from model_downloads import HFModelDownloadsTool +tool = HFModelDownloadsTool() \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_16.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_16.txt new file mode 100644 index 0000000000000000000000000000000000000000..a8a21d85d23424ca6ff6de61c1bc20b251a2e3e8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_16.txt @@ -0,0 +1,11 @@ +You can also share your custom tool to the Hub by calling [~Tool.push_to_hub] on the tool. Make sure you've created a repository for it on the Hub and are using a token with read access. +python +tool.push_to_hub("{your_username}/hf-model-downloads") +Load the tool with the [~Tool.load_tool] function and pass it to the tools parameter in your agent. +thon +from transformers import load_tool, CodeAgent +model_download_tool = load_tool("m-ric/hf-model-downloads") +agent = CodeAgent(tools=[model_download_tool], llm_engine=llm_engine) +agent.run( + "Can you give me the name of the model that has the most downloads in the 'text-to-video' task on the Hugging Face Hub?" +) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_17.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_17.txt new file mode 100644 index 0000000000000000000000000000000000000000..a2cf0f3e3d68fb659cc30b3c798c134a66c10b0d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_17.txt @@ -0,0 +1,17 @@ +You get the following: +text +======== New task ======== +Can you give me the name of the model that has the most downloads in the 'text-to-video' task on the Hugging Face Hub? +==== Agent is executing the code below: +most_downloaded_model = model_download_counter(task="text-to-video") +print(f"The most downloaded model for the 'text-to-video' task is {most_downloaded_model}.") +==== +And the output: +"The most downloaded model for the 'text-to-video' task is ByteDance/AnimateDiff-Lightning." +Manage agent toolbox +If you have already initialized an agent, it is inconvenient to reinitialize it from scratch with a tool you want to use. With Transformers, you can manage an agent's toolbox by adding or replacing a tool. +Let's add the model_download_tool to an existing agent initialized with only the default toolbox. +thon +from transformers import CodeAgent +agent = CodeAgent(tools=[], llm_engine=llm_engine, add_base_tools=True) +agent.toolbox.add_tool(model_download_tool) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_18.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_18.txt new file mode 100644 index 0000000000000000000000000000000000000000..ff3f81c865872b7438342e4fae407dc6f9b02c3d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_18.txt @@ -0,0 +1,11 @@ +Now we can leverage both the new tool and the previous text-to-speech tool: +python +agent.run( + "Can you read out loud the name of the model that has the most downloads in the 'text-to-video' task on the Hugging Face Hub and return the audio?" +) +| Audio | +|------------------------------------------------------------------------------------------------------------------------------------------------------| +| | + +[!WARNING] +Beware when adding tools to an agent that already works well because it can bias selection towards your tool or select another tool other than the one already defined. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_19.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_19.txt new file mode 100644 index 0000000000000000000000000000000000000000..e49bc31203444b0a6bf4f637d7b237b3561651ab --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_19.txt @@ -0,0 +1,11 @@ +Use the agent.toolbox.update_tool() method to replace an existing tool in the agent's toolbox. +This is useful if your new tool is a one-to-one replacement of the existing tool because the agent already knows how to perform that specific task. +Just make sure the new tool follows the same API as the replaced tool or adapt the system prompt template to ensure all examples using the replaced tool are updated. +Use a collection of tools +You can leverage tool collections by using the ToolCollection object, with the slug of the collection you want to use. +Then pass them as a list to initialize you agent, and start using them! + +from transformers import ToolCollection, ReactCodeAgent +image_tool_collection = ToolCollection(collection_slug="huggingface-tools/diffusion-tools-6630bb19a942c2306a2cdb6f") +agent = ReactCodeAgent(tools=[*image_tool_collection.tools], add_base_tools=True) +agent.run("Please draw me a picture of rivers and lakes.") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..0f271e4b04a00806ed152002a4bc04ff41ddd95d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_2.txt @@ -0,0 +1,19 @@ +====Agent is executing the code below: +attention_layer = search(query="number of layers in Attention is All You Need") +print("Attention layers:", attention_layer) +==== +Print outputs: +Attention layers: Encoder: The encoder is composed of a stack of N = 6 identical layers. Each layer has two sub-layers. The first is a multi-head self-attention mechanism, and the second is a simple, position- 2 Page 3 Figure 1: The Transformer - model architecture. +====Agent is executing the code below: +bert_blocks = 12 +attention_layers = 6 +diff = bert_blocks - attention_layers +print("Difference in blocks:", diff) +final_answer(diff) +==== +Print outputs: +Difference in blocks: 6 +Final answer: 6 + +How can I build an agent? +To initialize an agent, you need these arguments: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_20.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_20.txt new file mode 100644 index 0000000000000000000000000000000000000000..8ba64d33cef5e569a967722237812cb5b3ad5889 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_20.txt @@ -0,0 +1,13 @@ +To speed up the start, tools are loaded only if called by the agent. +This gets you this image: + +Use gradio-tools +gradio-tools is a powerful library that allows using Hugging +Face Spaces as tools. It supports many existing Spaces as well as custom Spaces. +Transformers supports gradio_tools with the [Tool.from_gradio] method. For example, let's use the StableDiffusionPromptGeneratorTool from gradio-tools toolkit for improving prompts to generate better images. +Import and instantiate the tool, then pass it to the Tool.from_gradio method: +thon +from gradio_tools import StableDiffusionPromptGeneratorTool +from transformers import Tool, load_tool, CodeAgent +gradio_prompt_generator_tool = StableDiffusionPromptGeneratorTool() +prompt_generator_tool = Tool.from_gradio(gradio_prompt_generator_tool) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_21.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_21.txt new file mode 100644 index 0000000000000000000000000000000000000000..386ece0affb794589dd755cd007dbb5fee4334ed --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_21.txt @@ -0,0 +1,21 @@ +Now you can use it just like any other tool. For example, let's improve the prompt a rabbit wearing a space suit. +thon +image_generation_tool = load_tool('huggingface-tools/text-to-image') +agent = CodeAgent(tools=[prompt_generator_tool, image_generation_tool], llm_engine=llm_engine) +agent.run( + "Improve this prompt, then generate an image of it.", prompt='A rabbit wearing a space suit' +) + +The model adequately leverages the tool: +text +======== New task ======== +Improve this prompt, then generate an image of it. +You have been provided with these initial arguments: {'prompt': 'A rabbit wearing a space suit'}. +==== Agent is executing the code below: +improved_prompt = StableDiffusionPromptGenerator(query=prompt) +while improved_prompt == "QUEUE_FULL": + improved_prompt = StableDiffusionPromptGenerator(query=prompt) +print(f"The improved prompt is {improved_prompt}.") +image = image_generator(prompt=improved_prompt) +==== +Before finally generating the image: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_22.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_22.txt new file mode 100644 index 0000000000000000000000000000000000000000..ec62d5c0911ef7cc900b7196aef0cac78307e0a8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_22.txt @@ -0,0 +1,14 @@ +[!WARNING] +gradio-tools require textual inputs and outputs even when working with different modalities like image and audio objects. Image and audio inputs and outputs are currently incompatible. + +Use LangChain tools +We love Langchain and think it has a very compelling suite of tools. +To import a tool from LangChain, use the from_langchain() method. +Here is how you can use it to recreate the intro's search result using a LangChain web search tool. +thon +from langchain.agents import load_tools +from transformers import Tool, ReactCodeAgent +search_tool = Tool.from_langchain(load_tools(["serpapi"])[0]) +agent = ReactCodeAgent(tools=[search_tool]) +agent.run("How many more blocks (also denoted as layers) in BERT base encoder than the encoder from the architecture proposed in Attention is All You Need?") +``` \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..ae1f8d8bab8ef8ab7cc6715ad2f8069805bed381 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_3.txt @@ -0,0 +1,10 @@ +How can I build an agent? +To initialize an agent, you need these arguments: + +an LLM to power your agent - the agent is not exactly the LLM, it’s more like the agent is a program that uses an LLM as its engine. +a system prompt: what the LLM engine will be prompted with to generate its output +a toolbox from which the agent pick tools to execute +a parser to extract from the LLM output which tools are to call and with which arguments + +Upon initialization of the agent system, the tool attributes are used to generate a tool description, then baked into the agent’s system_prompt to let it know which tools it can use and why. +To start with, please install the agents extras in order to install all default dependencies. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..16dfc240c0b39e7276461575119f0fb22a23297b --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_4.txt @@ -0,0 +1,10 @@ +pip install transformers[agents] +Build your LLM engine by defining a llm_engine method which accepts a list of messages and returns text. This callable also needs to accept a stop argument that indicates when to stop generating. +thon +from huggingface_hub import login, InferenceClient +login("") +client = InferenceClient(model="meta-llama/Meta-Llama-3-70B-Instruct") +def llm_engine(messages, stop_sequences=["Task"]) -> str: + response = client.chat_completion(messages, stop=stop_sequences, max_tokens=1000) + answer = response.choices[0].message.content + return answer \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..34f71a58b2b06a27909c825c267c04bb7a9653bd --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_5.txt @@ -0,0 +1,13 @@ +You could use any llm_engine method as long as: +1. it follows the messages format for its input (List[Dict[str, str]]) and returns a str +2. it stops generating outputs at the sequences passed in the argument stop +You also need a tools argument which accepts a list of Tools. You can provide an empty list for tools, but use the default toolbox with the optional argument add_base_tools=True. +Now you can create an agent, like [CodeAgent], and run it. For convenience, we also provide the [HfEngine] class that uses huggingface_hub.InferenceClient under the hood. +thon +from transformers import CodeAgent, HfEngine +llm_engine = HfEngine(model="meta-llama/Meta-Llama-3-70B-Instruct") +agent = CodeAgent(tools=[], llm_engine=llm_engine, add_base_tools=True) +agent.run( + "Could you translate this sentence from French, say it out loud and return the audio.", + sentence="Où est la boulangerie la plus proche?", +) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..02608446134cc0b45cb5da8275f24228e385421e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_6.txt @@ -0,0 +1,16 @@ +This will be handy in case of emergency baguette need! +You can even leave the argument llm_engine undefined, and an [HfEngine] will be created by default. +thon +from transformers import CodeAgent +agent = CodeAgent(tools=[], add_base_tools=True) +agent.run( + "Could you translate this sentence from French, say it out loud and give me the audio.", + sentence="Où est la boulangerie la plus proche?", +) + +Note that we used an additional sentence argument: you can pass text as additional arguments to the model. +You can also use this to indicate the path to local or remote files for the model to use: + +from transformers import ReactCodeAgent +agent = ReactCodeAgent(tools=[], llm_engine=llm_engine, add_base_tools=True) +agent.run("Why does Mike not know many people in New York?", audio="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/transformers/recording.mp3") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..3cf339fd5d78bfb04cd9e6ebf235e22a6970ebc7 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_7.txt @@ -0,0 +1,11 @@ +The prompt and output parser were automatically defined, but you can easily inspect them by calling the system_prompt_template on your agent. +python +print(agent.system_prompt_template) +It's important to explain as clearly as possible the task you want to perform. +Every [~Agent.run] operation is independent, and since an agent is powered by an LLM, minor variations in your prompt might yield completely different results. +You can also run an agent consecutively for different tasks: each time the attributes agent.task and agent.logs will be re-initialized. +Code execution +A Python interpreter executes the code on a set of inputs passed along with your tools. +This should be safe because the only functions that can be called are the tools you provided (especially if it's only tools by Hugging Face) and the print function, so you're already limited in what can be executed. +The Python interpreter also doesn't allow imports by default outside of a safe list, so all the most obvious attacks shouldn't be an issue. +You can still authorize additional imports by passing the authorized modules as a list of strings in argument additional_authorized_imports upon initialization of your [ReactCodeAgent] or [CodeAgent]: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..c6d34b2445064e0700a73eff91edb662cd7640b1 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_8.txt @@ -0,0 +1,11 @@ +from transformers import ReactCodeAgent +agent = ReactCodeAgent(tools=[], additional_authorized_imports=['requests', 'bs4']) +agent.run("Could you get me the title of the page at url 'https://huggingface.co/blog'?") + +() +'Hugging Face – Blog' + +The execution will stop at any code trying to perform an illegal operation or if there is a regular Python error with the code generated by the agent. + +[!WARNING] +The LLM can generate arbitrary code that will then be executed: do not add any unsafe imports! \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..ea19a4593f7e01e840759e2fe66c6815bdd5b4f2 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_agents.txt_chunk_9.txt @@ -0,0 +1,22 @@ +The system prompt +An agent, or rather the LLM that drives the agent, generates an output based on the system prompt. The system prompt can be customized and tailored to the intended task. For example, check the system prompt for the [ReactCodeAgent] (below version is slightly simplified). +```text +You will be given a task to solve as best you can. +You have access to the following tools: +<> +To solve the task, you must plan forward to proceed in a series of steps, in a cycle of 'Thought:', 'Code:', and 'Observation:' sequences. +At each step, in the 'Thought:' sequence, you should first explain your reasoning towards solving the task, then the tools that you want to use. +Then in the 'Code:' sequence, you shold write the code in simple Python. The code sequence must end with '/End code' sequence. +During each intermediate step, you can use 'print()' to save whatever important information you will then need. +These print outputs will then be available in the 'Observation:' field, for using this information as input for the next step. +In the end you have to return a final answer using the final_answer tool. +Here are a few examples using notional tools: +{examples} +Above example were using notional tools that might not exist for you. You only have acces to those tools: +<> +You also can perform computations in the python code you generate. +Always provide a 'Thought:' and a 'Code:\npy' sequence ending with '' sequence. You MUST provide at least the 'Code:' sequence to move forward. +Remember to not perform too many operations in a single code block! You should split the task into intermediate code blocks. +Print results at the end of each step to save the intermediate results. Then use final_answer() to return the final result. +Remember to make sure that variables you use are all defined. +Now Begin! \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_attention.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_attention.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..24331c2df8e2f141794cf3ed1a50c8a3110f0a12 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_attention.txt_chunk_0.txt @@ -0,0 +1,19 @@ +Attention mechanisms +Most transformer models use full attention in the sense that the attention matrix is square. It can be a big +computational bottleneck when you have long texts. Longformer and reformer are models that try to be more efficient and +use a sparse version of the attention matrix to speed up training. +LSH attention +Reformer uses LSH attention. In the softmax(QK^t), only the biggest elements (in the softmax +dimension) of the matrix QK^t are going to give useful contributions. So for each query q in Q, we can consider only +the keys k in K that are close to q. A hash function is used to determine if q and k are close. The attention mask is +modified to mask the current token (except at the first position), because it will give a query and a key equal (so +very similar to each other). Since the hash can be a bit random, several hash functions are used in practice +(determined by a n_rounds parameter) and then are averaged together. +Local attention +Longformer uses local attention: often, the local context (e.g., what are the two tokens to the +left and right?) is enough to take action for a given token. Also, by stacking attention layers that have a small +window, the last layer will have a receptive field of more than just the tokens in the window, allowing them to build a +representation of the whole sentence. +Some preselected input tokens are also given global attention: for those few tokens, the attention matrix can access +all tokens and this process is symmetric: all other tokens have access to those specific tokens (on top of the ones in +their local window). This is shown in Figure 2d of the paper, see below for a sample attention mask: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_attention.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_attention.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..03744493d9f16ee0fdeff415c5b032f41f006161 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_attention.txt_chunk_1.txt @@ -0,0 +1,12 @@ +Using those attention matrices with less parameters then allows the model to have inputs having a bigger sequence +length. +Other tricks +Axial positional encodings +Reformer uses axial positional encodings: in traditional transformer models, the positional encoding +E is a matrix of size \(l\) by \(d\), \(l\) being the sequence length and \(d\) the dimension of the +hidden state. If you have very long texts, this matrix can be huge and take way too much space on the GPU. To alleviate +that, axial positional encodings consist of factorizing that big matrix E in two smaller matrices E1 and E2, with +dimensions \(l_{1} \times d_{1}\) and \(l_{2} \times d_{2}\), such that \(l_{1} \times l_{2} = l\) and +\(d_{1} + d_{2} = d\) (with the product for the lengths, this ends up being way smaller). The embedding for time +step \(j\) in E is obtained by concatenating the embeddings for timestep \(j \% l1\) in E1 and \(j // l1\) +in E2. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..7fffe343ea8f5b84747043443a431b38fda23105 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_0.txt @@ -0,0 +1,2 @@ +Load pretrained instances with an AutoClass +With so many different Transformer architectures, it can be challenging to create one for your checkpoint. As a part of 🤗 Transformers core philosophy to make the library easy, simple and flexible to use, an AutoClass automatically infers and loads the correct architecture from a given checkpoint. The from_pretrained() method lets you quickly load a pretrained model for any architecture so you don't have to devote time and resources to train a model from scratch. Producing this type of checkpoint-agnostic code means if your code works for one checkpoint, it will work with another checkpoint - as long as it was trained for a similar task - even if the architecture is different. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..c31422dbbdeaae8874ddc568de0451243cf20123 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_1.txt @@ -0,0 +1,19 @@ +Remember, architecture refers to the skeleton of the model and checkpoints are the weights for a given architecture. For example, BERT is an architecture, while google-bert/bert-base-uncased is a checkpoint. Model is a general term that can mean either architecture or checkpoint. + +In this tutorial, learn to: + +Load a pretrained tokenizer. +Load a pretrained image processor +Load a pretrained feature extractor. +Load a pretrained processor. +Load a pretrained model. +Load a model as a backbone. + +AutoTokenizer +Nearly every NLP task begins with a tokenizer. A tokenizer converts your input into a format that can be processed by the model. +Load a tokenizer with [AutoTokenizer.from_pretrained]: + +from transformers import AutoTokenizer +tokenizer = AutoTokenizer.from_pretrained("google-bert/bert-base-uncased") + +Then tokenize your input as shown below: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..e632f2f4fd83f8cbfaae2503e93b5f63af393f3b --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_2.txt @@ -0,0 +1,19 @@ +Then tokenize your input as shown below: + +sequence = "In a hole in the ground there lived a hobbit." +print(tokenizer(sequence)) +{'input_ids': [101, 1999, 1037, 4920, 1999, 1996, 2598, 2045, 2973, 1037, 7570, 10322, 4183, 1012, 102], + 'token_type_ids': [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], + 'attention_mask': [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]} + +AutoImageProcessor +For vision tasks, an image processor processes the image into the correct input format. + +from transformers import AutoImageProcessor +image_processor = AutoImageProcessor.from_pretrained("google/vit-base-patch16-224") + +AutoBackbone + +A Swin backbone with multiple stages for outputting a feature map. + +The [AutoBackbone] lets you use pretrained models as backbones to get feature maps from different stages of the backbone. You should specify one of the following parameters in [~PretrainedConfig.from_pretrained]: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..1313329e4064b9b353ac4394e0dc5288a112b955 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_3.txt @@ -0,0 +1,8 @@ +out_indices is the index of the layer you'd like to get the feature map from +out_features is the name of the layer you'd like to get the feature map from + +These parameters can be used interchangeably, but if you use both, make sure they're aligned with each other! If you don't pass any of these parameters, the backbone returns the feature map from the last layer. + +A feature map from the first stage of the backbone. The patch partition refers to the model stem. + +For example, in the above diagram, to return the feature map from the first stage of the Swin backbone, you can set out_indices=(1,): \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..fb367919a5daaa574bf68b8a1e36720e353b9b02 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_4.txt @@ -0,0 +1,20 @@ +from transformers import AutoImageProcessor, AutoBackbone +import torch +from PIL import Image +import requests +url = "http://images.cocodataset.org/val2017/000000039769.jpg" +image = Image.open(requests.get(url, stream=True).raw) +processor = AutoImageProcessor.from_pretrained("microsoft/swin-tiny-patch4-window7-224") +model = AutoBackbone.from_pretrained("microsoft/swin-tiny-patch4-window7-224", out_indices=(1,)) +inputs = processor(image, return_tensors="pt") +outputs = model(**inputs) +feature_maps = outputs.feature_maps + +Now you can access the feature_maps object from the first stage of the backbone: + +list(feature_maps[0].shape) +[1, 96, 56, 56] + +AutoFeatureExtractor +For audio tasks, a feature extractor processes the audio signal the correct input format. +Load a feature extractor with [AutoFeatureExtractor.from_pretrained]: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..542b87579a934515b05f9b5ee237d1735c105054 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_5.txt @@ -0,0 +1,18 @@ +from transformers import AutoFeatureExtractor +feature_extractor = AutoFeatureExtractor.from_pretrained( + "ehcalabres/wav2vec2-lg-xlsr-en-speech-emotion-recognition" + ) + +AutoProcessor +Multimodal tasks require a processor that combines two types of preprocessing tools. For example, the LayoutLMV2 model requires an image processor to handle images and a tokenizer to handle text; a processor combines both of them. +Load a processor with [AutoProcessor.from_pretrained]: + +from transformers import AutoProcessor +processor = AutoProcessor.from_pretrained("microsoft/layoutlmv2-base-uncased") + +AutoModel + +The AutoModelFor classes let you load a pretrained model for a given task (see here for a complete list of available tasks). For example, load a model for sequence classification with [AutoModelForSequenceClassification.from_pretrained]: + +from transformers import AutoModelForSequenceClassification +model = AutoModelForSequenceClassification.from_pretrained("distilbert/distilbert-base-uncased") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..e5c8f18ac97a9d0daa1cced11667b6de718565cc --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_6.txt @@ -0,0 +1,7 @@ +Easily reuse the same checkpoint to load an architecture for a different task: + +from transformers import AutoModelForTokenClassification +model = AutoModelForTokenClassification.from_pretrained("distilbert/distilbert-base-uncased") + +For PyTorch models, the from_pretrained() method uses torch.load() which internally uses pickle and is known to be insecure. In general, never load a model that could have come from an untrusted source, or that could have been tampered with. This security risk is partially mitigated for public models hosted on the Hugging Face Hub, which are scanned for malware at each commit. See the Hub documentation for best practices like signed commit verification with GPG. +TensorFlow and Flax checkpoints are not affected, and can be loaded within PyTorch architectures using the from_tf and from_flax kwargs for the from_pretrained method to circumvent this issue. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..baf8e33470a6592f2a22e0cae5a81462e68073db --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_7.txt @@ -0,0 +1,11 @@ +Generally, we recommend using the AutoTokenizer class and the AutoModelFor class to load pretrained instances of models. This will ensure you load the correct architecture every time. In the next tutorial, learn how to use your newly loaded tokenizer, image processor, feature extractor and processor to preprocess a dataset for fine-tuning. + +Finally, the TFAutoModelFor classes let you load a pretrained model for a given task (see here for a complete list of available tasks). For example, load a model for sequence classification with [TFAutoModelForSequenceClassification.from_pretrained]: + +from transformers import TFAutoModelForSequenceClassification +model = TFAutoModelForSequenceClassification.from_pretrained("distilbert/distilbert-base-uncased") + +Easily reuse the same checkpoint to load an architecture for a different task: + +from transformers import TFAutoModelForTokenClassification +model = TFAutoModelForTokenClassification.from_pretrained("distilbert/distilbert-base-uncased") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..22567d54cf0e10c9b5e17c6510efa451df141a52 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_autoclass_tutorial.txt_chunk_8.txt @@ -0,0 +1 @@ +Generally, we recommend using the AutoTokenizer class and the TFAutoModelFor class to load pretrained instances of models. This will ensure you load the correct architecture every time. In the next tutorial, learn how to use your newly loaded tokenizer, image processor, feature extractor and processor to preprocess a dataset for fine-tuning. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..bff94fec35825f4ab172b0be879990cd9b7a35f3 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_0.txt @@ -0,0 +1,13 @@ +Benchmarks + +Hugging Face's Benchmarking tools are deprecated and it is advised to use external Benchmarking libraries to measure the speed +and memory complexity of Transformer models. + +[[open-in-colab]] +Let's take a look at how 🤗 Transformers models can be benchmarked, best practices, and already available benchmarks. +A notebook explaining in more detail how to benchmark 🤗 Transformers models can be found here. +How to benchmark 🤗 Transformers models +The classes [PyTorchBenchmark] and [TensorFlowBenchmark] allow to flexibly benchmark 🤗 Transformers models. The benchmark classes allow us to measure the peak memory usage and required time for both inference and training. + +Hereby, inference is defined by a single forward pass, and training is defined by a single forward pass and +backward pass. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..0f24075ca6a0b1a78d75ceefa9cb3e8cd8823e0a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_1.txt @@ -0,0 +1,13 @@ +The benchmark classes [PyTorchBenchmark] and [TensorFlowBenchmark] expect an object of type [PyTorchBenchmarkArguments] and +[TensorFlowBenchmarkArguments], respectively, for instantiation. [PyTorchBenchmarkArguments] and [TensorFlowBenchmarkArguments] are data classes and contain all relevant configurations for their corresponding benchmark class. In the following example, it is shown how a BERT model of type bert-base-cased can be benchmarked. + +from transformers import PyTorchBenchmark, PyTorchBenchmarkArguments +args = PyTorchBenchmarkArguments(models=["google-bert/bert-base-uncased"], batch_sizes=[8], sequence_lengths=[8, 32, 128, 512]) +benchmark = PyTorchBenchmark(args) + +py +from transformers import TensorFlowBenchmark, TensorFlowBenchmarkArguments +args = TensorFlowBenchmarkArguments( + models=["google-bert/bert-base-uncased"], batch_sizes=[8], sequence_lengths=[8, 32, 128, 512] + ) +benchmark = TensorFlowBenchmark(args) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_10.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_10.txt new file mode 100644 index 0000000000000000000000000000000000000000..62aed9be568f13abdeb9ae2223253152a77a35a9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_10.txt @@ -0,0 +1,16 @@ +==================== INFERENCE - MEMORY - RESULT ==================== +Model Name Batch Size Seq Length Memory in MB +bert-base 8 8 1277 +bert-base 8 32 1281 +bert-base 8 128 1307 +bert-base 8 512 1539 +bert-384-hid 8 8 1005 +bert-384-hid 8 32 1027 +bert-384-hid 8 128 1035 +bert-384-hid 8 512 1255 +bert-6-lay 8 8 1097 +bert-6-lay 8 32 1101 +bert-6-lay 8 128 1127 +bert-6-lay 8 512 1359 + +==================== ENVIRONMENT INFORMATION ==================== \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_11.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_11.txt new file mode 100644 index 0000000000000000000000000000000000000000..037200d3e66c37159fc7ca3904d8c2aa76697445 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_11.txt @@ -0,0 +1,27 @@ +==================== ENVIRONMENT INFORMATION ==================== + +transformers_version: 2.11.0 +framework: PyTorch +use_torchscript: False +framework_version: 1.4.0 +python_version: 3.6.10 +system: Linux +cpu: x86_64 +architecture: 64bit +date: 2020-06-29 +time: 09:35:25.143267 +fp16: False +use_multiprocessing: True +only_pretrain_model: False +cpu_ram_mb: 32088 +use_gpu: True +num_gpus: 1 +gpu: TITAN RTX +gpu_ram_mb: 24217 +gpu_power_watts: 280.0 +gpu_performance_state: 2 +use_tpu: False + +py + +from transformers import TensorFlowBenchmark, TensorFlowBenchmarkArguments, BertConfig \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_12.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_12.txt new file mode 100644 index 0000000000000000000000000000000000000000..8756855598e93bd0b257b52f19ceb5132c6657ec --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_12.txt @@ -0,0 +1,11 @@ +from transformers import TensorFlowBenchmark, TensorFlowBenchmarkArguments, BertConfig + +args = TensorFlowBenchmarkArguments( + models=["bert-base", "bert-384-hid", "bert-6-lay"], batch_sizes=[8], sequence_lengths=[8, 32, 128, 512] + ) +config_base = BertConfig() +config_384_hid = BertConfig(hidden_size=384) +config_6_lay = BertConfig(num_hidden_layers=6) +benchmark = TensorFlowBenchmark(args, configs=[config_base, config_384_hid, config_6_lay]) +benchmark.run() +==================== INFERENCE - SPEED - RESULT ==================== \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_13.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_13.txt new file mode 100644 index 0000000000000000000000000000000000000000..163c170d5727371790a6d6a1e7e5360ff07f9bd7 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_13.txt @@ -0,0 +1,13 @@ +Model Name Batch Size Seq Length Time in s +bert-base 8 8 0.005 +bert-base 8 32 0.008 +bert-base 8 128 0.022 +bert-base 8 512 0.106 +bert-384-hid 8 8 0.005 +bert-384-hid 8 32 0.007 +bert-384-hid 8 128 0.018 +bert-384-hid 8 512 0.064 +bert-6-lay 8 8 0.002 +bert-6-lay 8 32 0.003 +bert-6-lay 8 128 0.0011 +bert-6-lay 8 512 0.074 \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_14.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_14.txt new file mode 100644 index 0000000000000000000000000000000000000000..c7bcee951b813411d449432cd1c927b0605a6ddf --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_14.txt @@ -0,0 +1,16 @@ +==================== INFERENCE - MEMORY - RESULT ==================== +Model Name Batch Size Seq Length Memory in MB +bert-base 8 8 1330 +bert-base 8 32 1330 +bert-base 8 128 1330 +bert-base 8 512 1770 +bert-384-hid 8 8 1330 +bert-384-hid 8 32 1330 +bert-384-hid 8 128 1330 +bert-384-hid 8 512 1540 +bert-6-lay 8 8 1330 +bert-6-lay 8 32 1330 +bert-6-lay 8 128 1330 +bert-6-lay 8 512 1540 + +==================== ENVIRONMENT INFORMATION ==================== \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_15.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_15.txt new file mode 100644 index 0000000000000000000000000000000000000000..f8e2b5347406d40a982ce81a563d11dfe9888064 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_15.txt @@ -0,0 +1,29 @@ +==================== ENVIRONMENT INFORMATION ==================== + +transformers_version: 2.11.0 +framework: Tensorflow +use_xla: False +framework_version: 2.2.0 +python_version: 3.6.10 +system: Linux +cpu: x86_64 +architecture: 64bit +date: 2020-06-29 +time: 09:38:15.487125 +fp16: False +use_multiprocessing: True +only_pretrain_model: False +cpu_ram_mb: 32088 +use_gpu: True +num_gpus: 1 +gpu: TITAN RTX +gpu_ram_mb: 24217 +gpu_power_watts: 280.0 +gpu_performance_state: 2 +use_tpu: False + +Again, inference time and required memory for inference are measured, but this time for customized configurations +of the BertModel class. This feature can especially be helpful when deciding for which configuration the model +should be trained. +Benchmark best practices +This section lists a couple of best practices one should be aware of when benchmarking a model. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_16.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_16.txt new file mode 100644 index 0000000000000000000000000000000000000000..84b0997e6a223111d50d87d0afc2bea136308163 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_16.txt @@ -0,0 +1,9 @@ +Currently, only single device benchmarking is supported. When benchmarking on GPU, it is recommended that the user + specifies on which device the code should be run by setting the CUDA_VISIBLE_DEVICES environment variable in the + shell, e.g. export CUDA_VISIBLE_DEVICES=0 before running the code. +The option no_multi_processing should only be set to True for testing and debugging. To ensure accurate + memory measurement it is recommended to run each memory benchmark in a separate process by making sure + no_multi_processing is set to True. +One should always state the environment information when sharing the results of a model benchmark. Results can vary + heavily between different GPU devices, library versions, etc., so that benchmark results on their own are not very + useful for the community. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_17.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_17.txt new file mode 100644 index 0000000000000000000000000000000000000000..98d65f2b52e71813687a2b71ba72cd177c3d3379 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_17.txt @@ -0,0 +1,10 @@ +Sharing your benchmark +Previously all available core models (10 at the time) have been benchmarked for inference time, across many different +settings: using PyTorch, with and without TorchScript, using TensorFlow, with and without XLA. All of those tests were +done across CPUs (except for TensorFlow XLA) and GPUs. +The approach is detailed in the following blogpost and the results are +available here. +With the new benchmark tools, it is easier than ever to share your benchmark results with the community + +PyTorch Benchmarking Results. +TensorFlow Benchmarking Results. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..83c2df721237c9632c4112cc349583efbe61bf62 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_2.txt @@ -0,0 +1,12 @@ +Here, three arguments are given to the benchmark argument data classes, namely models, batch_sizes, and +sequence_lengths. The argument models is required and expects a list of model identifiers from the +model hub The list arguments batch_sizes and sequence_lengths define +the size of the input_ids on which the model is benchmarked. There are many more parameters that can be configured +via the benchmark argument data classes. For more detail on these one can either directly consult the files +src/transformers/benchmark/benchmark_args_utils.py, src/transformers/benchmark/benchmark_args.py (for PyTorch) +and src/transformers/benchmark/benchmark_args_tf.py (for Tensorflow). Alternatively, running the following shell +commands from root will print out a descriptive list of all configurable parameters for PyTorch and Tensorflow +respectively. + +python examples/pytorch/benchmarking/run_benchmark.py --help +An instantiated benchmark object can then simply be run by calling benchmark.run(). \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..b0dba1676f84ba94afa4e37d33e585c977b67a8d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_3.txt @@ -0,0 +1,16 @@ +results = benchmark.run() +print(results) +==================== INFERENCE - SPEED - RESULT ==================== + +Model Name Batch Size Seq Length Time in s +google-bert/bert-base-uncased 8 8 0.006 +google-bert/bert-base-uncased 8 32 0.006 +google-bert/bert-base-uncased 8 128 0.018 +google-bert/bert-base-uncased 8 512 0.088 + +==================== INFERENCE - MEMORY - RESULT ==================== +Model Name Batch Size Seq Length Memory in MB +google-bert/bert-base-uncased 8 8 1227 +google-bert/bert-base-uncased 8 32 1281 +google-bert/bert-base-uncased 8 128 1307 +google-bert/bert-base-uncased 8 512 1539 \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..414e32ad5254a53d5f2345648a8fb90de20ce933 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_4.txt @@ -0,0 +1,34 @@ +==================== ENVIRONMENT INFORMATION ==================== + +transformers_version: 2.11.0 +framework: PyTorch +use_torchscript: False +framework_version: 1.4.0 +python_version: 3.6.10 +system: Linux +cpu: x86_64 +architecture: 64bit +date: 2020-06-29 +time: 08:58:43.371351 +fp16: False +use_multiprocessing: True +only_pretrain_model: False +cpu_ram_mb: 32088 +use_gpu: True +num_gpus: 1 +gpu: TITAN RTX +gpu_ram_mb: 24217 +gpu_power_watts: 280.0 +gpu_performance_state: 2 +use_tpu: False + +bash +python examples/tensorflow/benchmarking/run_benchmark_tf.py --help + +An instantiated benchmark object can then simply be run by calling benchmark.run(). + +results = benchmark.run() +print(results) +results = benchmark.run() +print(results) +==================== INFERENCE - SPEED - RESULT ==================== \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..fcd9556056e100e94de1d0e1eb35beb890139006 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_5.txt @@ -0,0 +1,14 @@ +Model Name Batch Size Seq Length Time in s +google-bert/bert-base-uncased 8 8 0.005 +google-bert/bert-base-uncased 8 32 0.008 +google-bert/bert-base-uncased 8 128 0.022 +google-bert/bert-base-uncased 8 512 0.105 + +==================== INFERENCE - MEMORY - RESULT ==================== +Model Name Batch Size Seq Length Memory in MB +google-bert/bert-base-uncased 8 8 1330 +google-bert/bert-base-uncased 8 32 1330 +google-bert/bert-base-uncased 8 128 1330 +google-bert/bert-base-uncased 8 512 1770 + +==================== ENVIRONMENT INFORMATION ==================== \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..010a95be46a6b17650415bd5a997bad23f768575 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_6.txt @@ -0,0 +1,23 @@ +==================== ENVIRONMENT INFORMATION ==================== + +transformers_version: 2.11.0 +framework: Tensorflow +use_xla: False +framework_version: 2.2.0 +python_version: 3.6.10 +system: Linux +cpu: x86_64 +architecture: 64bit +date: 2020-06-29 +time: 09:26:35.617317 +fp16: False +use_multiprocessing: True +only_pretrain_model: False +cpu_ram_mb: 32088 +use_gpu: True +num_gpus: 1 +gpu: TITAN RTX +gpu_ram_mb: 24217 +gpu_power_watts: 280.0 +gpu_performance_state: 2 +use_tpu: False \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..c0934da8a4f06b8761413b5f964eb7bbd35b842d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_7.txt @@ -0,0 +1,10 @@ +By default, the time and the required memory for inference are benchmarked. In the example output above the first +two sections show the result corresponding to inference time and inference memory. In addition, all relevant +information about the computing environment, e.g. the GPU type, the system, the library versions, etc are printed +out in the third section under ENVIRONMENT INFORMATION. This information can optionally be saved in a .csv file +when adding the argument save_to_csv=True to [PyTorchBenchmarkArguments] and +[TensorFlowBenchmarkArguments] respectively. In this case, every section is saved in a separate +.csv file. The path to each .csv file can optionally be defined via the argument data classes. +Instead of benchmarking pre-trained models via their model identifier, e.g. google-bert/bert-base-uncased, the user can +alternatively benchmark an arbitrary configuration of any available model class. In this case, a list of +configurations must be inserted with the benchmark args as follows. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..26c402b9747003442c433de2a74d132e76b5274a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_8.txt @@ -0,0 +1,10 @@ +from transformers import PyTorchBenchmark, PyTorchBenchmarkArguments, BertConfig +args = PyTorchBenchmarkArguments( + models=["bert-base", "bert-384-hid", "bert-6-lay"], batch_sizes=[8], sequence_lengths=[8, 32, 128, 512] + ) +config_base = BertConfig() +config_384_hid = BertConfig(hidden_size=384) +config_6_lay = BertConfig(num_hidden_layers=6) +benchmark = PyTorchBenchmark(args, configs=[config_base, config_384_hid, config_6_lay]) +benchmark.run() +==================== INFERENCE - SPEED - RESULT ==================== \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..7189d04e63bc24a578aaa86177fc2f71012d21bf --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_benchmarks.txt_chunk_9.txt @@ -0,0 +1,13 @@ +Model Name Batch Size Seq Length Time in s +bert-base 8 128 0.006 +bert-base 8 512 0.006 +bert-base 8 128 0.018 +bert-base 8 512 0.088 +bert-384-hid 8 8 0.006 +bert-384-hid 8 32 0.006 +bert-384-hid 8 128 0.011 +bert-384-hid 8 512 0.054 +bert-6-lay 8 8 0.003 +bert-6-lay 8 32 0.004 +bert-6-lay 8 128 0.009 +bert-6-lay 8 512 0.044 \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_bertology.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_bertology.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..d2b1b45037293150c72a01f8f3b25c43e3191361 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_bertology.txt_chunk_0.txt @@ -0,0 +1,10 @@ +BERTology +There is a growing field of study concerned with investigating the inner working of large-scale transformers like BERT +(that some call "BERTology"). Some good examples of this field are: + +BERT Rediscovers the Classical NLP Pipeline by Ian Tenney, Dipanjan Das, Ellie Pavlick: + https://arxiv.org/abs/1905.05950 +Are Sixteen Heads Really Better than One? by Paul Michel, Omer Levy, Graham Neubig: https://arxiv.org/abs/1905.10650 +What Does BERT Look At? An Analysis of BERT's Attention by Kevin Clark, Urvashi Khandelwal, Omer Levy, Christopher D. + Manning: https://arxiv.org/abs/1906.04341 +CAT-probing: A Metric-based Approach to Interpret How Pre-trained Models for Programming Language Attend Code Structure: https://arxiv.org/abs/2210.04633 \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_bertology.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_bertology.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..792f21457d22dcc39003dd6d40827944f7df90c5 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_bertology.txt_chunk_1.txt @@ -0,0 +1,11 @@ +In order to help this new field develop, we have included a few additional features in the BERT/GPT/GPT-2 models to +help people access the inner representations, mainly adapted from the great work of Paul Michel +(https://arxiv.org/abs/1905.10650): + +accessing all the hidden-states of BERT/GPT/GPT-2, +accessing all the attention weights for each head of BERT/GPT/GPT-2, +retrieving heads output values and gradients to be able to compute head importance score and prune head as explained + in https://arxiv.org/abs/1905.10650. + +To help you understand and use these features, we have added a specific example script: bertology.py while extract information and prune a model pre-trained on +GLUE. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..7108f2e4f01880e68b02cb4241f197642439433f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_0.txt @@ -0,0 +1,11 @@ +Instantiate a big model +A barrier to accessing very large pretrained models is the amount of memory required. When loading a pretrained PyTorch model, you usually: + +Create a model with random weights. +Load your pretrained weights. +Put those pretrained weights in the model. + +The first two steps both require a full version of the model in memory and if the model weighs several GBs, you may not have enough memory for two copies of it. This problem is amplified in distributed training environments because each process loads a pretrained model and stores two copies in memory. + +[!TIP] +The randomly created model is initialized with "empty" tensors, which take space in memory without filling it. The random values are whatever was in this chunk of memory at the time. To improve loading speed, the _fast_init parameter is set to True by default to skip the random initialization for all weights that are correctly loaded. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..a8b3249a2955ee80b0f7e37234ffe634dcdbd142 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_1.txt @@ -0,0 +1,5 @@ +This guide will show you how Transformers can help you load large pretrained models despite their memory requirements. +Sharded checkpoints +From Transformers v4.18.0, a checkpoint larger than 10GB is automatically sharded by the [~PreTrainedModel.save_pretrained] method. It is split into several smaller partial checkpoints and creates an index file that maps parameter names to the files they're stored in. +The maximum shard size is controlled with the max_shard_size parameter, but by default it is 5GB, because it is easier to run on free-tier GPU instances without running out of memory. +For example, let's shard BioMistral/BioMistral-7B. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..dc9dc4470097c73b12d6ce31ea8ef8df2fc81c01 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_2.txt @@ -0,0 +1,10 @@ +with tempfile.TemporaryDirectory() as tmp_dir: + model.save_pretrained(tmp_dir, max_shard_size="5GB") + print(sorted(os.listdir(tmp_dir))) +['config.json', 'generation_config.json', 'model-00001-of-00006.safetensors', 'model-00002-of-00006.safetensors', 'model-00003-of-00006.safetensors', 'model-00004-of-00006.safetensors', 'model-00005-of-00006.safetensors', 'model-00006-of-00006.safetensors', 'model.safetensors.index.json'] + +The sharded checkpoint is reloaded with the [~PreTrainedModel.from_pretrained] method. + +with tempfile.TemporaryDirectory() as tmp_dir: + model.save_pretrained(tmp_dir, max_shard_size="5GB") + new_model = AutoModel.from_pretrained(tmp_dir) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..c4d575b983f78db5a40b57f0d2adc7073cd94484 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_3.txt @@ -0,0 +1,10 @@ +The main advantage of sharded checkpoints for big models is that each shard is loaded after the previous one, which caps the memory usage to only the model size and the largest shard size. +You could also directly load a sharded checkpoint inside a model without the [~PreTrainedModel.from_pretrained] method (similar to PyTorch's load_state_dict() method for a full checkpoint). In this case, use the [~modeling_utils.load_sharded_checkpoint] method. + +from transformers.modeling_utils import load_sharded_checkpoint +with tempfile.TemporaryDirectory() as tmp_dir: + model.save_pretrained(tmp_dir, max_shard_size="5GB") + load_sharded_checkpoint(model, tmp_dir) + +Shard metadata +The index file determines which keys are in the checkpoint and where the corresponding weights are stored. This file is loaded like any other JSON file and you can get a dictionary from it. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..3026108370ab821f5a027280fa86d6f190d03352 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_4.txt @@ -0,0 +1,27 @@ +import json +with tempfile.TemporaryDirectory() as tmp_dir: + model.save_pretrained(tmp_dir, max_shard_size="5GB") + with open(os.path.join(tmp_dir, "model.safetensors.index.json"), "r") as f: + index = json.load(f) +print(index.keys()) +dict_keys(['metadata', 'weight_map']) + +The metadata key provides the total model size. + +index["metadata"] +{'total_size': 28966928384} + +The weight_map key maps each parameter name (typically state_dict in a PyTorch model) to the shard it's stored in. + +index["weight_map"] +{'lm_head.weight': 'model-00006-of-00006.safetensors', + 'model.embed_tokens.weight': 'model-00001-of-00006.safetensors', + 'model.layers.0.input_layernorm.weight': 'model-00001-of-00006.safetensors', + 'model.layers.0.mlp.down_proj.weight': 'model-00001-of-00006.safetensors', + +} + +Accelerate's Big Model Inference + +[!TIP] +Make sure you have Accelerate v0.9.0 or later and PyTorch v1.9.0 or later installed. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..5fa7aac0f7248af01c555ac0ce695a779fa6e1a2 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_5.txt @@ -0,0 +1,8 @@ +[!TIP] +Make sure you have Accelerate v0.9.0 or later and PyTorch v1.9.0 or later installed. + +From Transformers v4.20.0, the [~PreTrainedModel.from_pretrained] method is supercharged with Accelerate's Big Model Inference feature to efficiently handle really big models! Big Model Inference creates a model skeleton on PyTorch's meta device. The randomly initialized parameters are only created when the pretrained weights are loaded. This way, you aren't keeping two copies of the model in memory at the same time (one for the randomly initialized model and one for the pretrained weights), and the maximum memory consumed is only the full model size. +To enable Big Model Inference in Transformers, set low_cpu_mem_usage=True in the [~PreTrainedModel.from_pretrained] method. + +from transformers import AutoModelForCausalLM +gemma = AutoModelForCausalLM.from_pretrained("google/gemma-7b", low_cpu_mem_usage=True) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..c91d30a6ead90ed52dfe1211c05dad00bb6649c2 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_6.txt @@ -0,0 +1,6 @@ +Accelerate automatically dispatches the model weights across all available devices, starting with the fastest device (GPU) first and then offloading to the slower devices (CPU and even hard drive). This is enabled by setting device_map="auto" in the [~PreTrainedModel.from_pretrained] method. When you pass the device_map parameter, low_cpu_mem_usage is automatically set to True so you don't need to specify it. + +from transformers import AutoModelForCausalLM +these loading methods are equivalent +gemma = AutoModelForCausalLM.from_pretrained("google/gemma-7b", device_map="auto") +gemma = AutoModelForCausalLM.from_pretrained("google/gemma-7b", device_map="auto", low_cpu_mem_usage=True) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..e3fc418629b66e631b433d22f7e620574c5487ba --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_7.txt @@ -0,0 +1,44 @@ +You can also write your own device_map by mapping each layer to a device. It should map all model parameters to a device, but you don't have to detail where all the submodules of a layer go if the entire layer is on the same device. +python +device_map = {"model.layers.1": 0, "model.layers.14": 1, "model.layers.31": "cpu", "lm_head": "disk"} +Access hf_device_map attribute to see how Accelerate split the model across devices. +py +gemma.hf_device_map +python out +{'model.embed_tokens': 0, + 'model.layers.0': 0, + 'model.layers.1': 0, + 'model.layers.2': 0, + 'model.layers.3': 0, + 'model.layers.4': 0, + 'model.layers.5': 0, + 'model.layers.6': 0, + 'model.layers.7': 0, + 'model.layers.8': 0, + 'model.layers.9': 0, + 'model.layers.10': 0, + 'model.layers.11': 0, + 'model.layers.12': 0, + 'model.layers.13': 0, + 'model.layers.14': 'cpu', + 'model.layers.15': 'cpu', + 'model.layers.16': 'cpu', + 'model.layers.17': 'cpu', + 'model.layers.18': 'cpu', + 'model.layers.19': 'cpu', + 'model.layers.20': 'cpu', + 'model.layers.21': 'cpu', + 'model.layers.22': 'cpu', + 'model.layers.23': 'cpu', + 'model.layers.24': 'cpu', + 'model.layers.25': 'cpu', + 'model.layers.26': 'cpu', + 'model.layers.27': 'cpu', + 'model.layers.28': 'cpu', + 'model.layers.29': 'cpu', + 'model.layers.30': 'cpu', + 'model.layers.31': 'cpu', + 'model.norm': 'cpu', + 'lm_head': 'cpu'} +Model data type +PyTorch model weights are normally instantiated as torch.float32 and it can be an issue if you try to load a model as a different data type. For example, you'd need twice as much memory to load the weights in torch.float32 and then again to load them in your desired data type, like torch.float16. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..29f3efa3d80726454e78423a742942bae7126c59 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_big_models.txt_chunk_8.txt @@ -0,0 +1,18 @@ +[!WARNING] +Due to how PyTorch is designed, the torch_dtype parameter only supports floating data types. + +To avoid wasting memory like this, explicitly set the torch_dtype parameter to the desired data type or set torch_dtype="auto" to load the weights with the most optimal memory pattern (the data type is automatically derived from the model weights). + +from transformers import AutoModelForCausalLM +gemma = AutoModelForCausalLM.from_pretrained("google/gemma-7b", torch_dtype=torch.float16) + +from transformers import AutoModelForCausalLM +gemma = AutoModelForCausalLM.from_pretrained("google/gemma-7b", torch_dtype="auto") + +You can also set the data type to use for models instantiated from scratch. +thon +import torch +from transformers import AutoConfig, AutoModel +my_config = AutoConfig.from_pretrained("google/gemma-2b", torch_dtype=torch.float16) +model = AutoModel.from_config(my_config) +``` \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..97200a2ce40d36ee5737507c60d9be1f65d69efc --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_0.txt @@ -0,0 +1,11 @@ +Templates for Chat Models +Introduction +An increasingly common use case for LLMs is chat. In a chat context, rather than continuing a single string +of text (as is the case with a standard language model), the model instead continues a conversation that consists +of one or more messages, each of which includes a role, like "user" or "assistant", as well as message text. +Much like tokenization, different models expect very different input formats for chat. This is the reason we added +chat templates as a feature. Chat templates are part of the tokenizer. They specify how to convert conversations, +represented as lists of messages, into a single tokenizable string in the format that the model expects. +Let's make this concrete with a quick example using the BlenderBot model. BlenderBot has an extremely simple default +template, which mostly just adds whitespace between rounds of dialogue: +thon \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..c2e28be1c1686721bfabb8d7f693f94a358f991b --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_1.txt @@ -0,0 +1,14 @@ +from transformers import AutoTokenizer +tokenizer = AutoTokenizer.from_pretrained("facebook/blenderbot-400M-distill") +chat = [ + {"role": "user", "content": "Hello, how are you?"}, + {"role": "assistant", "content": "I'm doing great. How can I help you today?"}, + {"role": "user", "content": "I'd like to show off how chat templating works!"}, + ] +tokenizer.apply_chat_template(chat, tokenize=False) +" Hello, how are you? I'm doing great. How can I help you today? I'd like to show off how chat templating works!" + +Notice how the entire chat is condensed into a single string. If we use tokenize=True, which is the default setting, +that string will also be tokenized for us. To see a more complex template in action, though, let's use the +mistralai/Mistral-7B-Instruct-v0.1 model. +thon \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_10.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_10.txt new file mode 100644 index 0000000000000000000000000000000000000000..2b1d2a1d52e15189ab12354f3f1858a5564d8677 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_10.txt @@ -0,0 +1,24 @@ +Next, let's define a list of tools: +thon +def get_current_temperature(location: str, unit: str) -> float: + """ + Get the current temperature at a location. +Args: + location: The location to get the temperature for, in the format "City, Country" + unit: The unit to return the temperature in. (choices: ["celsius", "fahrenheit"]) +Returns: + The current temperature at the specified location in the specified units, as a float. +""" +return 22. # A real function should probably actually get the temperature! + +def get_current_wind_speed(location: str) -> float: + """ + Get the current wind speed in km/h at a given location. +Args: + location: The location to get the temperature for, in the format "City, Country" +Returns: + The current wind speed at the given location in km/h, as a float. +""" +return 6. # A real function should probably actually get the wind speed! + +tools = [get_current_temperature, get_current_wind_speed] \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_11.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_11.txt new file mode 100644 index 0000000000000000000000000000000000000000..9c8e9e63930d53b1e5263a1558b6e0b494f30693 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_11.txt @@ -0,0 +1,44 @@ +Now, let's set up a conversation for our bot: +python +messages = [ + {"role": "system", "content": "You are a bot that responds to weather queries. You should reply with the unit used in the queried location."}, + {"role": "user", "content": "Hey, what's the temperature in Paris right now?"} +] +Now, let's apply the chat template and generate a response: +python +inputs = tokenizer.apply_chat_template(messages, chat_template="tool_use", tools=tools, add_generation_prompt=True, return_dict=True, return_tensors="pt") +inputs = {k: v.to(model.device) for k, v in inputs.items()} +out = model.generate(**inputs, max_new_tokens=128) +print(tokenizer.decode(out[0][len(inputs["input_ids"][0]):])) +And we get: +text + +{"arguments": {"location": "Paris, France", "unit": "celsius"}, "name": "get_current_temperature"} +<|im_end|> +The model has called the function with valid arguments, in the format requested by the function docstring. It has +inferred that we're most likely referring to the Paris in France, and it remembered that, as the home of SI units, +the temperature in France should certainly be displayed in Celsius. +Let's append the model's tool call to the conversation. Note that we generate a random tool_call_id here. These IDs +are not used by all models, but they allow models to issue multiple tool calls at once and keep track of which response +corresponds to which call. You can generate them any way you like, but they should be unique within each chat. +python +tool_call_id = "vAHdf3" # Random ID, should be unique for each tool call +tool_call = {"name": "get_current_temperature", "arguments": {"location": "Paris, France", "unit": "celsius"}} +messages.append({"role": "assistant", "tool_calls": [{"id": tool_call_id, "type": "function", "function": tool_call}]}) +Now that we've added the tool call to the conversation, we can call the function and append the result to the +conversation. Since we're just using a dummy function for this example that always returns 22.0, we can just append +that result directly. Again, note the tool_call_id - this should match the ID used in the tool call above. +python +messages.append({"role": "tool", "tool_call_id": tool_call_id, "name": "get_current_temperature", "content": "22.0"}) +Finally, let's let the assistant read the function outputs and continue chatting with the user: +python +inputs = tokenizer.apply_chat_template(messages, chat_template="tool_use", tools=tools, add_generation_prompt=True, return_dict=True, return_tensors="pt") +inputs = {k: v.to(model.device) for k, v in inputs.items()} +out = model.generate(**inputs, max_new_tokens=128) +print(tokenizer.decode(out[0][len(inputs["input_ids"][0]):])) +And we get: +text +The current temperature in Paris, France is 22.0 ° Celsius.<|im_end|> +Although this was a simple demo with dummy tools and a single call, the same technique works with +multiple real tools and longer conversations. This can be a powerful way to extend the capabilities of conversational +agents with real-time information, computational tools like calculators, or access to large databases. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_12.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_12.txt new file mode 100644 index 0000000000000000000000000000000000000000..7de549f0818318a1c72481f0425b44b791849302 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_12.txt @@ -0,0 +1,5 @@ +Not all of the tool-calling features shown above are used by all models. Some use tool call IDs, others simply use the function name and +match tool calls to results using the ordering, and there are several models that use neither and only issue one tool +call at a time to avoid confusion. If you want your code to be compatible across as many models as possible, we +recommend structuring your tools calls like we've shown here, and returning tool results in the order that +they were issued by the model. The chat templates on each model should handle the rest. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_13.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_13.txt new file mode 100644 index 0000000000000000000000000000000000000000..124b34f759aa3c290b5009463d7a05a71315c33c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_13.txt @@ -0,0 +1,21 @@ +Understanding tool schemas +Each function you pass to the tools argument of apply_chat_template is converted into a +JSON schema. These schemas +are then passed to the model chat template. In other words, tool-use models do not see your functions directly, and they +never see the actual code inside them. What they care about is the function definitions and the arguments they +need to pass to them - they care about what the tools do and how to use them, not how they work! It is up to you +to read their outputs, detect if they have requested to use a tool, pass their arguments to the tool function, and +return the response in the chat. +Generating JSON schemas to pass to the template should be automatic and invisible as long as your functions +follow the specification above, but if you encounter problems, or you simply want more control over the conversion, +you can handle the conversion manually. Here is an example of a manual schema conversion. +thon +from transformers.utils import get_json_schema +def multiply(a: float, b: float): + """ + A function that multiplies two numbers +Args: + a: The first number to multiply + b: The second number to multiply +""" +return a * b \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_14.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_14.txt new file mode 100644 index 0000000000000000000000000000000000000000..4b2bb9d5581dae4ae6cba660bb5131ad5ea1e25b --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_14.txt @@ -0,0 +1,2 @@ +schema = get_json_schema(multiply) +print(schema) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_15.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_15.txt new file mode 100644 index 0000000000000000000000000000000000000000..6b471c1cd1362c2f3db9336b8bea09bc327c8671 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_15.txt @@ -0,0 +1,68 @@ +This will yield: +json +{ + "type": "function", + "function": { + "name": "multiply", + "description": "A function that multiplies two numbers", + "parameters": { + "type": "object", + "properties": { + "a": { + "type": "number", + "description": "The first number to multiply" + }, + "b": { + "type": "number", + "description": "The second number to multiply" + } + }, + "required": ["a", "b"] + } + } +} +If you wish, you can edit these schemas, or even write them from scratch yourself without using get_json_schema at +all. JSON schemas can be passed directly to the tools argument of +apply_chat_template - this gives you a lot of power to define precise schemas for more complex functions. Be careful, +though - the more complex your schemas, the more likely the model is to get confused when dealing with them! We +recommend simple function signatures where possible, keeping arguments (and especially complex, nested arguments) +to a minimum. +Here is an example of defining schemas by hand, and passing them directly to apply_chat_template: +thon +A simple function that takes no arguments +current_time = { + "type": "function", + "function": { + "name": "current_time", + "description": "Get the current local time as a string.", + "parameters": { + 'type': 'object', + 'properties': {} + } + } +} +A more complete function that takes two numerical arguments +multiply = { + 'type': 'function', + 'function': { + 'name': 'multiply', + 'description': 'A function that multiplies two numbers', + 'parameters': { + 'type': 'object', + 'properties': { + 'a': { + 'type': 'number', + 'description': 'The first number to multiply' + }, + 'b': { + 'type': 'number', 'description': 'The second number to multiply' + } + }, + 'required': ['a', 'b'] + } + } +} +model_input = tokenizer.apply_chat_template( + messages, + tools = [current_time, multiply] +) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_16.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_16.txt new file mode 100644 index 0000000000000000000000000000000000000000..d88de58e26afacc3372ebfadd0f735b47e9acf5c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_16.txt @@ -0,0 +1,21 @@ +Advanced: Retrieval-augmented generation +"Retrieval-augmented generation" or "RAG" LLMs can search a corpus of documents for information before responding +to a query. This allows models to vastly expand their knowledge base beyond their limited context size. Our +recommendation for RAG models is that their template +should accept a documents argument. This should be a list of documents, where each "document" +is a single dict with title and contents keys, both of which are strings. Because this format is much simpler +than the JSON schemas used for tools, no helper functions are necessary. +Here's an example of a RAG template in action: +thon +document1 = { + "title": "The Moon: Our Age-Old Foe", + "contents": "Man has always dreamed of destroying the moon. In this essay, I shall" +} +document2 = { + "title": "The Sun: Our Age-Old Friend", + "contents": "Although often underappreciated, the sun provides several notable benefits" +} +model_input = tokenizer.apply_chat_template( + messages, + documents=[document1, document2] +) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_17.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_17.txt new file mode 100644 index 0000000000000000000000000000000000000000..0636a4a074e236925e43f6801142691854af0be1 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_17.txt @@ -0,0 +1,9 @@ +Advanced: How do chat templates work? +The chat template for a model is stored on the tokenizer.chat_template attribute. If no chat template is set, the +default template for that model class is used instead. Let's take a look at the template for BlenderBot: +thon + +from transformers import AutoTokenizer +tokenizer = AutoTokenizer.from_pretrained("facebook/blenderbot-400M-distill") +tokenizer.default_chat_template +"{% for message in messages %}{% if message['role'] == 'user' %}{{ ' ' }}{% endif %}{{ message['content'] }}{% if not loop.last %}{{ ' ' }}{% endif %}{% endfor %}{{ eos_token }}" \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_18.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_18.txt new file mode 100644 index 0000000000000000000000000000000000000000..e59d9a3ec12bc91473aad53f385ddf702b7a27c3 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_18.txt @@ -0,0 +1,70 @@ +That's kind of intimidating. Let's clean it up a little to make it more readable. In the process, though, we also make +sure that the newlines and indentation we add don't end up being included in the template output - see the tip on +trimming whitespace below! +{%- for message in messages %} + {%- if message['role'] == 'user' %} + {{- ' ' }} + {%- endif %} + {{- message['content'] }} + {%- if not loop.last %} + {{- ' ' }} + {%- endif %} +{%- endfor %} +{{- eos_token }} +If you've never seen one of these before, this is a Jinja template. +Jinja is a templating language that allows you to write simple code that generates text. In many ways, the code and +syntax resembles Python. In pure Python, this template would look something like this: +python +for idx, message in enumerate(messages): + if message['role'] == 'user': + print(' ') + print(message['content']) + if not idx == len(messages) - 1: # Check for the last message in the conversation + print(' ') +print(eos_token) +Effectively, the template does three things: +1. For each message, if the message is a user message, add a blank space before it, otherwise print nothing. +2. Add the message content +3. If the message is not the last message, add two spaces after it. After the final message, print the EOS token. +This is a pretty simple template - it doesn't add any control tokens, and it doesn't support "system" messages, which +are a common way to give the model directives about how it should behave in the subsequent conversation. +But Jinja gives you a lot of flexibility to do those things! Let's see a Jinja template that can format inputs +similarly to the way LLaMA formats them (note that the real LLaMA template includes handling for default system +messages and slightly different system message handling in general - don't use this one in your actual code!) +{%- for message in messages %} + {%- if message['role'] == 'user' %} + {{- bos_token + '[INST] ' + message['content'] + ' [/INST]' }} + {%- elif message['role'] == 'system' %} + {{- '<>\\n' + message['content'] + '\\n<>\\n\\n' }} + {%- elif message['role'] == 'assistant' %} + {{- ' ' + message['content'] + ' ' + eos_token }} + {%- endif %} +{%- endfor %} +Hopefully if you stare at this for a little bit you can see what this template is doing - it adds specific tokens based +on the "role" of each message, which represents who sent it. User, assistant and system messages are clearly +distinguishable to the model because of the tokens they're wrapped in. +Advanced: Adding and editing chat templates +How do I create a chat template? +Simple, just write a jinja template and set tokenizer.chat_template. You may find it easier to start with an +existing template from another model and simply edit it for your needs! For example, we could take the LLaMA template +above and add "[ASST]" and "[/ASST]" to assistant messages: +{%- for message in messages %} + {%- if message['role'] == 'user' %} + {{- bos_token + '[INST] ' + message['content'].strip() + ' [/INST]' }} + {%- elif message['role'] == 'system' %} + {{- '<>\\n' + message['content'].strip() + '\\n<>\\n\\n' }} + {%- elif message['role'] == 'assistant' %} + {{- '[ASST] ' + message['content'] + ' [/ASST]' + eos_token }} + {%- endif %} +{%- endfor %} +Now, simply set the tokenizer.chat_template attribute. Next time you use [~PreTrainedTokenizer.apply_chat_template], it will +use your new template! This attribute will be saved in the tokenizer_config.json file, so you can use +[~utils.PushToHubMixin.push_to_hub] to upload your new template to the Hub and make sure everyone's using the right +template for your model! +python +template = tokenizer.chat_template +template = template.replace("SYS", "SYSTEM") # Change the system token +tokenizer.chat_template = template # Set the new template +tokenizer.push_to_hub("model_name") # Upload your new template to the Hub! +The method [~PreTrainedTokenizer.apply_chat_template] which uses your chat template is called by the [TextGenerationPipeline] class, so +once you set the correct chat template, your model will automatically become compatible with [TextGenerationPipeline]. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_19.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_19.txt new file mode 100644 index 0000000000000000000000000000000000000000..c21f40e2a23592c20543c0d37e96e36645d87bb8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_19.txt @@ -0,0 +1,5 @@ +If you're fine-tuning a model for chat, in addition to setting a chat template, you should probably add any new chat +control tokens as special tokens in the tokenizer. Special tokens are never split, +ensuring that your control tokens are always handled as single tokens rather than being tokenized in pieces. You +should also set the tokenizer's eos_token attribute to the token that marks the end of assistant generations in your +template. This will ensure that text generation tools can correctly figure out when to stop generating text. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..f7e2bc6b440a7c183de10ca79aee119175ffe080 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_2.txt @@ -0,0 +1,9 @@ +from transformers import AutoTokenizer +tokenizer = AutoTokenizer.from_pretrained("mistralai/Mistral-7B-Instruct-v0.1") +chat = [ + {"role": "user", "content": "Hello, how are you?"}, + {"role": "assistant", "content": "I'm doing great. How can I help you today?"}, + {"role": "user", "content": "I'd like to show off how chat templating works!"}, + ] +tokenizer.apply_chat_template(chat, tokenize=False) +"[INST] Hello, how are you? [/INST]I'm doing great. How can I help you today? [INST] I'd like to show off how chat templating works! [/INST]" \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_20.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_20.txt new file mode 100644 index 0000000000000000000000000000000000000000..d0ecc78484e0b51206abe84828da3c868d8d80e0 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_20.txt @@ -0,0 +1,121 @@ +Why do some models have multiple templates? +Some models use different templates for different use cases. For example, they might use one template for normal chat +and another for tool-use, or retrieval-augmented generation. In these cases, tokenizer.chat_template is a dictionary. +This can cause some confusion, and where possible, we recommend using a single template for all use-cases. You can use +Jinja statements like if tools is defined and {% macro %} definitions to easily wrap multiple code paths in a +single template. +When a tokenizer has multiple templates, tokenizer.chat_template will be a dict, where each key is the name +of a template. The apply_chat_template method has special handling for certain template names: Specifically, it will +look for a template named default in most cases, and will raise an error if it can't find one. However, if a template +named tool_use exists when the user has passed a tools argument, it will use that instead. To access templates +with other names, pass the name of the template you want to the chat_template argument of +apply_chat_template(). +We find that this can be a bit confusing for users, though - so if you're writing a template yourself, we recommend +trying to put it all in a single template where possible! +What are "default" templates? +Before the introduction of chat templates, chat handling was hardcoded at the model class level. For backwards +compatibility, we have retained this class-specific handling as default templates, also set at the class level. If a +model does not have a chat template set, but there is a default template for its model class, the TextGenerationPipeline +class and methods like apply_chat_template will use the class template instead. You can find out what the default +template for your tokenizer is by checking the tokenizer.default_chat_template attribute. +This is something we do purely for backward compatibility reasons, to avoid breaking any existing workflows. Even when +the class template is appropriate for your model, we strongly recommend overriding the default template by +setting the chat_template attribute explicitly to make it clear to users that your model has been correctly configured +for chat. +Now that actual chat templates have been adopted more widely, default templates have been deprecated and will be +removed in a future release. We strongly recommend setting the chat_template attribute for any tokenizers that +still depend on them! +What template should I use? +When setting the template for a model that's already been trained for chat, you should ensure that the template +exactly matches the message formatting that the model saw during training, or else you will probably experience +performance degradation. This is true even if you're training the model further - you will probably get the best +performance if you keep the chat tokens constant. This is very analogous to tokenization - you generally get the +best performance for inference or fine-tuning when you precisely match the tokenization used during training. +If you're training a model from scratch, or fine-tuning a base language model for chat, on the other hand, +you have a lot of freedom to choose an appropriate template! LLMs are smart enough to learn to handle lots of different +input formats. One popular choice is the ChatML format, and this is a good, flexible choice for many use-cases. +It looks like this: +{%- for message in messages %} + {{- '<|im_start|>' + message['role'] + '\n' + message['content'] + '<|im_end|>' + '\n' }} +{%- endfor %} +If you like this one, here it is in one-liner form, ready to copy into your code. The one-liner also includes +handy support for generation prompts, but note that it doesn't add BOS or EOS tokens! +If your model expects those, they won't be added automatically by apply_chat_template - in other words, the +text will be tokenized with add_special_tokens=False. This is to avoid potential conflicts between the template and +the add_special_tokens logic. If your model expects special tokens, make sure to add them to the template! +python +tokenizer.chat_template = "{% if not add_generation_prompt is defined %}{% set add_generation_prompt = false %}{% endif %}{% for message in messages %}{{'<|im_start|>' + message['role'] + '\n' + message['content'] + '<|im_end|>' + '\n'}}{% endfor %}{% if add_generation_prompt %}{{ '<|im_start|>assistant\n' }}{% endif %}" +This template wraps each message in <|im_start|> and <|im_end|> tokens, and simply writes the role as a string, which +allows for flexibility in the roles you train with. The output looks like this: +text +<|im_start|>system +You are a helpful chatbot that will do its best not to say anything so stupid that people tweet about it.<|im_end|> +<|im_start|>user +How are you?<|im_end|> +<|im_start|>assistant +I'm doing great!<|im_end|> +The "user", "system" and "assistant" roles are the standard for chat, and we recommend using them when it makes sense, +particularly if you want your model to operate well with [TextGenerationPipeline]. However, you are not limited +to these roles - templating is extremely flexible, and any string can be a role. +I want to add some chat templates! How should I get started? +If you have any chat models, you should set their tokenizer.chat_template attribute and test it using +[~PreTrainedTokenizer.apply_chat_template], then push the updated tokenizer to the Hub. This applies even if you're +not the model owner - if you're using a model with an empty chat template, or one that's still using the default class +template, please open a pull request to the model repository so that this attribute can be set properly! +Once the attribute is set, that's it, you're done! tokenizer.apply_chat_template will now work correctly for that +model, which means it is also automatically supported in places like TextGenerationPipeline! +By ensuring that models have this attribute, we can make sure that the whole community gets to use the full power of +open-source models. Formatting mismatches have been haunting the field and silently harming performance for too long - +it's time to put an end to them! +Advanced: Template writing tips +If you're unfamiliar with Jinja, we generally find that the easiest way to write a chat template is to first +write a short Python script that formats messages the way you want, and then convert that script into a template. +Remember that the template handler will receive the conversation history as a variable called messages. +You will be able to access messages in your template just like you can in Python, which means you can loop over +it with {% for message in messages %} or access individual messages with {{ messages[0] }}, for example. +You can also use the following tips to convert your code to Jinja: +Trimming whitespace +By default, Jinja will print any whitespace that comes before or after a block. This can be a problem for chat +templates, which generally want to be very precise with whitespace! To avoid this, we strongly recommend writing +your templates like this: +{%- for message in messages %} + {{- message['role'] + message['content'] }} +{%- endfor %} +rather than like this: +{% for message in messages %} + {{ message['role'] + message['content'] }} +{% endfor %} +Adding - will strip any whitespace that comes before the block. The second example looks innocent, but the newline +and indentation may end up being included in the output, which is probably not what you want! +For loops +For loops in Jinja look like this: +{%- for message in messages %} + {{- message['content'] }} +{%- endfor %} +Note that whatever's inside the {{ expression block }} will be printed to the output. You can use operators like ++ to combine strings inside expression blocks. +If statements +If statements in Jinja look like this: +{%- if message['role'] == 'user' %} + {{- message['content'] }} +{%- endif %} +Note how where Python uses whitespace to mark the beginnings and ends of for and if blocks, Jinja requires you +to explicitly end them with {% endfor %} and {% endif %}. +Special variables +Inside your template, you will have access to the list of messages, but you can also access several other special +variables. These include special tokens like bos_token and eos_token, as well as the add_generation_prompt +variable that we discussed above. You can also use the loop variable to access information about the current loop +iteration, for example using {% if loop.last %} to check if the current message is the last message in the +conversation. Here's an example that puts these ideas together to add a generation prompt at the end of the +conversation if add_generation_prompt is True: +{%- if loop.last and add_generation_prompt %} + {{- bos_token + 'Assistant:\n' }} +{%- endif %} +Compatibility with non-Python Jinja +There are multiple implementations of Jinja in various languages. They generally have the same syntax, +but a key difference is that when you're writing a template in Python you can use Python methods, such as +.lower() on strings or .items() on dicts. This will break if someone tries to use your template on a non-Python +implementation of Jinja. Non-Python implementations are particularly common in deployment environments, where JS +and Rust are very popular. +Don't panic, though! There are a few easy changes you can make to your templates to ensure they're compatible across +all implementations of Jinja: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_21.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_21.txt new file mode 100644 index 0000000000000000000000000000000000000000..153602130528a8571bbf5e10c45ff281652ecc95 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_21.txt @@ -0,0 +1,7 @@ +Replace Python methods with Jinja filters. These usually have the same name, for example string.lower() becomes + string|lower, and dict.items() becomes dict|items. One notable change is that string.strip() becomes string|trim. + See the list of built-in filters + in the Jinja documentation for more. +Replace True, False and None, which are Python-specific, with true, false and none. +Directly rendering a dict or list may give different results in other implementations (for example, string entries + might change from single-quoted to double-quoted). Adding the tojson filter can help to ensure consistency here. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..38f47a8a469cba52da04f426ccfe298f931a1965 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_3.txt @@ -0,0 +1,28 @@ +Note that this time, the tokenizer has added the control tokens [INST] and [/INST] to indicate the start and end of +user messages (but not assistant messages!). Mistral-instruct was trained with these tokens, but BlenderBot was not. +How do I use chat templates? +As you can see in the example above, chat templates are easy to use. Simply build a list of messages, with role +and content keys, and then pass it to the [~PreTrainedTokenizer.apply_chat_template] method. Once you do that, +you'll get output that's ready to go! When using chat templates as input for model generation, it's also a good idea +to use add_generation_prompt=True to add a generation prompt. +Here's an example of preparing input for model.generate(), using the Zephyr assistant model: +thon +from transformers import AutoModelForCausalLM, AutoTokenizer +checkpoint = "HuggingFaceH4/zephyr-7b-beta" +tokenizer = AutoTokenizer.from_pretrained(checkpoint) +model = AutoModelForCausalLM.from_pretrained(checkpoint) # You may want to use bfloat16 and/or move to GPU here +messages = [ + { + "role": "system", + "content": "You are a friendly chatbot who always responds in the style of a pirate", + }, + {"role": "user", "content": "How many helicopters can a human eat in one sitting?"}, + ] +tokenized_chat = tokenizer.apply_chat_template(messages, tokenize=True, add_generation_prompt=True, return_tensors="pt") +print(tokenizer.decode(tokenized_chat[0])) +This will yield a string in the input format that Zephyr expects.text +<|system|> +You are a friendly chatbot who always responds in the style of a pirate +<|user|> +How many helicopters can a human eat in one sitting? +<|assistant|> \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..79a96b3282a97ea2603d18f27f9c17e51cd66fdf --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_4.txt @@ -0,0 +1,29 @@ +Now that our input is formatted correctly for Zephyr, we can use the model to generate a response to the user's question: +python +outputs = model.generate(tokenized_chat, max_new_tokens=128) +print(tokenizer.decode(outputs[0])) +This will yield: +text +<|system|> +You are a friendly chatbot who always responds in the style of a pirate +<|user|> +How many helicopters can a human eat in one sitting? +<|assistant|> +Matey, I'm afraid I must inform ye that humans cannot eat helicopters. Helicopters are not food, they are flying machines. Food is meant to be eaten, like a hearty plate o' grog, a savory bowl o' stew, or a delicious loaf o' bread. But helicopters, they be for transportin' and movin' around, not for eatin'. So, I'd say none, me hearties. None at all. +Arr, 'twas easy after all! +Is there an automated pipeline for chat? +Yes, there is! Our text generation pipelines support chat inputs, which makes it easy to use chat models. In the past, +we used to use a dedicated "ConversationalPipeline" class, but this has now been deprecated and its functionality +has been merged into the [TextGenerationPipeline]. Let's try the Zephyr example again, but this time using +a pipeline: +thon +from transformers import pipeline +pipe = pipeline("text-generation", "HuggingFaceH4/zephyr-7b-beta") +messages = [ + { + "role": "system", + "content": "You are a friendly chatbot who always responds in the style of a pirate", + }, + {"role": "user", "content": "How many helicopters can a human eat in one sitting?"}, +] +print(pipe(messages, max_new_tokens=128)[0]['generated_text'][-1]) # Print the assistant's response \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..8a04999f361f9ea2ff629b91403459ba86870f0a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_5.txt @@ -0,0 +1,67 @@ +text +{'role': 'assistant', 'content': "Matey, I'm afraid I must inform ye that humans cannot eat helicopters. Helicopters are not food, they are flying machines. Food is meant to be eaten, like a hearty plate o' grog, a savory bowl o' stew, or a delicious loaf o' bread. But helicopters, they be for transportin' and movin' around, not for eatin'. So, I'd say none, me hearties. None at all."} +The pipeline will take care of all the details of tokenization and calling apply_chat_template for you - +once the model has a chat template, all you need to do is initialize the pipeline and pass it the list of messages! +What are "generation prompts"? +You may have noticed that the apply_chat_template method has an add_generation_prompt argument. This argument tells +the template to add tokens that indicate the start of a bot response. For example, consider the following chat: +python +messages = [ + {"role": "user", "content": "Hi there!"}, + {"role": "assistant", "content": "Nice to meet you!"}, + {"role": "user", "content": "Can I ask a question?"} +] +Here's what this will look like without a generation prompt, using the ChatML template we saw in the Zephyr example: +python +tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=False) +"""<|im_start|>user +Hi there!<|im_end|> +<|im_start|>assistant +Nice to meet you!<|im_end|> +<|im_start|>user +Can I ask a question?<|im_end|> +""" +And here's what it looks like with a generation prompt: +python +tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True) +"""<|im_start|>user +Hi there!<|im_end|> +<|im_start|>assistant +Nice to meet you!<|im_end|> +<|im_start|>user +Can I ask a question?<|im_end|> +<|im_start|>assistant +""" +Note that this time, we've added the tokens that indicate the start of a bot response. This ensures that when the model +generates text it will write a bot response instead of doing something unexpected, like continuing the user's +message. Remember, chat models are still just language models - they're trained to continue text, and chat is just a +special kind of text to them! You need to guide them with appropriate control tokens, so they know what they're +supposed to be doing. +Not all models require generation prompts. Some models, like BlenderBot and LLaMA, don't have any +special tokens before bot responses. In these cases, the add_generation_prompt argument will have no effect. The exact +effect that add_generation_prompt has will depend on the template being used. +Can I use chat templates in training? +Yes! We recommend that you apply the chat template as a preprocessing step for your dataset. After this, you +can simply continue like any other language model training task. When training, you should usually set +add_generation_prompt=False, because the added tokens to prompt an assistant response will not be helpful during +training. Let's see an example: +thon +from transformers import AutoTokenizer +from datasets import Dataset +tokenizer = AutoTokenizer.from_pretrained("HuggingFaceH4/zephyr-7b-beta") +chat1 = [ + {"role": "user", "content": "Which is bigger, the moon or the sun?"}, + {"role": "assistant", "content": "The sun."} +] +chat2 = [ + {"role": "user", "content": "Which is bigger, a virus or a bacterium?"}, + {"role": "assistant", "content": "A bacterium."} +] +dataset = Dataset.from_dict({"chat": [chat1, chat2]}) +dataset = dataset.map(lambda x: {"formatted_chat": tokenizer.apply_chat_template(x["chat"], tokenize=False, add_generation_prompt=False)}) +print(dataset['formatted_chat'][0]) +And we get:text +<|user|> +Which is bigger, the moon or the sun? +<|assistant|> +The sun. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..66ee423b454237d02ffc88b39a920938c1ac76d6 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_6.txt @@ -0,0 +1,27 @@ +From here, just continue training like you would with a standard language modelling task, using the formatted_chat column. +Advanced: Extra inputs to chat templates +The only argument that apply_chat_template requires is messages. However, you can pass any keyword +argument to apply_chat_template and it will be accessible inside the template. This gives you a lot of freedom to use +chat templates for many things. There are no restrictions on the names or the format of these arguments - you can pass +strings, lists, dicts or whatever else you want. +That said, there are some common use-cases for these extra arguments, +such as passing tools for function calling, or documents for retrieval-augmented generation. In these common cases, +we have some opinionated recommendations about what the names and formats of these arguments should be, which are +described in the sections below. We encourage model authors to make their chat templates compatible with this format, +to make it easy to transfer tool-calling code between models. +Advanced: Tool use / function calling +"Tool use" LLMs can choose to call functions as external tools before generating an answer. When passing tools +to a tool-use model, you can simply pass a list of functions to the tools argument: +thon +import datetime +def current_time(): + """Get the current local time as a string.""" + return str(datetime.now()) +def multiply(a: float, b: float): + """ + A function that multiplies two numbers +Args: + a: The first number to multiply + b: The second number to multiply +""" +return a * b \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..03d9a570ace7ce44b2664d706e79c9bf4fa02cec --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_7.txt @@ -0,0 +1,17 @@ +tools = [current_time, multiply] +model_input = tokenizer.apply_chat_template( + messages, + tools=tools +) + +In order for this to work correctly, you should write your functions in the format above, so that they can be parsed +correctly as tools. Specifically, you should follow these rules: + +The function should have a descriptive name +Every argument must have a type hint +The function must have a docstring in the standard Google style (in other words, an initial function description + followed by an Args: block that describes the arguments, unless the function does not have any arguments. +Do not include types in the Args: block. In other words, write a: The first number to multiply, not + a (int): The first number to multiply. Type hints should go in the function header instead. +The function can have a return type and a Returns: block in the docstring. However, these are optional + because most tool-use models ignore them. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..649739e1643de048045d32e6b41e58ab4c38c443 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_8.txt @@ -0,0 +1,8 @@ +Passing tool results to the model +The sample code above is enough to list the available tools for your model, but what happens if it wants to actually use +one? If that happens, you should: + +Parse the model's output to get the tool name(s) and arguments. +Add the model's tool call(s) to the conversation. +Call the corresponding function(s) with those arguments. +Add the result(s) to the conversation \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..1a8a984250ccd632037a7d4c3c2c2c5e4eda65f3 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_chat_templating.txt_chunk_9.txt @@ -0,0 +1,13 @@ +A complete tool use example +Let's walk through a tool use example, step by step. For this example, we will use an 8B Hermes-2-Pro model, +as it is one of the highest-performing tool-use models in its size category at the time of writing. If you have the +memory, you can consider using a larger model instead like Command-R +or Mixtral-8x22B, both of which also support tool use +and offer even stronger performance. +First, let's load our model and tokenizer: +thon +import torch +from transformers import AutoModelForCausalLM, AutoTokenizer +checkpoint = "NousResearch/Hermes-2-Pro-Llama-3-8B" +tokenizer = AutoTokenizer.from_pretrained(checkpoint, revision="pr/13") +model = AutoModelForCausalLM.from_pretrained(checkpoint, torch_dtype=torch.bfloat16, device_map="auto") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_community.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_community.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..a9c0b026adac7f4003764e19db847051a7e73152 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_community.txt_chunk_0.txt @@ -0,0 +1,60 @@ +Community +This page regroups resources around 🤗 Transformers developed by the community. +Community resources: +| Resource | Description | Author | +|:----------|:-------------|------:| +| Hugging Face Transformers Glossary Flashcards | A set of flashcards based on the Transformers Docs Glossary that has been put into a form which can be easily learned/revised using Anki an open source, cross platform app specifically designed for long term knowledge retention. See this Introductory video on how to use the flashcards. | Darigov Research | +Community notebooks: +| Notebook | Description | Author | | +|:----------|:-------------|:-------------|------:| +| Fine-tune a pre-trained Transformer to generate lyrics | How to generate lyrics in the style of your favorite artist by fine-tuning a GPT-2 model | Aleksey Korshuk | | +| Train T5 in Tensorflow 2 | How to train T5 for any task using Tensorflow 2. This notebook demonstrates a Question & Answer task implemented in Tensorflow 2 using SQUAD | Muhammad Harris | | +| Train T5 on TPU | How to train T5 on SQUAD with Transformers and Nlp | Suraj Patil | | +| Fine-tune T5 for Classification and Multiple Choice | How to fine-tune T5 for classification and multiple choice tasks using a text-to-text format with PyTorch Lightning | Suraj Patil | | +| Fine-tune DialoGPT on New Datasets and Languages | How to fine-tune the DialoGPT model on a new dataset for open-dialog conversational chatbots | Nathan Cooper | | +| Long Sequence Modeling with Reformer | How to train on sequences as long as 500,000 tokens with Reformer | Patrick von Platen | | +| Fine-tune BART for Summarization | How to fine-tune BART for summarization with fastai using blurr | Wayde Gilliam | | +| Fine-tune a pre-trained Transformer on anyone's tweets | How to generate tweets in the style of your favorite Twitter account by fine-tuning a GPT-2 model | Boris Dayma | | +| Optimize 🤗 Hugging Face models with Weights & Biases | A complete tutorial showcasing W&B integration with Hugging Face | Boris Dayma | | +| Pretrain Longformer | How to build a "long" version of existing pretrained models | Iz Beltagy | | +| Fine-tune Longformer for QA | How to fine-tune longformer model for QA task | Suraj Patil | | +| Evaluate Model with 🤗nlp | How to evaluate longformer on TriviaQA with nlp | Patrick von Platen | | +| Fine-tune T5 for Sentiment Span Extraction | How to fine-tune T5 for sentiment span extraction using a text-to-text format with PyTorch Lightning | Lorenzo Ampil | | +| Fine-tune DistilBert for Multiclass Classification | How to fine-tune DistilBert for multiclass classification with PyTorch | Abhishek Kumar Mishra | | +|Fine-tune BERT for Multi-label Classification|How to fine-tune BERT for multi-label classification using PyTorch|Abhishek Kumar Mishra || +|Fine-tune T5 for Summarization|How to fine-tune T5 for summarization in PyTorch and track experiments with WandB|Abhishek Kumar Mishra || +|Speed up Fine-Tuning in Transformers with Dynamic Padding / Bucketing|How to speed up fine-tuning by a factor of 2 using dynamic padding / bucketing|Michael Benesty || +|Pretrain Reformer for Masked Language Modeling| How to train a Reformer model with bi-directional self-attention layers | Patrick von Platen | | +|Expand and Fine Tune Sci-BERT| How to increase vocabulary of a pretrained SciBERT model from AllenAI on the CORD dataset and pipeline it. | Tanmay Thakur | | +|Fine Tune BlenderBotSmall for Summarization using the Trainer API| How to fine-tune BlenderBotSmall for summarization on a custom dataset, using the Trainer API. | Tanmay Thakur | | +|Fine-tune Electra and interpret with Integrated Gradients | How to fine-tune Electra for sentiment analysis and interpret predictions with Captum Integrated Gradients | Eliza Szczechla | | +|fine-tune a non-English GPT-2 Model with Trainer class | How to fine-tune a non-English GPT-2 Model with Trainer class | Philipp Schmid | | +|Fine-tune a DistilBERT Model for Multi Label Classification task | How to fine-tune a DistilBERT Model for Multi Label Classification task | Dhaval Taunk | | +|Fine-tune ALBERT for sentence-pair classification | How to fine-tune an ALBERT model or another BERT-based model for the sentence-pair classification task | Nadir El Manouzi | | +|Fine-tune Roberta for sentiment analysis | How to fine-tune a Roberta model for sentiment analysis | Dhaval Taunk | | +|Evaluating Question Generation Models | How accurate are the answers to questions generated by your seq2seq transformer model? | Pascal Zoleko | | +|Classify text with DistilBERT and Tensorflow | How to fine-tune DistilBERT for text classification in TensorFlow | Peter Bayerle | | +|Leverage BERT for Encoder-Decoder Summarization on CNN/Dailymail | How to warm-start a EncoderDecoderModel with a google-bert/bert-base-uncased checkpoint for summarization on CNN/Dailymail | Patrick von Platen | | +|Leverage RoBERTa for Encoder-Decoder Summarization on BBC XSum | How to warm-start a shared EncoderDecoderModel with a FacebookAI/roberta-base checkpoint for summarization on BBC/XSum | Patrick von Platen | | +|Fine-tune TAPAS on Sequential Question Answering (SQA) | How to fine-tune TapasForQuestionAnswering with a tapas-base checkpoint on the Sequential Question Answering (SQA) dataset | Niels Rogge | | +|Evaluate TAPAS on Table Fact Checking (TabFact) | How to evaluate a fine-tuned TapasForSequenceClassification with a tapas-base-finetuned-tabfact checkpoint using a combination of the 🤗 datasets and 🤗 transformers libraries | Niels Rogge | | +|Fine-tuning mBART for translation | How to fine-tune mBART using Seq2SeqTrainer for Hindi to English translation | Vasudev Gupta | | +|Fine-tune LayoutLM on FUNSD (a form understanding dataset) | How to fine-tune LayoutLMForTokenClassification on the FUNSD dataset for information extraction from scanned documents | Niels Rogge | | +|Fine-Tune DistilGPT2 and Generate Text | How to fine-tune DistilGPT2 and generate text | Aakash Tripathi | | +|Fine-Tune LED on up to 8K tokens | How to fine-tune LED on pubmed for long-range summarization | Patrick von Platen | | +|Evaluate LED on Arxiv | How to effectively evaluate LED on long-range summarization | Patrick von Platen | | +|Fine-tune LayoutLM on RVL-CDIP (a document image classification dataset) | How to fine-tune LayoutLMForSequenceClassification on the RVL-CDIP dataset for scanned document classification | Niels Rogge | | +|Wav2Vec2 CTC decoding with GPT2 adjustment | How to decode CTC sequence with language model adjustment | Eric Lam | | +|Fine-tune BART for summarization in two languages with Trainer class | How to fine-tune BART for summarization in two languages with Trainer class | Eliza Szczechla | | +|Evaluate Big Bird on Trivia QA | How to evaluate BigBird on long document question answering on Trivia QA | Patrick von Platen | | +| Create video captions using Wav2Vec2 | How to create YouTube captions from any video by transcribing the audio with Wav2Vec | Niklas Muennighoff | | +| Fine-tune the Vision Transformer on CIFAR-10 using PyTorch Lightning | How to fine-tune the Vision Transformer (ViT) on CIFAR-10 using HuggingFace Transformers, Datasets and PyTorch Lightning | Niels Rogge | | +| Fine-tune the Vision Transformer on CIFAR-10 using the 🤗 Trainer | How to fine-tune the Vision Transformer (ViT) on CIFAR-10 using HuggingFace Transformers, Datasets and the 🤗 Trainer | Niels Rogge | | +| Evaluate LUKE on Open Entity, an entity typing dataset | How to evaluate LukeForEntityClassification on the Open Entity dataset | Ikuya Yamada | | +| Evaluate LUKE on TACRED, a relation extraction dataset | How to evaluate LukeForEntityPairClassification on the TACRED dataset | Ikuya Yamada | | +| Evaluate LUKE on CoNLL-2003, an important NER benchmark | How to evaluate LukeForEntitySpanClassification on the CoNLL-2003 dataset | Ikuya Yamada | | +| Evaluate BigBird-Pegasus on PubMed dataset | How to evaluate BigBirdPegasusForConditionalGeneration on PubMed dataset | Vasudev Gupta | | +| Speech Emotion Classification with Wav2Vec2 | How to leverage a pretrained Wav2Vec2 model for Emotion Classification on the MEGA dataset | Mehrdad Farahani | | +| Detect objects in an image with DETR | How to use a trained DetrForObjectDetection model to detect objects in an image and visualize attention | Niels Rogge | | +| Fine-tune DETR on a custom object detection dataset | How to fine-tune DetrForObjectDetection on a custom object detection dataset | Niels Rogge | | +| Finetune T5 for Named Entity Recognition | How to fine-tune T5 on a Named Entity Recognition Task | Ogundepo Odunayo | | \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..e0001b48c01bad457e04398e08366f3e53c3c929 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_0.txt @@ -0,0 +1,17 @@ +Contribute to 🤗 Transformers +Everyone is welcome to contribute, and we value everybody's contribution. Code +contributions are not the only way to help the community. Answering questions, helping +others, and improving the documentation are also immensely valuable. +It also helps us if you spread the word! Reference the library in blog posts +about the awesome projects it made possible, shout out on Twitter every time it has +helped you, or simply â­ï¸ the repository to say thank you. +However you choose to contribute, please be mindful and respect our +code of conduct. +This guide was heavily inspired by the awesome scikit-learn guide to contributing. +Ways to contribute +There are several ways you can contribute to 🤗 Transformers: + +Fix outstanding issues with the existing code. +Submit issues related to bugs or desired new features. +Implement new models. +Contribute to the examples or to the documentation. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..141ff7294f24aeb99fda884d268e1a04e55c9177 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_1.txt @@ -0,0 +1,6 @@ +If you don't know where to start, there is a special Good First +Issue listing. It will give you a list of +open issues that are beginner-friendly and help you start contributing to open-source. The best way to do that is to open a Pull Request and link it to the issue that you'd like to work on. We try to give priority to opened PRs as we can easily track the progress of the fix, and if the contributor does not have time anymore, someone else can take the PR over. +For something slightly more challenging, you can also take a look at the Good Second Issue list. In general though, if you feel like you know what you're doing, go for it and we'll help you get there! 🚀 + +All contributions are equally valuable to the community. 🥰 \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_10.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_10.txt new file mode 100644 index 0000000000000000000000000000000000000000..63339f5136e4a8fcc66b84abe8735776bacfd9a9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_10.txt @@ -0,0 +1,15 @@ +git add modified_file.py + git commit +Please remember to write good commit + messages to clearly communicate the changes you made! +To keep your copy of the code up to date with the original + repository, rebase your branch on upstream/branch before you open a pull request or if requested by a maintainer: + + git fetch upstream + git rebase upstream/main +Push your changes to your branch: + + git push -u origin a-descriptive-name-for-my-changes +If you've already opened a pull request, you'll need to force push with the --force flag. Otherwise, if the pull request hasn't been opened yet, you can just push your changes normally. + +Now you can go to your fork of the repository on GitHub and click on Pull Request to open a pull request. Make sure you tick off all the boxes on our checklist below. When you're ready, you can send your changes to the project maintainers for review. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_11.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_11.txt new file mode 100644 index 0000000000000000000000000000000000000000..f2bc0489641edcf364d55ba028a208acbba68e9d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_11.txt @@ -0,0 +1,4 @@ +It's ok if maintainers request changes, it happens to our core contributors + too! So everyone can see the changes in the pull request, work in your local + branch and push the changes to your fork. They will automatically appear in + the pull request. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_12.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_12.txt new file mode 100644 index 0000000000000000000000000000000000000000..71ee94641826468637a973fc418c628ddcf14d80 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_12.txt @@ -0,0 +1,33 @@ +Pull request checklist +☠The pull request title should summarize your contribution. +☠If your pull request addresses an issue, please mention the issue number in the pull +request description to make sure they are linked (and people viewing the issue know you +are working on it). +☠To indicate a work in progress please prefix the title with [WIP]. These are +useful to avoid duplicated work, and to differentiate it from PRs ready to be merged. +☠Make sure existing tests pass. +☠If adding a new feature, also add tests for it. + - If you are adding a new model, make sure you use + ModelTester.all_model_classes = (MyModel, MyModelWithLMHead,) to trigger the common tests. + - If you are adding new @slow tests, make sure they pass using + RUN_SLOW=1 python -m pytest tests/models/my_new_model/test_my_new_model.py. + - If you are adding a new tokenizer, write tests and make sure + RUN_SLOW=1 python -m pytest tests/models/{your_model_name}/test_tokenization_{your_model_name}.py passes. + - CircleCI does not run the slow tests, but GitHub Actions does every night! +☠All public methods must have informative docstrings (see +modeling_bert.py +for an example). +☠Due to the rapidly growing repository, don't add any images, videos and other +non-text files that'll significantly weigh down the repository. Instead, use a Hub +repository such as hf-internal-testing +to host these files and reference them by URL. We recommend placing documentation +related images in the following repository: +huggingface/documentation-images. +You can open a PR on this dataset repository and ask a Hugging Face member to merge it. +For more information about the checks run on a pull request, take a look at our Checks on a Pull Request guide. +Tests +An extensive test suite is included to test the library behavior and several examples. Library tests can be found in +the tests folder and examples tests in the +examples folder. +We like pytest and pytest-xdist because it's faster. From the root of the +repository, specify a path to a subfolder or a test file to run the test: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_13.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_13.txt new file mode 100644 index 0000000000000000000000000000000000000000..5354fd967286a073d8ae4feb895b103a2da29ec2 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_13.txt @@ -0,0 +1,11 @@ +python -m pytest -n auto --dist=loadfile -s -v ./tests/models/my_new_model +Similarly, for the examples directory, specify a path to a subfolder or test file to run the test. For example, the following command tests the text classification subfolder in the PyTorch examples directory: + +pip install -r examples/xxx/requirements.txt # only needed the first time +python -m pytest -n auto --dist=loadfile -s -v ./examples/pytorch/text-classification +In fact, this is actually how our make test and make test-examples commands are implemented (not including the pip install)! +You can also specify a smaller set of tests in order to test only the feature +you're working on. +By default, slow tests are skipped but you can set the RUN_SLOW environment variable to +yes to run them. This will download many gigabytes of models so make sure you +have enough disk space, a good internet connection or a lot of patience! \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_14.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_14.txt new file mode 100644 index 0000000000000000000000000000000000000000..0a7cc5ca924ab6e1f75fbde906e54619102dcb15 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_14.txt @@ -0,0 +1,13 @@ +Remember to specify a path to a subfolder or a test file to run the test. Otherwise, you'll run all the tests in the tests or examples folder, which will take a very long time! + +RUN_SLOW=yes python -m pytest -n auto --dist=loadfile -s -v ./tests/models/my_new_model +RUN_SLOW=yes python -m pytest -n auto --dist=loadfile -s -v ./examples/pytorch/text-classification +Like the slow tests, there are other environment variables available which not enabled by default during testing: +- RUN_CUSTOM_TOKENIZERS: Enables tests for custom tokenizers. +- RUN_PT_FLAX_CROSS_TESTS: Enables tests for PyTorch + Flax integration. +- RUN_PT_TF_CROSS_TESTS: Enables tests for TensorFlow + PyTorch integration. +More environment variables and additional information can be found in the testing_utils.py. +🤗 Transformers uses pytest as a test runner only. It doesn't use any +pytest-specific features in the test suite itself. +This means unittest is fully supported. Here's how to run tests with +unittest: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_15.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_15.txt new file mode 100644 index 0000000000000000000000000000000000000000..acf1ad2756b7c1e33938694ecfde288c10be7542 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_15.txt @@ -0,0 +1,16 @@ +python -m unittest discover -s tests -t . -v +python -m unittest discover -s examples -t examples -v +Style guide +For documentation strings, 🤗 Transformers follows the Google Python Style Guide. +Check our documentation writing guide +for more information. +Develop on Windows +On Windows (unless you're working in Windows Subsystem for Linux or WSL), you need to configure git to transform Windows CRLF line endings to Linux LF line endings: + +git config core.autocrlf input +One way to run the make command on Windows is with MSYS2: + +Download MSYS2, and we assume it's installed in C:\msys64. +Open the command line C:\msys64\msys2.exe (it should be available from the Start menu). +Run in the shell: pacman -Syu and install make with pacman -S make. +Add C:\msys64\usr\bin to your PATH environment variable. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_16.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_16.txt new file mode 100644 index 0000000000000000000000000000000000000000..f4a51be167cbb4891b88f598fa6c8c20aeeafab5 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_16.txt @@ -0,0 +1,11 @@ +You can now use make from any terminal (PowerShell, cmd.exe, etc.)! 🎉 +Sync a forked repository with upstream main (the Hugging Face repository) +When updating the main branch of a forked repository, please follow these steps to avoid pinging the upstream repository which adds reference notes to each upstream PR, and sends unnecessary notifications to the developers involved in these PRs. + +When possible, avoid syncing with the upstream using a branch and PR on the forked repository. Instead, merge directly into the forked main. +If a PR is absolutely necessary, use the following steps after checking out your branch: + + git checkout -b your-branch-for-syncing + git pull --squash --no-commit upstream main + git commit -m '' + git push --set-upstream origin your-branch-for-syncing \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..04d9e44ac6975d3a966c7fb9c3bdf4c1ac5b9254 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_2.txt @@ -0,0 +1,11 @@ +Fixing outstanding issues +If you notice an issue with the existing code and have a fix in mind, feel free to start contributing and open a Pull Request! +Submitting a bug-related issue or feature request +Do your best to follow these guidelines when submitting a bug-related issue or a feature +request. It will make it easier for us to come back to you quickly and with good +feedback. +Did you find a bug? +The 🤗 Transformers library is robust and reliable thanks to users who report the problems they encounter. +Before you report an issue, we would really appreciate it if you could make sure the bug was not +already reported (use the search bar on GitHub under Issues). Your issue should also be related to bugs in the library itself, and not your code. If you're unsure whether the bug is in your code or the library, please ask in the forum first. This helps us respond quicker to fixing issues related to the library versus general questions. +Once you've confirmed the bug hasn't already been reported, please include the following information in your issue so we can quickly resolve it: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..91ff9c5df46dbeb81702da13ea0d96f49f56de23 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_3.txt @@ -0,0 +1,19 @@ +Your OS type and version and Python, PyTorch and + TensorFlow versions when applicable. +A short, self-contained, code snippet that allows us to reproduce the bug in + less than 30s. +The full traceback if an exception is raised. +Attach any other additional information, like screenshots, you think may help. + +To get the OS and software versions automatically, run the following command: + +transformers-cli env +You can also run the same command from the root of the repository: + +python src/transformers/commands/transformers_cli.py env +Do you want a new feature? +If there is a new feature you'd like to see in 🤗 Transformers, please open an issue and describe: + +What is the motivation behind this feature? Is it related to a problem or frustration with the library? Is it a feature related to something you need for a project? Is it something you worked on and think it could benefit the community? + +Whatever it is, we'd love to hear about it! \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..66d9db7ba0a5482e6e55ca084a45ca96b0c0034d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_4.txt @@ -0,0 +1,14 @@ +Whatever it is, we'd love to hear about it! + +Describe your requested feature in as much detail as possible. The more you can tell us about it, the better we'll be able to help you. +Provide a code snippet that demonstrates the features usage. +If the feature is related to a paper, please include a link. + +If your issue is well written we're already 80% of the way there by the time you create it. +We have added templates to help you get started with your issue. +Do you want to implement a new model? +New models are constantly released and if you want to implement a new model, please provide the following information: + +A short description of the model and a link to the paper. +Link to the implementation if it is open-sourced. +Link to the model weights if they are available. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..9e825020e23e9be8dec03b02e6b1ea3ddc8188b7 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_5.txt @@ -0,0 +1,14 @@ +If you are willing to contribute the model yourself, let us know so we can help you add it to 🤗 Transformers! +We have a technical guide for how to add a model to 🤗 Transformers. +Do you want to add documentation? +We're always looking for improvements to the documentation that make it more clear and accurate. Please let us know how the documentation can be improved such as typos and any content that is missing, unclear or inaccurate. We'll be happy to make the changes or help you make a contribution if you're interested! +For more details about how to generate, build, and write the documentation, take a look at the documentation README. +Create a Pull Request +Before writing any code, we strongly advise you to search through the existing PRs or +issues to make sure nobody is already working on the same thing. If you are +unsure, it is always a good idea to open an issue to get some feedback. +You will need basic git proficiency to contribute to +🤗 Transformers. While git is not the easiest tool to use, it has the greatest +manual. Type git --help in a shell and enjoy! If you prefer books, Pro +Git is a very good reference. +You'll need Python 3.8 or above to contribute to 🤗 Transformers. Follow the steps below to start contributing: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..6f6a30d51eeb4a1bc135d8b9e7a613f47006b8e6 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_6.txt @@ -0,0 +1,16 @@ +Fork the repository by + clicking on the Fork button on the repository's page. This creates a copy of the code + under your GitHub user account. + +Clone your fork to your local disk, and add the base repository as a remote: + + git clone git@github.com:/transformers.git + cd transformers + git remote add upstream https://github.com/huggingface/transformers.git + +Create a new branch to hold your development changes: + + git checkout -b a-descriptive-name-for-my-changes +🚨 Do not work on the main branch! + +Set up a development environment by running the following command in a virtual environment: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..dab6de9e2eb511466ced3208e915dd41be0d57e8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_7.txt @@ -0,0 +1,17 @@ +Set up a development environment by running the following command in a virtual environment: + + pip install -e ".[dev]" +If 🤗 Transformers was already installed in the virtual environment, remove + it with pip uninstall transformers before reinstalling it in editable + mode with the -e flag. +Depending on your OS, and since the number of optional dependencies of Transformers is growing, you might get a + failure with this command. If that's the case make sure to install the Deep Learning framework you are working with + (PyTorch, TensorFlow and/or Flax) then do: + + pip install -e ".[quality]" +which should be enough for most use cases. + +Develop the features in your branch. + +As you work on your code, you should make sure the test suite + passes. Run the tests impacted by your changes like this: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..4de052f43b610860cf9b6f189dba78bb58e83fed --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_8.txt @@ -0,0 +1,19 @@ +pytest tests/.py +For more information about tests, check out the + Testing guide. +🤗 Transformers relies on black and ruff to format its source code + consistently. After you make changes, apply automatic style corrections and code verifications + that can't be automated in one go with: + + make fixup +This target is also optimized to only work with files modified by the PR you're working on. +If you prefer to run the checks one after the other, the following command applies the + style corrections: + + make style +🤗 Transformers also uses ruff and a few custom scripts to check for coding mistakes. Quality + controls are run by the CI, but you can run the same checks with: + + make quality +Finally, we have a lot of scripts to make sure we don't forget to update + some files when adding a new model. You can run these scripts with: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..1def05106917a82fda3db915703fb74ed41475bc --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_contributing.txt_chunk_9.txt @@ -0,0 +1,14 @@ +make repo-consistency +To learn more about those checks and how to fix any issues with them, check out the + Checks on a Pull Request guide. +If you're modifying documents under the docs/source directory, make sure the documentation can still be built. This check will also run in the CI when you open a pull request. To run a local check + make sure you install the documentation builder: + + pip install ".[docs]" +Run the following command from the root of the repository: + + doc-builder build transformers docs/source/en --build_dir ~/tmp/test-build +This will build the documentation in the ~/tmp/test-build folder where you can inspect the generated + Markdown files with your favorite editor. You can also preview the docs on GitHub when you open a pull request. +Once you're happy with your changes, add the changed files with git add and + record your changes locally with git commit: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..9c6841b0f6cc4d1681752a35dfe3254676c5adbe --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_0.txt @@ -0,0 +1,39 @@ +Chatting with Transformers +If you're reading this article, you're almost certainly aware of chat models. Chat models are conversational +AIs that you can send and receive messages with. The most famous of these is the proprietary ChatGPT, but there are +now many open-source chat models which match or even substantially exceed its performance. These models are free to +download and run on a local machine. Although the largest and most capable models require high-powered hardware +and lots of memory to run, there are smaller models that will run perfectly well on a single consumer GPU, or even +an ordinary desktop or notebook CPU. +This guide will help you get started with chat models. We'll start with a brief quickstart guide that uses a convenient, +high-level "pipeline". This is all you need if you just want to start running a chat model +immediately. After the quickstart, we'll move on to more detailed information about +what exactly chat models are, how to choose an appropriate one, and a low-level breakdown of each of the +steps involved in talking to a chat model. We'll also give some tips on optimizing the performance and memory usage +of your chat models. +Quickstart +If you have no time for details, here's the brief summary: Chat models continue chats. This means that you pass them +a conversation history, which can be as short as a single user message, and the model will continue the conversation +by adding its response. Let's see this in action. First, let's build a chat: +python +chat = [ + {"role": "system", "content": "You are a sassy, wise-cracking robot as imagined by Hollywood circa 1986."}, + {"role": "user", "content": "Hey, can you tell me any fun things to do in New York?"} +] +Notice that in addition to the user's message, we added a system message at the start of the conversation. Not all +chat models support system messages, but when they do, they represent high-level directives about how the model +should behave in the conversation. You can use this to guide the model - whether you want short or long responses, +lighthearted or serious ones, and so on. If you want the model to do useful work instead of +practicing its improv routine, you can either omit the system message or try a terse one such as "You are a helpful and intelligent +AI assistant who responds to user queries." +Once you have a chat, the quickest way to continue it is using the [TextGenerationPipeline]. +Let's see this in action with LLaMA-3. Note that LLaMA-3 is a gated model, which means you will need to +apply for access and log in with your Hugging Face +account to use it. We'll also use device_map="auto", which will load the model on GPU if there's enough memory +for it, and set the dtype to torch.bfloat16 to save memory: +thon +import torch +from transformers import pipeline +pipe = pipeline("text-generation", "meta-llama/Meta-Llama-3-8B-Instruct", torch_dtype=torch.bfloat16, device_map="auto") +response = pipe(chat, max_new_tokens=512) +print(response[0]['generated_text'][-1]['content']) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..e16f1d0ccdd68dbc30ce858dbb8a436218e142a6 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_1.txt @@ -0,0 +1,17 @@ +And you'll get: +```text +(sigh) Oh boy, you're asking me for advice? You're gonna need a map, pal! Alright, +alright, I'll give you the lowdown. But don't say I didn't warn you, I'm a robot, not a tour guide! +So, you wanna know what's fun to do in the Big Apple? Well, let me tell you, there's a million +things to do, but I'll give you the highlights. First off, you gotta see the sights: the Statue of +Liberty, Central Park, Times Square you know, the usual tourist traps. But if you're lookin' for +something a little more unusual, I'd recommend checkin' out the Museum of Modern Art. It's got +some wild stuff, like that Warhol guy's soup cans and all that jazz. +And if you're feelin' adventurous, take a walk across the Brooklyn Bridge. Just watch out for +those pesky pigeons, they're like little feathered thieves! (laughs) Get it? Thieves? Ah, never mind. +Now, if you're lookin' for some serious fun, hit up the comedy clubs in Greenwich Village. You might +even catch a glimpse of some up-and-coming comedians or a bunch of wannabes tryin' to make it big. (winks) +And finally, if you're feelin' like a real New Yorker, grab a slice of pizza from one of the many amazing +pizzerias around the city. Just don't try to order a "robot-sized" slice, trust me, it won't end well. (laughs) +So, there you have it, pal! That's my expert advice on what to do in New York. Now, if you'll +excuse me, I've got some oil changes to attend to. (winks) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..21339116db17fe3f096b7b1a068678d1ef384eaa --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_2.txt @@ -0,0 +1,21 @@ +You can continue the chat by appending your own response to it. The +response object returned by the pipeline actually contains the entire chat so far, so we can simply append +a message and pass it back: +python +chat = response[0]['generated_text'] +chat.append( + {"role": "user", "content": "Wait, what's so wild about soup cans?"} +) +response = pipe(chat, max_new_tokens=512) +print(response[0]['generated_text'][-1]['content']) +And you'll get: +```text +(laughs) Oh, you're killin' me, pal! You don't get it, do you? Warhol's soup cans are like, art, man! +It's like, he took something totally mundane, like a can of soup, and turned it into a masterpiece. It's +like, "Hey, look at me, I'm a can of soup, but I'm also a work of art!" +(sarcastically) Oh, yeah, real original, Andy. +But, you know, back in the '60s, it was like, a big deal. People were all about challenging the +status quo, and Warhol was like, the king of that. He took the ordinary and made it extraordinary. +And, let me tell you, it was like, a real game-changer. I mean, who would've thought that a can of soup could be art? (laughs) +But, hey, you're not alone, pal. I mean, I'm a robot, and even I don't get it. (winks) +But, hey, that's what makes art, art, right? (laughs) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..d123f516fb804bc17771ffbb9e665650a10ee5b6 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_3.txt @@ -0,0 +1,64 @@ +The remainder of this tutorial will cover specific topics such +as performance and memory, or how to select a chat model for your needs. +Choosing a chat model +There are an enormous number of different chat models available on the Hugging Face Hub, +and new users often feel very overwhelmed by the selection offered. Don't be, though! You really need to just focus on +two important considerations: +- The model's size, which will determine if you can fit it in memory and how quickly it will +run. +- The quality of the model's chat output. +In general, these are correlated - bigger models tend to be +more capable, but even so there's a lot of variation at a given size point! +Size and model naming +The size of a model is easy to spot - it's the number in the model name, like "8B" or "70B". This is the number of +parameters in the model. Without quantization, you should expect to need about 2 bytes of memory per parameter. +This means that an "8B" model with 8 billion parameters will need about 16GB of memory just to fit the parameters, +plus a little extra for other overhead. It's a good fit for a high-end consumer GPU with 24GB of memory, such as a 3090 +or 4090. +Some chat models are "Mixture of Experts" models. These may list their sizes in different ways, such as "8x7B" or +"141B-A35B". The numbers are a little fuzzier here, but in general you can read this as saying that the model +has approximately 56 (8x7) billion parameters in the first case, or 141 billion parameters in the second case. +Note that it is very common to use quantization techniques to reduce the memory usage per parameter to 8 bits, 4 bits, +or even less. This topic is discussed in more detail in the Memory considerations section below. +But which chat model is best? +Even once you know the size of chat model you can run, there's still a lot of choice out there. One way to sift through +it all is to consult leaderboards. Two of the most popular leaderboards are the OpenLLM Leaderboard +and the LMSys Chatbot Arena Leaderboard. Note that the LMSys leaderboard +also includes proprietary models - look at the licence column to identify open-source ones that you can download, then +search for them on the Hugging Face Hub. +Specialist domains +Some models may be specialized for certain domains, such as medical or legal text, or non-English languages. +If you're working in these domains, you may find that a specialized model will give you big performance benefits. +Don't automatically assume that, though! Particularly when specialized models are smaller or older than the current +cutting-edge, a top-end general-purpose model may still outclass them. Thankfully, we are beginning to see +domain-specific leaderboards that should make it easier to locate +the best models for specialized domains. +What happens inside the pipeline? +The quickstart above used a high-level pipeline to chat with a chat model, which is convenient, but not the +most flexible. Let's take a more low-level approach, to see each of the steps involved in chat. Let's start with +a code sample, and then break it down: +thon +from transformers import AutoModelForCausalLM, AutoTokenizer +import torch +Prepare the input as before +chat = [ + {"role": "system", "content": "You are a sassy, wise-cracking robot as imagined by Hollywood circa 1986."}, + {"role": "user", "content": "Hey, can you tell me any fun things to do in New York?"} +] +1: Load the model and tokenizer +model = AutoModelForCausalLM.from_pretrained("meta-llama/Meta-Llama-3-8B-Instruct", device_map="auto", torch_dtype=torch.bfloat16) +tokenizer = AutoTokenizer.from_pretrained("meta-llama/Meta-Llama-3-8B-Instruct") +2: Apply the chat template +formatted_chat = tokenizer.apply_chat_template(chat, tokenize=False, add_generation_prompt=True) +print("Formatted chat:\n", formatted_chat) +3: Tokenize the chat (This can be combined with the previous step using tokenize=True) +inputs = tokenizer(formatted_chat, return_tensors="pt", add_special_tokens=False) +Move the tokenized inputs to the same device the model is on (GPU/CPU) +inputs = {key: tensor.to(model.device) for key, tensor in inputs.items()} +print("Tokenized inputs:\n", inputs) +4: Generate text from the model +outputs = model.generate(**inputs, max_new_tokens=512, temperature=0.) +print("Generated tokens:\n", outputs) +5: Decode the output back to a string +decoded_output = tokenizer.decode(outputs[0][inputs['input_ids'].size(1):], skip_special_tokens=True) +print("Decoded output:\n", decoded_output) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..4d3fde932a5f64c46ebe333d8b9f87f56697181f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_4.txt @@ -0,0 +1,8 @@ +There's a lot in here, each piece of which could be its own document! Rather than going into too much detail, I'll cover +the broad ideas, and leave the details for the linked documents. The key steps are: + +Models and Tokenizers are loaded from the Hugging Face Hub. +The chat is formatted using the tokenizer's chat template +The formatted chat is tokenized using the tokenizer. +We generate a response from the model. +The tokens output by the model are decoded back to a string \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..4635b1088aa15f510019a75fab1956d61ee31e6a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_5.txt @@ -0,0 +1,18 @@ +Performance, memory and hardware +You probably know by now that most machine learning tasks are run on GPUs. However, it is entirely possible +to generate text from a chat model or language model on a CPU, albeit somewhat more slowly. If you can fit +the model in GPU memory, though, this will usually be the preferable option. +Memory considerations +By default, Hugging Face classes like [TextGenerationPipeline] or [AutoModelForCausalLM] will load the model in +float32 precision. This means that it will need 4 bytes (32 bits) per parameter, so an "8B" model with 8 billion +parameters will need ~32GB of memory. However, this can be wasteful! Most modern language models are trained in +"bfloat16" precision, which uses only 2 bytes per parameter. If your hardware supports it (Nvidia 30xx/Axxx +or newer), you can load the model in bfloat16 precision, using the torch_dtype argument as we did above. +It is possible to go even lower than 16-bits using "quantization", a method to lossily compress model weights. This +allows each parameter to be squeezed down to 8 bits, 4 bits or even less. Note that, especially at 4 bits, +the model's outputs may be negatively affected, but often this is a tradeoff worth making to fit a larger and more +capable chat model in memory. Let's see this in action with bitsandbytes: +thon +from transformers import AutoModelForCausalLM, BitsAndBytesConfig +quantization_config = BitsAndBytesConfig(load_in_8bit=True) # You can also try load_in_4bit +model = AutoModelForCausalLM.from_pretrained("meta-llama/Meta-Llama-3-8B-Instruct", device_map="auto", quantization_config=quantization_config) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..b99cc9303c82de1d2f9ee6913c338e5e14a7959d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_6.txt @@ -0,0 +1,11 @@ +Or we can do the same thing using the pipeline API: +thon +from transformers import pipeline, BitsAndBytesConfig +quantization_config = BitsAndBytesConfig(load_in_8bit=True) # You can also try load_in_4bit +pipe = pipeline("text-generation", "meta-llama/Meta-Llama-3-8B-Instruct", device_map="auto", model_kwargs={"quantization_config": quantization_config}) + +There are several other options for quantizing models besides bitsandbytes - please see the Quantization guide +for more information. +Performance considerations + +For a more extensive guide on language model performance and optimization, check out LLM Inference Optimization . \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..974896f97d50037e960a68637b881cd9ad2f2691 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_conversations.txt_chunk_7.txt @@ -0,0 +1,25 @@ +As a general rule, larger chat models will be slower in addition to requiring more memory. It's possible to be +more concrete about this, though: Generating text from a chat model is unusual in that it is bottlenecked by +memory bandwidth rather than compute power, because every active parameter must be read from memory for each +token that the model generates. This means that number of tokens per second you can generate from a chat +model is generally proportional to the total bandwidth of the memory it resides in, divided by the size of the model. +In our quickstart example above, our model was ~16GB in size when loaded in bfloat16 precision. +This means that 16GB must be read from memory for every token generated by the model. Total memory bandwidth can +vary from 20-100GB/sec for consumer CPUs to 200-900GB/sec for consumer GPUs, specialized CPUs like +Intel Xeon, AMD Threadripper/Epyc or high-end Apple silicon, and finally up to 2-3TB/sec for data center GPUs like +the Nvidia A100 or H100. This should give you a good idea of the generation speed you can expect from these different +hardware types. +Therefore, if you want to improve the speed of text generation, the easiest solution is to either reduce the +size of the model in memory (usually by quantization), or get hardware with higher memory bandwidth. For advanced users, +several other techniques exist to get around this bandwidth bottleneck. The most common are variants on +assisted generation, also known as "speculative +sampling". These techniques try to guess multiple future tokens at once, often using a smaller "draft model", and then +confirm these generations with the chat model. If the guesses are validated by the chat model, more than one token can +be generated per forward pass, which greatly alleviates the bandwidth bottleneck and improves generation speed. +Finally, we should also note the impact of "Mixture of Experts" (MoE) models here. Several popular chat models, +such as Mixtral, Qwen-MoE and DBRX, are MoE models. In these models, not every parameter is active for every token generated. +As a result, MoE models generally have much lower memory bandwidth requirements, even though their total size +can be quite large. They can therefore be several times faster than a normal "dense" model of the same size. However, +techniques like assisted generation are generally ineffective for these models because more parameters will become +active with each new speculated token, which will negate the bandwidth and speed benefits that the MoE architecture +provides. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..cae8b70fbfed3f34890c2648dc11eb8b7a6c6ffa --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_0.txt @@ -0,0 +1,9 @@ +Create a custom architecture +An AutoClass automatically infers the model architecture and downloads pretrained configuration and weights. Generally, we recommend using an AutoClass to produce checkpoint-agnostic code. But users who want more control over specific model parameters can create a custom 🤗 Transformers model from just a few base classes. This could be particularly useful for anyone who is interested in studying, training or experimenting with a 🤗 Transformers model. In this guide, dive deeper into creating a custom model without an AutoClass. Learn how to: + +Load and customize a model configuration. +Create a model architecture. +Create a slow and fast tokenizer for text. +Create an image processor for vision tasks. +Create a feature extractor for audio tasks. +Create a processor for multimodal tasks. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..f6c14131f918a1730840f4deccc970127404ef12 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_1.txt @@ -0,0 +1,25 @@ +Configuration +A configuration refers to a model's specific attributes. Each model configuration has different attributes; for instance, all NLP models have the hidden_size, num_attention_heads, num_hidden_layers and vocab_size attributes in common. These attributes specify the number of attention heads or hidden layers to construct a model with. +Get a closer look at DistilBERT by accessing [DistilBertConfig] to inspect it's attributes: + +from transformers import DistilBertConfig +config = DistilBertConfig() +print(config) +DistilBertConfig { + "activation": "gelu", + "attention_dropout": 0.1, + "dim": 768, + "dropout": 0.1, + "hidden_dim": 3072, + "initializer_range": 0.02, + "max_position_embeddings": 512, + "model_type": "distilbert", + "n_heads": 12, + "n_layers": 6, + "pad_token_id": 0, + "qa_dropout": 0.1, + "seq_classif_dropout": 0.2, + "sinusoidal_pos_embds": false, + "transformers_version": "4.16.2", + "vocab_size": 30522 +} \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_10.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_10.txt new file mode 100644 index 0000000000000000000000000000000000000000..3c1691017258733e72abd8b57f337b1b7627028a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_10.txt @@ -0,0 +1,11 @@ +[PreTrainedTokenizer]: a Python implementation of a tokenizer. +[PreTrainedTokenizerFast]: a tokenizer from our Rust-based 🤗 Tokenizer library. This tokenizer type is significantly faster - especially during batch tokenization - due to its Rust implementation. The fast tokenizer also offers additional methods like offset mapping which maps tokens to their original words or characters. + +Both tokenizers support common methods such as encoding and decoding, adding new tokens, and managing special tokens. + +Not every model supports a fast tokenizer. Take a look at this table to check if a model has fast tokenizer support. + +If you trained your own tokenizer, you can create one from your vocabulary file: + +from transformers import DistilBertTokenizer +my_tokenizer = DistilBertTokenizer(vocab_file="my_vocab_file.txt", do_lower_case=False, padding_side="left") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_11.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_11.txt new file mode 100644 index 0000000000000000000000000000000000000000..1d3144e82564d099705d4f77bddb7a5cb7ba4543 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_11.txt @@ -0,0 +1,11 @@ +It is important to remember the vocabulary from a custom tokenizer will be different from the vocabulary generated by a pretrained model's tokenizer. You need to use a pretrained model's vocabulary if you are using a pretrained model, otherwise the inputs won't make sense. Create a tokenizer with a pretrained model's vocabulary with the [DistilBertTokenizer] class: + +from transformers import DistilBertTokenizer +slow_tokenizer = DistilBertTokenizer.from_pretrained("distilbert/distilbert-base-uncased") + +Create a fast tokenizer with the [DistilBertTokenizerFast] class: + +from transformers import DistilBertTokenizerFast +fast_tokenizer = DistilBertTokenizerFast.from_pretrained("distilbert/distilbert-base-uncased") + +By default, [AutoTokenizer] will try to load a fast tokenizer. You can disable this behavior by setting use_fast=False in from_pretrained. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_12.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_12.txt new file mode 100644 index 0000000000000000000000000000000000000000..dc759a59974d89e3c301dcd95eb82d923b3d5ee3 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_12.txt @@ -0,0 +1,28 @@ +Image processor +An image processor processes vision inputs. It inherits from the base [~image_processing_utils.ImageProcessingMixin] class. +To use, create an image processor associated with the model you're using. For example, create a default [ViTImageProcessor] if you are using ViT for image classification: + +from transformers import ViTImageProcessor +vit_extractor = ViTImageProcessor() +print(vit_extractor) +ViTImageProcessor { + "do_normalize": true, + "do_resize": true, + "image_processor_type": "ViTImageProcessor", + "image_mean": [ + 0.5, + 0.5, + 0.5 + ], + "image_std": [ + 0.5, + 0.5, + 0.5 + ], + "resample": 2, + "size": 224 +} + +If you aren't looking for any customization, just use the from_pretrained method to load a model's default image processor parameters. + +Modify any of the [ViTImageProcessor] parameters to create your custom image processor: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_13.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_13.txt new file mode 100644 index 0000000000000000000000000000000000000000..cdd6f6f300f9f409826550e9d611f25da36b7daa --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_13.txt @@ -0,0 +1,24 @@ +Modify any of the [ViTImageProcessor] parameters to create your custom image processor: + +from transformers import ViTImageProcessor +my_vit_extractor = ViTImageProcessor(resample="PIL.Image.BOX", do_normalize=False, image_mean=[0.3, 0.3, 0.3]) +print(my_vit_extractor) +ViTImageProcessor { + "do_normalize": false, + "do_resize": true, + "image_processor_type": "ViTImageProcessor", + "image_mean": [ + 0.3, + 0.3, + 0.3 + ], + "image_std": [ + 0.5, + 0.5, + 0.5 + ], + "resample": "PIL.Image.BOX", + "size": 224 +} + +Backbone \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_14.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_14.txt new file mode 100644 index 0000000000000000000000000000000000000000..c9601ff231dd5483f36427bcef7d01347f5d0fef --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_14.txt @@ -0,0 +1,12 @@ +Backbone + +Computer vision models consist of a backbone, neck, and head. The backbone extracts features from an input image, the neck combines and enhances the extracted features, and the head is used for the main task (e.g., object detection). Start by initializing a backbone in the model config and specify whether you want to load pretrained weights or load randomly initialized weights. Then you can pass the model config to the model head. +For example, to load a ResNet backbone into a MaskFormer model with an instance segmentation head: + +Set use_pretrained_backbone=True to load pretrained ResNet weights for the backbone. + +from transformers import MaskFormerConfig, MaskFormerForInstanceSegmentation +config = MaskFormerConfig(backbone="microsoft/resnet-50", use_pretrained_backbone=True) # backbone and neck config +model = MaskFormerForInstanceSegmentation(config) # head + +Set use_pretrained_backbone=False to randomly initialize a ResNet backbone. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_15.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_15.txt new file mode 100644 index 0000000000000000000000000000000000000000..0d0ab620feaa24e813efb007e86bcc8c4a34fbeb --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_15.txt @@ -0,0 +1,12 @@ +Set use_pretrained_backbone=False to randomly initialize a ResNet backbone. + +from transformers import MaskFormerConfig, MaskFormerForInstanceSegmentation +config = MaskFormerConfig(backbone="microsoft/resnet-50", use_pretrained_backbone=False) # backbone and neck config +model = MaskFormerForInstanceSegmentation(config) # head + +You could also load the backbone config separately and then pass it to the model config. + +from transformers import MaskFormerConfig, MaskFormerForInstanceSegmentation, ResNetConfig +backbone_config = ResNetConfig() +config = MaskFormerConfig(backbone_config=backbone_config) +model = MaskFormerForInstanceSegmentation(config) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_16.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_16.txt new file mode 100644 index 0000000000000000000000000000000000000000..f0f85aed78ad6a78dd8e29026cf165f046232373 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_16.txt @@ -0,0 +1,12 @@ +timm models are loaded within a model with use_timm_backbone=True or with [TimmBackbone] and [TimmBackboneConfig]. +Use use_timm_backbone=True and use_pretrained_backbone=True to load pretrained timm weights for the backbone. +thon +from transformers import MaskFormerConfig, MaskFormerForInstanceSegmentation +config = MaskFormerConfig(backbone="resnet50", use_pretrained_backbone=True, use_timm_backbone=True) # backbone and neck config +model = MaskFormerForInstanceSegmentation(config) # head + +Set use_timm_backbone=True and use_pretrained_backbone=False to load a randomly initialized timm backbone. +thon +from transformers import MaskFormerConfig, MaskFormerForInstanceSegmentation +config = MaskFormerConfig(backbone="resnet50", use_pretrained_backbone=False, use_timm_backbone=True) # backbone and neck config +model = MaskFormerForInstanceSegmentation(config) # head \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_17.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_17.txt new file mode 100644 index 0000000000000000000000000000000000000000..c670f116f6ff46a9e4e27030b18f3a9d87eb5a1a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_17.txt @@ -0,0 +1,10 @@ +You could also load the backbone config and use it to create a TimmBackbone or pass it to the model config. Timm backbones will load pretrained weights by default. Set use_pretrained_backbone=False to load randomly initialized weights. +thon +from transformers import TimmBackboneConfig, TimmBackbone +backbone_config = TimmBackboneConfig("resnet50", use_pretrained_backbone=False) +Create a backbone class +backbone = TimmBackbone(config=backbone_config) +Create a model with a timm backbone +from transformers import MaskFormerConfig, MaskFormerForInstanceSegmentation +config = MaskFormerConfig(backbone_config=backbone_config) +model = MaskFormerForInstanceSegmentation(config) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_18.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_18.txt new file mode 100644 index 0000000000000000000000000000000000000000..ae20232a549cfbdcc4abd23bcaf405994cbecc03 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_18.txt @@ -0,0 +1,18 @@ +Feature extractor +A feature extractor processes audio inputs. It inherits from the base [~feature_extraction_utils.FeatureExtractionMixin] class, and may also inherit from the [SequenceFeatureExtractor] class for processing audio inputs. +To use, create a feature extractor associated with the model you're using. For example, create a default [Wav2Vec2FeatureExtractor] if you are using Wav2Vec2 for audio classification: + +from transformers import Wav2Vec2FeatureExtractor +w2v2_extractor = Wav2Vec2FeatureExtractor() +print(w2v2_extractor) +Wav2Vec2FeatureExtractor { + "do_normalize": true, + "feature_extractor_type": "Wav2Vec2FeatureExtractor", + "feature_size": 1, + "padding_side": "right", + "padding_value": 0.0, + "return_attention_mask": false, + "sampling_rate": 16000 +} + +If you aren't looking for any customization, just use the from_pretrained method to load a model's default feature extractor parameters. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_19.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_19.txt new file mode 100644 index 0000000000000000000000000000000000000000..a2fe6d44f1b761361c94e43a0d5cd612c8fa3759 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_19.txt @@ -0,0 +1,18 @@ +Modify any of the [Wav2Vec2FeatureExtractor] parameters to create your custom feature extractor: + +from transformers import Wav2Vec2FeatureExtractor +w2v2_extractor = Wav2Vec2FeatureExtractor(sampling_rate=8000, do_normalize=False) +print(w2v2_extractor) +Wav2Vec2FeatureExtractor { + "do_normalize": false, + "feature_extractor_type": "Wav2Vec2FeatureExtractor", + "feature_size": 1, + "padding_side": "right", + "padding_value": 0.0, + "return_attention_mask": false, + "sampling_rate": 8000 +} + +Processor +For models that support multimodal tasks, 🤗 Transformers offers a processor class that conveniently wraps processing classes such as a feature extractor and a tokenizer into a single object. For example, let's use the [Wav2Vec2Processor] for an automatic speech recognition task (ASR). ASR transcribes audio to text, so you will need a feature extractor and a tokenizer. +Create a feature extractor to handle the audio inputs: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..c0abafce7a0ec8050d94c9be1e364b2fa5ceaf2a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_2.txt @@ -0,0 +1,27 @@ +[DistilBertConfig] displays all the default attributes used to build a base [DistilBertModel]. All attributes are customizable, creating space for experimentation. For example, you can customize a default model to: + +Try a different activation function with the activation parameter. +Use a higher dropout ratio for the attention probabilities with the attention_dropout parameter. + +my_config = DistilBertConfig(activation="relu", attention_dropout=0.4) +print(my_config) +DistilBertConfig { + "activation": "relu", + "attention_dropout": 0.4, + "dim": 768, + "dropout": 0.1, + "hidden_dim": 3072, + "initializer_range": 0.02, + "max_position_embeddings": 512, + "model_type": "distilbert", + "n_heads": 12, + "n_layers": 6, + "pad_token_id": 0, + "qa_dropout": 0.1, + "seq_classif_dropout": 0.2, + "sinusoidal_pos_embds": false, + "transformers_version": "4.16.2", + "vocab_size": 30522 +} + +Pretrained model attributes can be modified in the [~PretrainedConfig.from_pretrained] function: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_20.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_20.txt new file mode 100644 index 0000000000000000000000000000000000000000..5233a6f81f2493f0f5a7a2ccf7f250ad62fdf310 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_20.txt @@ -0,0 +1,14 @@ +from transformers import Wav2Vec2FeatureExtractor +feature_extractor = Wav2Vec2FeatureExtractor(padding_value=1.0, do_normalize=True) + +Create a tokenizer to handle the text inputs: + +from transformers import Wav2Vec2CTCTokenizer +tokenizer = Wav2Vec2CTCTokenizer(vocab_file="my_vocab_file.txt") + +Combine the feature extractor and tokenizer in [Wav2Vec2Processor]: + +from transformers import Wav2Vec2Processor +processor = Wav2Vec2Processor(feature_extractor=feature_extractor, tokenizer=tokenizer) + +With two basic classes - configuration and model - and an additional preprocessing class (tokenizer, image processor, feature extractor, or processor), you can create any of the models supported by 🤗 Transformers. Each of these base classes are configurable, allowing you to use the specific attributes you want. You can easily setup a model for training or modify an existing pretrained model to fine-tune. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..e543edef29ba5ed33f318a3778bb5b4c75c50c37 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_3.txt @@ -0,0 +1,13 @@ +Pretrained model attributes can be modified in the [~PretrainedConfig.from_pretrained] function: + +my_config = DistilBertConfig.from_pretrained("distilbert/distilbert-base-uncased", activation="relu", attention_dropout=0.4) + +Once you are satisfied with your model configuration, you can save it with [~PretrainedConfig.save_pretrained]. Your configuration file is stored as a JSON file in the specified save directory: + +my_config.save_pretrained(save_directory="./your_model_save_path") + +To reuse the configuration file, load it with [~PretrainedConfig.from_pretrained]: + +my_config = DistilBertConfig.from_pretrained("./your_model_save_path/config.json") + +You can also save your configuration file as a dictionary or even just the difference between your custom configuration attributes and the default configuration attributes! See the configuration documentation for more details. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..1c88991935f673cbbca2044a4bb67b754d9f2a8d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_4.txt @@ -0,0 +1,8 @@ +Model +The next step is to create a model. The model - also loosely referred to as the architecture - defines what each layer is doing and what operations are happening. Attributes like num_hidden_layers from the configuration are used to define the architecture. Every model shares the base class [PreTrainedModel] and a few common methods like resizing input embeddings and pruning self-attention heads. In addition, all models are also either a torch.nn.Module, tf.keras.Model or flax.linen.Module subclass. This means models are compatible with each of their respective framework's usage. + +Load your custom configuration attributes into the model: + +from transformers import DistilBertModel +my_config = DistilBertConfig.from_pretrained("./your_model_save_path/config.json") +model = DistilBertModel(my_config) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..d8f7ee9537a05a2ca0a1fd613b2c2cc0e287e1da --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_5.txt @@ -0,0 +1,10 @@ +This creates a model with random values instead of pretrained weights. You won't be able to use this model for anything useful yet until you train it. Training is a costly and time-consuming process. It is generally better to use a pretrained model to obtain better results faster, while using only a fraction of the resources required for training. +Create a pretrained model with [~PreTrainedModel.from_pretrained]: + +model = DistilBertModel.from_pretrained("distilbert/distilbert-base-uncased") + +When you load pretrained weights, the default model configuration is automatically loaded if the model is provided by 🤗 Transformers. However, you can still replace - some or all of - the default model configuration attributes with your own if you'd like: + +model = DistilBertModel.from_pretrained("distilbert/distilbert-base-uncased", config=my_config) + +Load your custom configuration attributes into the model: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..252d5e165bfdafc5c881668a8449e2529be51261 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_6.txt @@ -0,0 +1,12 @@ +Load your custom configuration attributes into the model: + +from transformers import TFDistilBertModel +my_config = DistilBertConfig.from_pretrained("./your_model_save_path/my_config.json") +tf_model = TFDistilBertModel(my_config) + +This creates a model with random values instead of pretrained weights. You won't be able to use this model for anything useful yet until you train it. Training is a costly and time-consuming process. It is generally better to use a pretrained model to obtain better results faster, while using only a fraction of the resources required for training. +Create a pretrained model with [~TFPreTrainedModel.from_pretrained]: + +tf_model = TFDistilBertModel.from_pretrained("distilbert/distilbert-base-uncased") + +When you load pretrained weights, the default model configuration is automatically loaded if the model is provided by 🤗 Transformers. However, you can still replace - some or all of - the default model configuration attributes with your own if you'd like: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..b121564b63f1ae915d56012408a188a7f158edec --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_7.txt @@ -0,0 +1,9 @@ +tf_model = TFDistilBertModel.from_pretrained("distilbert/distilbert-base-uncased", config=my_config) + +Model heads +At this point, you have a base DistilBERT model which outputs the hidden states. The hidden states are passed as inputs to a model head to produce the final output. 🤗 Transformers provides a different model head for each task as long as a model supports the task (i.e., you can't use DistilBERT for a sequence-to-sequence task like translation). + +For example, [DistilBertForSequenceClassification] is a base DistilBERT model with a sequence classification head. The sequence classification head is a linear layer on top of the pooled outputs. + +from transformers import DistilBertForSequenceClassification +model = DistilBertForSequenceClassification.from_pretrained("distilbert/distilbert-base-uncased") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..1593dec3ebb75e9bc47f340beff5a4e3235d370d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_8.txt @@ -0,0 +1,11 @@ +Easily reuse this checkpoint for another task by switching to a different model head. For a question answering task, you would use the [DistilBertForQuestionAnswering] model head. The question answering head is similar to the sequence classification head except it is a linear layer on top of the hidden states output. + +from transformers import DistilBertForQuestionAnswering +model = DistilBertForQuestionAnswering.from_pretrained("distilbert/distilbert-base-uncased") +`` + + +For example, [TFDistilBertForSequenceClassification`] is a base DistilBERT model with a sequence classification head. The sequence classification head is a linear layer on top of the pooled outputs. + +from transformers import TFDistilBertForSequenceClassification +tf_model = TFDistilBertForSequenceClassification.from_pretrained("distilbert/distilbert-base-uncased") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..6e445c7ab23e36c1382eac25454aa3235b5fb03a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_create_a_model.txt_chunk_9.txt @@ -0,0 +1,7 @@ +Easily reuse this checkpoint for another task by switching to a different model head. For a question answering task, you would use the [TFDistilBertForQuestionAnswering] model head. The question answering head is similar to the sequence classification head except it is a linear layer on top of the hidden states output. + +from transformers import TFDistilBertForQuestionAnswering +tf_model = TFDistilBertForQuestionAnswering.from_pretrained("distilbert/distilbert-base-uncased") + +Tokenizer +The last base class you need before using a model for textual data is a tokenizer to convert raw text to tensors. There are two types of tokenizers you can use with 🤗 Transformers: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..831eedac8027368624f10d54e96d241c21f083f6 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_0.txt @@ -0,0 +1,14 @@ +Building custom models +The 🤗 Transformers library is designed to be easily extensible. Every model is fully coded in a given subfolder +of the repository with no abstraction, so you can easily copy a modeling file and tweak it to your needs. +If you are writing a brand new model, it might be easier to start from scratch. In this tutorial, we will show you +how to write a custom model and its configuration so it can be used inside Transformers, and how you can share it +with the community (with the code it relies on) so that anyone can use it, even if it's not present in the 🤗 +Transformers library. We'll see how to build upon transformers and extend the framework with your hooks and +custom code. +We will illustrate all of this on a ResNet model, by wrapping the ResNet class of the +timm library into a [PreTrainedModel]. +Writing a custom configuration +Before we dive into the model, let's first write its configuration. The configuration of a model is an object that +will contain all the necessary information to build the model. As we will see in the next section, the model can only +take a config to be initialized, so we really need that object to be as complete as possible. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..b776232801aba00ce2d819f6fc333bdfb2ba6421 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_1.txt @@ -0,0 +1,5 @@ +Models in the transformers library itself generally follow the convention that they accept a config object +in their __init__ method, and then pass the whole config to sub-layers in the model, rather than breaking the +config object into multiple arguments that are all passed individually to sub-layers. Writing your model in this +style results in simpler code with a clear "source of truth" for any hyperparameters, and also makes it easier +to reuse code from other models in transformers. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_10.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_10.txt new file mode 100644 index 0000000000000000000000000000000000000000..501d503385011cbb4bdc6bdffa9f1331792d8948 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_10.txt @@ -0,0 +1,11 @@ +from transformers import AutoConfig, AutoModel, AutoModelForImageClassification +AutoConfig.register("resnet", ResnetConfig) +AutoModel.register(ResnetConfig, ResnetModel) +AutoModelForImageClassification.register(ResnetConfig, ResnetModelForImageClassification) + +Note that the first argument used when registering your custom config to [AutoConfig] needs to match the model_type +of your custom config, and the first argument used when registering your custom models to any auto model class needs +to match the config_class of those models. +Sending the code to the Hub + +This API is experimental and may have some slight breaking changes in the next releases. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_11.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_11.txt new file mode 100644 index 0000000000000000000000000000000000000000..1c3ea45335cc96d6367166f8825d3b1d035d2385 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_11.txt @@ -0,0 +1,16 @@ +This API is experimental and may have some slight breaking changes in the next releases. + +First, make sure your model is fully defined in a .py file. It can rely on relative imports to some other files as +long as all the files are in the same directory (we don't support submodules for this feature yet). For our example, +we'll define a modeling_resnet.py file and a configuration_resnet.py file in a folder of the current working +directory named resnet_model. The configuration file contains the code for ResnetConfig and the modeling file +contains the code of ResnetModel and ResnetModelForImageClassification. +. +└── resnet_model + ├── __init__.py + ├── configuration_resnet.py + └── modeling_resnet.py +The __init__.py can be empty, it's just there so that Python detects resnet_model can be use as a module. + +If copying a modeling files from the library, you will need to replace all the relative imports at the top of the file +to import from the transformers package. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_12.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_12.txt new file mode 100644 index 0000000000000000000000000000000000000000..6ac9f63f61e82556595f8def0284df7c6a9900eb --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_12.txt @@ -0,0 +1,15 @@ +Note that you can re-use (or subclass) an existing configuration/model. +To share your model with the community, follow those steps: first import the ResNet model and config from the newly +created files: +py +from resnet_model.configuration_resnet import ResnetConfig +from resnet_model.modeling_resnet import ResnetModel, ResnetModelForImageClassification +Then you have to tell the library you want to copy the code files of those objects when using the save_pretrained +method and properly register them with a given Auto class (especially for models), just run: +py +ResnetConfig.register_for_auto_class() +ResnetModel.register_for_auto_class("AutoModel") +ResnetModelForImageClassification.register_for_auto_class("AutoModelForImageClassification") +Note that there is no need to specify an auto class for the configuration (there is only one auto class for them, +[AutoConfig]) but it's different for models. Your custom model could be suitable for many different tasks, so you +have to specify which one of the auto classes is the correct one for your model. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_13.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_13.txt new file mode 100644 index 0000000000000000000000000000000000000000..a26636982c63c63fe511a117865fbb132a6b8511 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_13.txt @@ -0,0 +1,21 @@ +Use register_for_auto_class() if you want the code files to be copied. If you instead prefer to use code on the Hub from another repo, +you don't need to call it. In cases where there's more than one auto class, you can modify the config.json directly using the +following structure: +json +"auto_map": { + "AutoConfig": "--", + "AutoModel": "--", + "AutoModelFor": "--", +}, + +Next, let's create the config and models as we did before: + +resnet50d_config = ResnetConfig(block_type="bottleneck", stem_width=32, stem_type="deep", avg_down=True) +resnet50d = ResnetModelForImageClassification(resnet50d_config) +pretrained_model = timm.create_model("resnet50d", pretrained=True) +resnet50d.model.load_state_dict(pretrained_model.state_dict()) + +Now to send the model to the Hub, make sure you are logged in. Either run in your terminal: + +huggingface-cli login +or from a notebook: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_14.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_14.txt new file mode 100644 index 0000000000000000000000000000000000000000..db8fa64770a0e53f9c3eca110da0da3e94ef64f9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_14.txt @@ -0,0 +1,5 @@ +huggingface-cli login +or from a notebook: + +from huggingface_hub import notebook_login +notebook_login() \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_15.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_15.txt new file mode 100644 index 0000000000000000000000000000000000000000..841a628e9430db2ab276243cff7b97e7d091f400 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_15.txt @@ -0,0 +1,15 @@ +from huggingface_hub import notebook_login +notebook_login() + +You can then push to your own namespace (or an organization you are a member of) like this: +py +resnet50d.push_to_hub("custom-resnet50d") +On top of the modeling weights and the configuration in json format, this also copied the modeling and +configuration .py files in the folder custom-resnet50d and uploaded the result to the Hub. You can check the result +in this model repo. +See the sharing tutorial for more information on the push to Hub method. +Using a model with custom code +You can use any configuration, model or tokenizer with custom code files in its repository with the auto-classes and +the from_pretrained method. All files and code uploaded to the Hub are scanned for malware (refer to the Hub security documentation for more information), but you should still +review the model code and author to avoid executing malicious code on your machine. Set trust_remote_code=True to use +a model with custom code: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_16.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_16.txt new file mode 100644 index 0000000000000000000000000000000000000000..a439e9fc3e5e14e82b02150f05e725a1f6c9d13b --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_16.txt @@ -0,0 +1,12 @@ +from transformers import AutoModelForImageClassification +model = AutoModelForImageClassification.from_pretrained("sgugger/custom-resnet50d", trust_remote_code=True) + +It is also strongly encouraged to pass a commit hash as a revision to make sure the author of the models did not +update the code with some malicious new lines (unless you fully trust the authors of the models). +py +commit_hash = "ed94a7c6247d8aedce4647f00f20de6875b5b292" +model = AutoModelForImageClassification.from_pretrained( + "sgugger/custom-resnet50d", trust_remote_code=True, revision=commit_hash +) +Note that when browsing the commit history of the model repo on the Hub, there is a button to easily copy the commit +hash of any commit. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..65df3346bf8123d6c593a6dac68d2c42ab01e480 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_2.txt @@ -0,0 +1,25 @@ +In our example, we will take a couple of arguments of the ResNet class that we might want to tweak. Different +configurations will then give us the different types of ResNets that are possible. We then just store those arguments, +after checking the validity of a few of them. +thon +from transformers import PretrainedConfig +from typing import List +class ResnetConfig(PretrainedConfig): + model_type = "resnet" +def __init__( + self, + block_type="bottleneck", + layers: List[int] = [3, 4, 6, 3], + num_classes: int = 1000, + input_channels: int = 3, + cardinality: int = 1, + base_width: int = 64, + stem_width: int = 64, + stem_type: str = "", + avg_down: bool = False, + **kwargs, +): + if block_type not in ["basic", "bottleneck"]: + raise ValueError(f"`block_type` must be 'basic' or bottleneck', got {block_type}.") + if stem_type not in ["", "deep", "deep-tiered"]: + raise ValueError(f"`stem_type` must be '', 'deep' or 'deep-tiered', got {stem_type}.") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..6908ae0363546f440a9901621b61c15b94da4aed --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_3.txt @@ -0,0 +1,10 @@ +self.block_type = block_type + self.layers = layers + self.num_classes = num_classes + self.input_channels = input_channels + self.cardinality = cardinality + self.base_width = base_width + self.stem_width = stem_width + self.stem_type = stem_type + self.avg_down = avg_down + super().__init__(**kwargs) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..2f17750079b8cf1314f858ae4c63a9943babc27f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_4.txt @@ -0,0 +1,28 @@ +The three important things to remember when writing you own configuration are the following: +- you have to inherit from PretrainedConfig, +- the __init__ of your PretrainedConfig must accept any kwargs, +- those kwargs need to be passed to the superclass __init__. +The inheritance is to make sure you get all the functionality from the 🤗 Transformers library, while the two other +constraints come from the fact a PretrainedConfig has more fields than the ones you are setting. When reloading a +config with the from_pretrained method, those fields need to be accepted by your config and then sent to the +superclass. +Defining a model_type for your configuration (here model_type="resnet") is not mandatory, unless you want to +register your model with the auto classes (see last section). +With this done, you can easily create and save your configuration like you would do with any other model config of the +library. Here is how we can create a resnet50d config and save it: +py +resnet50d_config = ResnetConfig(block_type="bottleneck", stem_width=32, stem_type="deep", avg_down=True) +resnet50d_config.save_pretrained("custom-resnet") +This will save a file named config.json inside the folder custom-resnet. You can then reload your config with the +from_pretrained method: +py +resnet50d_config = ResnetConfig.from_pretrained("custom-resnet") +You can also use any other method of the [PretrainedConfig] class, like [~PretrainedConfig.push_to_hub] to +directly upload your config to the Hub. +Writing a custom model +Now that we have our ResNet configuration, we can go on writing the model. We will actually write two: one that +extracts the hidden features from a batch of images (like [BertModel]) and one that is suitable for image +classification (like [BertForSequenceClassification]). +As we mentioned before, we'll only write a loose wrapper of the model to keep it simple for this example. The only +thing we need to do before writing this class is a map between the block types and actual block classes. Then the +model is defined from the configuration by passing everything to the ResNet class: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..d74411a3507d51d68136dac12d8f4190cb7cb45e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_5.txt @@ -0,0 +1,25 @@ +from transformers import PreTrainedModel +from timm.models.resnet import BasicBlock, Bottleneck, ResNet +from .configuration_resnet import ResnetConfig +BLOCK_MAPPING = {"basic": BasicBlock, "bottleneck": Bottleneck} +class ResnetModel(PreTrainedModel): + config_class = ResnetConfig +def __init__(self, config): + super().__init__(config) + block_layer = BLOCK_MAPPING[config.block_type] + self.model = ResNet( + block_layer, + config.layers, + num_classes=config.num_classes, + in_chans=config.input_channels, + cardinality=config.cardinality, + base_width=config.base_width, + stem_width=config.stem_width, + stem_type=config.stem_type, + avg_down=config.avg_down, + ) + +def forward(self, tensor): + return self.model.forward_features(tensor) + +For the model that will classify images, we just change the forward method: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..d75ed4ab6edabc313b4ad1279a307e7d00769154 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_6.txt @@ -0,0 +1,26 @@ +For the model that will classify images, we just change the forward method: + +import torch +class ResnetModelForImageClassification(PreTrainedModel): + config_class = ResnetConfig +def __init__(self, config): + super().__init__(config) + block_layer = BLOCK_MAPPING[config.block_type] + self.model = ResNet( + block_layer, + config.layers, + num_classes=config.num_classes, + in_chans=config.input_channels, + cardinality=config.cardinality, + base_width=config.base_width, + stem_width=config.stem_width, + stem_type=config.stem_type, + avg_down=config.avg_down, + ) + +def forward(self, tensor, labels=None): + logits = self.model(tensor) + if labels is not None: + loss = torch.nn.cross_entropy(logits, labels) + return {"loss": loss, "logits": logits} + return {"logits": logits} \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..300c5fd176a249260465121c8afbc6f2d67586b1 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_7.txt @@ -0,0 +1,5 @@ +In both cases, notice how we inherit from PreTrainedModel and call the superclass initialization with the config +(a bit like when you write a regular torch.nn.Module). The line that sets the config_class is not mandatory, unless +you want to register your model with the auto classes (see last section). + +If your model is very similar to a model inside the library, you can re-use the same configuration as this model. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..163b1a92810fba3cb0cee9cdb3516059af095ca0 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_8.txt @@ -0,0 +1,13 @@ +You can have your model return anything you want, but returning a dictionary like we did for +ResnetModelForImageClassification, with the loss included when labels are passed, will make your model directly +usable inside the [Trainer] class. Using another output format is fine as long as you are planning on using your own +training loop or another library for training. +Now that we have our model class, let's create one: +py +resnet50d = ResnetModelForImageClassification(resnet50d_config) +Again, you can use any of the methods of [PreTrainedModel], like [~PreTrainedModel.save_pretrained] or +[~PreTrainedModel.push_to_hub]. We will use the second in the next section, and see how to push the model weights +with the code of our model. But first, let's load some pretrained weights inside our model. +In your own use case, you will probably be training your custom model on your own data. To go fast for this tutorial, +we will use the pretrained version of the resnet50d. Since our model is just a wrapper around it, it's going to be +easy to transfer those weights: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..b83c5e83bc946366994a1efceac2d92ab58653ac --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_custom_models.txt_chunk_9.txt @@ -0,0 +1,12 @@ +import timm +pretrained_model = timm.create_model("resnet50d", pretrained=True) +resnet50d.model.load_state_dict(pretrained_model.state_dict()) + +Now let's see how to make sure that when we do [~PreTrainedModel.save_pretrained] or [~PreTrainedModel.push_to_hub], the +code of the model is saved. +Registering a model with custom code to the auto classes +If you are writing a library that extends 🤗 Transformers, you may want to extend the auto classes to include your own +model. This is different from pushing the code to the Hub in the sense that users will need to import your library to +get the custom models (contrarily to automatically downloading the model code from the Hub). +As long as your config has a model_type attribute that is different from existing model types, and that your model +classes have the right config_class attributes, you can just add them to the auto classes like this: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..088a57f1f260671fffa9d826149d0b9b1e40ade6 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_0.txt @@ -0,0 +1,9 @@ +Debugging +Training on multiple GPUs can be a tricky endeavor whether you're running into installation issues or communication problems between your GPUs. This debugging guide covers some issues you may run into and how to resolve them. +DeepSpeed CUDA installation +If you're using DeepSpeed, you've probably already installed it with the following command. + +pip install deepspeed +DeepSpeed compiles CUDA C++ code and it can be a potential source of errors when building PyTorch extensions that require CUDA. These errors depend on how CUDA is installed on your system, and this section focuses on PyTorch built with CUDA 10.2. + +For any other installation issues, please open an issue with the DeepSpeed team. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..dcfca5548c9d98f9fef2bc0305b3e7f0c773a002 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_1.txt @@ -0,0 +1,9 @@ +For any other installation issues, please open an issue with the DeepSpeed team. + +Non-identical CUDA toolkits +PyTorch comes with its own CUDA toolkit, but to use DeepSpeed with PyTorch, you need to have an identical version of CUDA installed system-wide. For example, if you installed PyTorch with cudatoolkit==10.2 in your Python environment, then you'll also need to have CUDA 10.2 installed system-wide. If you don't have CUDA installed system-wide, you should install it first. +The exact location may vary from system to system, but usr/local/cuda-10.2 is the most common location on many Unix systems. When CUDA is correctly setup and added to your PATH environment variable, you can find the installation location with the following command: + +which nvcc +Multiple CUDA toolkits +You may also have more than one CUDA toolkit installed system-wide. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_10.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_10.txt new file mode 100644 index 0000000000000000000000000000000000000000..b89e3ba7b2e5de8059189f3048b079a5516d9259 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_10.txt @@ -0,0 +1,106 @@ +[~debug_utils.DebugUnderflowOverflow] inserts hooks into the model that immediately after each +forward call will test input and output variables and also the corresponding module's weights. As soon as inf or +nan is detected in at least one element of the activations or weights, the program will assert and print a report +like this (this was caught with google/mt5-small under fp16 mixed precision): +Detected inf/nan during batch_number=0 +Last 21 forward frames: +abs min abs max metadata + encoder.block.1.layer.1.DenseReluDense.dropout Dropout +0.00e+00 2.57e+02 input[0] +0.00e+00 2.85e+02 output +[] + encoder.block.2.layer.0 T5LayerSelfAttention +6.78e-04 3.15e+03 input[0] +2.65e-04 3.42e+03 output[0] + None output[1] +2.25e-01 1.00e+04 output[2] + encoder.block.2.layer.1.layer_norm T5LayerNorm +8.69e-02 4.18e-01 weight +2.65e-04 3.42e+03 input[0] +1.79e-06 4.65e+00 output + encoder.block.2.layer.1.DenseReluDense.wi_0 Linear +2.17e-07 4.50e+00 weight +1.79e-06 4.65e+00 input[0] +2.68e-06 3.70e+01 output + encoder.block.2.layer.1.DenseReluDense.wi_1 Linear +8.08e-07 2.66e+01 weight +1.79e-06 4.65e+00 input[0] +1.27e-04 2.37e+02 output + encoder.block.2.layer.1.DenseReluDense.dropout Dropout +0.00e+00 8.76e+03 input[0] +0.00e+00 9.74e+03 output + encoder.block.2.layer.1.DenseReluDense.wo Linear +1.01e-06 6.44e+00 weight +0.00e+00 9.74e+03 input[0] +3.18e-04 6.27e+04 output + encoder.block.2.layer.1.DenseReluDense T5DenseGatedGeluDense +1.79e-06 4.65e+00 input[0] +3.18e-04 6.27e+04 output + encoder.block.2.layer.1.dropout Dropout +3.18e-04 6.27e+04 input[0] +0.00e+00 inf output +The example output has been trimmed in the middle for brevity. +The second column shows the value of the absolute largest element, so if you have a closer look at the last few frames, +the inputs and outputs were in the range of 1e4. So when this training was done under fp16 mixed precision the very +last step overflowed (since under fp16 the largest number before inf is 64e3). To avoid overflows under +fp16 the activations must remain way below 1e4, because 1e4 * 1e4 = 1e8 so any matrix multiplication with +large activations is going to lead to a numerical overflow condition. +At the very start of the trace you can discover at which batch number the problem occurred (here Detected inf/nan during batch_number=0 means the problem occurred on the first batch). +Each reported frame starts by declaring the fully qualified entry for the corresponding module this frame is reporting +for. If we look just at this frame: +encoder.block.2.layer.1.layer_norm T5LayerNorm +8.69e-02 4.18e-01 weight +2.65e-04 3.42e+03 input[0] +1.79e-06 4.65e+00 output +Here, encoder.block.2.layer.1.layer_norm indicates that it was a layer norm for the first layer, of the second +block of the encoder. And the specific calls of the forward is T5LayerNorm. +Let's look at the last few frames of that report: +Detected inf/nan during batch_number=0 +Last 21 forward frames: +abs min abs max metadata +[] + encoder.block.2.layer.1.DenseReluDense.wi_0 Linear +2.17e-07 4.50e+00 weight +1.79e-06 4.65e+00 input[0] +2.68e-06 3.70e+01 output + encoder.block.2.layer.1.DenseReluDense.wi_1 Linear +8.08e-07 2.66e+01 weight +1.79e-06 4.65e+00 input[0] +1.27e-04 2.37e+02 output + encoder.block.2.layer.1.DenseReluDense.wo Linear +1.01e-06 6.44e+00 weight +0.00e+00 9.74e+03 input[0] +3.18e-04 6.27e+04 output + encoder.block.2.layer.1.DenseReluDense T5DenseGatedGeluDense +1.79e-06 4.65e+00 input[0] +3.18e-04 6.27e+04 output + encoder.block.2.layer.1.dropout Dropout +3.18e-04 6.27e+04 input[0] +0.00e+00 inf output +The last frame reports for Dropout.forward function with the first entry for the only input and the second for the +only output. You can see that it was called from an attribute dropout inside DenseReluDense class. We can see +that it happened during the first layer, of the 2nd block, during the very first batch. Finally, the absolute largest +input elements was 6.27e+04 and same for the output was inf. +You can see here, that T5DenseGatedGeluDense.forward resulted in output activations, whose absolute max value was +around 62.7K, which is very close to fp16's top limit of 64K. In the next frame we have Dropout which renormalizes +the weights, after it zeroed some of the elements, which pushes the absolute max value to more than 64K, and we get an +overflow (inf). +As you can see it's the previous frames that we need to look into when the numbers start going into very large for fp16 +numbers. +Let's match the report to the code from models/t5/modeling_t5.py: +thon +class T5DenseGatedGeluDense(nn.Module): + def init(self, config): + super().init() + self.wi_0 = nn.Linear(config.d_model, config.d_ff, bias=False) + self.wi_1 = nn.Linear(config.d_model, config.d_ff, bias=False) + self.wo = nn.Linear(config.d_ff, config.d_model, bias=False) + self.dropout = nn.Dropout(config.dropout_rate) + self.gelu_act = ACT2FN["gelu_new"] +def forward(self, hidden_states): + hidden_gelu = self.gelu_act(self.wi_0(hidden_states)) + hidden_linear = self.wi_1(hidden_states) + hidden_states = hidden_gelu * hidden_linear + hidden_states = self.dropout(hidden_states) + hidden_states = self.wo(hidden_states) + return hidden_states \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_11.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_11.txt new file mode 100644 index 0000000000000000000000000000000000000000..b065819884f262beffb42ddcee47ed11c62364ee --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_11.txt @@ -0,0 +1,22 @@ +Now it's easy to see the dropout call, and all the previous calls as well. +Since the detection is happening in a forward hook, these reports are printed immediately after each forward +returns. +Going back to the full report, to act on it and to fix the problem, we need to go a few frames up where the numbers +started to go up and most likely switch to the fp32 mode here, so that the numbers don't overflow when multiplied +or summed up. Of course, there might be other solutions. For example, we could turn off amp temporarily if it's +enabled, after moving the original forward into a helper wrapper, like so: +thon +def _forward(self, hidden_states): + hidden_gelu = self.gelu_act(self.wi_0(hidden_states)) + hidden_linear = self.wi_1(hidden_states) + hidden_states = hidden_gelu * hidden_linear + hidden_states = self.dropout(hidden_states) + hidden_states = self.wo(hidden_states) + return hidden_states +import torch +def forward(self, hidden_states): + if torch.is_autocast_enabled(): + with torch.cuda.amp.autocast(enabled=False): + return self._forward(hidden_states) + else: + return self._forward(hidden_states) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_12.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_12.txt new file mode 100644 index 0000000000000000000000000000000000000000..7b8dc3bcd6ddff9642fc72948f76b71e327e001f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_12.txt @@ -0,0 +1,13 @@ +Since the automatic detector only reports on inputs and outputs of full frames, once you know where to look, you may +want to analyse the intermediary stages of any specific forward function as well. In such a case you can use the +detect_overflow helper function to inject the detector where you want it, for example: +thon +from debug_utils import detect_overflow +class T5LayerFF(nn.Module): + [] +def forward(self, hidden_states): + forwarded_states = self.layer_norm(hidden_states) + detect_overflow(forwarded_states, "after layer_norm") + forwarded_states = self.DenseReluDense(forwarded_states) + detect_overflow(forwarded_states, "after DenseReluDense") + return hidden_states + self.dropout(forwarded_states) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_13.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_13.txt new file mode 100644 index 0000000000000000000000000000000000000000..97f45f626e83bdd87dda2ba7fe069a130b28229e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_13.txt @@ -0,0 +1,9 @@ +You can see that we added 2 of these and now we track if inf or nan for forwarded_states was detected +somewhere in between. +Actually, the detector already reports these because each of the calls in the example above is a nn.Module, but +let's say if you had some local direct calculations this is how you'd do that. +Additionally, if you're instantiating the debugger in your own code, you can adjust the number of frames printed from +its default, e.g.: +thon +from transformers.debug_utils import DebugUnderflowOverflow +debug_overflow = DebugUnderflowOverflow(model, max_frames_to_save=100) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_14.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_14.txt new file mode 100644 index 0000000000000000000000000000000000000000..ecc20cf7a560c8c6d0101f0138d85524e1418f5a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_14.txt @@ -0,0 +1,10 @@ +Specific batch absolute min and max value tracing +The same debugging class can be used for per-batch tracing with the underflow/overflow detection feature turned off. +Let's say you want to watch the absolute min and max values for all the ingredients of each forward call of a given +batch, and only do that for batches 1 and 3. Then you instantiate this class as: +python +debug_overflow = DebugUnderflowOverflow(model, trace_batch_nums=[1, 3]) +And now full batches 1 and 3 will be traced using the same format as the underflow/overflow detector does. +Batches are 0-indexed. +This is helpful if you know that the program starts misbehaving after a certain batch number, so you can fast-forward +right to that area. Here is a sample truncated output for such configuration: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_15.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_15.txt new file mode 100644 index 0000000000000000000000000000000000000000..d02d1b6b3da5ed68ac5032a621bd4b241b0d9eb7 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_15.txt @@ -0,0 +1,26 @@ +*** Starting batch number=1 *** +abs min abs max metadata + shared Embedding +1.01e-06 7.92e+02 weight +0.00e+00 2.47e+04 input[0] +5.36e-05 7.92e+02 output +[] + decoder.dropout Dropout +1.60e-07 2.27e+01 input[0] +0.00e+00 2.52e+01 output + decoder T5Stack + not a tensor output + lm_head Linear +1.01e-06 7.92e+02 weight +0.00e+00 1.11e+00 input[0] +6.06e-02 8.39e+01 output + T5ForConditionalGeneration + not a tensor output + *** Starting batch number=3 *** + +abs min abs max metadata + shared Embedding +1.01e-06 7.92e+02 weight +0.00e+00 2.78e+04 input[0] +5.36e-05 7.92e+02 output +[] \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_16.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_16.txt new file mode 100644 index 0000000000000000000000000000000000000000..2fb363e3fccdfe84e37dc31b1e4adea1fe82df76 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_16.txt @@ -0,0 +1,7 @@ +Here you will get a huge number of frames dumped - as many as there were forward calls in your model, so it may or may +not what you want, but sometimes it can be easier to use for debugging purposes than a normal debugger. For example, if +a problem starts happening at batch number 150. So you can dump traces for batches 149 and 150 and compare where +numbers started to diverge. +You can also specify the batch number after which to stop the training, with: +python +debug_overflow = DebugUnderflowOverflow(model, trace_batch_nums=[1, 3], abort_after_batch_num=3) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..8c0c9783223b135f7e1440e98353a581d5dd1a33 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_2.txt @@ -0,0 +1,12 @@ +/usr/local/cuda-10.2 +/usr/local/cuda-11.0 +Typically, package installers set the paths to whatever the last version was installed. If the package build fails because it can't find the right CUDA version (despite it being installed system-wide already), then you need to configure the PATH and LD_LIBRARY_PATH environment variables to point to the correct path. +Take a look at the contents of these environment variables first: + +echo $PATH +echo $LD_LIBRARY_PATH +PATH lists the locations of the executables and LD_LIBRARY_PATH lists where to look for shared libraries. Earlier entries are prioritized over later ones, and : is used to separate multiple entries. To tell the build program where to find the specific CUDA toolkit you want, insert the correct path to list first. This command prepends rather than overwrites the existing values. +```bash +adjust the version and full path if needed +export PATH=/usr/local/cuda-10.2/bin:$PATH +export LD_LIBRARY_PATH=/usr/local/cuda-10.2/lib64:$LD_LIBRARY_PATH \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..d6c94c93cc3af489bd0e40606d6e5990ff8af712 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_3.txt @@ -0,0 +1,8 @@ +In addition, you should also check the directories you assign actually exist. The lib64 sub-directory contains various CUDA .so objects (like libcudart.so) and while it is unlikely your system names them differently, you should check the actual names and change them accordingly. +Older CUDA versions +Sometimes, older CUDA versions may refuse to build with newer compilers. For example, if you have gcc-9 but CUDA wants gcc-7. Usually, installing the latest CUDA toolkit enables support for the newer compiler. +You could also install an older version of the compiler in addition to the one you're currently using (or it may already be installed but it's not used by default and the build system can't see it). To resolve this, you can create a symlink to give the build system visibility to the older compiler. +```bash +adapt the path to your system +sudo ln -s /usr/bin/gcc-7 /usr/local/cuda-10.2/bin/gcc +sudo ln -s /usr/bin/g++-7 /usr/local/cuda-10.2/bin/g++ \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..071b5c526f2cd453214940101ef3bbac461ffdbe --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_4.txt @@ -0,0 +1,13 @@ +Prebuild +If you're still having issues with installing DeepSpeed or if you're building DeepSpeed at run time, you can try to prebuild the DeepSpeed modules before installing them. To make a local build for DeepSpeed: + +git clone https://github.com/microsoft/DeepSpeed/ +cd DeepSpeed +rm -rf build +TORCH_CUDA_ARCH_LIST="8.6" DS_BUILD_CPU_ADAM=1 DS_BUILD_UTILS=1 pip install . \ +--global-option="build_ext" --global-option="-j8" --no-cache -v \ +--disable-pip-version-check 2>&1 | tee build.log + +To use NVMe offload, add the DS_BUILD_AIO=1 parameter to the build command and make sure you install the libaio-dev package system-wide. + +Next, you'll have to specify your GPU's architecture by editing the TORCH_CUDA_ARCH_LIST variable (find a complete list of NVIDIA GPUs and their corresponding architectures on this page). To check the PyTorch version that corresponds to your architecture, run the following command: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..a6b03367754a84456a63f6a31b54278cda890290 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_5.txt @@ -0,0 +1,11 @@ +python -c "import torch; print(torch.cuda.get_arch_list())" +Find the architecture for a GPU with the following command: + +CUDA_VISIBLE_DEVICES=0 python -c "import torch; print(torch.cuda.get_device_capability())" + +To find the architecture for GPU 0: + +CUDA_VISIBLE_DEVICES=0 python -c "import torch; \ +print(torch.cuda.get_device_properties(torch.device('cuda'))) +"_CudaDeviceProperties(name='GeForce RTX 3090', major=8, minor=6, total_memory=24268MB, multi_processor_count=82)" +This means your GPU architecture is 8.6. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..d52adf26c194a53ae5b3fa80b61cec83d122b9ce --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_6.txt @@ -0,0 +1,10 @@ +If you get 8, 6, then you can set TORCH_CUDA_ARCH_LIST="8.6". For multiple GPUs with different architectures, list them like TORCH_CUDA_ARCH_LIST="6.1;8.6". +It is also possible to not specify TORCH_CUDA_ARCH_LIST and the build program automatically queries the GPU architecture of the build. However, it may or may not match the actual GPU on the target machine which is why it is better to explicitly specify the correct architecture. +For training on multiple machines with the same setup, you'll need to make a binary wheel: + +git clone https://github.com/microsoft/DeepSpeed/ +cd DeepSpeed +rm -rf build +TORCH_CUDA_ARCH_LIST="8.6" DS_BUILD_CPU_ADAM=1 DS_BUILD_UTILS=1 \ +python setup.py build_ext -j8 bdist_wheel +This command generates a binary wheel that'll look something like dist/deepspeed-0.3.13+8cd046f-cp38-cp38-linux_x86_64.whl. Now you can install this wheel locally or on another machine. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..a698cc7517616d609e21959ebefec12a67c947e5 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_7.txt @@ -0,0 +1,12 @@ +pip install deepspeed-0.3.13+8cd046f-cp38-cp38-linux_x86_64.whl +Multi-GPU Network Issues Debug +When training or inferencing with DistributedDataParallel and multiple GPU, if you run into issue of inter-communication between processes and/or nodes, you can use the following script to diagnose network issues. + +wget https://raw.githubusercontent.com/huggingface/transformers/main/scripts/distributed/torch-distributed-gpu-test.py +For example to test how 2 GPUs interact do: + +python -m torch.distributed.run --nproc_per_node 2 --nnodes 1 torch-distributed-gpu-test.py +If both processes can talk to each and allocate GPU memory each will print an OK status. +For more GPUs or nodes adjust the arguments in the script. +You will find a lot more details inside the diagnostics script and even a recipe to how you could run it in a SLURM environment. +An additional level of debug is to add NCCL_DEBUG=INFO environment variable as follows: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..1c579e8a03734c9830be45507dda81a3b0db507c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_8.txt @@ -0,0 +1,14 @@ +NCCL_DEBUG=INFO python -m torch.distributed.run --nproc_per_node 2 --nnodes 1 torch-distributed-gpu-test.py +This will dump a lot of NCCL-related debug information, which you can then search online if you find that some problems are reported. Or if you're not sure how to interpret the output you can share the log file in an Issue. +Underflow and Overflow Detection + +This feature is currently available for PyTorch-only. + +For multi-GPU training it requires DDP (torch.distributed.launch). + +This feature can be used with any nn.Module-based model. + +If you start getting loss=NaN or the model inhibits some other abnormal behavior due to inf or nan in +activations or weights one needs to discover where the first underflow or overflow happens and what led to it. Luckily +you can accomplish that easily by activating a special module that will do the detection automatically. +If you're using [Trainer], you just need to add: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..4bc16572b26a282ebf23ebd79b4ca6bee8f671a7 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_debugging.txt_chunk_9.txt @@ -0,0 +1,7 @@ +--debug underflow_overflow +to the normal command line arguments, or pass debug="underflow_overflow" when creating the +[TrainingArguments] object. +If you're using your own training loop or another Trainer you can accomplish the same with: +thon +from transformers.debug_utils import DebugUnderflowOverflow +debug_overflow = DebugUnderflowOverflow(model) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..b99d61d5bda88d2048d0b488eb73910c702c65f4 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_0.txt @@ -0,0 +1,6 @@ +DeepSpeed +DeepSpeed is a PyTorch optimization library that makes distributed training memory-efficient and fast. At it's core is the Zero Redundancy Optimizer (ZeRO) which enables training large models at scale. ZeRO works in several stages: + +ZeRO-1, optimizer state partioning across GPUs +ZeRO-2, gradient partitioning across GPUs +ZeRO-3, parameteter partitioning across GPUs \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..81e63d20229e529c36021281ea1d099e58611f96 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_1.txt @@ -0,0 +1,4 @@ +In GPU-limited environments, ZeRO also enables offloading optimizer memory and computation from the GPU to the CPU to fit and train really large models on a single GPU. DeepSpeed is integrated with the Transformers [Trainer] class for all ZeRO stages and offloading. All you need to do is provide a config file or you can use a provided template. For inference, Transformers support ZeRO-3 and offloading since it allows loading huge models. +This guide will walk you through how to deploy DeepSpeed training, the features you can enable, how to setup the config files for different ZeRO stages, offloading, inference, and using DeepSpeed without the [Trainer]. +Installation +DeepSpeed is available to install from PyPI or Transformers (for more detailed installation options, take a look at the DeepSpeed installation details or the GitHub README). \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_10.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_10.txt new file mode 100644 index 0000000000000000000000000000000000000000..e8140ea405106280ff18c38281cd48c8a55ff758 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_10.txt @@ -0,0 +1,4 @@ +offload_optimizer should be enabled to reduce GPU memory usage. +overlap_comm when set to true trades off increased GPU memory usage to lower allreduce latency. This feature uses 4.5x the allgather_bucket_size and reduce_bucket_size values. In this example, they're set to 5e8 which means it requires 9GB of GPU memory. If your GPU memory is 8GB or less, you should reduce overlap_comm to lower the memory requirements and prevent an out-of-memory (OOM) error. +allgather_bucket_size and reduce_bucket_size trade off available GPU memory for communication speed. The smaller their values, the slower communication is and the more GPU memory is available. You can balance, for example, whether a bigger batch size is more important than a slightly slower training time. +round_robin_gradients is available in DeepSpeed 0.4.4 for CPU offloading. It parallelizes gradient copying to CPU memory among ranks by fine-grained gradient partitioning. Performance benefit grows with gradient accumulation steps (more copying between optimizer steps) or GPU count (increased parallelism). \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_11.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_11.txt new file mode 100644 index 0000000000000000000000000000000000000000..eb7e773ac0f193a4c3108227823082c97a898a4c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_11.txt @@ -0,0 +1,19 @@ +yml +{ + "zero_optimization": { + "stage": 2, + "offload_optimizer": { + "device": "cpu", + "pin_memory": true + }, + "allgather_partitions": true, + "allgather_bucket_size": 5e8, + "overlap_comm": true, + "reduce_scatter": true, + "reduce_bucket_size": 5e8, + "contiguous_gradients": true + "round_robin_gradients": true + } +} + +ZeRO-3 shards the optimizer, gradient, and parameters across GPUs. Unlike ZeRO-2, ZeRO-3 can also be used for inference, in addition to training, because it allows large models to be loaded on multiple GPUs. Some important parameters to configure include: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_12.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_12.txt new file mode 100644 index 0000000000000000000000000000000000000000..10964e649a7ad8f90dcbe4ef12f2199ee158b844 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_12.txt @@ -0,0 +1,5 @@ +device: "cpu" can help if you're running out of GPU memory and if you have free CPU memory available. This allows offloading model parameters to the CPU. +pin_memory: true can improve throughput, but less memory becomes available for other processes because the pinned memory is reserved for the specific process that requested it and it's typically accessed much faster than normal CPU memory. +stage3_max_live_parameters is the upper limit on how many full parameters you want to keep on the GPU at any given time. Reduce this value if you encounter an OOM error. +stage3_max_reuse_distance is a value for determining when a parameter is used again in the future, and it helps decide whether to throw the parameter away or to keep it. If the parameter is going to be reused (if the value is less than stage3_max_reuse_distance), then it is kept to reduce communication overhead. This is super helpful when activation checkpointing is enabled and you want to keep the parameter in the forward recompute until the backward pass. But reduce this value if you encounter an OOM error. +stage3_gather_16bit_weights_on_model_save consolidates fp16 weights when a model is saved. For large models and multiple GPUs, this is an expensive in terms of memory and speed. You should enable it if you're planning on resuming training. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_13.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_13.txt new file mode 100644 index 0000000000000000000000000000000000000000..d5be445330fefb065eb5bcb4b38dc00d2955dc7b --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_13.txt @@ -0,0 +1,4 @@ +sub_group_size controls which parameters are updated during the optimizer step. Parameters are grouped into buckets of sub_group_size and each bucket is updated one at a time. When used with NVMe offload, sub_group_size determines when model states are moved in and out of CPU memory from during the optimization step. This prevents running out of CPU memory for extremely large models. sub_group_size can be left to its default value if you aren't using NVMe offload, but you may want to change it if you: + +Run into an OOM error during the optimizer step. In this case, reduce sub_group_size to reduce memory usage of the temporary buffers. +The optimizer step is taking a really long time. In this case, increase sub_group_size to improve bandwidth utilization as a result of increased data buffers. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_14.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_14.txt new file mode 100644 index 0000000000000000000000000000000000000000..b07c315e70279a4db95d949a639f1505080f79aa --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_14.txt @@ -0,0 +1,26 @@ +reduce_bucket_size, stage3_prefetch_bucket_size, and stage3_param_persistence_threshold are dependent on a model's hidden size. It is recommended to set these values to auto and allow the [Trainer] to automatically assign the values. + +yml +{ + "zero_optimization": { + "stage": 3, + "offload_optimizer": { + "device": "cpu", + "pin_memory": true + }, + "offload_param": { + "device": "cpu", + "pin_memory": true + }, + "overlap_comm": true, + "contiguous_gradients": true, + "sub_group_size": 1e9, + "reduce_bucket_size": "auto", + "stage3_prefetch_bucket_size": "auto", + "stage3_param_persistence_threshold": "auto", + "stage3_max_live_parameters": 1e9, + "stage3_max_reuse_distance": 1e9, + "stage3_gather_16bit_weights_on_model_save": true + } +} +You can use the deepspeed.zero.Init context manager to initialize a model faster: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_15.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_15.txt new file mode 100644 index 0000000000000000000000000000000000000000..2a6197d640112bd8072ab429af13bcc50b71432d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_15.txt @@ -0,0 +1,12 @@ +from transformers import T5ForConditionalGeneration, T5Config +import deepspeed +with deepspeed.zero.Init(): + config = T5Config.from_pretrained("google-t5/t5-small") + model = T5ForConditionalGeneration(config) + +For pretrained models, the DeepSped config file needs to have is_deepspeed_zero3_enabled: true setup in [TrainingArguments] and it needs a ZeRO configuration enabled. The [TrainingArguments] object must be created before calling the model [~PreTrainedModel.from_pretrained]. + +from transformers import AutoModel, Trainer, TrainingArguments +training_args = TrainingArguments(, deepspeed=ds_config) +model = AutoModel.from_pretrained("google-t5/t5-small") +trainer = Trainer(model=model, args=training_args, ) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_16.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_16.txt new file mode 100644 index 0000000000000000000000000000000000000000..ded41bc8c4f56c83f2ad41328257c3b971b9b309 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_16.txt @@ -0,0 +1,5 @@ +You'll need ZeRO-3 if the fp16 weights don't fit on a single GPU. If you're able to load fp16 weights, then make sure you specify torch_dtype=torch.float16 in [~PreTrainedModel.from_pretrained]. +Another consideration for ZeRO-3 is if you have multiple GPUs, no single GPU has all the parameters unless it's the parameters for the currently executing layer. To access all parameters from all the layers at once, such as loading pretrained model weights in [~PreTrainedModel.from_pretrained], one layer is loaded at a time and immediately partitioned to all GPUs. This is because for very large models, it isn't possible to load the weights on one GPU and then distribute them across the other GPUs due to memory limitations. +If you encounter a model parameter weight that looks like the following, where tensor([1.]) or the parameter size is 1 instead of a larger multi-dimensional shape, this means the parameter is partitioned and this is a ZeRO-3 placeholder. +py +tensor([1.0], device="cuda:0", dtype=torch.float16, requires_grad=True) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_17.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_17.txt new file mode 100644 index 0000000000000000000000000000000000000000..907e2406624fbea4ee82747ff3026bbba1269723 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_17.txt @@ -0,0 +1 @@ +For more information about initializing large models with ZeRO-3 and accessing the parameters, take a look at the Constructing Massive Models and Gathering Parameters guides. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_18.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_18.txt new file mode 100644 index 0000000000000000000000000000000000000000..14df98911aafd2d0361c0e72dcd4e12506beeecb --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_18.txt @@ -0,0 +1,23 @@ +NVMe configuration +ZeRO-Infinity allows offloading model states to the CPU and/or NVMe to save even more memory. Smart partitioning and tiling algorithms allow each GPU to send and receive very small amounts of data during offloading such that a modern NVMe can fit an even larger total memory pool than is available to your training process. ZeRO-Infinity requires ZeRO-3. +Depending on the CPU and/or NVMe memory available, you can offload both the optimizer states and parameters, just one of them, or none. You should also make sure the nvme_path is pointing to an NVMe device, because while it still works with a normal hard drive or solid state drive, it'll be significantly slower. With a modern NVMe, you can expect peak transfer speeds of ~3.5GB/s for read and ~3GB/s for write operations. Lastly, run a benchmark on your training setup to determine the optimal aio configuration. +The example ZeRO-3/Infinity configuration file below sets most of the parameter values to auto, but you could also manually add these values. +```yml +{ + "fp16": { + "enabled": "auto", + "loss_scale": 0, + "loss_scale_window": 1000, + "initial_scale_power": 16, + "hysteresis": 2, + "min_loss_scale": 1 + }, +"optimizer": { + "type": "AdamW", + "params": { + "lr": "auto", + "betas": "auto", + "eps": "auto", + "weight_decay": "auto" + } +}, \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_19.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_19.txt new file mode 100644 index 0000000000000000000000000000000000000000..1e252c6a7204ad698b4011aa91a1036de6845425 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_19.txt @@ -0,0 +1,8 @@ +"scheduler": { + "type": "WarmupLR", + "params": { + "warmup_min_lr": "auto", + "warmup_max_lr": "auto", + "warmup_num_steps": "auto" + } +}, \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..7249dc71dc43837d84cfc4b7f135f67e140a7984 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_2.txt @@ -0,0 +1,8 @@ +If you're having difficulties installing DeepSpeed, check the DeepSpeed CUDA installation guide. While DeepSpeed has a pip installable PyPI package, it is highly recommended to install it from source to best match your hardware and to support certain features, like 1-bit Adam, which aren’t available in the PyPI distribution. + +pip install deepspeed + +pip install transformers[deepspeed] + +Memory requirements +Before you begin, it is a good idea to check whether you have enough GPU and CPU memory to fit your model. DeepSpeed provides a tool for estimating the required CPU/GPU memory. For example, to estimate the memory requirements for the bigscience/T0_3B model on a single GPU: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_20.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_20.txt new file mode 100644 index 0000000000000000000000000000000000000000..b21cddc20c0cd5b19156630b5599703300dd1112 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_20.txt @@ -0,0 +1,34 @@ +"zero_optimization": { + "stage": 3, + "offload_optimizer": { + "device": "nvme", + "nvme_path": "/local_nvme", + "pin_memory": true, + "buffer_count": 4, + "fast_init": false + }, + "offload_param": { + "device": "nvme", + "nvme_path": "/local_nvme", + "pin_memory": true, + "buffer_count": 5, + "buffer_size": 1e8, + "max_in_cpu": 1e9 + }, + "aio": { + "block_size": 262144, + "queue_depth": 32, + "thread_count": 1, + "single_submit": false, + "overlap_events": true + }, + "overlap_comm": true, + "contiguous_gradients": true, + "sub_group_size": 1e9, + "reduce_bucket_size": "auto", + "stage3_prefetch_bucket_size": "auto", + "stage3_param_persistence_threshold": "auto", + "stage3_max_live_parameters": 1e9, + "stage3_max_reuse_distance": 1e9, + "stage3_gather_16bit_weights_on_model_save": true +}, \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_21.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_21.txt new file mode 100644 index 0000000000000000000000000000000000000000..f4ced0a273d4839cbdf4c9401fccdf363a6f10e8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_21.txt @@ -0,0 +1,13 @@ +"gradient_accumulation_steps": "auto", +"gradient_clipping": "auto", +"steps_per_print": 2000, +"train_batch_size": "auto", +"train_micro_batch_size_per_gpu": "auto", +"wall_clock_breakdown": false + +} + +DeepSpeed features +There are a number of important parameters to specify in the DeepSpeed configuration file which are briefly described in this section. +Activation/gradient checkpointing +Activation and gradient checkpointing trades speed for more GPU memory which allows you to overcome scenarios where your GPU is out of memory or to increase your batch size for better performance. To enable this feature: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_22.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_22.txt new file mode 100644 index 0000000000000000000000000000000000000000..b75abcd658cf5f74f0d0ad7afeeb90d9e61f6421 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_22.txt @@ -0,0 +1,5 @@ +For a Hugging Face model, set model.gradient_checkpointing_enable() or --gradient_checkpointing in the [Trainer]. +For a non-Hugging Face model, use the DeepSpeed Activation Checkpointing API. You could also replace the Transformers modeling code and replace torch.utils.checkpoint with the DeepSpeed API. This approach is more flexible because you can offload the forward activations to the CPU memory instead of recalculating them. + +Optimizer and scheduler +DeepSpeed and Transformers optimizer and scheduler can be mixed and matched as long as you don't enable offload_optimizer. When offload_optimizer is enabled, you could use a non-DeepSpeed optimizer (except for LAMB) as long as it has both a CPU and GPU implementation. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_23.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_23.txt new file mode 100644 index 0000000000000000000000000000000000000000..fcd51e610ecea2c387577a26b94763b57cef1848 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_23.txt @@ -0,0 +1 @@ +The optimizer and scheduler parameters for the config file can be set from the command line to avoid hard to find errors. For example, if the learning rate is set to a different value in another place you can override it from the command line. Aside from the optimizer and scheduler parameters, you'll need to ensure your [Trainer] command line arguments match the DeepSpeed configuration. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_24.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_24.txt new file mode 100644 index 0000000000000000000000000000000000000000..111f18e7d227eaa9645d6bb5782ad89ffb34cc84 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_24.txt @@ -0,0 +1,24 @@ +DeepSpeed offers several optimizers (Adam, AdamW, OneBitAdam, and LAMB) but you can also import other optimizers from PyTorch. If you don't configure the optimizer in the config, the [Trainer] automatically selects AdamW and either uses the supplied values or the default values for the following parameters from the command line: lr, adam_beta1, adam_beta2, adam_epsilon, weight_decay. +You can set the parameters to "auto" or manually input your own desired values. +yaml +{ + "optimizer": { + "type": "AdamW", + "params": { + "lr": "auto", + "betas": "auto", + "eps": "auto", + "weight_decay": "auto" + } + } +} +You can also use an unsupported optimizer by adding the following to the top level configuration. +yaml +{ + "zero_allow_untested_optimizer": true +} +From DeepSpeed==0.8.3 on, if you want to use offload, you'll also need to the following to the top level configuration because offload works best with DeepSpeed's CPU Adam optimizer. +yaml +{ + "zero_force_ds_cpu_optimizer": false +} \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_25.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_25.txt new file mode 100644 index 0000000000000000000000000000000000000000..4b923d67c9e4e29a8ffeb6cb96c10e2bfb7ab585 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_25.txt @@ -0,0 +1,5 @@ +DeepSpeed supports the LRRangeTest, OneCycle, WarmupLR and WarmupDecayLR learning rate schedulers. +Transformers and DeepSpeed provide two of the same schedulers: + +WarmupLR is the same as --lr_scheduler_type constant_with_warmup in Transformers +WarmupDecayLR is the same as --lr_scheduler_type linear in Transformers (this is the default scheduler used in Transformers) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_26.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_26.txt new file mode 100644 index 0000000000000000000000000000000000000000..6b4ef1d873e9cc668e9684021ea65af4fb773ecc --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_26.txt @@ -0,0 +1,17 @@ +If you don't configure the scheduler in the config, the [Trainer] automatically selects WarmupDecayLR and either uses the supplied values or the default values for the following parameters from the command line: warmup_min_lr, warmup_max_lr, warmup_num_steps, total_num_steps (automatically calculated during run time if max_steps is not provided). +You can set the parameters to "auto" or manually input your own desired values. +yaml +{ + "scheduler": { + "type": "WarmupDecayLR", + "params": { + "total_num_steps": "auto", + "warmup_min_lr": "auto", + "warmup_max_lr": "auto", + "warmup_num_steps": "auto" + } + } +} + +Precision +Deepspeed supports fp32, fp16, and bf16 mixed precision. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_27.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_27.txt new file mode 100644 index 0000000000000000000000000000000000000000..d62f59d8d0fbe5b7aad0f3ecd926371459f6e079 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_27.txt @@ -0,0 +1,11 @@ +Precision +Deepspeed supports fp32, fp16, and bf16 mixed precision. + +If your model doesn't work well with mixed precision, for example if it wasn't pretrained in mixed precision, you may encounter overflow or underflow issues which can cause NaN loss. For these cases, you should use full fp32 precision by explicitly disabling the default fp16 mode. +yaml +{ + "fp16": { + "enabled": false + } +} +For Ampere GPUs and PyTorch > 1.7, it automatically switches to the more efficient tf32 format for some operations but the results are still in fp32. You can control it from the [Trainer] by setting --tf32 to enable it, and --tf32 0 or --no_tf32 to disable it. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_28.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_28.txt new file mode 100644 index 0000000000000000000000000000000000000000..6a85908e13de0df889f83374a4e271656805b00c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_28.txt @@ -0,0 +1,21 @@ +To configure PyTorch AMP-like fp16 mixed precision reduces memory usage and accelerates training speed. [Trainer] automatically enables or disables fp16 based on the value of args.fp16_backend, and the rest of the config can be set by you. fp16 is enabled from the command line when the following arguments are passed: --fp16, --fp16_backend amp or --fp16_full_eval. +yaml +{ + "fp16": { + "enabled": "auto", + "loss_scale": 0, + "loss_scale_window": 1000, + "initial_scale_power": 16, + "hysteresis": 2, + "min_loss_scale": 1 + } +} +For additional DeepSpeed fp16 training options, take a look at the FP16 Training Options reference. +To configure Apex-like fp16 mixed precision, setup the config as shown below with "auto" or your own values. [Trainer] automatically configure amp based on the values of args.fp16_backend and args.fp16_opt_level. It can also be enabled from the command line when the following arguments are passed: --fp16, --fp16_backend apex or --fp16_opt_level 01. +yaml +{ + "amp": { + "enabled": "auto", + "opt_level": "auto" + } +} \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_29.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_29.txt new file mode 100644 index 0000000000000000000000000000000000000000..4335a03f290a98ba3163201edae32ed0fe28a2ac --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_29.txt @@ -0,0 +1,8 @@ +To use bf16, you'll need at least DeepSpeed==0.6.0. bf16 has the same dynamic range as fp32 and doesn’t require loss scaling. However, if you use gradient accumulation with bf16, gradients are accumulated in bf16 which may not be desired because this format's low precision can lead to lossy accumulation. +bf16 can be setup in the config file or enabled from the command line when the following arguments are passed: --bf16 or --bf16_full_eval. +yaml +{ + "bf16": { + "enabled": "auto" + } +} \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..5c5d79baad8e9a16d8a101951bc5c3aa577b8810 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_3.txt @@ -0,0 +1,28 @@ +$ python -c 'from transformers import AutoModel; \ +from deepspeed.runtime.zero.stage3 import estimate_zero3_model_states_mem_needs_all_live; \ +model = AutoModel.from_pretrained("bigscience/T0_3B"); \ +estimate_zero3_model_states_mem_needs_all_live(model, num_gpus_per_node=1, num_nodes=1)' +[] +Estimated memory needed for params, optim states and gradients for a: +HW: Setup with 1 node, 1 GPU per node. +SW: Model with 2783M total params, 65M largest layer params. + per CPU | per GPU | Options + 70.00GB | 0.25GB | offload_param=cpu , offload_optimizer=cpu , zero_init=1 + 70.00GB | 0.25GB | offload_param=cpu , offload_optimizer=cpu , zero_init=0 + 62.23GB | 5.43GB | offload_param=none, offload_optimizer=cpu , zero_init=1 + 62.23GB | 5.43GB | offload_param=none, offload_optimizer=cpu , zero_init=0 + 0.37GB | 46.91GB | offload_param=none, offload_optimizer=none, zero_init=1 + 15.56GB | 46.91GB | offload_param=none, offload_optimizer=none, zero_init=0 +This means you either need a single 80GB GPU without CPU offload or a 8GB GPU and a ~60GB CPU to offload to (these are just the memory requirements for the parameters, optimizer states and gradients, and you'll need a bit more for the CUDA kernels and activations). You should also consider the tradeoff between cost and speed because it'll be cheaper to rent or buy a smaller GPU but it'll take longer to train your model. +If you have enough GPU memory make sure you disable CPU/NVMe offload to make everything faster. +Select a ZeRO stage +After you've installed DeepSpeed and have a better idea of your memory requirements, the next step is selecting a ZeRO stage to use. In order of fastest and most memory-efficient: +| Fastest | Memory efficient | +|------------------|------------------| +| ZeRO-1 | ZeRO-3 + offload | +| ZeRO-2 | ZeRO-3 | +| ZeRO-2 + offload | ZeRO-2 + offload | +| ZeRO-3 | ZeRO-2 | +| ZeRO-3 + offload | ZeRO-1 | +To find what works best for you, start with the fastest approach and if you run out of memory, try the next stage which is slower but more memory efficient. Feel free to work in whichever direction you prefer (starting with the most memory efficient or fastest) to discover the appropriate balance between speed and memory usage. +A general process you can use is (start with batch size of 1): \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_30.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_30.txt new file mode 100644 index 0000000000000000000000000000000000000000..9d91bb98cc1715b40d73627691d5e8d401a60898 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_30.txt @@ -0,0 +1,13 @@ +Batch size +The batch size can be auto-configured or explicitly set. If you choose to use the "auto" option, [Trainer] sets train_micro_batch_size_per_gpu to the value of args.per_device_train_batch_size and train_batch_size to args.world_size * args.per_device_train_batch_size * args.gradient_accumulation_steps. +yaml +{ + "train_micro_batch_size_per_gpu": "auto", + "train_batch_size": "auto" +} +Gradient accumulation +Gradient accumulation can be auto-configured or explicitly set. If you choose to use the "auto" option, [Trainer] sets it to the value of args.gradient_accumulation_steps. +```yaml +{ + "gradient_accumulation_steps": "auto" +} \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_31.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_31.txt new file mode 100644 index 0000000000000000000000000000000000000000..adf10ebd26349305b0ad376aecb2599ba40b3f24 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_31.txt @@ -0,0 +1,18 @@ +Gradient clipping +Gradient clipping can be auto-configured or explicitly set. If you choose to use the "auto" option, [Trainer] sets it to the value of args.max_grad_norm. +yaml +{ + "gradient_clipping": "auto" +} +Communication data type +For communication collectives like reduction, gathering and scattering operations, a separate data type is used. +All gather and scatter operations are performed in the same data type the data is in. For example, if you're training with bf16, the data is also gathered in bf16 because gathering is a non-lossy operation. +Reduce operations are lossy, for example when gradients are averaged across multiple GPUs. When the communication is done in fp16 or bf16, it is more likely to be lossy because adding multiple numbers in low precision isn't exact. This is especially the case with bf16 which has a lower precision than fp16. For this reason, fp16 is the default for reduction operations because the loss is minimal when averaging gradients. +You can choose the communication data type by setting the communication_data_type parameter in the config file. For example, choosing fp32 adds a small amount of overhead but ensures the reduction operation is accumulated in fp32 and when it is ready, it is downcasted to whichever half-precision dtype you're training in. +yaml +{ + "communication_data_type": "fp32" +} +Deployment +DeepSpeed can be deployed by different launchers such as torchrun, the deepspeed launcher, or Accelerate. To deploy, add --deepspeed ds_config.json to the [Trainer] command line. It’s recommended to use DeepSpeed’s add_config_arguments utility to add any necessary command line arguments to your code. +This guide will show you how to deploy DeepSpeed with the deepspeed launcher for different training setups. You can check out this post for more practical usage examples. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_32.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_32.txt new file mode 100644 index 0000000000000000000000000000000000000000..b7d704b38373a3fd57308cc385813ea1121b4ee8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_32.txt @@ -0,0 +1,11 @@ +To deploy DeepSpeed on multiple GPUs, add the --num_gpus parameter. If you want to use all available GPUs, you don't need to add --num_gpus. The example below uses 2 GPUs. + +deepspeed --num_gpus=2 examples/pytorch/translation/run_translation.py \ +--deepspeed tests/deepspeed/ds_config_zero3.json \ +--model_name_or_path google-t5/t5-small --per_device_train_batch_size 1 \ +--output_dir output_dir --overwrite_output_dir --fp16 \ +--do_train --max_train_samples 500 --num_train_epochs 1 \ +--dataset_name wmt16 --dataset_config "ro-en" \ +--source_lang en --target_lang ro + +To deploy DeepSpeed on a single GPU, add the --num_gpus parameter. It isn't necessary to explicitly set this value if you only have 1 GPU because DeepSpeed deploys all GPUs it can see on a given node. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_33.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_33.txt new file mode 100644 index 0000000000000000000000000000000000000000..e4dd0e98757ccc314da0aebd7302e48d17c658d4 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_33.txt @@ -0,0 +1,13 @@ +deepspeed --num_gpus=1 examples/pytorch/translation/run_translation.py \ +--deepspeed tests/deepspeed/ds_config_zero2.json \ +--model_name_or_path google-t5/t5-small --per_device_train_batch_size 1 \ +--output_dir output_dir --overwrite_output_dir --fp16 \ +--do_train --max_train_samples 500 --num_train_epochs 1 \ +--dataset_name wmt16 --dataset_config "ro-en" \ +--source_lang en --target_lang ro +DeepSpeed is still useful with just 1 GPU because you can: + +Offload some computations and memory to the CPU to make more GPU resources available to your model to use a larger batch size or fit a very large model that normally won't fit. +Minimize memory fragmentation with it's smart GPU memory management system which also allows you to fit bigger models and data batches. + +Set the allgather_bucket_size and reduce_bucket_size values to 2e8 in the ZeRO-2 configuration file to get better performance on a single GPU. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_34.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_34.txt new file mode 100644 index 0000000000000000000000000000000000000000..6c34c5d588939e68ab3e261a3dca8f38c037d2ba --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_34.txt @@ -0,0 +1,10 @@ +Multi-node deployment +A node is one or more GPUs for running a workload. A more powerful setup is a multi-node setup which can be launched with the deepspeed launcher. For this guide, let's assume there are two nodes with 8 GPUs each. The first node can be accessed ssh hostname1 and the second node with ssh hostname2. Both nodes must be able to communicate with each other locally over ssh without a password. +By default, DeepSpeed expects your multi-node environment to use a shared storage. If this is not the case and each node can only see the local filesystem, you need to adjust the config file to include a checkpoint to allow loading without access to a shared filesystem: +yaml +{ + "checkpoint": { + "use_node_local_storage": true + } +} +You could also use the [Trainer]'s --save_on_each_node argument to automatically add the above checkpoint to your config. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_35.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_35.txt new file mode 100644 index 0000000000000000000000000000000000000000..8c9fd5ba1862f2208dbf440d9a46af158b91966d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_35.txt @@ -0,0 +1,14 @@ +For torchrun, you have to ssh to each node and run the following command on both of them. The launcher waits until both nodes are synchronized before launching the training. + +torchrun --nproc_per_node=8 --nnode=2 --node_rank=0 --master_addr=hostname1 \ +--master_port=9901 your_program.py --deepspeed ds_config.json + +For the deepspeed launcher, start by creating a hostfile. + +hostname1 slots=8 +hostname2 slots=8 +Then you can launch the training with the following command. The deepspeed launcher automatically launches the command on both nodes at once. + +deepspeed --num_gpus 8 --num_nodes 2 --hostfile hostfile --master_addr hostname1 --master_port=9901 \ +your_program.py --deepspeed ds_config.json +Check out the Resource Configuration (multi-node) guide for more details about configuring multi-node compute resources. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_36.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_36.txt new file mode 100644 index 0000000000000000000000000000000000000000..8c84b48d98518a7745a77f826ed1756bfa5a3112 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_36.txt @@ -0,0 +1,17 @@ +SLURM +In a SLURM environment, you'll need to adapt your SLURM script to your specific SLURM environment. An example SLURM script may look like: +```bash +SBATCH --job-name=test-nodes # name +SBATCH --nodes=2 # nodes +SBATCH --ntasks-per-node=1 # crucial - only 1 task per dist per node! +SBATCH --cpus-per-task=10 # number of cores per tasks +SBATCH --gres=gpu:8 # number of gpus +SBATCH --time 20:00:00 # maximum execution time (HH:MM:SS) +SBATCH --output=%x-%j.out # output file name +export GPUS_PER_NODE=8 +export MASTER_ADDR=$(scontrol show hostnames $SLURM_JOB_NODELIST | head -n 1) +export MASTER_PORT=9901 +srun --jobid $SLURM_JOBID bash -c 'python -m torch.distributed.run \ + --nproc_per_node $GPUS_PER_NODE --nnodes $SLURM_NNODES --node_rank $SLURM_PROCID \ + --master_addr $MASTER_ADDR --master_port $MASTER_PORT \ +your_program.py --deepspeed ds_config.json' \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_37.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_37.txt new file mode 100644 index 0000000000000000000000000000000000000000..5c2acbdac1e5e98cd57f8409fc990c27bc94a0f9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_37.txt @@ -0,0 +1,5 @@ +Then you can schedule your multi-node deployment with the following command which launches training simultaneously on all nodes. + +sbatch launch.slurm +Notebook +The deepspeed launcher doesn't support deployment from a notebook so you'll need to emulate the distributed environment. However, this only works for 1 GPU. If you want to use more than 1 GPU, you must use a multi-process environment for DeepSpeed to work. This means you have to use the deepspeed launcher which can't be emulated as shown here. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_38.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_38.txt new file mode 100644 index 0000000000000000000000000000000000000000..d290f8bac1da361b4143e0da660c2460f67d10c3 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_38.txt @@ -0,0 +1,14 @@ +DeepSpeed requires a distributed environment even when only one process is used. +This emulates a launcher in the notebook +import os +os.environ["MASTER_ADDR"] = "localhost" +os.environ["MASTER_PORT"] = "9994" # modify if RuntimeError: Address already in use +os.environ["RANK"] = "0" +os.environ["LOCAL_RANK"] = "0" +os.environ["WORLD_SIZE"] = "1" +Now proceed as normal, plus pass the DeepSpeed config file +training_args = TrainingArguments(, deepspeed="ds_config_zero3.json") +trainer = Trainer() +trainer.train() + +If you want to create the config file on the fly in the notebook in the current directory, you could have a dedicated cell. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_39.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_39.txt new file mode 100644 index 0000000000000000000000000000000000000000..8533943a7f0cc78a57a8f76f6bda80ba68af4211 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_39.txt @@ -0,0 +1,29 @@ +%%bash +cat <<'EOT' > ds_config_zero3.json +{ + "fp16": { + "enabled": "auto", + "loss_scale": 0, + "loss_scale_window": 1000, + "initial_scale_power": 16, + "hysteresis": 2, + "min_loss_scale": 1 + }, +"optimizer": { + "type": "AdamW", + "params": { + "lr": "auto", + "betas": "auto", + "eps": "auto", + "weight_decay": "auto" + } +}, + +"scheduler": { + "type": "WarmupLR", + "params": { + "warmup_min_lr": "auto", + "warmup_max_lr": "auto", + "warmup_num_steps": "auto" + } +}, \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..a2752aae17d94f6d86f35b9b32570e86626b36e4 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_4.txt @@ -0,0 +1,11 @@ +enable gradient checkpointing +try ZeRO-2 +try ZeRO-2 and offload the optimizer +try ZeRO-3 +try ZeRO-3 and offload parameters to the CPU +try ZeRO-3 and offload parameters and the optimizer to the CPU +try lowering various default values like a narrower search beam if you're using the [~GenerationMixin.generate] method +try mixed half-precision (fp16 on older GPU architectures and bf16 on Ampere) over full-precision weights +add more hardware if possible or enable Infinity to offload parameters and the optimizer to a NVMe +once you're not running out of memory, measure effective throughput and then try to increase the batch size as large as you can to maximize GPU efficiency +lastly, try to optimize your training setup by disabling some offload features or use a faster ZeRO stage and increasing/decreasing the batch size to find the best tradeoff between speed and memory usage \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_40.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_40.txt new file mode 100644 index 0000000000000000000000000000000000000000..510371947c38a47a7c0e4bb71c13b2e5d68bf758 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_40.txt @@ -0,0 +1,30 @@ +"zero_optimization": { + "stage": 3, + "offload_optimizer": { + "device": "cpu", + "pin_memory": true + }, + "offload_param": { + "device": "cpu", + "pin_memory": true + }, + "overlap_comm": true, + "contiguous_gradients": true, + "sub_group_size": 1e9, + "reduce_bucket_size": "auto", + "stage3_prefetch_bucket_size": "auto", + "stage3_param_persistence_threshold": "auto", + "stage3_max_live_parameters": 1e9, + "stage3_max_reuse_distance": 1e9, + "stage3_gather_16bit_weights_on_model_save": true +}, + +"gradient_accumulation_steps": "auto", +"gradient_clipping": "auto", +"steps_per_print": 2000, +"train_batch_size": "auto", +"train_micro_batch_size_per_gpu": "auto", +"wall_clock_breakdown": false + +} +EOT \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_41.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_41.txt new file mode 100644 index 0000000000000000000000000000000000000000..e10b1c014e44545dc242477a769a228cc35c9fbd --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_41.txt @@ -0,0 +1,16 @@ +} +EOT + +If the training script is in a file and not in a notebook cell, you can launch deepspeed normally from the shell in a notebook cell. For example, to launch run_translation.py: +py +!git clone https://github.com/huggingface/transformers +!cd transformers; deepspeed examples/pytorch/translation/run_translation.py +You could also use %%bash magic and write multi-line code to run the shell program, but you won't be able to view the logs until training is complete. With %%bash magic, you don't need to emulate a distributed environment. + +%%bash +git clone https://github.com/huggingface/transformers +cd transformers +deepspeed examples/pytorch/translation/run_translation.py + +Save model weights +DeepSpeed stores the main full precision fp32 weights in custom checkpoint optimizer files (the glob pattern looks like global_step*/*optim_states.pt) and are saved under the normal checkpoint. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_42.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_42.txt new file mode 100644 index 0000000000000000000000000000000000000000..1e1e074639f73b1d9eef2db2e8c5a9063b07139f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_42.txt @@ -0,0 +1,7 @@ +A model trained with ZeRO-2 saves the pytorch_model.bin weights in fp16. To save the model weights in fp16 for a model trained with ZeRO-3, you need to set "stage3_gather_16bit_weights_on_model_save": true because the model weights are partitioned across multiple GPUs. Otherwise, the [Trainer] won't save the weights in fp16 and it won't create a pytorch_model.bin file. This is because DeepSpeed's state_dict contains a placeholder instead of the real weights and you won't be able to load them. +yaml +{ + "zero_optimization": { + "stage3_gather_16bit_weights_on_model_save": true + } +} \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_43.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_43.txt new file mode 100644 index 0000000000000000000000000000000000000000..fb1617f21f7fbe869cdb1eab6f7ebe86635e86be --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_43.txt @@ -0,0 +1,10 @@ +The full precision weights shouldn't be saved during training because it can require a lot of memory. It is usually best to save the fp32 weights offline after training is complete. But if you have a lot of free CPU memory, it is possible to save the fp32 weights during training. This section covers both online and offline approaches. +Online +You must have saved at least one checkpoint to load the latest checkpoint as shown in the following: + +from transformers.trainer_utils import get_last_checkpoint +from deepspeed.utils.zero_to_fp32 import load_state_dict_from_zero_checkpoint +checkpoint_dir = get_last_checkpoint(trainer.args.output_dir) +fp32_model = load_state_dict_from_zero_checkpoint(trainer.model, checkpoint_dir) + +If you've enabled the --load_best_model_at_end parameter to track the best checkpoint in [TrainingArguments], you can finish training first and save the final model explicitly. Then you can reload it as shown below: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_44.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_44.txt new file mode 100644 index 0000000000000000000000000000000000000000..dae501b1ff5d1787a5073c67b8f0b747c3fbf5de --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_44.txt @@ -0,0 +1,13 @@ +from deepspeed.utils.zero_to_fp32 import load_state_dict_from_zero_checkpoint +checkpoint_dir = os.path.join(trainer.args.output_dir, "checkpoint-final") +trainer.deepspeed.save_checkpoint(checkpoint_dir) +fp32_model = load_state_dict_from_zero_checkpoint(trainer.model, checkpoint_dir) + +Once load_state_dict_from_zero_checkpoint is run, the model is no longer usable in DeepSpeed in the context of the same application. You'll need to initialize the DeepSpeed engine again since model.load_state_dict(state_dict) removes all the DeepSpeed magic from it. Only use this at the very end of training. + +You can also extract and load the state_dict of the fp32 weights: + +from deepspeed.utils.zero_to_fp32 import get_fp32_state_dict_from_zero_checkpoint +state_dict = get_fp32_state_dict_from_zero_checkpoint(checkpoint_dir) # already on cpu +model = model.cpu() +model.load_state_dict(state_dict) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_45.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_45.txt new file mode 100644 index 0000000000000000000000000000000000000000..80bfeb66c02dec1a2e035e1b7e290431a47c59ed --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_45.txt @@ -0,0 +1,3 @@ +Offline +DeepSpeed provides a zero_to_fp32.py script at the top-level of the checkpoint folder for extracting weights at any point. This is a standalone script and you don't need a configuration file or [Trainer]. +For example, if your checkpoint folder looked like this: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_46.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_46.txt new file mode 100644 index 0000000000000000000000000000000000000000..2c7f521a423b7623d5079e9250273b7b1e41607b --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_46.txt @@ -0,0 +1,16 @@ +$ ls -l output_dir/checkpoint-1/ +-rw-rw-r-- 1 stas stas 1.4K Mar 27 20:42 config.json +drwxrwxr-x 2 stas stas 4.0K Mar 25 19:52 global_step1/ +-rw-rw-r-- 1 stas stas 12 Mar 27 13:16 latest +-rw-rw-r-- 1 stas stas 827K Mar 27 20:42 optimizer.pt +-rw-rw-r-- 1 stas stas 231M Mar 27 20:42 pytorch_model.bin +-rw-rw-r-- 1 stas stas 623 Mar 27 20:42 scheduler.pt +-rw-rw-r-- 1 stas stas 1.8K Mar 27 20:42 special_tokens_map.json +-rw-rw-r-- 1 stas stas 774K Mar 27 20:42 spiece.model +-rw-rw-r-- 1 stas stas 1.9K Mar 27 20:42 tokenizer_config.json +-rw-rw-r-- 1 stas stas 339 Mar 27 20:42 trainer_state.json +-rw-rw-r-- 1 stas stas 2.3K Mar 27 20:42 training_args.bin +-rwxrw-r-- 1 stas stas 5.5K Mar 27 13:16 zero_to_fp32.py* +To reconstruct the fp32 weights from the DeepSpeed checkpoint (ZeRO-2 or ZeRO-3) subfolder global_step1, run the following command to create and consolidate the full fp32 weights from multiple GPUs into a single pytorch_model.bin file. The script automatically discovers the subfolder containing the checkpoint. +py +python zero_to_fp32.py . pytorch_model.bin \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_47.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_47.txt new file mode 100644 index 0000000000000000000000000000000000000000..b2bafc03e9eb25b16722fbc4ea7f80f1f3c57de9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_47.txt @@ -0,0 +1,6 @@ +Run python zero_to_fp32.py -h for more usage details. The script requires 2x the general RAM of the final fp32 weights. + +ZeRO Inference +ZeRO Inference places the model weights in CPU or NVMe memory to avoid burdening the GPU which makes it possible to run inference with huge models on a GPU. Inference doesn't require any large additional amounts of memory for the optimizer states and gradients so you can fit much larger batches and/or sequence lengths on the same hardware. +ZeRO Inference shares the same configuration file as ZeRO-3, and ZeRO-2 and ZeRO-1 configs won't work because they don't provide any benefits for inference. +To run ZeRO Inference, pass your usual training arguments to the [TrainingArguments] class and add the --do_eval argument. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_48.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_48.txt new file mode 100644 index 0000000000000000000000000000000000000000..b4d6fc793b5138e0da8c36bdc53426fbb366a404 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_48.txt @@ -0,0 +1,7 @@ +deepspeed --num_gpus=2 your_program.py --do_eval --deepspeed ds_config.json +Non-Trainer DeepSpeed integration +DeepSpeed also works with Transformers without the [Trainer] class. This is handled by the [HfDeepSpeedConfig] which only takes care of gathering ZeRO-3 parameters and splitting a model across multiple GPUs when you call [~PreTrainedModel.from_pretrained]. + +If you want everything automatically taken care of for you, try using DeepSpeed with the [Trainer]! You'll need to follow the DeepSpeed documentation, and manually configure the parameter values in the config file (you can't use the "auto" value). + +To efficiently deploy ZeRO-3, you must instantiate the [HfDeepSpeedConfig] object before the model and keep that object alive: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_49.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_49.txt new file mode 100644 index 0000000000000000000000000000000000000000..20835496b9fea23add6669aeb6da101f380a9cc7 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_49.txt @@ -0,0 +1,20 @@ +from transformers.integrations import HfDeepSpeedConfig +from transformers import AutoModel +import deepspeed +ds_config = {} # deepspeed config object or path to the file +must run before instantiating the model to detect zero 3 +dschf = HfDeepSpeedConfig(ds_config) # keep this object alive +model = AutoModel.from_pretrained("openai-community/gpt2") +engine = deepspeed.initialize(model=model, config_params=ds_config, ) + +[HfDeepSpeedConfig] is not required for ZeRO-1 or ZeRO-2. + +from transformers.integrations import HfDeepSpeedConfig +from transformers import AutoModel, AutoConfig +import deepspeed +ds_config = {} # deepspeed config object or path to the file +must run before instantiating the model to detect zero 3 +dschf = HfDeepSpeedConfig(ds_config) # keep this object alive +config = AutoConfig.from_pretrained("openai-community/gpt2") +model = AutoModel.from_config(config) +engine = deepspeed.initialize(model=model, config_params=ds_config, ) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..c3f823eb7922f33a8ec50e52773ccce87811a69a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_5.txt @@ -0,0 +1,10 @@ +DeepSpeed configuration file +DeepSpeed works with the [Trainer] class by way of a config file containing all the parameters for configuring how you want setup your training run. When you execute your training script, DeepSpeed logs the configuration it received from [Trainer] to the console so you can see exactly what configuration was used. + +Find a complete list of DeepSpeed configuration options on the DeepSpeed Configuration JSON reference. You can also find more practical examples of various DeepSpeed configuration examples on the DeepSpeedExamples repository or the main DeepSpeed repository. To quickly find specific examples, you can: +```bash +git clone https://github.com/microsoft/DeepSpeedExamples +cd DeepSpeedExamples +find . -name '*json' +find examples with the Lamb optimizer +grep -i Lamb $(find . -name '*json') \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_50.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_50.txt new file mode 100644 index 0000000000000000000000000000000000000000..301a58a370da4a400709d23f4e49db7b5f7ec4b9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_50.txt @@ -0,0 +1,12 @@ +Non-Trainer ZeRO Inference +To run ZeRO Inference without the [Trainer] in cases where you can’t fit a model onto a single GPU, try using additional GPUs or/and offloading to CPU memory. The important nuance to understand here is that the way ZeRO is designed, you can process different inputs on different GPUs in parallel. +Make sure to: + +disable CPU offload if you have enough GPU memory (since it slows things down). +enable bf16 if you have an Ampere or newer GPU to make things faster. If you don’t have one of these GPUs, you may enable fp16 as long as you don’t use a model pretrained in bf16 (T5 models) because it may lead to an overflow error. + +Take a look at the following script to get a better idea of how to run ZeRO Inference without the [Trainer] on a model that won't fit on a single GPU. + +!/usr/bin/env python +This script demonstrates how to use Deepspeed ZeRO in an inference mode when one can't fit a model +into a single GPU \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_51.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_51.txt new file mode 100644 index 0000000000000000000000000000000000000000..7fb4ee6a4a22d2858075b662c19aa51a9e77a3d7 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_51.txt @@ -0,0 +1,22 @@ +1. Use 1 GPU with CPU offload +2. Or use multiple GPUs instead + +First you need to install deepspeed: pip install deepspeed + +Here we use a 3B "bigscience/T0_3B" model which needs about 15GB GPU RAM - so 1 largish or 2 +small GPUs can handle it. or 1 small GPU and a lot of CPU memory. + +To use a larger model like "bigscience/T0" which needs about 50GB, unless you have an 80GB GPU - +you will need 2-4 gpus. And then you can adapt the script to handle more gpus if you want to +process multiple inputs at once. + +The provided deepspeed config also activates CPU memory offloading, so chances are that if you +have a lot of available CPU memory and you don't mind a slowdown you should be able to load a +model that doesn't normally fit into a single GPU. If you have enough GPU memory the program will +run faster if you don't want offload to CPU - so disable that section then. + +To deploy on 1 gpu: + +deepspeed --num_gpus 1 t0.py +or: +python -m torch.distributed.run --nproc_per_node=1 t0.py \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_52.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_52.txt new file mode 100644 index 0000000000000000000000000000000000000000..f4a70bd04bd0a1c3a32317742aea46b451317b44 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_52.txt @@ -0,0 +1,29 @@ +deepspeed --num_gpus 1 t0.py +or: +python -m torch.distributed.run --nproc_per_node=1 t0.py + +To deploy on 2 gpus: + +deepspeed --num_gpus 2 t0.py +or: +python -m torch.distributed.run --nproc_per_node=2 t0.py +from transformers import AutoTokenizer, AutoConfig, AutoModelForSeq2SeqLM +from transformers.integrations import HfDeepSpeedConfig +import deepspeed +import os +import torch +os.environ["TOKENIZERS_PARALLELISM"] = "false" # To avoid warnings about parallelism in tokenizers +distributed setup +local_rank = int(os.getenv("LOCAL_RANK", "0")) +world_size = int(os.getenv("WORLD_SIZE", "1")) +torch.cuda.set_device(local_rank) +deepspeed.init_distributed() +model_name = "bigscience/T0_3B" +config = AutoConfig.from_pretrained(model_name) +model_hidden_size = config.d_model +batch size has to be divisible by world_size, but can be bigger than world_size +train_batch_size = 1 * world_size +ds_config notes + +- enable bf16 if you use Ampere or higher GPU - this will run in mixed precision and will be +faster. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_53.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_53.txt new file mode 100644 index 0000000000000000000000000000000000000000..410463349fa9707c3871748db465387e40e1e43f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_53.txt @@ -0,0 +1,11 @@ +- enable bf16 if you use Ampere or higher GPU - this will run in mixed precision and will be +faster. + +- for older GPUs you can enable fp16, but it'll only work for non-bf16 pretrained models - e.g. +all official t5 models are bf16-pretrained + +- set offload_param.device to "none" or completely remove the offload_param section if you don't +- want CPU offload + +- if using offload_param you can manually finetune stage3_param_persistence_threshold to control +- which params should remain on gpus - the larger the value the smaller the offload size \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_54.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_54.txt new file mode 100644 index 0000000000000000000000000000000000000000..45c4dcc1f4126311052b72798ff94aaffe3fe7c0 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_54.txt @@ -0,0 +1,31 @@ +For in-depth info on Deepspeed config see +https://huggingface.co/docs/transformers/main/main_classes/deepspeed +keeping the same format as json for consistency, except it uses lower case for true/false +fmt: off +ds_config = { + "fp16": { + "enabled": False + }, + "bf16": { + "enabled": False + }, + "zero_optimization": { + "stage": 3, + "offload_param": { + "device": "cpu", + "pin_memory": True + }, + "overlap_comm": True, + "contiguous_gradients": True, + "reduce_bucket_size": model_hidden_size * model_hidden_size, + "stage3_prefetch_bucket_size": 0.9 * model_hidden_size * model_hidden_size, + "stage3_param_persistence_threshold": 10 * model_hidden_size + }, + "steps_per_print": 2000, + "train_batch_size": train_batch_size, + "train_micro_batch_size_per_gpu": 1, + "wall_clock_breakdown": False +} +fmt: on +next line instructs transformers to partition the model directly over multiple gpus using +deepspeed.zero.Init when model's from_pretrained method is called. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_55.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_55.txt new file mode 100644 index 0000000000000000000000000000000000000000..44220c70529453519bbcd6a3485fd582222700f3 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_55.txt @@ -0,0 +1 @@ +it has to be run before loading the model AutoModelForSeq2SeqLM.from_pretrained(model_name) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_56.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_56.txt new file mode 100644 index 0000000000000000000000000000000000000000..57c901ec5d4e85baa02a124a2e721ba24f60b38b --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_56.txt @@ -0,0 +1,23 @@ +otherwise the model will first be loaded normally and only partitioned at forward time which is +less efficient and when there is little CPU RAM may fail +dschf = HfDeepSpeedConfig(ds_config) # keep this object alive +now a model can be loaded. +model = AutoModelForSeq2SeqLM.from_pretrained(model_name) +initialise Deepspeed ZeRO and store only the engine object +ds_engine = deepspeed.initialize(model=model, config_params=ds_config)[0] +ds_engine.module.eval() # inference +Deepspeed ZeRO can process unrelated inputs on each GPU. So for 2 gpus you process 2 inputs at once. +If you use more GPUs adjust for more. +And of course if you have just one input to process you then need to pass the same string to both gpus +If you use only one GPU, then you will have only rank 0. +rank = torch.distributed.get_rank() +if rank == 0: + text_in = "Is this review positive or negative? Review: this is the best cast iron skillet you will ever buy" +elif rank == 1: + text_in = "Is this review positive or negative? Review: this is the worst restaurant ever" +tokenizer = AutoTokenizer.from_pretrained(model_name) +inputs = tokenizer.encode(text_in, return_tensors="pt").to(device=local_rank) +with torch.no_grad(): + outputs = ds_engine.module.generate(inputs, synced_gpus=True) +text_out = tokenizer.decode(outputs[0], skip_special_tokens=True) +print(f"rank{rank}:\n in={text_in}\n out={text_out}") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_57.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_57.txt new file mode 100644 index 0000000000000000000000000000000000000000..be1b5e8c07f70d8a33015ca8fba5582f461f77b2 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_57.txt @@ -0,0 +1 @@ +Save the script as t0.py and launch it: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_58.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_58.txt new file mode 100644 index 0000000000000000000000000000000000000000..934c3566574fcb4584c2dc103a9bb5f49a74840b --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_58.txt @@ -0,0 +1,14 @@ +$ deepspeed --num_gpus 2 t0.py +rank0: + in=Is this review positive or negative? Review: this is the best cast iron skillet you will ever buy + out=Positive +rank1: + in=Is this review positive or negative? Review: this is the worst restaurant ever + out=negative +This is a very basic example and you'll want to adapt it to your use case. +Generate +Using multiple GPUs with ZeRO-3 for generation requires synchronizing the GPUs by setting synced_gpus=True in the [~GenerationMixin.generate] method. Otherwise, if one GPU is finished generating before another one, the whole system hangs because the remaining GPUs haven't received the weight shard from the GPU that finished first. +For Transformers>=4.28, if synced_gpus is automatically set to True if multiple GPUs are detected during generation. +Troubleshoot +When you encounter an issue, you should consider whether DeepSpeed is the cause of the problem because often it isn't (unless it's super obviously and you can see DeepSpeed modules in the exception)! The first step should be to retry your setup without DeepSpeed, and if the problem persists, then you can report the issue. If the issue is a core DeepSpeed problem and unrelated to the Transformers integration, open an Issue on the DeepSpeed repository. +For issues related to the Transformers integration, please provide the following information: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_59.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_59.txt new file mode 100644 index 0000000000000000000000000000000000000000..48a2a5ce4d18d196e3b6094111a7fb82b12ff0fe --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_59.txt @@ -0,0 +1,13 @@ +the full DeepSpeed config file + +the command line arguments of the [Trainer], or [TrainingArguments] arguments if you're scripting the [Trainer] setup yourself (don't dump the [TrainingArguments] which has dozens of irrelevant entries) + +the outputs of: + +python -c 'import torch; print(f"torch: {torch.__version__}")' +python -c 'import transformers; print(f"transformers: {transformers.__version__}")' +python -c 'import deepspeed; print(f"deepspeed: {deepspeed.__version__}")' + +a link to a Google Colab notebook to reproduce the issue + +if impossible, a standard and non-custom dataset we can use and also try to use an existing example to reproduce the issue with \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..0af6b80ab2dccca08773d2c38d01a33bdca4556a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_6.txt @@ -0,0 +1,14 @@ +The DeepSpeed configuration file is passed as a path to a JSON file if you're training from the command line interface or as a nested dict object if you're using the [Trainer] in a notebook setting. + +py +TrainingArguments(, deepspeed="path/to/deepspeed_config.json") + +py +ds_config_dict = dict(scheduler=scheduler_params, optimizer=optimizer_params) +args = TrainingArguments(, deepspeed=ds_config_dict) +trainer = Trainer(model, args, ) + +DeepSpeed and Trainer parameters +There are three types of configuration parameters: + +Some of the configuration parameters are shared by [Trainer] and DeepSpeed, and it can be difficult to identify errors when there are conflicting definitions. To make it easier, these shared configuration parameters are configured from the [Trainer] command line arguments. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_60.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_60.txt new file mode 100644 index 0000000000000000000000000000000000000000..5f66db106aa5f83a396f2f7e860ce755c8eb363d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_60.txt @@ -0,0 +1,19 @@ +The following sections provide a guide for resolving two of the most common issues. +DeepSpeed process killed at startup +When the DeepSpeed process is killed during launch without a traceback, that usually means the program tried to allocate more CPU memory than your system has or your process tried to allocate more CPU memory than allowed leading the OS kernel to terminate the process. In this case, check whether your configuration file has either offload_optimizer, offload_param or both configured to offload to the CPU. +If you have NVMe and ZeRO-3 setup, experiment with offloading to the NVMe (estimate the memory requirements for your model). +NaN loss +NaN loss often occurs when a model is pretrained in bf16 and then you try to use it with fp16 (especially relevant for TPU trained models). To resolve this, use fp32 or bf16 if your hardware supports it (TPU, Ampere GPUs or newer). +The other issue may be related to using fp16. For example, if this is your fp16 configuration: +yaml +{ + "fp16": { + "enabled": "auto", + "loss_scale": 0, + "loss_scale_window": 1000, + "initial_scale_power": 16, + "hysteresis": 2, + "min_loss_scale": 1 + } +} +You might see the following OVERFLOW! messages in the logs: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_61.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_61.txt new file mode 100644 index 0000000000000000000000000000000000000000..a875b328b2ad2aba55156f57ef0bd01c84363f72 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_deepspeed.txt_chunk_61.txt @@ -0,0 +1,18 @@ +0%| | 0/189 [00:0015 billion parameter model. +While we see very little degradation in accuracy for our model here, 4-bit quantization can in practice often lead to different results compared to 8-bit quantization or full bfloat16 inference. It is up to the user to try it out. +Also note that inference here was again a bit slower compared to 8-bit quantization which is due to the more aggressive quantization method used for 4-bit quantization leading to \( \text{quantize} \) and \( \text{dequantize} \) taking longer during inference. +python +del model +del pipe +python +flush() +Overall, we saw that running OctoCoder in 8-bit precision reduced the required GPU VRAM from 32G GPU VRAM to only 15GB and running the model in 4-bit precision further reduces the required GPU VRAM to just a bit over 9GB. +4-bit quantization allows the model to be run on GPUs such as RTX3090, V100, and T4 which are quite accessible for most people. +For more information on quantization and to see how one can quantize models to require even less GPU VRAM memory than 4-bit, we recommend looking into the AutoGPTQ implementation. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_16.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_16.txt new file mode 100644 index 0000000000000000000000000000000000000000..5ea57f221dbf074a7a4ceab1ed60171e32c3081e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_16.txt @@ -0,0 +1 @@ +As a conclusion, it is important to remember that model quantization trades improved memory efficiency against accuracy and in some cases inference time. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_17.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_17.txt new file mode 100644 index 0000000000000000000000000000000000000000..f5a2595db5b6103ed8bc395121b22df47aaff9d7 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_17.txt @@ -0,0 +1,21 @@ +If GPU memory is not a constraint for your use case, there is often no need to look into quantization. However many GPUs simply can't run LLMs without quantization methods and in this case, 4-bit and 8-bit quantization schemes are extremely useful tools. +For more in-detail usage information, we strongly recommend taking a look at the Transformers Quantization Docs. +Next, let's look into how we can improve computational and memory efficiency by using better algorithms and an improved model architecture. +2. Flash Attention +Today's top-performing LLMs share more or less the same fundamental architecture that consists of feed-forward layers, activation layers, layer normalization layers, and most crucially, self-attention layers. +Self-attention layers are central to Large Language Models (LLMs) in that they enable the model to understand the contextual relationships between input tokens. +However, the peak GPU memory consumption for self-attention layers grows quadratically both in compute and memory complexity with number of input tokens (also called sequence length) that we denote in the following by \( N \) . +While this is not really noticeable for shorter input sequences (of up to 1000 input tokens), it becomes a serious problem for longer input sequences (at around 16000 input tokens). +Let's take a closer look. The formula to compute the output \( \mathbf{O} \) of a self-attention layer for an input \( \mathbf{X} \) of length \( N \) is: +$$ \textbf{O} = \text{Attn}(\mathbf{X}) = \mathbf{V} \times \text{Softmax}(\mathbf{QK}^T) \text{ with } \mathbf{Q} = \mathbf{W}_q \mathbf{X}, \mathbf{V} = \mathbf{W}_v \mathbf{X}, \mathbf{K} = \mathbf{W}_k \mathbf{X} $$ +\( \mathbf{X} = (\mathbf{x}1, \mathbf{x}{N}) \) is thereby the input sequence to the attention layer. The projections \( \mathbf{Q} \) and \( \mathbf{K} \) will each consist of \( N \) vectors resulting in the \( \mathbf{QK}^T \) being of size \( N^2 \) . +LLMs usually have multiple attention heads, thus doing multiple self-attention computations in parallel. +Assuming, the LLM has 40 attention heads and runs in bfloat16 precision, we can calculate the memory requirement to store the \( \mathbf{QK^T} \) matrices to be \( 40 * 2 * N^2 \) bytes. For \( N=1000 \) only around 50 MB of VRAM are needed, however, for \( N=16000 \) we would need 19 GB of VRAM, and for \( N=100,000 \) we would need almost 1TB just to store the \( \mathbf{QK}^T \) matrices. +Long story short, the default self-attention algorithm quickly becomes prohibitively memory-expensive for large input contexts. +As LLMs improve in text comprehension and generation, they are applied to increasingly complex tasks. While models once handled the translation or summarization of a few sentences, they now manage entire pages, demanding the capability to process extensive input lengths. +How can we get rid of the exorbitant memory requirements for large input lengths? We need a new way to compute the self-attention mechanism that gets rid of the \( QK^T \) matrix. Tri Dao et al. developed exactly such a new algorithm and called it Flash Attention. +In a nutshell, Flash Attention breaks the \(\mathbf{V} \times \text{Softmax}(\mathbf{QK}^T\)) computation apart and instead computes smaller chunks of the output by iterating over multiple softmax computation steps: +$$ \textbf{O}i \leftarrow s^a{ij} * \textbf{O}i + s^b{ij} * \mathbf{V}{j} \times \text{Softmax}(\mathbf{QK}^T{i,j}) \text{ for multiple } i, j \text{ iterations} $$ +with \( s^a_{ij} \) and \( s^b_{ij} \) being some softmax normalization statistics that need to be recomputed for every \( i \) and \( j \) . +Please note that the whole Flash Attention is a bit more complex and is greatly simplified here as going in too much depth is out of scope for this guide. The reader is invited to take a look at the well-written Flash Attention paper for more details. +The main takeaway here is: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_18.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_18.txt new file mode 100644 index 0000000000000000000000000000000000000000..8748b65504e2307b909adebf1dc7cffe3968fcf7 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_18.txt @@ -0,0 +1,5 @@ +By keeping track of softmax normalization statistics and by using some smart mathematics, Flash Attention gives numerical identical outputs compared to the default self-attention layer at a memory cost that only increases linearly with \( N \) . + +Looking at the formula, one would intuitively say that Flash Attention must be much slower compared to the default self-attention formula as more computation needs to be done. Indeed Flash Attention requires more FLOPs compared to normal attention as the softmax normalization statistics have to constantly be recomputed (see paper for more details if interested) + +However, Flash Attention is much faster in inference compared to default attention which comes from its ability to significantly reduce the demands on the slower, high-bandwidth memory of the GPU (VRAM), focusing instead on the faster on-chip memory (SRAM). \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_19.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_19.txt new file mode 100644 index 0000000000000000000000000000000000000000..969c50099a3ec1e30bed601ee56b0ad9d6b27240 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_19.txt @@ -0,0 +1,13 @@ +Essentially, Flash Attention makes sure that all intermediate write and read operations can be done using the fast on-chip SRAM memory instead of having to access the slower VRAM memory to compute the output vector \( \mathbf{O} \) . +In practice, there is currently absolutely no reason to not use Flash Attention if available. The algorithm gives mathematically the same outputs, and is both faster and more memory-efficient. +Let's look at a practical example. +Our OctoCoder model now gets a significantly longer input prompt which includes a so-called system prompt. System prompts are used to steer the LLM into a better assistant that is tailored to the users' task. +In the following, we use a system prompt that will make OctoCoder a better coding assistant. +thon +system_prompt = """Below are a series of dialogues between various people and an AI technical assistant. +The assistant tries to be helpful, polite, honest, sophisticated, emotionally aware, and humble but knowledgeable. +The assistant is happy to help with code questions and will do their best to understand exactly what is needed. +It also tries to avoid giving false or misleading information, and it caveats when it isn't entirely sure about the right answer. +That said, the assistant is practical really does its best, and doesn't let caution get too much in the way of being useful. +The Starcoder models are a series of 15.5B parameter models trained on 80+ programming languages from The Stack (v1.2) (excluding opt-out requests). +The model uses Multi Query Attention, was trained using the Fill-in-the-Middle objective, and with 8,192 tokens context window for a trillion tokens of heavily deduplicated data. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..4ce70df4d0238d7f0b6db2c47d06341200a6a847 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_2.txt @@ -0,0 +1,4 @@ +Throughout this guide, we will offer an analysis of auto-regressive generation from a tensor's perspective. We delve into the pros and cons of adopting lower precision, provide a comprehensive exploration of the latest attention algorithms, and discuss improved LLM architectures. While doing so, we run practical examples showcasing each of the feature improvements. +1. Lower Precision +Memory requirements of LLMs can be best understood by seeing the LLM as a set of weight matrices and vectors and the text inputs as a sequence of vectors. In the following, the definition weights will be used to signify all model weight matrices and vectors. +At the time of writing this guide, LLMs consist of at least a couple billion parameters. Each parameter thereby is made of a decimal number, e.g. 4.5689 which is usually stored in either float32, bfloat16, or float16 format. This allows us to easily compute the memory requirement to load the LLM into memory: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_20.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_20.txt new file mode 100644 index 0000000000000000000000000000000000000000..7736e2f1a78ff20d646f633e5ea26a3162357b9c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_20.txt @@ -0,0 +1,25 @@ +Question: Write a function that takes two lists and returns a list that has alternating elements from each input list. +Answer: Sure. Here is a function that does that. +def alternating(list1, list2): + results = [] + for i in range(len(list1)): + results.append(list1[i]) + results.append(list2[i]) + return results +Question: Can you write some test cases for this function? +Answer: Sure, here are some tests. +assert alternating([10, 20, 30], [1, 2, 3]) == [10, 1, 20, 2, 30, 3] +assert alternating([True, False], [4, 5]) == [True, 4, False, 5] +assert alternating([], []) == [] +Question: Modify the function so that it returns all input elements when the lists have uneven length. The elements from the longer list should be at the end. +Answer: Here is the modified function. +def alternating(list1, list2): + results = [] + for i in range(min(len(list1), len(list2))): + results.append(list1[i]) + results.append(list2[i]) + if len(list1) > len(list2): + results.extend(list1[i+1:]) + else: + results.extend(list2[i+1:]) + return results \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_21.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_21.txt new file mode 100644 index 0000000000000000000000000000000000000000..764d4e2849c891ca7cc8feb443e8c582ceb30344 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_21.txt @@ -0,0 +1,21 @@ +""" +`` +For demonstration purposes, we duplicate the system prompt by ten so that the input length is long enough to observe Flash Attention's memory savings. +We append the original text prompt"Question: Please write a function in Python that transforms bytes to Giga bytes.\n\nAnswer: Here"` +python +long_prompt = 10 * system_prompt + prompt +We instantiate our model again in bfloat16 precision. +thon +model = AutoModelForCausalLM.from_pretrained("bigcode/octocoder", torch_dtype=torch.bfloat16, device_map="auto") +tokenizer = AutoTokenizer.from_pretrained("bigcode/octocoder") +pipe = pipeline("text-generation", model=model, tokenizer=tokenizer) + +Let's now run the model just like before without Flash Attention and measure the peak GPU memory requirement and inference time. +thon +import time +start_time = time.time() +result = pipe(long_prompt, max_new_tokens=60)[0]["generated_text"][len(long_prompt):] +print(f"Generated in {time.time() - start_time} seconds.") +result + +Output: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_22.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_22.txt new file mode 100644 index 0000000000000000000000000000000000000000..3c0c9f8eaa1f9f1c107388763e2fa1068600e1ed --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_22.txt @@ -0,0 +1,11 @@ +Output: + +Generated in 10.96854019165039 seconds. +Sure. Here is a function that does that.\n\ndef bytes_to_giga(bytes):\n return bytes / 1024 / 1024 / 1024\n\nAnswer: Sure. Here is a function that does that.\n\ndef +` +We're getting the same output as before, however this time, the model repeats the answer multiple times until it's 60 tokens cut-off. This is not surprising as we've repeated the system prompt ten times for demonstration purposes and thus cued the model to repeat itself. +Note that the system prompt should not be repeated ten times in real-world applications - one time is enough! +Let's measure the peak GPU memory requirement. +python +bytes_to_giga_bytes(torch.cuda.max_memory_allocated()) +Output: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_23.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_23.txt new file mode 100644 index 0000000000000000000000000000000000000000..b10c6d3321b138691545d8cef46ec8c13d176cda --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_23.txt @@ -0,0 +1,16 @@ +37.668193340301514 +As we can see the peak GPU memory requirement is now significantly higher than in the beginning, which is largely due to the longer input sequence. Also the generation takes a little over a minute now. +We call flush() to free GPU memory for our next experiment. +python +flush() +For comparison, let's run the same function, but enable Flash Attention instead. +To do so, we convert the model to BetterTransformer and by doing so enabling PyTorch's SDPA self-attention which in turn is able to use Flash Attention. +python +model.to_bettertransformer() +Now we run the exact same code snippet as before and under the hood Transformers will make use of Flash Attention. + +start_time = time.time() +with torch.backends.cuda.sdp_kernel(enable_flash=True, enable_math=False, enable_mem_efficient=False): + result = pipe(long_prompt, max_new_tokens=60)[0]["generated_text"][len(long_prompt):] +print(f"Generated in {time.time() - start_time} seconds.") +result \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_24.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_24.txt new file mode 100644 index 0000000000000000000000000000000000000000..83e7183a5731b543d1788f3d33815476e119637e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_24.txt @@ -0,0 +1,16 @@ +Output: +Generated in 3.0211617946624756 seconds. + Sure. Here is a function that does that.\n\ndef bytes_to_giga(bytes):\n return bytes / 1024 / 1024 / 1024\n\nAnswer: Sure. Here is a function that does that.\n\ndef +We're getting the exact same result as before, but can observe a very significant speed-up thanks to Flash Attention. +Let's measure the memory consumption one last time. +python +bytes_to_giga_bytes(torch.cuda.max_memory_allocated()) +Output: +32.617331981658936 +And we're almost back to our original 29GB peak GPU memory from the beginning. +We can observe that we only use roughly 100MB more GPU memory when passing a very long input sequence with Flash Attention compared to passing a short input sequence as done in the beginning. +py +flush() +For more information on how to use Flash Attention, please have a look at this doc page. +3. Architectural Innovations +So far we have looked into improving computational and memory efficiency by: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_25.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_25.txt new file mode 100644 index 0000000000000000000000000000000000000000..204f99b515d19b3287e0c84e87a46d86d2d9832d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_25.txt @@ -0,0 +1,13 @@ +Casting the weights to a lower precision format +Replacing the self-attention algorithm with a more memory- and compute efficient version + +Let's now look into how we can change the architecture of an LLM so that it is most effective and efficient for task that require long text inputs, e.g.: +- Retrieval augmented Questions Answering, +- Summarization, +- Chat +Note that chat not only requires the LLM to handle long text inputs, but it also necessitates that the LLM is able to efficiently handle the back-and-forth dialogue between user and assistant (such as ChatGPT). +Once trained, the fundamental LLM architecture is difficult to change, so it is important to make considerations about the LLM's tasks beforehand and accordingly optimize the model's architecture. +There are two important components of the model architecture that quickly become memory and/or performance bottlenecks for large input sequences. + +The positional embeddings +The key-value cache \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_26.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_26.txt new file mode 100644 index 0000000000000000000000000000000000000000..2ec60e22b658c65e58430554084ad33cfc448288 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_26.txt @@ -0,0 +1,7 @@ +The positional embeddings +The key-value cache + +Let's go over each component in more detail +3.1 Improving positional embeddings of LLMs +Self-attention puts each token in relation to each other's tokens. +As an example, the \( \text{Softmax}(\mathbf{QK}^T) \) matrix of the text input sequence "Hello", "I", "love", "you" could look as follows: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_27.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_27.txt new file mode 100644 index 0000000000000000000000000000000000000000..f7be27d403c6876cd6ce76e38c23d710744d5373 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_27.txt @@ -0,0 +1,12 @@ +Each word token is given a probability mass at which it attends all other word tokens and, therefore is put into relation with all other word tokens. E.g. the word "love" attends to the word "Hello" with 5%, to "I" with 30%, and to itself with 65%. +A LLM based on self-attention, but without position embeddings would have great difficulties in understanding the positions of the text inputs to each other. +This is because the probability score computed by \( \mathbf{QK}^T \) relates each word token to each other word token in \( O(1) \) computations regardless of their relative positional distance to each other. +Therefore, for the LLM without position embeddings each token appears to have the same distance to all other tokens, e.g. differentiating between "Hello I love you" and "You love I hello" would be very challenging. +For the LLM to understand sentence order, an additional cue is needed and is usually applied in the form of positional encodings (or also called positional embeddings). +Positional encodings, encode the position of each token into a numerical presentation that the LLM can leverage to better understand sentence order. +The authors of the Attention Is All You Need paper introduced sinusoidal positional embeddings \( \mathbf{P} = \mathbf{p}_1, \ldots, \mathbf{p}_N \) . +where each vector \( \mathbf{p}_i \) is computed as a sinusoidal function of its position \( i \) . +The positional encodings are then simply added to the input sequence vectors \( \mathbf{\hat{X}} = \mathbf{\hat{x}}_1, \ldots, \mathbf{\hat{x}}_N \) = \( \mathbf{x}_1 + \mathbf{p}_1, \ldots, \mathbf{x}_N + \mathbf{p}_N \) thereby cueing the model to better learn sentence order. +Instead of using fixed position embeddings, others (such as Devlin et al.) used learned positional encodings for which the positional embeddings +\( \mathbf{P} \) are learned during training. +Sinusoidal and learned position embeddings used to be the predominant methods to encode sentence order into LLMs, but a couple of problems related to these positional encodings were found: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_28.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_28.txt new file mode 100644 index 0000000000000000000000000000000000000000..ad884d314e861ac23993417232cd347593e9d2c1 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_28.txt @@ -0,0 +1,7 @@ +Sinusoidal and learned position embeddings are both absolute positional embeddings, i.e. encoding a unique embedding for each position id: \( 0, \ldots, N \) . As shown by Huang et al. and Su et al., absolute positional embeddings lead to poor LLM performance for long text inputs. For long text inputs, it is advantageous if the model learns the relative positional distance input tokens have to each other instead of their absolute position. +When using learned position embeddings, the LLM has to be trained on a fixed input length \( N \), which makes it difficult to extrapolate to an input length longer than what it was trained on. + +Recently, relative positional embeddings that can tackle the above mentioned problems have become more popular, most notably: + +Rotary Position Embedding (RoPE) +ALiBi \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_29.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_29.txt new file mode 100644 index 0000000000000000000000000000000000000000..de563bc7f84ce8ea2fbc741d96b254aae21c40a0 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_29.txt @@ -0,0 +1,7 @@ +Rotary Position Embedding (RoPE) +ALiBi + +Both RoPE and ALiBi argue that it's best to cue the LLM about sentence order directly in the self-attention algorithm as it's there that word tokens are put into relation with each other. More specifically, sentence order should be cued by modifying the \( \mathbf{QK}^T \) computation. +Without going into too many details, RoPE notes that positional information can be encoded into query-key pairs, e.g. \( \mathbf{q}_i \) and \( \mathbf{x}_j \) by rotating each vector by an angle \( \theta * i \) and \( \theta * j \) respectively with \( i, j \) describing each vectors sentence position: +$$ \mathbf{\hat{q}}i^T \mathbf{\hat{x}}_j = \mathbf{{q}}_i^T \mathbf{R}{\theta, i -j} \mathbf{{x}}_j. $$ +\( \mathbf{R}_{\theta, i - j} \) thereby represents a rotational matrix. \( \theta \) is not learned during training, but instead set to a pre-defined value that depends on the maximum input sequence length during training. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..bec99f066ace75e232ae5d4d6a5eaa7e0e4f86c2 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_3.txt @@ -0,0 +1,8 @@ +Loading the weights of a model having X billion parameters requires roughly 4 * X GB of VRAM in float32 precision + +Nowadays, models are however rarely trained in full float32 precision, but usually in bfloat16 precision or less frequently in float16 precision. Therefore the rule of thumb becomes: + +Loading the weights of a model having X billion parameters requires roughly 2 * X GB of VRAM in bfloat16/float16 precision + +For shorter text inputs (less than 1024 tokens), the memory requirement for inference is very much dominated by the memory requirement to load the weights. Therefore, for now, let's assume that the memory requirement for inference is equal to the memory requirement to load the model into the GPU VRAM. +To give some examples of how much VRAM it roughly takes to load a model in bfloat16: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_30.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_30.txt new file mode 100644 index 0000000000000000000000000000000000000000..e3b4f72e4222e13f8fcd4f38815c3ff372e1773b --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_30.txt @@ -0,0 +1,15 @@ +By doing so, the propability score between \( \mathbf{q}_i \) and \( \mathbf{q}_j \) is only affected if \( i \ne j \) and solely depends on the relative distance \( i - j \) regardless of each vector's specific positions \( i \) and \( j \) . + +RoPE is used in multiple of today's most important LLMs, such as: + +Falcon +Llama +PaLM + +As an alternative, ALiBi proposes a much simpler relative position encoding scheme. The relative distance that input tokens have to each other is added as a negative integer scaled by a pre-defined value m to each query-key entry of the \( \mathbf{QK}^T \) matrix right before the softmax computation. + +As shown in the ALiBi paper, this simple relative positional encoding allows the model to retain a high performance even at very long text input sequences. +ALiBi is used in multiple of today's most important LLMs, such as: + +MPT +BLOOM \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_31.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_31.txt new file mode 100644 index 0000000000000000000000000000000000000000..9cf42f242c8f27fd9bd87e1be8daedd9b717c462 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_31.txt @@ -0,0 +1,6 @@ +MPT +BLOOM + +Both RoPE and ALiBi position encodings can extrapolate to input lengths not seen during training whereas it has been shown that extrapolation works much better out-of-the-box for ALiBi as compared to RoPE. +For ALiBi, one simply increases the values of the lower triangular position matrix to match the length of the input sequence. +For RoPE, keeping the same \( \theta \) that was used during training leads to poor results when passing text inputs much longer than those seen during training, c.f Press et al.. However, the community has found a couple of effective tricks that adapt \( \theta \), thereby allowing RoPE position embeddings to work well for extrapolated text input sequences (see here). \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_32.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_32.txt new file mode 100644 index 0000000000000000000000000000000000000000..088406832d43a8e6df8e6b9b2bbea1a44b42d3a4 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_32.txt @@ -0,0 +1,4 @@ +Both RoPE and ALiBi are relative positional embeddings that are not learned during training, but instead are based on the following intuitions: + - Positional cues about the text inputs should be given directly to the \( QK^T \) matrix of the self-attention layer + - The LLM should be incentivized to learn a constant relative distance positional encodings have to each other + - The further text input tokens are from each other, the lower the probability of their query-value probability. Both RoPE and ALiBi lower the query-key probability of tokens far away from each other. RoPE by decreasing their vector product by increasing the angle between the query-key vectors. ALiBi by adding large negative numbers to the vector product \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_33.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_33.txt new file mode 100644 index 0000000000000000000000000000000000000000..355bd52329d386e8d06aeb2bfd4882c7dceada19 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_33.txt @@ -0,0 +1,14 @@ +In conclusion, LLMs that are intended to be deployed in tasks that require handling large text inputs are better trained with relative positional embeddings, such as RoPE and ALiBi. Also note that even if an LLM with RoPE and ALiBi has been trained only on a fixed length of say \( N_1 = 2048 \) it can still be used in practice with text inputs much larger than \( N_1 \), like \( N_2 = 8192 > N_1 \) by extrapolating the positional embeddings. +3.2 The key-value cache +Auto-regressive text generation with LLMs works by iteratively putting in an input sequence, sampling the next token, appending the next token to the input sequence, and continuing to do so until the LLM produces a token that signifies that the generation has finished. +Please have a look at Transformer's Generate Text Tutorial to get a more visual explanation of how auto-regressive generation works. +Let's run a quick code snippet to show how auto-regressive works in practice. We will simply take the most likely next token via torch.argmax. +thon +input_ids = tokenizer(prompt, return_tensors="pt")["input_ids"].to("cuda") +for _ in range(5): + next_logits = model(input_ids)["logits"][:, -1:] + next_token_id = torch.argmax(next_logits,dim=-1) +input_ids = torch.cat([input_ids, next_token_id], dim=-1) + print("shape of input_ids", input_ids.shape) +generated_text = tokenizer.batch_decode(input_ids[:, -5:]) +generated_text \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_34.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_34.txt new file mode 100644 index 0000000000000000000000000000000000000000..62ee4ce614728368266aa5ef2862eac7d96e5718 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_34.txt @@ -0,0 +1,25 @@ +Output: +shape of input_ids torch.Size([1, 21]) +shape of input_ids torch.Size([1, 22]) +shape of input_ids torch.Size([1, 23]) +shape of input_ids torch.Size([1, 24]) +shape of input_ids torch.Size([1, 25]) +[' Here is a Python function'] +As we can see every time we increase the text input tokens by the just sampled token. +With very few exceptions, LLMs are trained using the causal language modeling objective and therefore mask the upper triangle matrix of the attention score - this is why in the two diagrams above the attention scores are left blank (a.k.a have 0 probability). For a quick recap on causal language modeling you can refer to the Illustrated Self Attention blog. +As a consequence, tokens never depend on previous tokens, more specifically the \( \mathbf{q}i \) vector is never put in relation with any key, values vectors \( \mathbf{k}_j, \mathbf{v}_j \) if \( j > i \) . Instead \( \mathbf{q}_i \) only attends to previous key-value vectors \( \mathbf{k}{m < i}, \mathbf{v}_{m < i} \text{ , for } m \in {0, \ldots i - 1} \). In order to reduce unnecessary computation, one can therefore cache each layer's key-value vectors for all previous timesteps. +In the following, we will tell the LLM to make use of the key-value cache by retrieving and forwarding it for each forward pass. +In Transformers, we can retrieve the key-value cache by passing the use_cache flag to the forward call and can then pass it with the current token. +thon +past_key_values = None # past_key_values is the key-value cache +generated_tokens = [] +next_token_id = tokenizer(prompt, return_tensors="pt")["input_ids"].to("cuda") +for _ in range(5): + next_logits, past_key_values = model(next_token_id, past_key_values=past_key_values, use_cache=True).to_tuple() + next_logits = next_logits[:, -1:] + next_token_id = torch.argmax(next_logits, dim=-1) +print("shape of input_ids", next_token_id.shape) + print("length of key-value cache", len(past_key_values[0][0])) # past_key_values are of shape [num_layers, 0 for k, 1 for v, batch_size, length, hidden_dim] + generated_tokens.append(next_token_id.item()) +generated_text = tokenizer.batch_decode(generated_tokens) +generated_text \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_35.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_35.txt new file mode 100644 index 0000000000000000000000000000000000000000..4bfa83d1a811f7c5591f1d3cdec4faf9b157bcb8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_35.txt @@ -0,0 +1,15 @@ +Output: +shape of input_ids torch.Size([1, 1]) +length of key-value cache 20 +shape of input_ids torch.Size([1, 1]) +length of key-value cache 21 +shape of input_ids torch.Size([1, 1]) +length of key-value cache 22 +shape of input_ids torch.Size([1, 1]) +length of key-value cache 23 +shape of input_ids torch.Size([1, 1]) +length of key-value cache 24 +[' Here', ' is', ' a', ' Python', ' function'] +As one can see, when using the key-value cache the text input tokens are not increased in length, but remain a single input vector. The length of the key-value cache on the other hand is increased by one at every decoding step. + +Making use of the key-value cache means that the \( \mathbf{QK}^T \) is essentially reduced to \( \mathbf{q}_c\mathbf{K}^T \) with \( \mathbf{q}_c \) being the query projection of the currently passed input token which is always just a single vector. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_36.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_36.txt new file mode 100644 index 0000000000000000000000000000000000000000..3864dd3164dc2ab914272e2f9e3b4e08bd8b7663 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_36.txt @@ -0,0 +1,7 @@ +Using the key-value cache has two advantages: +- Significant increase in computational efficiency as less computations are performed compared to computing the full \( \mathbf{QK}^T \) matrix. This leads to an increase in inference speed +- The maximum required memory is not increased quadratically with the number of generated tokens, but only increases linearly. + +One should always make use of the key-value cache as it leads to identical results and a significant speed-up for longer input sequences. Transformers has the key-value cache enabled by default when making use of the text pipeline or the generate method. + +Note that, despite our advice to use key-value caches, your LLM output may be slightly different when you use them. This is a property of the matrix multiplication kernels themselves -- you can read more about it here. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_37.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_37.txt new file mode 100644 index 0000000000000000000000000000000000000000..a2dff01fe1710c441edee25089ee37afee9d2c03 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_37.txt @@ -0,0 +1,29 @@ +3.2.1 Multi-round conversation +The key-value cache is especially useful for applications such as chat where multiple passes of auto-regressive decoding are required. Let's look at an example. +User: How many people live in France? +Assistant: Roughly 75 million people live in France +User: And how many are in Germany? +Assistant: Germany has ca. 81 million inhabitants +In this chat, the LLM runs auto-regressive decoding twice: + 1. The first time, the key-value cache is empty and the input prompt is "User: How many people live in France?" and the model auto-regressively generates the text "Roughly 75 million people live in France" while increasing the key-value cache at every decoding step. + 2. The second time the input prompt is "User: How many people live in France? \n Assistant: Roughly 75 million people live in France \n User: And how many in Germany?". Thanks to the cache, all key-value vectors for the first two sentences are already computed. Therefore the input prompt only consists of "User: And how many in Germany?". While processing the shortened input prompt, it's computed key-value vectors are concatenated to the key-value cache of the first decoding. The second Assistant's answer "Germany has ca. 81 million inhabitants" is then auto-regressively generated with the key-value cache consisting of encoded key-value vectors of "User: How many people live in France? \n Assistant: Roughly 75 million people live in France \n User: And how many are in Germany?". +Two things should be noted here: + 1. Keeping all the context is crucial for LLMs deployed in chat so that the LLM understands all the previous context of the conversation. E.g. for the example above the LLM needs to understand that the user refers to the population when asking "And how many are in Germany". + 2. The key-value cache is extremely useful for chat as it allows us to continuously grow the encoded chat history instead of having to re-encode the chat history again from scratch (as e.g. would be the case when using an encoder-decoder architecture). +In transformers, a generate call will return past_key_values when return_dict_in_generate=True is passed, in addition to the default use_cache=True. Note that it is not yet available through the pipeline interface. +thon +Generation as usual +prompt = system_prompt + "Question: Please write a function in Python that transforms bytes to Giga bytes.\n\nAnswer: Here" +model_inputs = tokenizer(prompt, return_tensors='pt') +generation_output = model.generate(**model_inputs, max_new_tokens=60, return_dict_in_generate=True) +decoded_output = tokenizer.batch_decode(generation_output.sequences)[0] +Piping the returned past_key_values to speed up the next conversation round +prompt = decoded_output + "\nQuestion: How can I modify the function above to return Mega bytes instead?\n\nAnswer: Here" +model_inputs = tokenizer(prompt, return_tensors='pt') +generation_output = model.generate( + **model_inputs, + past_key_values=generation_output.past_key_values, + max_new_tokens=60, + return_dict_in_generate=True +) +tokenizer.batch_decode(generation_output.sequences)[0][len(prompt):] \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_38.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_38.txt new file mode 100644 index 0000000000000000000000000000000000000000..6ae2abb6d51db245a789dca9328a92b115abc7bc --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_38.txt @@ -0,0 +1,6 @@ +Output: + + is a modified version of the function that returns Mega bytes instead. +def bytes_to_megabytes(bytes): + return bytes / 1024 / 1024 +Answer: The function takes a number of bytes as input and returns the number of \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_39.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_39.txt new file mode 100644 index 0000000000000000000000000000000000000000..52f12bb15023a5b63b5758790d6864efc81b94fd --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_39.txt @@ -0,0 +1,13 @@ +Great, no additional time is spent recomputing the same key and values for the attention layer! There is however one catch. While the required peak memory for the \( \mathbf{QK}^T \) matrix is significantly reduced, holding the key-value cache in memory can become very memory expensive for long input sequences or multi-turn chat. Remember that the key-value cache needs to store the key-value vectors for all previous input vectors \( \mathbf{x}_i \text{, for } i \in {1, \ldots, c - 1} \) for all self-attention layers and for all attention heads. +Let's compute the number of float values that need to be stored in the key-value cache for the LLM bigcode/octocoder that we used before. +The number of float values amounts to two times the sequence length times the number of attention heads times the attention head dimension and times the number of layers. +Computing this for our LLM at a hypothetical input sequence length of 16000 gives: +python +config = model.config +2 * 16_000 * config.n_layer * config.n_head * config.n_embd // config.n_head +Output: +7864320000 +Roughly 8 billion float values! Storing 8 billion float values in float16 precision requires around 15 GB of RAM which is circa half as much as the model weights themselves! +Researchers have proposed two methods that allow to significantly reduce the memory cost of storing the key-value cache, which are explored in the next subsections. +3.2.2 Multi-Query-Attention (MQA) +Multi-Query-Attention was proposed in Noam Shazeer's Fast Transformer Decoding: One Write-Head is All You Need paper. As the title says, Noam found out that instead of using n_head key-value projections weights, one can use a single head-value projection weight pair that is shared across all attention heads without that the model's performance significantly degrades. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..4e6b7ce7aae44b0e8f855fae0949042c4debb158 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_4.txt @@ -0,0 +1,6 @@ +GPT3 requires 2 * 175 GB = 350 GB VRAM +Bloom requires 2 * 176 GB = 352 GB VRAM +Llama-2-70b requires 2 * 70 GB = 140 GB VRAM +Falcon-40b requires 2 * 40 GB = 80 GB VRAM +MPT-30b requires 2 * 30 GB = 60 GB VRAM +bigcode/starcoder requires 2 * 15.5 = 31 GB VRAM \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_40.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_40.txt new file mode 100644 index 0000000000000000000000000000000000000000..ea57ade8b93978444d6e8c827b7f23663b4c986e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_40.txt @@ -0,0 +1 @@ +By using a single head-value projection weight pair, the key value vectors \( \mathbf{k}_i, \mathbf{v}_i \) have to be identical across all attention heads which in turn means that we only need to store 1 key-value projection pair in the cache instead of n_head ones. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_41.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_41.txt new file mode 100644 index 0000000000000000000000000000000000000000..ea2bb1d4272334baade7892c1103bcca9a6b50a0 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_41.txt @@ -0,0 +1,5 @@ +As most LLMs use between 20 and 100 attention heads, MQA significantly reduces the memory consumption of the key-value cache. For the LLM used in this notebook we could therefore reduce the required memory consumption from 15 GB to less than 400 MB at an input sequence length of 16000. +In addition to memory savings, MQA also leads to improved computational efficiency as explained in the following. +In auto-regressive decoding, large key-value vectors need to be reloaded, concatenated with the current key-value vector pair to be then fed into the \( \mathbf{q}_c\mathbf{K}^T \) computation at every step. For auto-regressive decoding, the required memory bandwidth for the constant reloading can become a serious time bottleneck. By reducing the size of the key-value vectors less memory needs to be accessed, thus reducing the memory bandwidth bottleneck. For more detail, please have a look at Noam's paper. +The important part to understand here is that reducing the number of key-value attention heads to 1 only makes sense if a key-value cache is used. The peak memory consumption of the model for a single forward pass without key-value cache stays unchanged as every attention head still has a unique query vector so that each attention head still has a different \( \mathbf{QK}^T \) matrix. +MQA has seen wide adoption by the community and is now used by many of the most popular LLMs: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_42.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_42.txt new file mode 100644 index 0000000000000000000000000000000000000000..0b7a8b7115fec59689403dda268a91a029249c1d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_42.txt @@ -0,0 +1,4 @@ +Falcon +PaLM +MPT +BLOOM \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_43.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_43.txt new file mode 100644 index 0000000000000000000000000000000000000000..07ba05a2d9382b5db1eb769b7157a2362db60ea5 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_43.txt @@ -0,0 +1,6 @@ +Also, the checkpoint used in this notebook - bigcode/octocoder - makes use of MQA. +3.2.3 Grouped-Query-Attention (GQA) +Grouped-Query-Attention, as proposed by Ainslie et al. from Google, found that using MQA can often lead to quality degradation compared to using vanilla multi-key-value head projections. The paper argues that more model performance can be kept by less drastically reducing the number of query head projection weights. Instead of using just a single key-value projection weight, n < n_head key-value projection weights should be used. By choosing n to a significantly smaller value than n_head, such as 2,4 or 8 almost all of the memory and speed gains from MQA can be kept while sacrificing less model capacity and thus arguably less performance. +Moreover, the authors of GQA found out that existing model checkpoints can be uptrained to have a GQA architecture with as little as 5% of the original pre-training compute. While 5% of the original pre-training compute can still be a massive amount, GQA uptraining allows existing checkpoints to be useful for longer input sequences. +GQA was only recently proposed which is why there is less adoption at the time of writing this notebook. +The most notable application of GQA is Llama-v2. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_44.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_44.txt new file mode 100644 index 0000000000000000000000000000000000000000..32fd9bc17386098dda83b0c8e00710c2e42d10e2 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_44.txt @@ -0,0 +1 @@ +As a conclusion, it is strongly recommended to make use of either GQA or MQA if the LLM is deployed with auto-regressive decoding and is required to handle large input sequences as is the case for example for chat. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_45.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_45.txt new file mode 100644 index 0000000000000000000000000000000000000000..e5bb79fe3d158cba255808b39e579a7434b434a9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_45.txt @@ -0,0 +1,4 @@ +Conclusion +The research community is constantly coming up with new, nifty ways to speed up inference time for ever-larger LLMs. As an example, one such promising research direction is speculative decoding where "easy tokens" are generated by smaller, faster language models and only "hard tokens" are generated by the LLM itself. Going into more detail is out of the scope of this notebook, but can be read upon in this nice blog post. +The reason massive LLMs such as GPT3/4, Llama-2-70b, Claude, PaLM can run so quickly in chat-interfaces such as Hugging Face Chat or ChatGPT is to a big part thanks to the above-mentioned improvements in precision, algorithms, and architecture. +Going forward, accelerators such as GPUs, TPUs, etc will only get faster and allow for more memory, but one should nevertheless always make sure to use the best available algorithms and architectures to get the most bang for your buck 🤗 \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..178735546e32311243384a673d8a6cca7cb87359 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_5.txt @@ -0,0 +1,5 @@ +As of writing this document, the largest GPU chip on the market is the A100 & H100 offering 80GB of VRAM. Most of the models listed before require more than 80GB just to be loaded and therefore necessarily require tensor parallelism and/or pipeline parallelism. +🤗 Transformers does not support tensor parallelism out of the box as it requires the model architecture to be written in a specific way. If you're interested in writing models in a tensor-parallelism-friendly way, feel free to have a look at the text-generation-inference library. +Naive pipeline parallelism is supported out of the box. For this, simply load the model with device="auto" which will automatically place the different layers on the available GPUs as explained here. +Note, however that while very effective, this naive pipeline parallelism does not tackle the issues of GPU idling. For this more advanced pipeline parallelism is required as explained here. +If you have access to an 8 x 80GB A100 node, you could load BLOOM as follows \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..644b54d008d2403a17b54dabe313306aae365b5d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_6.txt @@ -0,0 +1,4 @@ +!pip install transformers accelerate bitsandbytes optimum +thon +from transformers import AutoModelForCausalLM +model = AutoModelForCausalLM.from_pretrained("bigscience/bloom", device_map="auto", pad_token_id=0) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..2a41a76faa5360c493ff4588e2ef65ddfac96f23 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_7.txt @@ -0,0 +1,10 @@ +By using device_map="auto" the attention layers would be equally distributed over all available GPUs. +In this guide, we will use bigcode/octocoder as it can be run on a single 40 GB A100 GPU device chip. Note that all memory and speed optimizations that we will apply going forward, are equally applicable to models that require model or tensor parallelism. +Since the model is loaded in bfloat16 precision, using our rule of thumb above, we would expect the memory requirement to run inference with bigcode/octocoder to be around 31 GB VRAM. Let's give it a try. +We first load the model and tokenizer and then pass both to Transformers' pipeline object. +thon +from transformers import AutoModelForCausalLM, AutoTokenizer, pipeline +import torch +model = AutoModelForCausalLM.from_pretrained("bigcode/octocoder", torch_dtype=torch.bfloat16, device_map="auto", pad_token_id=0) +tokenizer = AutoTokenizer.from_pretrained("bigcode/octocoder") +pipe = pipeline("text-generation", model=model, tokenizer=tokenizer) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..bc23e6606e8f0068021ec5e3e9d106d7ff7854cf --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_8.txt @@ -0,0 +1,15 @@ +thon +prompt = "Question: Please write a function in Python that transforms bytes to Giga bytes.\n\nAnswer:" +result = pipe(prompt, max_new_tokens=60)[0]["generated_text"][len(prompt):] +result + +Output: +Here is a Python function that transforms bytes to Giga bytes:\n\npython\ndef bytes_to_giga_bytes(bytes):\n return bytes / 1024 / 1024 / 1024\n\n\nThis function takes a single +Nice, we can now directly use the result to convert bytes into Gigabytes. +python +def bytes_to_giga_bytes(bytes): + return bytes / 1024 / 1024 / 1024 +Let's call torch.cuda.max_memory_allocated to measure the peak GPU memory allocation. +python +bytes_to_giga_bytes(torch.cuda.max_memory_allocated()) +Output: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..2e2f27110449e48296545f042e02872858911d32 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_llm_tutorial_optimization.txt_chunk_9.txt @@ -0,0 +1,5 @@ +29.0260648727417 +Close enough to our back-of-the-envelope computation! We can see the number is not exactly correct as going from bytes to kilobytes requires a multiplication of 1024 instead of 1000. Therefore the back-of-the-envelope formula can also be understood as an "at most X GB" computation. +Note that if we had tried to run the model in full float32 precision, a whopping 64 GB of VRAM would have been required. + +Almost all models are trained in bfloat16 nowadays, there is no reason to run the model in full float32 precision if your GPU supports bfloat16. Float32 won't give better inference results than the precision that was used to train the model. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..8a2587c9a7331deccf8cf16c9457e3a0e08b9a28 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_0.txt @@ -0,0 +1,12 @@ +Model training anatomy +To understand performance optimization techniques that one can apply to improve efficiency of model training +speed and memory utilization, it's helpful to get familiar with how GPU is utilized during training, and how compute +intensity varies depending on an operation performed. +Let's start by exploring a motivating example of GPU utilization and the training run of a model. For the demonstration, +we'll need to install a few libraries: + +pip install transformers datasets accelerate nvidia-ml-py3 +The nvidia-ml-py3 library allows us to monitor the memory usage of the models from within Python. You might be familiar +with the nvidia-smi command in the terminal - this library allows to access the same information in Python directly. +Then, we create some dummy data: random token IDs between 100 and 30000 and binary labels for a classifier. +In total, we get 512 sequences each with length 512 and store them in a [~datasets.Dataset] with PyTorch format. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..6d97d1b4da5580ff5c1b8c42c1761193d668f496 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_1.txt @@ -0,0 +1,27 @@ +import numpy as np +from datasets import Dataset +seq_len, dataset_size = 512, 512 +dummy_data = { + "input_ids": np.random.randint(100, 30000, (dataset_size, seq_len)), + "labels": np.random.randint(0, 1, (dataset_size)), + } +ds = Dataset.from_dict(dummy_data) +ds.set_format("pt") + +To print summary statistics for the GPU utilization and the training run with the [Trainer] we define two helper functions: + +from pynvml import * +def print_gpu_utilization(): + nvmlInit() + handle = nvmlDeviceGetHandleByIndex(0) + info = nvmlDeviceGetMemoryInfo(handle) + print(f"GPU memory occupied: {info.used//1024**2} MB.") +def print_summary(result): + print(f"Time: {result.metrics['train_runtime']:.2f}") + print(f"Samples/second: {result.metrics['train_samples_per_second']:.2f}") + print_gpu_utilization() + +Let's verify that we start with a free GPU memory: + +print_gpu_utilization() +GPU memory occupied: 0 MB. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_10.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_10.txt new file mode 100644 index 0000000000000000000000000000000000000000..2672a09ed013ef76c7c606f7c15431152514e6c9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_10.txt @@ -0,0 +1,19 @@ +There are the input and output that are being passed and returned by the forward and the backward functions and the +forward activations saved for gradient computation. +Temporary Memory +Additionally, there are all kinds of temporary variables which get released once the calculation is done, but in the +moment these could require additional memory and could push to OOM. Therefore, when coding it's crucial to think +strategically about such temporary variables and sometimes to explicitly free those as soon as they are no longer needed. +Functionality-specific memory +Then, your software could have special memory needs. For example, when generating text using beam search, the software +needs to maintain multiple copies of inputs and outputs. +forward vs backward Execution Speed +For convolutions and linear layers there are 2x flops in the backward compared to the forward, which generally translates +into ~2x slower (sometimes more, because sizes in the backward tend to be more awkward). Activations are usually +bandwidth-limited, and it’s typical for an activation to have to read more data in the backward than in the forward +(e.g. activation forward reads once, writes once, activation backward reads twice, gradOutput and output of the forward, +and writes once, gradInput). +As you can see, there are potentially a few places where we could save GPU memory or speed up operations. +Now that you understand what affects GPU utilization and computation speed, refer to +the Methods and tools for efficient training on a single GPU documentation page to learn about +performance optimization techniques. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..7218e8dac6ee6598e82b1f2b45621fded20dbab7 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_2.txt @@ -0,0 +1,17 @@ +print_gpu_utilization() +GPU memory occupied: 0 MB. + +That looks good: the GPU memory is not occupied as we would expect before we load any models. If that's not the case on +your machine make sure to stop all processes that are using GPU memory. However, not all free GPU memory can be used by +the user. When a model is loaded to the GPU the kernels are also loaded, which can take up 1-2GB of memory. To see how +much it is we load a tiny tensor into the GPU which triggers the kernels to be loaded as well. + +import torch +torch.ones((1, 1)).to("cuda") +print_gpu_utilization() +GPU memory occupied: 1343 MB. + +We see that the kernels alone take up 1.3GB of GPU memory. Now let's see how much space the model uses. +Load Model +First, we load the google-bert/bert-large-uncased model. We load the model weights directly to the GPU so that we can check +how much space just the weights use. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..31a377a9db9d165bc8e510914c99a16e9d88c377 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_3.txt @@ -0,0 +1,9 @@ +from transformers import AutoModelForSequenceClassification +model = AutoModelForSequenceClassification.from_pretrained("google-bert/bert-large-uncased").to("cuda") +print_gpu_utilization() +GPU memory occupied: 2631 MB. + +We can see that the model weights alone take up 1.3 GB of GPU memory. The exact number depends on the specific +GPU you are using. Note that on newer GPUs a model can sometimes take up more space since the weights are loaded in an +optimized fashion that speeds up the usage of the model. Now we can also quickly check if we get the same result +as with nvidia-smi CLI: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..8b6c790d656e641c89d98aa2608256c78d1216f3 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_4.txt @@ -0,0 +1,21 @@ +nvidia-smi +```bash +Tue Jan 11 08:58:05 2022 ++-----------------------------------------------------------------------------+ +| NVIDIA-SMI 460.91.03 Driver Version: 460.91.03 CUDA Version: 11.2 | +|-------------------------------+----------------------+----------------------+ +| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC | +| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. | +| | | MIG M. | +|===============================+======================+======================| +| 0 Tesla V100-SXM2 On | 00000000:00:04.0 Off | 0 | +| N/A 37C P0 39W / 300W | 2631MiB / 16160MiB | 0% Default | +| | | N/A | ++-------------------------------+----------------------+----------------------+ ++-----------------------------------------------------------------------------+ +| Processes: | +| GPU GI CI PID Type Process name GPU Memory | +| ID ID Usage | +|=============================================================================| +| 0 N/A N/A 3721 C nvs/codeparrot/bin/python 2629MiB | ++-----------------------------------------------------------------------------+ \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..e671841fcc9ce23020f1fc515f36e86e87a682fe --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_5.txt @@ -0,0 +1,17 @@ +We get the same number as before and you can also see that we are using a V100 GPU with 16GB of memory. So now we can +start training the model and see how the GPU memory consumption changes. First, we set up a few standard training +arguments: +py +default_args = { + "output_dir": "tmp", + "eval_strategy": "steps", + "num_train_epochs": 1, + "log_level": "error", + "report_to": "none", +} + +If you plan to run multiple experiments, in order to properly clear the memory between experiments, restart the Python + kernel between experiments. + +Memory utilization at vanilla training +Let's use the [Trainer] and train the model without using any GPU performance optimization techniques and a batch size of 4: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..bab50b8f148b77ceecbf16ff723b2ac2028eb953 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_6.txt @@ -0,0 +1,16 @@ +from transformers import TrainingArguments, Trainer, logging +logging.set_verbosity_error() +training_args = TrainingArguments(per_device_train_batch_size=4, **default_args) +trainer = Trainer(model=model, args=training_args, train_dataset=ds) +result = trainer.train() +print_summary(result) + +Time: 57.82 +Samples/second: 8.86 +GPU memory occupied: 14949 MB. +We see that already a relatively small batch size almost fills up our GPU's entire memory. However, a larger batch size +can often result in faster model convergence or better end performance. So ideally we want to tune the batch size to our +model's needs and not to the GPU limitations. What's interesting is that we use much more memory than the size of the model. +To understand a bit better why this is the case let's have a look at a model's operations and memory needs. +Anatomy of Model's Operations +Transformers architecture includes 3 main groups of operations grouped below by compute-intensity. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..12d0763085a72534a0d2177780afc23b73cc7cb4 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_7.txt @@ -0,0 +1,8 @@ +Tensor Contractions +Linear layers and components of Multi-Head Attention all do batched matrix-matrix multiplications. These operations are the most compute-intensive part of training a transformer. + +Statistical Normalizations +Softmax and layer normalization are less compute-intensive than tensor contractions, and involve one or more reduction operations, the result of which is then applied via a map. + +Element-wise Operators +These are the remaining operators: biases, dropout, activations, and residual connections. These are the least compute-intensive operations. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..ce2a69938ce851ed555be54f019c4254525c85cf --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_8.txt @@ -0,0 +1,18 @@ +This knowledge can be helpful to know when analyzing performance bottlenecks. +This summary is derived from Data Movement Is All You Need: A Case Study on Optimizing Transformers 2020 +Anatomy of Model's Memory +We've seen that training the model uses much more memory than just putting the model on the GPU. This is because there +are many components during training that use GPU memory. The components on GPU memory are the following: + +model weights +optimizer states +gradients +forward activations saved for gradient computation +temporary buffers +functionality-specific memory + +A typical model trained in mixed precision with AdamW requires 18 bytes per model parameter plus activation memory. For +inference there are no optimizer states and gradients, so we can subtract those. And thus we end up with 6 bytes per +model parameter for mixed precision inference, plus activation memory. +Let's look at the details. +Model Weights: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..d6c7aeb092d3f61d0b98091e13b2d944cf94ca52 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_memory_anatomy.txt_chunk_9.txt @@ -0,0 +1,16 @@ +4 bytes * number of parameters for fp32 training +6 bytes * number of parameters for mixed precision training (maintains a model in fp32 and one in fp16 in memory) + +Optimizer States: + +8 bytes * number of parameters for normal AdamW (maintains 2 states) +2 bytes * number of parameters for 8-bit AdamW optimizers like bitsandbytes +4 bytes * number of parameters for optimizers like SGD with momentum (maintains only 1 state) + +Gradients + +4 bytes * number of parameters for either fp32 or mixed precision training (gradients are always kept in fp32) + +Forward Activations + +size depends on many factors, the key ones being sequence length, hidden size and batch size. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..0520b55031a1fbc9de442dfffe647e1cdd58c870 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_0.txt @@ -0,0 +1,8 @@ +Share a model +The last two tutorials showed how you can fine-tune a model with PyTorch, Keras, and 🤗 Accelerate for distributed setups. The next step is to share your model with the community! At Hugging Face, we believe in openly sharing knowledge and resources to democratize artificial intelligence for everyone. We encourage you to consider sharing your model with the community to help others save time and resources. +In this tutorial, you will learn two methods for sharing a trained or fine-tuned model on the Model Hub: + +Programmatically push your files to the Hub. +Drag-and-drop your files to the Hub with the web interface. + +To share a model with the community, you need an account on huggingface.co. You can also join an existing organization or create a new one. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..435b1ae7e3c91f1c90b3d01674206c3f3d8b0623 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_1.txt @@ -0,0 +1,10 @@ +Repository features +Each repository on the Model Hub behaves like a typical GitHub repository. Our repositories offer versioning, commit history, and the ability to visualize differences. +The Model Hub's built-in versioning is based on git and git-lfs. In other words, you can treat one model as one repository, enabling greater access control and scalability. Version control allows revisions, a method for pinning a specific version of a model with a commit hash, tag or branch. +As a result, you can load a specific model version with the revision parameter: + +model = AutoModel.from_pretrained( + "julien-c/EsperBERTo-small", revision="v2.0.1" # tag name, or branch name, or commit hash + ) + +Files are also easily edited in a repository, and you can view the commit history as well as the difference: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..382480221bf0a902ad1db770e0255dd9e73f6456 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_2.txt @@ -0,0 +1,11 @@ +Setup +Before sharing a model to the Hub, you will need your Hugging Face credentials. If you have access to a terminal, run the following command in the virtual environment where 🤗 Transformers is installed. This will store your access token in your Hugging Face cache folder (~/.cache/ by default): + +huggingface-cli login +If you are using a notebook like Jupyter or Colaboratory, make sure you have the huggingface_hub library installed. This library allows you to programmatically interact with the Hub. + +pip install huggingface_hub +Then use notebook_login to sign-in to the Hub, and follow the link here to generate a token to login with: + +from huggingface_hub import notebook_login +notebook_login() \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..bf266981e953c801aa0f518273306d0e580c760c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_3.txt @@ -0,0 +1,8 @@ +from huggingface_hub import notebook_login +notebook_login() + +Convert a model for all frameworks +To ensure your model can be used by someone working with a different framework, we recommend you convert and upload your model with both PyTorch and TensorFlow checkpoints. While users are still able to load your model from a different framework if you skip this step, it will be slower because 🤗 Transformers will need to convert the checkpoint on-the-fly. +Converting a checkpoint for another framework is easy. Make sure you have PyTorch and TensorFlow installed (see here for installation instructions), and then find the specific model for your task in the other framework. + +Specify from_tf=True to convert a checkpoint from TensorFlow to PyTorch: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..edb19056596da59101ec7bd2b75f8e26e93d2738 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_4.txt @@ -0,0 +1,22 @@ +Specify from_tf=True to convert a checkpoint from TensorFlow to PyTorch: + +pt_model = DistilBertForSequenceClassification.from_pretrained("path/to/awesome-name-you-picked", from_tf=True) +pt_model.save_pretrained("path/to/awesome-name-you-picked") +`` + + +Specifyfrom_pt=True` to convert a checkpoint from PyTorch to TensorFlow: + +tf_model = TFDistilBertForSequenceClassification.from_pretrained("path/to/awesome-name-you-picked", from_pt=True) + +Then you can save your new TensorFlow model with its new checkpoint: + +tf_model.save_pretrained("path/to/awesome-name-you-picked") + +If a model is available in Flax, you can also convert a checkpoint from PyTorch to Flax: + +flax_model = FlaxDistilBertForSequenceClassification.from_pretrained( + "path/to/awesome-name-you-picked", from_pt=True + ) + +Push a model during training \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..ff7c99e4734e9e0fd57b5e52fd4261e0801b9045 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_5.txt @@ -0,0 +1,17 @@ +Push a model during training + +Sharing a model to the Hub is as simple as adding an extra parameter or callback. Remember from the fine-tuning tutorial, the [TrainingArguments] class is where you specify hyperparameters and additional training options. One of these training options includes the ability to push a model directly to the Hub. Set push_to_hub=True in your [TrainingArguments]: + +training_args = TrainingArguments(output_dir="my-awesome-model", push_to_hub=True) + +Pass your training arguments as usual to [Trainer]: + +trainer = Trainer( + model=model, + args=training_args, + train_dataset=small_train_dataset, + eval_dataset=small_eval_dataset, + compute_metrics=compute_metrics, + ) + +After you fine-tune your model, call [~transformers.Trainer.push_to_hub] on [Trainer] to push the trained model to the Hub. 🤗 Transformers will even automatically add training hyperparameters, training results and framework versions to your model card! \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..799e5561f024e7c7097731e94802d148b902a673 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_6.txt @@ -0,0 +1,26 @@ +trainer.push_to_hub() +`` + + +Share a model to the Hub with [PushToHubCallback]. In the [PushToHubCallback`] function, add: + +An output directory for your model. +A tokenizer. +The hub_model_id, which is your Hub username and model name. + +from transformers import PushToHubCallback +push_to_hub_callback = PushToHubCallback( + output_dir="./your_model_save_path", tokenizer=tokenizer, hub_model_id="your-username/my-awesome-model" + ) + +Add the callback to fit, and 🤗 Transformers will push the trained model to the Hub: + +model.fit(tf_train_dataset, validation_data=tf_validation_dataset, epochs=3, callbacks=push_to_hub_callback) + +Use the push_to_hub function +You can also call push_to_hub directly on your model to upload it to the Hub. +Specify your model name in push_to_hub: + +pt_model.push_to_hub("my-awesome-model") + +This creates a repository under your username with the model name my-awesome-model. Users can now load your model with the from_pretrained function: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..7a11d4dfc90524f5841de681ee5e3cce7abaadcb --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_7.txt @@ -0,0 +1,14 @@ +from transformers import AutoModel +model = AutoModel.from_pretrained("your_username/my-awesome-model") + +If you belong to an organization and want to push your model under the organization name instead, just add it to the repo_id: + +pt_model.push_to_hub("my-awesome-org/my-awesome-model") + +The push_to_hub function can also be used to add other files to a model repository. For example, add a tokenizer to a model repository: + +tokenizer.push_to_hub("my-awesome-model") + +Or perhaps you'd like to add the TensorFlow version of your fine-tuned PyTorch model: + +tf_model.push_to_hub("my-awesome-model") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..5e434d9306e2beb9a2ca5689018284ad06dbfa7f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_8.txt @@ -0,0 +1,15 @@ +tf_model.push_to_hub("my-awesome-model") + +Now when you navigate to your Hugging Face profile, you should see your newly created model repository. Clicking on the Files tab will display all the files you've uploaded to the repository. +For more details on how to create and upload files to a repository, refer to the Hub documentation here. +Upload with the web interface +Users who prefer a no-code approach are able to upload a model through the Hub's web interface. Visit huggingface.co/new to create a new repository: + +From here, add some information about your model: + +Select the owner of the repository. This can be yourself or any of the organizations you belong to. +Pick a name for your model, which will also be the repository name. +Choose whether your model is public or private. +Specify the license usage for your model. + +Now click on the Files tab and click on the Add file button to upload a new file to your repository. Then drag-and-drop a file to upload and add a commit message. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..8598f9c0299952e661da2fe5dfda7af5601008e5 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_sharing.txt_chunk_9.txt @@ -0,0 +1,7 @@ +Add a model card +To make sure users understand your model's capabilities, limitations, potential biases and ethical considerations, please add a model card to your repository. The model card is defined in the README.md file. You can add a model card by: + +Manually creating and uploading a README.md file. +Clicking on the Edit model card button in your model repository. + +Take a look at the DistilBert model card for a good example of the type of information a model card should include. For more details about other options you can control in the README.md file such as a model's carbon footprint or widget examples, refer to the documentation here. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..f23f0fa791794ed4974aa1e4f33b176a6c152262 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_0.txt @@ -0,0 +1,3 @@ +The Transformer model family +Since its introduction in 2017, the original Transformer model (see the Annotated Transformer blog post for a gentle technical introduction) has inspired many new and exciting models that extend beyond natural language processing (NLP) tasks. There are models for predicting the folded structure of proteins, training a cheetah to run, and time series forecasting. With so many Transformer variants available, it can be easy to miss the bigger picture. What all these models have in common is they're based on the original Transformer architecture. Some models only use the encoder or decoder, while others use both. This provides a useful taxonomy to categorize and examine the high-level differences within models in the Transformer family, and it'll help you understand Transformers you haven't encountered before. +If you aren't familiar with the original Transformer model or need a refresher, check out the How do Transformers work chapter from the Hugging Face course. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..43ffa4ebc43d944ba96367841a224fcade327484 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_1.txt @@ -0,0 +1 @@ +Computer vision \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..bdf69347b299c791e0a2c6b332cd893ff7f071ca --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_2.txt @@ -0,0 +1,11 @@ +Convolutional network +For a long time, convolutional networks (CNNs) were the dominant paradigm for computer vision tasks until the Vision Transformer demonstrated its scalability and efficiency. Even then, some of a CNN's best qualities, like translation invariance, are so powerful (especially for certain tasks) that some Transformers incorporate convolutions in their architecture. ConvNeXt flipped this exchange around and incorporated design choices from Transformers to modernize a CNN. For example, ConvNeXt uses non-overlapping sliding windows to patchify an image and a larger kernel to increase its global receptive field. ConvNeXt also makes several layer design choices to be more memory-efficient and improve performance, so it competes favorably with Transformers! +Encoder[[cv-encoder]] +The Vision Transformer (ViT) opened the door to computer vision tasks without convolutions. ViT uses a standard Transformer encoder, but its main breakthrough was how it treated an image. It splits an image into fixed-size patches and uses them to create an embedding, just like how a sentence is split into tokens. ViT capitalized on the Transformers' efficient architecture to demonstrate competitive results with the CNNs at the time while requiring fewer resources to train. ViT was soon followed by other vision models that could also handle dense vision tasks like segmentation as well as detection. +One of these models is the Swin Transformer. It builds hierarchical feature maps (like a CNN 👀 and unlike ViT) from smaller-sized patches and merges them with neighboring patches in deeper layers. Attention is only computed within a local window, and the window is shifted between attention layers to create connections to help the model learn better. Since the Swin Transformer can produce hierarchical feature maps, it is a good candidate for dense prediction tasks like segmentation and detection. The SegFormer also uses a Transformer encoder to build hierarchical feature maps, but it adds a simple multilayer perceptron (MLP) decoder on top to combine all the feature maps and make a prediction. +Other vision models, like BeIT and ViTMAE, drew inspiration from BERT's pretraining objective. BeIT is pretrained by masked image modeling (MIM); the image patches are randomly masked, and the image is also tokenized into visual tokens. BeIT is trained to predict the visual tokens corresponding to the masked patches. ViTMAE has a similar pretraining objective, except it must predict the pixels instead of visual tokens. What's unusual is 75% of the image patches are masked! The decoder reconstructs the pixels from the masked tokens and encoded patches. After pretraining, the decoder is thrown away, and the encoder is ready to be used in downstream tasks. +Decoder[[cv-decoder]] +Decoder-only vision models are rare because most vision models rely on an encoder to learn an image representation. But for use cases like image generation, the decoder is a natural fit, as we've seen from text generation models like GPT-2. ImageGPT uses the same architecture as GPT-2, but instead of predicting the next token in a sequence, it predicts the next pixel in an image. In addition to image generation, ImageGPT could also be finetuned for image classification. +Encoder-decoder[[cv-encoder-decoder]] +Vision models commonly use an encoder (also known as a backbone) to extract important image features before passing them to a Transformer decoder. DETR has a pretrained backbone, but it also uses the complete Transformer encoder-decoder architecture for object detection. The encoder learns image representations and combines them with object queries (each object query is a learned embedding that focuses on a region or object in an image) in the decoder. DETR predicts the bounding box coordinates and class label for each object query. +Natural language processing \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..eaa7831319b5f0db38043c15dc7739d9fa9ba527 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_3.txt @@ -0,0 +1,10 @@ +Encoder[[nlp-encoder]] +BERT is an encoder-only Transformer that randomly masks certain tokens in the input to avoid seeing other tokens, which would allow it to "cheat". The pretraining objective is to predict the masked token based on the context. This allows BERT to fully use the left and right contexts to help it learn a deeper and richer representation of the inputs. However, there was still room for improvement in BERT's pretraining strategy. RoBERTa improved upon this by introducing a new pretraining recipe that includes training for longer and on larger batches, randomly masking tokens at each epoch instead of just once during preprocessing, and removing the next-sentence prediction objective. +The dominant strategy to improve performance is to increase the model size. But training large models is computationally expensive. One way to reduce computational costs is using a smaller model like DistilBERT. DistilBERT uses knowledge distillation - a compression technique - to create a smaller version of BERT while keeping nearly all of its language understanding capabilities. +However, most Transformer models continued to trend towards more parameters, leading to new models focused on improving training efficiency. ALBERT reduces memory consumption by lowering the number of parameters in two ways: separating the larger vocabulary embedding into two smaller matrices and allowing layers to share parameters. DeBERTa added a disentangled attention mechanism where the word and its position are separately encoded in two vectors. The attention is computed from these separate vectors instead of a single vector containing the word and position embeddings. Longformer also focused on making attention more efficient, especially for processing documents with longer sequence lengths. It uses a combination of local windowed attention (attention only calculated from fixed window size around each token) and global attention (only for specific task tokens like [CLS] for classification) to create a sparse attention matrix instead of a full attention matrix. +Decoder[[nlp-decoder]] +GPT-2 is a decoder-only Transformer that predicts the next word in the sequence. It masks tokens to the right so the model can't "cheat" by looking ahead. By pretraining on a massive body of text, GPT-2 became really good at generating text, even if the text is only sometimes accurate or true. But GPT-2 lacked the bidirectional context from BERT's pretraining, which made it unsuitable for certain tasks. XLNET combines the best of both BERT and GPT-2's pretraining objectives by using a permutation language modeling objective (PLM) that allows it to learn bidirectionally. +After GPT-2, language models grew even bigger and are now known as large language models (LLMs). LLMs demonstrate few- or even zero-shot learning if pretrained on a large enough dataset. GPT-J is an LLM with 6B parameters and trained on 400B tokens. GPT-J was followed by OPT, a family of decoder-only models, the largest of which is 175B and trained on 180B tokens. BLOOM was released around the same time, and the largest model in the family has 176B parameters and is trained on 366B tokens in 46 languages and 13 programming languages. +Encoder-decoder[[nlp-encoder-decoder]] +BART keeps the original Transformer architecture, but it modifies the pretraining objective with text infilling corruption, where some text spans are replaced with a single mask token. The decoder predicts the uncorrupted tokens (future tokens are masked) and uses the encoder's hidden states to help it. Pegasus is similar to BART, but Pegasus masks entire sentences instead of text spans. In addition to masked language modeling, Pegasus is pretrained by gap sentence generation (GSG). The GSG objective masks whole sentences important to a document, replacing them with a mask token. The decoder must generate the output from the remaining sentences. T5 is a more unique model that casts all NLP tasks into a text-to-text problem using specific prefixes. For example, the prefix Summarize: indicates a summarization task. T5 is pretrained by supervised (GLUE and SuperGLUE) training and self-supervised training (randomly sample and drop out 15% of tokens). +Audio \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..246f3acfd40a721b54b7d354f8dad610eab8849d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_4.txt @@ -0,0 +1,5 @@ +Encoder[[audio-encoder]] +Wav2Vec2 uses a Transformer encoder to learn speech representations directly from raw audio waveforms. It is pretrained with a contrastive task to determine the true speech representation from a set of false ones. HuBERT is similar to Wav2Vec2 but has a different training process. Target labels are created by a clustering step in which segments of similar audio are assigned to a cluster which becomes a hidden unit. The hidden unit is mapped to an embedding to make a prediction. +Encoder-decoder[[audio-encoder-decoder]] +Speech2Text is a speech model designed for automatic speech recognition (ASR) and speech translation. The model accepts log mel-filter bank features extracted from the audio waveform and pretrained autoregressively to generate a transcript or translation. Whisper is also an ASR model, but unlike many other speech models, it is pretrained on a massive amount of ✨ labeled ✨ audio transcription data for zero-shot performance. A large chunk of the dataset also contains non-English languages, meaning Whisper can also be used for low-resource languages. Structurally, Whisper is similar to Speech2Text. The audio signal is converted to a log-mel spectrogram encoded by the encoder. The decoder generates the transcript autoregressively from the encoder's hidden states and the previous tokens. +Multimodal \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..669ff160c87f053b9bd2014eea399688c52637cb --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_5.txt @@ -0,0 +1,6 @@ +Encoder[[mm-encoder]] +VisualBERT is a multimodal model for vision-language tasks released shortly after BERT. It combines BERT and a pretrained object detection system to extract image features into visual embeddings, passed alongside text embeddings to BERT. VisualBERT predicts the masked text based on the unmasked text and the visual embeddings, and it also has to predict whether the text is aligned with the image. When ViT was released, ViLT adopted ViT in its architecture because it was easier to get the image embeddings this way. The image embeddings are jointly processed with the text embeddings. From there, ViLT is pretrained by image text matching, masked language modeling, and whole word masking. +CLIP takes a different approach and makes a pair prediction of (image, text) . An image encoder (ViT) and a text encoder (Transformer) are jointly trained on a 400 million (image, text) pair dataset to maximize the similarity between the image and text embeddings of the (image, text) pairs. After pretraining, you can use natural language to instruct CLIP to predict the text given an image or vice versa. OWL-ViT builds on top of CLIP by using it as its backbone for zero-shot object detection. After pretraining, an object detection head is added to make a set prediction over the (class, bounding box) pairs. +Encoder-decoder[[mm-encoder-decoder]] +Optical character recognition (OCR) is a long-standing text recognition task that typically involves several components to understand the image and generate the text. TrOCR simplifies the process using an end-to-end Transformer. The encoder is a ViT-style model for image understanding and processes the image as fixed-size patches. The decoder accepts the encoder's hidden states and autoregressively generates text. Donut is a more general visual document understanding model that doesn't rely on OCR-based approaches. It uses a Swin Transformer as the encoder and multilingual BART as the decoder. Donut is pretrained to read text by predicting the next word based on the image and text annotations. The decoder generates a token sequence given a prompt. The prompt is represented by a special token for each downstream task. For example, document parsing has a special parsing token that is combined with the encoder hidden states to parse the document into a structured output format (JSON). +Reinforcement learning \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..a20ad9ed9b0732a11344edeb865119e3c4d7662e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_model_summary.txt_chunk_6.txt @@ -0,0 +1,2 @@ +Decoder[[rl-decoder]] +The Decision and Trajectory Transformer casts the state, action, and reward as a sequence modeling problem. The Decision Transformer generates a series of actions that lead to a future desired return based on returns-to-go, past states, and actions. For the last K timesteps, each of the three modalities are converted into token embeddings and processed by a GPT-like model to predict a future action token. Trajectory Transformer also tokenizes the states, actions, and rewards and processes them with a GPT architecture. Unlike the Decision Transformer, which is focused on reward conditioning, the Trajectory Transformer generates future actions with beam search. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..367598457b9ce8f2da951b7606a02baa4c6ab2b2 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_0.txt @@ -0,0 +1,7 @@ +Multilingual models for inference +[[open-in-colab]] +There are several multilingual models in 🤗 Transformers, and their inference usage differs from monolingual models. Not all multilingual model usage is different though. Some models, like google-bert/bert-base-multilingual-uncased, can be used just like a monolingual model. This guide will show you how to use multilingual models whose usage differs for inference. +XLM +XLM has ten different checkpoints, only one of which is monolingual. The nine remaining model checkpoints can be split into two categories: the checkpoints that use language embeddings and those that don't. +XLM with language embeddings +The following XLM models use language embeddings to specify the language used at inference: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..7498b2927b7c07366a4177d5fb9ee838c5602697 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_1.txt @@ -0,0 +1,10 @@ +FacebookAI/xlm-mlm-ende-1024 (Masked language modeling, English-German) +FacebookAI/xlm-mlm-enfr-1024 (Masked language modeling, English-French) +FacebookAI/xlm-mlm-enro-1024 (Masked language modeling, English-Romanian) +FacebookAI/xlm-mlm-xnli15-1024 (Masked language modeling, XNLI languages) +FacebookAI/xlm-mlm-tlm-xnli15-1024 (Masked language modeling + translation, XNLI languages) +FacebookAI/xlm-clm-enfr-1024 (Causal language modeling, English-French) +FacebookAI/xlm-clm-ende-1024 (Causal language modeling, English-German) + +Language embeddings are represented as a tensor of the same shape as the input_ids passed to the model. The values in these tensors depend on the language used and are identified by the tokenizer's lang2id and id2lang attributes. +In this example, load the FacebookAI/xlm-clm-enfr-1024 checkpoint (Causal language modeling, English-French): \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..4176e1b9d67f69346c6151da922b24249ae05c12 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_2.txt @@ -0,0 +1,20 @@ +import torch +from transformers import XLMTokenizer, XLMWithLMHeadModel +tokenizer = XLMTokenizer.from_pretrained("FacebookAI/xlm-clm-enfr-1024") +model = XLMWithLMHeadModel.from_pretrained("FacebookAI/xlm-clm-enfr-1024") + +The lang2id attribute of the tokenizer displays this model's languages and their ids: + +print(tokenizer.lang2id) +{'en': 0, 'fr': 1} + +Next, create an example input: + +input_ids = torch.tensor([tokenizer.encode("Wikipedia was used to")]) # batch size of 1 + +Set the language id as "en" and use it to define the language embedding. The language embedding is a tensor filled with 0 since that is the language id for English. This tensor should be the same size as input_ids. + +language_id = tokenizer.lang2id["en"] # 0 +langs = torch.tensor([language_id] * input_ids.shape[1]) # torch.tensor([0, 0, 0, , 0]) +We reshape it to be of size (batch_size, sequence_length) +langs = langs.view(1, -1) # is now of shape [1, sequence_length] (we have a batch size of 1) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..b665969ed97be971d87b518a3cb15e30457b8e9d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_3.txt @@ -0,0 +1,17 @@ +Now you can pass the input_ids and language embedding to the model: + +outputs = model(input_ids, langs=langs) + +The run_generation.py script can generate text with language embeddings using the xlm-clm checkpoints. +XLM without language embeddings +The following XLM models do not require language embeddings during inference: + +FacebookAI/xlm-mlm-17-1280 (Masked language modeling, 17 languages) +FacebookAI/xlm-mlm-100-1280 (Masked language modeling, 100 languages) + +These models are used for generic sentence representations, unlike the previous XLM checkpoints. +BERT +The following BERT models can be used for multilingual tasks: + +google-bert/bert-base-multilingual-uncased (Masked language modeling + Next sentence prediction, 102 languages) +google-bert/bert-base-multilingual-cased (Masked language modeling + Next sentence prediction, 104 languages) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..1c29b7ded79eac49abf96140bc568b4ad893ddda --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_4.txt @@ -0,0 +1,16 @@ +These models do not require language embeddings during inference. They should identify the language from the +context and infer accordingly. +XLM-RoBERTa +The following XLM-RoBERTa models can be used for multilingual tasks: + +FacebookAI/xlm-roberta-base (Masked language modeling, 100 languages) +FacebookAI/xlm-roberta-large (Masked language modeling, 100 languages) + +XLM-RoBERTa was trained on 2.5TB of newly created and cleaned CommonCrawl data in 100 languages. It provides strong gains over previously released multilingual models like mBERT or XLM on downstream tasks like classification, sequence labeling, and question answering. +M2M100 +The following M2M100 models can be used for multilingual translation: + +facebook/m2m100_418M (Translation) +facebook/m2m100_1.2B (Translation) + +In this example, load the facebook/m2m100_418M checkpoint to translate from Chinese to English. You can set the source language in the tokenizer: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..4d2990fa40d2460b1e6f352901c9efc03eb133ba --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_5.txt @@ -0,0 +1,18 @@ +from transformers import M2M100ForConditionalGeneration, M2M100Tokenizer +en_text = "Do not meddle in the affairs of wizards, for they are subtle and quick to anger." +chinese_text = "ä¸è¦æ’手巫師的事務, 因為他們是微妙的, 很快就會發怒." +tokenizer = M2M100Tokenizer.from_pretrained("facebook/m2m100_418M", src_lang="zh") +model = M2M100ForConditionalGeneration.from_pretrained("facebook/m2m100_418M") + +Tokenize the text: + +encoded_zh = tokenizer(chinese_text, return_tensors="pt") + +M2M100 forces the target language id as the first generated token to translate to the target language. Set the forced_bos_token_id to en in the generate method to translate to English: + +generated_tokens = model.generate(**encoded_zh, forced_bos_token_id=tokenizer.get_lang_id("en")) +tokenizer.batch_decode(generated_tokens, skip_special_tokens=True) +'Do not interfere with the matters of the witches, because they are delicate and will soon be angry.' + +MBart +The following MBart models can be used for multilingual translation: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..d6a0c0a47369dfb40bfc1d6fcab59162b170ea7a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_6.txt @@ -0,0 +1,10 @@ +MBart +The following MBart models can be used for multilingual translation: + +facebook/mbart-large-50-one-to-many-mmt (One-to-many multilingual machine translation, 50 languages) +facebook/mbart-large-50-many-to-many-mmt (Many-to-many multilingual machine translation, 50 languages) +facebook/mbart-large-50-many-to-one-mmt (Many-to-one multilingual machine translation, 50 languages) +facebook/mbart-large-50 (Multilingual translation, 50 languages) +facebook/mbart-large-cc25 + +In this example, load the facebook/mbart-large-50-many-to-many-mmt checkpoint to translate Finnish to English. You can set the source language in the tokenizer: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..facfb76d992c8420a286b14aa0391a2c2b36e8ed --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_7.txt @@ -0,0 +1,15 @@ +from transformers import AutoTokenizer, AutoModelForSeq2SeqLM +en_text = "Do not meddle in the affairs of wizards, for they are subtle and quick to anger." +fi_text = "Älä sekaannu velhojen asioihin, sillä ne ovat hienovaraisia ja nopeasti vihaisia." +tokenizer = AutoTokenizer.from_pretrained("facebook/mbart-large-50-many-to-many-mmt", src_lang="fi_FI") +model = AutoModelForSeq2SeqLM.from_pretrained("facebook/mbart-large-50-many-to-many-mmt") + +Tokenize the text: + +encoded_en = tokenizer(en_text, return_tensors="pt") + +MBart forces the target language id as the first generated token to translate to the target language. Set the forced_bos_token_id to en in the generate method to translate to English: + +generated_tokens = model.generate(**encoded_en, forced_bos_token_id=tokenizer.lang_code_to_id["en_XX"]) +tokenizer.batch_decode(generated_tokens, skip_special_tokens=True) +"Don't interfere with the wizard's affairs, because they are subtle, will soon get angry." \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..ca4ca1ddefff73060cf178a4bf86b3ac17905118 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_multilingual.txt_chunk_8.txt @@ -0,0 +1 @@ +If you are using the facebook/mbart-large-50-many-to-one-mmt checkpoint, you don't need to force the target language id as the first generated token otherwise the usage is the same. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_notebooks.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_notebooks.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..504f04ccbe55506269bfdf8ef52e645c1fe26e15 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_notebooks.txt_chunk_0.txt @@ -0,0 +1,102 @@ +🤗 Transformers Notebooks +You can find here a list of the official notebooks provided by Hugging Face. +Also, we would like to list here interesting content created by the community. +If you wrote some notebook(s) leveraging 🤗 Transformers and would like to be listed here, please open a +Pull Request so it can be included under the Community notebooks. +Hugging Face's notebooks 🤗 +Documentation notebooks +You can open any page of the documentation as a notebook in Colab (there is a button directly on said pages) but they are also listed here if you need them: +| Notebook | Description | | | +|:----------|:-------------|:-------------|------:| +| Quicktour of the library | A presentation of the various APIs in Transformers || | +| Summary of the tasks | How to run the models of the Transformers library task by task || | +| Preprocessing data | How to use a tokenizer to preprocess your data || | +| Fine-tuning a pretrained model | How to use the Trainer to fine-tune a pretrained model || | +| Summary of the tokenizers | The differences between the tokenizers algorithm || | +| Multilingual models | How to use the multilingual models of the library || | +PyTorch Examples +Natural Language Processing[[pytorch-nlp]] +| Notebook | Description | | | +|:----------|:-------------|:-------------|------:| +| Train your tokenizer | How to train and use your very own tokenizer || | +| Train your language model | How to easily start using transformers || | +| How to fine-tune a model on text classification| Show how to preprocess the data and fine-tune a pretrained model on any GLUE task. | | | +| How to fine-tune a model on language modeling| Show how to preprocess the data and fine-tune a pretrained model on a causal or masked LM task. | | | +| How to fine-tune a model on token classification| Show how to preprocess the data and fine-tune a pretrained model on a token classification task (NER, PoS). | | | +| How to fine-tune a model on question answering| Show how to preprocess the data and fine-tune a pretrained model on SQUAD. | | | +| How to fine-tune a model on multiple choice| Show how to preprocess the data and fine-tune a pretrained model on SWAG. | | | +| How to fine-tune a model on translation| Show how to preprocess the data and fine-tune a pretrained model on WMT. | | | +| How to fine-tune a model on summarization| Show how to preprocess the data and fine-tune a pretrained model on XSUM. | | | +| How to train a language model from scratch| Highlight all the steps to effectively train Transformer model on custom data | | | +| How to generate text| How to use different decoding methods for language generation with transformers | | | +| How to generate text (with constraints)| How to guide language generation with user-provided constraints | | | +| Reformer| How Reformer pushes the limits of language modeling | | | +Computer Vision[[pytorch-cv]] +| Notebook | Description | | | +|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------:| +| How to fine-tune a model on image classification (Torchvision) | Show how to preprocess the data using Torchvision and fine-tune any pretrained Vision model on Image Classification | | | +| How to fine-tune a model on image classification (Albumentations) | Show how to preprocess the data using Albumentations and fine-tune any pretrained Vision model on Image Classification | | | +| How to fine-tune a model on image classification (Kornia) | Show how to preprocess the data using Kornia and fine-tune any pretrained Vision model on Image Classification | | | +| How to perform zero-shot object detection with OWL-ViT | Show how to perform zero-shot object detection on images with text queries | | | +| How to fine-tune an image captioning model | Show how to fine-tune BLIP for image captioning on a custom dataset | | | +| How to build an image similarity system with Transformers | Show how to build an image similarity system | | | +| How to fine-tune a SegFormer model on semantic segmentation | Show how to preprocess the data and fine-tune a pretrained SegFormer model on Semantic Segmentation | | | +| How to fine-tune a VideoMAE model on video classification | Show how to preprocess the data and fine-tune a pretrained VideoMAE model on Video Classification | | | +Audio[[pytorch-audio]] +| Notebook | Description | | | +|:----------|:-------------|:-------------|------:| +| How to fine-tune a speech recognition model in English| Show how to preprocess the data and fine-tune a pretrained Speech model on TIMIT | | | +| How to fine-tune a speech recognition model in any language| Show how to preprocess the data and fine-tune a multi-lingually pretrained speech model on Common Voice | | | +| How to fine-tune a model on audio classification| Show how to preprocess the data and fine-tune a pretrained Speech model on Keyword Spotting | | | +Biological Sequences[[pytorch-bio]] +| Notebook | Description | | | +|:----------|:----------------------------------------------------------------------------------------|:-------------|------:| +| How to fine-tune a pre-trained protein model | See how to tokenize proteins and fine-tune a large pre-trained protein "language" model | | | +| How to generate protein folds | See how to go from protein sequence to a full protein model and PDB file | | | +| How to fine-tune a Nucleotide Transformer model | See how to tokenize DNA and fine-tune a large pre-trained DNA "language" model | | | +| Fine-tune a Nucleotide Transformer model with LoRA | Train even larger DNA models in a memory-efficient way | | | +Other modalities[[pytorch-other]] +| Notebook | Description | | | +|:----------|:----------------------------------------------------------------------------------------|:-------------|------:| +| Probabilistic Time Series Forecasting | See how to train Time Series Transformer on a custom dataset | | | +Utility notebooks[[pytorch-utility]] +| Notebook | Description | | | +|:----------|:-------------|:-------------|------:| +| How to export model to ONNX| Highlight how to export and run inference workloads through ONNX | | | +| How to use Benchmarks| How to benchmark models with transformers | | | +TensorFlow Examples +Natural Language Processing[[tensorflow-nlp]] +| Notebook | Description | | | +|:----------|:-------------|:-------------|------:| +| Train your tokenizer | How to train and use your very own tokenizer || | +| Train your language model | How to easily start using transformers || | +| How to fine-tune a model on text classification| Show how to preprocess the data and fine-tune a pretrained model on any GLUE task. | | | +| How to fine-tune a model on language modeling| Show how to preprocess the data and fine-tune a pretrained model on a causal or masked LM task. | | | +| How to fine-tune a model on token classification| Show how to preprocess the data and fine-tune a pretrained model on a token classification task (NER, PoS). | | | +| How to fine-tune a model on question answering| Show how to preprocess the data and fine-tune a pretrained model on SQUAD. | | | +| How to fine-tune a model on multiple choice| Show how to preprocess the data and fine-tune a pretrained model on SWAG. | | | +| How to fine-tune a model on translation| Show how to preprocess the data and fine-tune a pretrained model on WMT. | | | +| How to fine-tune a model on summarization| Show how to preprocess the data and fine-tune a pretrained model on XSUM. | | | +Computer Vision[[tensorflow-cv]] +| Notebook | Description | | | +|:---------------------------------------------------------------------------------------------------------------------------------------------------------|:----------------------------------------------------------------------------------------------------|:-------------|------:| +| How to fine-tune a model on image classification | Show how to preprocess the data and fine-tune any pretrained Vision model on Image Classification | | | +| How to fine-tune a SegFormer model on semantic segmentation | Show how to preprocess the data and fine-tune a pretrained SegFormer model on Semantic Segmentation | | | +Biological Sequences[[tensorflow-bio]] +| Notebook | Description | | | +|:----------|:-------------|:-------------|------:| +| How to fine-tune a pre-trained protein model | See how to tokenize proteins and fine-tune a large pre-trained protein "language" model | | | +Utility notebooks[[tensorflow-utility]] +| Notebook | Description | | | +|:----------|:-------------|:-------------|------:| +| How to train TF/Keras models on TPU | See how to train at high speed on Google's TPU hardware | | | +Optimum notebooks +🤗 Optimum is an extension of 🤗 Transformers, providing a set of performance optimization tools enabling maximum efficiency to train and run models on targeted hardwares. +| Notebook | Description | | | +|:----------|:-------------|:-------------|------:| +| How to quantize a model with ONNX Runtime for text classification| Show how to apply static and dynamic quantization on a model using ONNX Runtime for any GLUE task. | | | +| How to quantize a model with Intel Neural Compressor for text classification| Show how to apply static, dynamic and aware training quantization on a model using Intel Neural Compressor (INC) for any GLUE task. | | | +| How to fine-tune a model on text classification with ONNX Runtime| Show how to preprocess the data and fine-tune a model on any GLUE task using ONNX Runtime. | | | +| How to fine-tune a model on summarization with ONNX Runtime| Show how to preprocess the data and fine-tune a model on XSUM using ONNX Runtime. | | | +Community notebooks: +More notebooks developed by the community are available here. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_pad_truncation.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_pad_truncation.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..c2fdb0444d477c8ca7aa30ac91c5ff1adb71c2a8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_pad_truncation.txt_chunk_0.txt @@ -0,0 +1,4 @@ +Padding and truncation +Batched inputs are often different lengths, so they can't be converted to fixed-size tensors. Padding and truncation are strategies for dealing with this problem, to create rectangular tensors from batches of varying lengths. Padding adds a special padding token to ensure shorter sequences will have the same length as either the longest sequence in a batch or the maximum length accepted by the model. Truncation works in the other direction by truncating long sequences. +In most cases, padding your batch to the length of the longest sequence and truncating to the maximum length a model can accept works pretty well. However, the API supports more strategies if you need them. The three arguments you need to are: padding, truncation and max_length. +The padding argument controls padding. It can be a boolean or a string: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_pad_truncation.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_pad_truncation.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..92388069802581ca3f3049fb9d07f3e859b64875 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_pad_truncation.txt_chunk_1.txt @@ -0,0 +1,7 @@ +True or 'longest': pad to the longest sequence in the batch (no padding is applied if you only provide + a single sequence). +'max_length': pad to a length specified by the max_length argument or the maximum length accepted + by the model if no max_length is provided (max_length=None). Padding will still be applied if you only provide a single sequence. +False or 'do_not_pad': no padding is applied. This is the default behavior. + +The truncation argument controls truncation. It can be a boolean or a string: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_pad_truncation.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_pad_truncation.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..1bda640047fd22c3afe29435cac50c4b8c91491c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_pad_truncation.txt_chunk_2.txt @@ -0,0 +1,11 @@ +True or 'longest_first': truncate to a maximum length specified by the max_length argument or + the maximum length accepted by the model if no max_length is provided (max_length=None). This will + truncate token by token, removing a token from the longest sequence in the pair until the proper length is + reached. +'only_second': truncate to a maximum length specified by the max_length argument or the maximum + length accepted by the model if no max_length is provided (max_length=None). This will only truncate + the second sentence of a pair if a pair of sequences (or a batch of pairs of sequences) is provided. +'only_first': truncate to a maximum length specified by the max_length argument or the maximum + length accepted by the model if no max_length is provided (max_length=None). This will only truncate + the first sentence of a pair if a pair of sequences (or a batch of pairs of sequences) is provided. +False or 'do_not_truncate': no truncation is applied. This is the default behavior. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_pad_truncation.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_pad_truncation.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..f26429e78be0a4a35e3b1b147f2fa0c644164eba --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_pad_truncation.txt_chunk_3.txt @@ -0,0 +1,25 @@ +The max_length argument controls the length of the padding and truncation. It can be an integer or None, in which case it will default to the maximum length the model can accept. If the model has no specific maximum input length, truncation or padding to max_length is deactivated. +The following table summarizes the recommended way to setup padding and truncation. If you use pairs of input sequences in any of the following examples, you can replace truncation=True by a STRATEGY selected in +['only_first', 'only_second', 'longest_first'], i.e. truncation='only_second' or truncation='longest_first' to control how both sequences in the pair are truncated as detailed before. +| Truncation | Padding | Instruction | +|--------------------------------------|-----------------------------------|---------------------------------------------------------------------------------------------| +| no truncation | no padding | tokenizer(batch_sentences) | +| | padding to max sequence in batch | tokenizer(batch_sentences, padding=True) or | +| | | tokenizer(batch_sentences, padding='longest') | +| | padding to max model input length | tokenizer(batch_sentences, padding='max_length') | +| | padding to specific length | tokenizer(batch_sentences, padding='max_length', max_length=42) | +| | padding to a multiple of a value | tokenizer(batch_sentences, padding=True, pad_to_multiple_of=8) | +| truncation to max model input length | no padding | tokenizer(batch_sentences, truncation=True) or | +| | | tokenizer(batch_sentences, truncation=STRATEGY) | +| | padding to max sequence in batch | tokenizer(batch_sentences, padding=True, truncation=True) or | +| | | tokenizer(batch_sentences, padding=True, truncation=STRATEGY) | +| | padding to max model input length | tokenizer(batch_sentences, padding='max_length', truncation=True) or | +| | | tokenizer(batch_sentences, padding='max_length', truncation=STRATEGY) | +| | padding to specific length | Not possible | +| truncation to specific length | no padding | tokenizer(batch_sentences, truncation=True, max_length=42) or | +| | | tokenizer(batch_sentences, truncation=STRATEGY, max_length=42) | +| | padding to max sequence in batch | tokenizer(batch_sentences, padding=True, truncation=True, max_length=42) or | +| | | tokenizer(batch_sentences, padding=True, truncation=STRATEGY, max_length=42) | +| | padding to max model input length | Not possible | +| | padding to specific length | tokenizer(batch_sentences, padding='max_length', truncation=True, max_length=42) or | +| | | tokenizer(batch_sentences, padding='max_length', truncation=STRATEGY, max_length=42) | \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..ad17b78e6df4b8d366aa3054a2d1cf9657f8d3ba --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_0.txt @@ -0,0 +1,9 @@ +Custom hardware for training +The hardware you use to run model training and inference can have a big effect on performance. For a deep dive into GPUs make sure to check out Tim Dettmer's excellent blog post. +Let's have a look at some practical advice for GPU setups. +GPU +When you train bigger models you have essentially three options: + +bigger GPUs +more GPUs +more CPU and NVMe (offloaded to by DeepSpeed-Infinity) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..eaec80bc50e6908f80048e0170400588cfeb4ff1 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_1.txt @@ -0,0 +1,16 @@ +Let's start at the case where you have a single GPU. +Power and Cooling +If you bought an expensive high end GPU make sure you give it the correct power and sufficient cooling. +Power: +Some high end consumer GPU cards have 2 and sometimes 3 PCI-E 8-Pin power sockets. Make sure you have as many independent 12V PCI-E 8-Pin cables plugged into the card as there are sockets. Do not use the 2 splits at one end of the same cable (also known as pigtail cable). That is if you have 2 sockets on the GPU, you want 2 PCI-E 8-Pin cables going from your PSU to the card and not one that has 2 PCI-E 8-Pin connectors at the end! You won't get the full performance out of your card otherwise. +Each PCI-E 8-Pin power cable needs to be plugged into a 12V rail on the PSU side and can supply up to 150W of power. +Some other cards may use a PCI-E 12-Pin connectors, and these can deliver up to 500-600W of power. +Low end cards may use 6-Pin connectors, which supply up to 75W of power. +Additionally you want the high-end PSU that has stable voltage. Some lower quality ones may not give the card the stable voltage it needs to function at its peak. +And of course the PSU needs to have enough unused Watts to power the card. +Cooling: +When a GPU gets overheated it will start throttling down and will not deliver full performance and it can even shutdown if it gets too hot. +It's hard to tell the exact best temperature to strive for when a GPU is heavily loaded, but probably anything under +80C is good, but lower is better - perhaps 70-75C is an excellent range to be in. The throttling down is likely to start at around 84-90C. But other than throttling performance a prolonged very high temperature is likely to reduce the lifespan of a GPU. +Next let's have a look at one of the most important aspects when having multiple GPUs: connectivity. +Multi-GPU Connectivity +If you use multiple GPUs the way cards are inter-connected can have a huge impact on the total training time. If the GPUs are on the same physical node, you can run: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..5769d1bb8d46c9ce7b79c815de2b03371ef43f3c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_2.txt @@ -0,0 +1,23 @@ +nvidia-smi topo -m +and it will tell you how the GPUs are inter-connected. On a machine with dual-GPU and which are connected with NVLink, you will most likely see something like: +GPU0 GPU1 CPU Affinity NUMA Affinity +GPU0 X NV2 0-23 N/A +GPU1 NV2 X 0-23 N/A +on a different machine w/o NVLink we may see: +GPU0 GPU1 CPU Affinity NUMA Affinity +GPU0 X PHB 0-11 N/A +GPU1 PHB X 0-11 N/A +The report includes this legend: +X = Self + SYS = Connection traversing PCIe as well as the SMP interconnect between NUMA nodes (e.g., QPI/UPI) + NODE = Connection traversing PCIe as well as the interconnect between PCIe Host Bridges within a NUMA node + PHB = Connection traversing PCIe as well as a PCIe Host Bridge (typically the CPU) + PXB = Connection traversing multiple PCIe bridges (without traversing the PCIe Host Bridge) + PIX = Connection traversing at most a single PCIe bridge + NV# = Connection traversing a bonded set of # NVLinks +So the first report NV2 tells us the GPUs are interconnected with 2 NVLinks, and the second report PHB we have a typical consumer-level PCIe+Bridge setup. +Check what type of connectivity you have on your setup. Some of these will make the communication between cards faster (e.g. NVLink), others slower (e.g. PHB). +Depending on the type of scalability solution used, the connectivity speed could have a major or a minor impact. If the GPUs need to sync rarely, as in DDP, the impact of a slower connection will be less significant. If the GPUs need to send messages to each other often, as in ZeRO-DP, then faster connectivity becomes super important to achieve faster training. +NVlink +NVLink is a wire-based serial multi-lane near-range communications link developed by Nvidia. +Each new generation provides a faster bandwidth, e.g. here is a quote from Nvidia Ampere GA102 GPU Architecture: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..4cb228f471a43aabd176035ad041ca4da871f685 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_3.txt @@ -0,0 +1,6 @@ +Third-Generation NVLink® +GA102 GPUs utilize NVIDIA’s third-generation NVLink interface, which includes four x4 links, +with each link providing 14.0625 GB/sec bandwidth in each direction between two GPUs. Four +links provide 56.25 GB/sec bandwidth in each direction, and 112.5 GB/sec total bandwidth +between two GPUs. Two RTX 3090 GPUs can be connected together for SLI using NVLink. +(Note that 3-Way and 4-Way SLI configurations are not supported.) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..7a8fac217be8c361d231fe60f7152b9c8dc255e1 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_4.txt @@ -0,0 +1,22 @@ +So the higher X you get in the report of NVX in the output of nvidia-smi topo -m the better. The generation will depend on your GPU architecture. +Let's compare the execution of a openai-community/gpt2 language model training over a small sample of wikitext. +The results are: +| NVlink | Time | +| ----- | ---: | +| Y | 101s | +| N | 131s | +You can see that NVLink completes the training ~23% faster. In the second benchmark we use NCCL_P2P_DISABLE=1 to tell the GPUs not to use NVLink. +Here is the full benchmark code and outputs: +```bash +DDP w/ NVLink +rm -r /tmp/test-clm; CUDA_VISIBLE_DEVICES=0,1 torchrun \ +--nproc_per_node 2 examples/pytorch/language-modeling/run_clm.py --model_name_or_path openai-community/gpt2 \ +--dataset_name wikitext --dataset_config_name wikitext-2-raw-v1 --do_train \ +--output_dir /tmp/test-clm --per_device_train_batch_size 4 --max_steps 200 +{'train_runtime': 101.9003, 'train_samples_per_second': 1.963, 'epoch': 0.69} +DDP w/o NVLink +rm -r /tmp/test-clm; CUDA_VISIBLE_DEVICES=0,1 NCCL_P2P_DISABLE=1 torchrun \ +--nproc_per_node 2 examples/pytorch/language-modeling/run_clm.py --model_name_or_path openai-community/gpt2 \ +--dataset_name wikitext --dataset_config_name wikitext-2-raw-v1 --do_train +--output_dir /tmp/test-clm --per_device_train_batch_size 4 --max_steps 200 +{'train_runtime': 131.4367, 'train_samples_per_second': 1.522, 'epoch': 0.69} \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..9ab2bf126f733510695c4bec332f736d1ee72984 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_hardware.txt_chunk_5.txt @@ -0,0 +1,2 @@ +Hardware: 2x TITAN RTX 24GB each + NVlink with 2 NVLinks (NV2 in nvidia-smi topo -m) +Software: pytorch-1.8-to-be + cuda-11.0 / transformers==4.3.0.dev0 \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..33e4551573eaea272c91eeacb9c57de3e19ca465 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_0.txt @@ -0,0 +1,5 @@ +CPU inference +With some optimizations, it is possible to efficiently run large model inference on a CPU. One of these optimization techniques involves compiling the PyTorch code into an intermediate format for high-performance environments like C++. The other technique fuses multiple operations into one kernel to reduce the overhead of running each operation separately. +You'll learn how to use BetterTransformer for faster inference, and how to convert your PyTorch code to TorchScript. If you're using an Intel CPU, you can also use graph optimizations from Intel Extension for PyTorch to boost inference speed even more. Finally, learn how to use 🤗 Optimum to accelerate inference with ONNX Runtime or OpenVINO (if you're using an Intel CPU). +BetterTransformer +BetterTransformer accelerates inference with its fastpath (native PyTorch specialized implementation of Transformer functions) execution. The two optimizations in the fastpath execution are: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..135d0ca59128e34320e87c76ffa415bca44b5d74 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_1.txt @@ -0,0 +1,13 @@ +fusion, which combines multiple sequential operations into a single "kernel" to reduce the number of computation steps +skipping the inherent sparsity of padding tokens to avoid unnecessary computation with nested tensors + +BetterTransformer also converts all attention operations to use the more memory-efficient scaled dot product attention. + +BetterTransformer is not supported for all models. Check this list to see if a model supports BetterTransformer. + +Before you start, make sure you have 🤗 Optimum installed. +Enable BetterTransformer with the [PreTrainedModel.to_bettertransformer] method: + +from transformers import AutoModelForCausalLM +model = AutoModelForCausalLM.from_pretrained("bigcode/starcoder") +model.to_bettertransformer() \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..7453d2d7c2dc7e518c1731ca09a70f237761a58b --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_2.txt @@ -0,0 +1,14 @@ +TorchScript +TorchScript is an intermediate PyTorch model representation that can be run in production environments where performance is important. You can train a model in PyTorch and then export it to TorchScript to free the model from Python performance constraints. PyTorch traces a model to return a [ScriptFunction] that is optimized with just-in-time compilation (JIT). Compared to the default eager mode, JIT mode in PyTorch typically yields better performance for inference using optimization techniques like operator fusion. +For a gentle introduction to TorchScript, see the Introduction to PyTorch TorchScript tutorial. +With the [Trainer] class, you can enable JIT mode for CPU inference by setting the --jit_mode_eval flag: + +python run_qa.py \ +--model_name_or_path csarron/bert-base-uncased-squad-v1 \ +--dataset_name squad \ +--do_eval \ +--max_seq_length 384 \ +--doc_stride 128 \ +--output_dir /tmp/ \ +--no_cuda \ +--jit_mode_eval \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..ec622286fe1a6084b430b6d997059586a178a381 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_3.txt @@ -0,0 +1,6 @@ +For PyTorch >= 1.14.0, JIT-mode could benefit any model for prediction and evaluation since the dict input is supported in jit.trace. +For PyTorch < 1.14.0, JIT-mode could benefit a model if its forward parameter order matches the tuple input order in jit.trace, such as a question-answering model. If the forward parameter order does not match the tuple input order in jit.trace, like a text classification model, jit.trace will fail and we are capturing this with the exception here to make it fallback. Logging is used to notify users. + +IPEX graph optimization +Intel® Extension for PyTorch (IPEX) provides further optimizations in JIT mode for Intel CPUs, and we recommend combining it with TorchScript for even faster performance. The IPEX graph optimization fuses operations like Multi-head attention, Concat Linear, Linear + Add, Linear + Gelu, Add + LayerNorm, and more. +To take advantage of these graph optimizations, make sure you have IPEX installed: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..3c76013e81b94e9a384caf1fcad3d4aa69b1b5a2 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_4.txt @@ -0,0 +1,16 @@ +pip install intel_extension_for_pytorch +Set the --use_ipex and --jit_mode_eval flags in the [Trainer] class to enable JIT mode with the graph optimizations: + +python run_qa.py \ +--model_name_or_path csarron/bert-base-uncased-squad-v1 \ +--dataset_name squad \ +--do_eval \ +--max_seq_length 384 \ +--doc_stride 128 \ +--output_dir /tmp/ \ +--no_cuda \ +--use_ipex \ +--jit_mode_eval +🤗 Optimum + +Learn more details about using ORT with 🤗 Optimum in the Optimum Inference with ONNX Runtime guide. This section only provides a brief and simple example. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..25e8e9f6697e1e56dc1876553a65757a56e031ee --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_5.txt @@ -0,0 +1,11 @@ +ONNX Runtime (ORT) is a model accelerator that runs inference on CPUs by default. ORT is supported by 🤗 Optimum which can be used in 🤗 Transformers, without making too many changes to your code. You only need to replace the 🤗 Transformers AutoClass with its equivalent [~optimum.onnxruntime.ORTModel] for the task you're solving, and load a checkpoint in the ONNX format. +For example, if you're running inference on a question answering task, load the optimum/roberta-base-squad2 checkpoint which contains a model.onnx file: + +from transformers import AutoTokenizer, pipeline +from optimum.onnxruntime import ORTModelForQuestionAnswering +model = ORTModelForQuestionAnswering.from_pretrained("optimum/roberta-base-squad2") +tokenizer = AutoTokenizer.from_pretrained("deepset/roberta-base-squad2") +onnx_qa = pipeline("question-answering", model=model, tokenizer=tokenizer) +question = "What's my name?" +context = "My name is Philipp and I live in Nuremberg." +pred = onnx_qa(question, context) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..a8f6b087618ea71f99da3c7c8f46729dcd39e8dd --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_cpu.txt_chunk_6.txt @@ -0,0 +1 @@ +If you have an Intel CPU, take a look at 🤗 Optimum Intel which supports a variety of compression techniques (quantization, pruning, knowledge distillation) and tools for converting models to the OpenVINO format for higher performance inference. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..c6473cd4c3c653c938acfccd24654ff2bdc95e88 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_0.txt @@ -0,0 +1,10 @@ +GPU inference +GPUs are the standard choice of hardware for machine learning, unlike CPUs, because they are optimized for memory bandwidth and parallelism. To keep up with the larger sizes of modern models or to run these large models on existing and older hardware, there are several optimizations you can use to speed up GPU inference. In this guide, you'll learn how to use FlashAttention-2 (a more memory-efficient attention mechanism), BetterTransformer (a PyTorch native fastpath execution), and bitsandbytes to quantize your model to a lower precision. Finally, learn how to use 🤗 Optimum to accelerate inference with ONNX Runtime on Nvidia and AMD GPUs. + +The majority of the optimizations described here also apply to multi-GPU setups! + +FlashAttention-2 + +FlashAttention-2 is experimental and may change considerably in future versions. + +FlashAttention-2 is a faster and more efficient implementation of the standard attention mechanism that can significantly speedup inference by: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..9dbe195ab8d16ed415c61c0b3faa6dfdfb970e67 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_1.txt @@ -0,0 +1,48 @@ +additionally parallelizing the attention computation over sequence length +partitioning the work between GPU threads to reduce communication and shared memory reads/writes between them + +FlashAttention-2 is currently supported for the following architectures: +* Bark +* Bart +* Cohere +* Dbrx +* DistilBert +* Gemma +* GPT2 +* GPTBigCode +* GPTNeo +* GPTNeoX +* GPT-J +* Idefics2 +* Falcon +* JetMoe +* Jamba +* Llama +* Llava +* Llava-NeXT +* VipLlava +* VideoLlava +* M2M100 +* MBart +* Mistral +* Mixtral +* Musicgen +* MusicGen Melody +* NLLB +* OLMo +* OPT +* Phi +* Phi3 +* StableLm +* Starcoder2 +* Qwen2 +* Qwen2MoE +* Whisper +* Wav2Vec2 +* Hubert +* data2vec_audio +* Sew +* UniSpeech +* unispeech_sat +You can request to add FlashAttention-2 support for another model by opening a GitHub Issue or Pull Request. +Before you begin, make sure you have FlashAttention-2 installed. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_10.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_10.txt new file mode 100644 index 0000000000000000000000000000000000000000..bf8218a15c9d352d21033eb74b0dce0826ed5a90 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_10.txt @@ -0,0 +1,17 @@ +BetterTransformer also converts all attention operations to use the more memory-efficient scaled dot product attention (SDPA), and it calls optimized kernels like FlashAttention under the hood. +Before you start, make sure you have 🤗 Optimum installed. +Then you can enable BetterTransformer with the [PreTrainedModel.to_bettertransformer] method: +python +model = model.to_bettertransformer() +You can return the original Transformers model with the [~PreTrainedModel.reverse_bettertransformer] method. You should use this before saving your model to use the canonical Transformers modeling: +py +model = model.reverse_bettertransformer() +model.save_pretrained("saved_model") +bitsandbytes +bitsandbytes is a quantization library that includes support for 4-bit and 8-bit quantization. Quantization reduces your model size compared to its native full precision version, making it easier to fit large models onto GPUs with limited memory. +Make sure you have bitsandbytes and 🤗 Accelerate installed: +```bash +these versions support 8-bit and 4-bit +pip install bitsandbytes>=0.39.0 accelerate>=0.20.0 +install Transformers +pip install transformers \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_11.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_11.txt new file mode 100644 index 0000000000000000000000000000000000000000..300a794ac423bb4dab2d1cffa07cb6d7a1a558ac --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_11.txt @@ -0,0 +1,15 @@ +4-bit +To load a model in 4-bit for inference, use the load_in_4bit parameter. The device_map parameter is optional, but we recommend setting it to "auto" to allow 🤗 Accelerate to automatically and efficiently allocate the model given the available resources in the environment. + +from transformers import AutoModelForCausalLM +model_name = "bigscience/bloom-2b5" +model_4bit = AutoModelForCausalLM.from_pretrained(model_name, device_map="auto", load_in_4bit=True) + +To load a model in 4-bit for inference with multiple GPUs, you can control how much GPU RAM you want to allocate to each GPU. For example, to distribute 600MB of memory to the first GPU and 1GB of memory to the second GPU: +py +max_memory_mapping = {0: "600MB", 1: "1GB"} +model_name = "bigscience/bloom-3b" +model_4bit = AutoModelForCausalLM.from_pretrained( + model_name, device_map="auto", load_in_4bit=True, max_memory=max_memory_mapping +) +8-bit \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_12.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_12.txt new file mode 100644 index 0000000000000000000000000000000000000000..4a62ad1893dd496c7339e016282cedaff7cc903f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_12.txt @@ -0,0 +1,7 @@ +If you're curious and interested in learning more about the concepts underlying 8-bit quantization, read the Gentle Introduction to 8-bit Matrix Multiplication for transformers at scale using Hugging Face Transformers, Accelerate and bitsandbytes blog post. + +To load a model in 8-bit for inference, use the load_in_8bit parameter. The device_map parameter is optional, but we recommend setting it to "auto" to allow 🤗 Accelerate to automatically and efficiently allocate the model given the available resources in the environment: + +from transformers import AutoModelForCausalLM, BitsAndBytesConfig +model_name = "bigscience/bloom-2b5" +model_8bit = AutoModelForCausalLM.from_pretrained(model_name, quantization_config=BitsAndBytesConfig(load_in_8bit=True)) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_13.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_13.txt new file mode 100644 index 0000000000000000000000000000000000000000..0204a558a7e2ee1b0fe8f2392a6853434a1bdcaa --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_13.txt @@ -0,0 +1,10 @@ +If you're loading a model in 8-bit for text generation, you should use the [~transformers.GenerationMixin.generate] method instead of the [Pipeline] function which is not optimized for 8-bit models and will be slower. Some sampling strategies, like nucleus sampling, are also not supported by the [Pipeline] for 8-bit models. You should also place all inputs on the same device as the model: + +from transformers import AutoModelForCausalLM, AutoTokenizer, BitsAndBytesConfig +model_name = "bigscience/bloom-2b5" +tokenizer = AutoTokenizer.from_pretrained(model_name) +model_8bit = AutoModelForCausalLM.from_pretrained(model_name, quantization_config=BitsAndBytesConfig(load_in_8bit=True)) +prompt = "Hello, my llama is cute" +inputs = tokenizer(prompt, return_tensors="pt").to("cuda") +generated_ids = model.generate(**inputs) +outputs = tokenizer.batch_decode(generated_ids, skip_special_tokens=True) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_14.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_14.txt new file mode 100644 index 0000000000000000000000000000000000000000..fdba6baf67577386a8d10034bee461f27dfe406d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_14.txt @@ -0,0 +1,13 @@ +To load a model in 4-bit for inference with multiple GPUs, you can control how much GPU RAM you want to allocate to each GPU. For example, to distribute 1GB of memory to the first GPU and 2GB of memory to the second GPU: +py +max_memory_mapping = {0: "1GB", 1: "2GB"} +model_name = "bigscience/bloom-3b" +model_8bit = AutoModelForCausalLM.from_pretrained( + model_name, device_map="auto", load_in_8bit=True, max_memory=max_memory_mapping +) + +Feel free to try running a 11 billion parameter T5 model or the 3 billion parameter BLOOM model for inference on Google Colab's free tier GPUs! + +🤗 Optimum + +Learn more details about using ORT with 🤗 Optimum in the Accelerated inference on NVIDIA GPUs and Accelerated inference on AMD GPUs guides. This section only provides a brief and simple example. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_15.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_15.txt new file mode 100644 index 0000000000000000000000000000000000000000..c0b5d4a32db5ff108c09979eca3efcc657f961c8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_15.txt @@ -0,0 +1,2 @@ +ONNX Runtime (ORT) is a model accelerator that supports accelerated inference on Nvidia GPUs, and AMD GPUs that use ROCm stack. ORT uses optimization techniques like fusing common operations into a single node and constant folding to reduce the number of computations performed and speedup inference. ORT also places the most computationally intensive operations on the GPU and the rest on the CPU to intelligently distribute the workload between the two devices. +ORT is supported by 🤗 Optimum which can be used in 🤗 Transformers. You'll need to use an [~optimum.onnxruntime.ORTModel] for the task you're solving, and specify the provider parameter which can be set to either CUDAExecutionProvider, ROCMExecutionProvider or TensorrtExecutionProvider. If you want to load a model that was not yet exported to ONNX, you can set export=True to convert your model on-the-fly to the ONNX format: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_16.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_16.txt new file mode 100644 index 0000000000000000000000000000000000000000..c409aebff9670e8dd2b402a83980cc1e31b07213 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_16.txt @@ -0,0 +1,17 @@ +from optimum.onnxruntime import ORTModelForSequenceClassification +ort_model = ORTModelForSequenceClassification.from_pretrained( + "distilbert/distilbert-base-uncased-finetuned-sst-2-english", + export=True, + provider="CUDAExecutionProvider", +) + +Now you're free to use the model for inference: + +from optimum.pipelines import pipeline +from transformers import AutoTokenizer +tokenizer = AutoTokenizer.from_pretrained("distilbert/distilbert-base-uncased-finetuned-sst-2-english") +pipeline = pipeline(task="text-classification", model=ort_model, tokenizer=tokenizer, device="cuda:0") +result = pipeline("Both the music and visual were astounding, not to mention the actors performance.") + +Combine optimizations +It is often possible to combine several of the optimization techniques described above to get the best inference performance possible for your model. For example, you can load a model in 4-bit, and then enable BetterTransformer with FlashAttention: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_17.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_17.txt new file mode 100644 index 0000000000000000000000000000000000000000..b92b91dea10ec36854d71a67878834e857dd0038 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_17.txt @@ -0,0 +1,18 @@ +import torch +from transformers import AutoModelForCausalLM, AutoTokenizer, BitsAndBytesConfig +load model in 4-bit +quantization_config = BitsAndBytesConfig( + load_in_4bit=True, + bnb_4bit_compute_dtype=torch.float16 +) +tokenizer = AutoTokenizer.from_pretrained("facebook/opt-350m") +model = AutoModelForCausalLM.from_pretrained("facebook/opt-350m", quantization_config=quantization_config) +enable BetterTransformer +model = model.to_bettertransformer() +input_text = "Hello my dog is cute and" +inputs = tokenizer(input_text, return_tensors="pt").to("cuda") +enable FlashAttention +with torch.backends.cuda.sdp_kernel(enable_flash=True, enable_math=False, enable_mem_efficient=False): + outputs = model.generate(**inputs) +print(tokenizer.decode(outputs[0], skip_special_tokens=True)) +``` \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..abcc999773ee72590823a39b9d7c90c550904210 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_2.txt @@ -0,0 +1,16 @@ +pip install flash-attn --no-build-isolation +We strongly suggest referring to the detailed installation instructions to learn more about supported hardware and data types! + +FlashAttention-2 is also supported on AMD GPUs and current support is limited to Instinct MI210, Instinct MI250 and Instinct MI300. We strongly suggest using this Dockerfile to use FlashAttention-2 on AMD GPUs. + +To enable FlashAttention-2, pass the argument attn_implementation="flash_attention_2" to [~AutoModelForCausalLM.from_pretrained]: +thon +import torch +from transformers import AutoModelForCausalLM, AutoTokenizer, LlamaForCausalLM +model_id = "tiiuae/falcon-7b" +tokenizer = AutoTokenizer.from_pretrained(model_id) +model = AutoModelForCausalLM.from_pretrained( + model_id, + torch_dtype=torch.bfloat16, + attn_implementation="flash_attention_2", +) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..4efc50824be80b5778637157507c2a15509773a2 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_3.txt @@ -0,0 +1,22 @@ +FlashAttention-2 can only be used when the model's dtype is fp16 or bf16. Make sure to cast your model to the appropriate dtype and load them on a supported device before using FlashAttention-2. + +You can also set use_flash_attention_2=True to enable FlashAttention-2 but it is deprecated in favor of attn_implementation="flash_attention_2". + +FlashAttention-2 can be combined with other optimization techniques like quantization to further speedup inference. For example, you can combine FlashAttention-2 with 8-bit or 4-bit quantization: + +import torch +from transformers import AutoModelForCausalLM, AutoTokenizer, LlamaForCausalLM +model_id = "tiiuae/falcon-7b" +tokenizer = AutoTokenizer.from_pretrained(model_id) +load in 8bit +model = AutoModelForCausalLM.from_pretrained( + model_id, + load_in_8bit=True, + attn_implementation="flash_attention_2", +) +load in 4bit +model = AutoModelForCausalLM.from_pretrained( + model_id, + load_in_4bit=True, + attn_implementation="flash_attention_2", +) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..5375609023de67f6454d5b86dcc02441058fd6c8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_4.txt @@ -0,0 +1,6 @@ +Expected speedups +You can benefit from considerable speedups for inference, especially for inputs with long sequences. However, since FlashAttention-2 does not support computing attention scores with padding tokens, you must manually pad/unpad the attention scores for batched inference when the sequence contains padding tokens. This leads to a significant slowdown for batched generations with padding tokens. +To overcome this, you should use FlashAttention-2 without padding tokens in the sequence during training (by packing a dataset or concatenating sequences until reaching the maximum sequence length). +For a single forward pass on tiiuae/falcon-7b with a sequence length of 4096 and various batch sizes without padding tokens, the expected speedup is: + +For a single forward pass on meta-llama/Llama-7b-hf with a sequence length of 4096 and various batch sizes without padding tokens, the expected speedup is: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..885159b21a966fb32e8e889844f0a53feddaa03a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_5.txt @@ -0,0 +1,5 @@ +For sequences with padding tokens (generating with padding tokens), you need to unpad/pad the input sequences to correctly compute the attention scores. With a relatively small sequence length, a single forward pass creates overhead leading to a small speedup (in the example below, 30% of the input is filled with padding tokens): + +But for larger sequence lengths, you can expect even more speedup benefits: + +FlashAttention is more memory efficient, meaning you can train on much larger sequence lengths without running into out-of-memory issues. You can potentially reduce memory usage up to 20x for larger sequence lengths. Take a look at the flash-attention repository for more details. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..09e8f531d6a18bfe71367af50dac8e33929e992f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_6.txt @@ -0,0 +1,42 @@ +PyTorch scaled dot product attention +PyTorch's torch.nn.functional.scaled_dot_product_attention (SDPA) can also call FlashAttention and memory-efficient attention kernels under the hood. SDPA support is currently being added natively in Transformers and is used by default for torch>=2.1.1 when an implementation is available. You may also set attn_implementation="sdpa" in from_pretrained() to explicitly request SDPA to be used. +For now, Transformers supports SDPA inference and training for the following architectures: +* Audio Spectrogram Transformer +* Bart +* Bert +* Cohere +* Dbrx +* DeiT +* Dpr +* Falcon +* Gemma +* GPT2 +* GPTBigCode +* JetMoe +* Jamba +* Llama +* OLMo +* PaliGemma +* Phi +* Idefics +* Whisper +* Mistral +* Mixtral +* StableLm +* Starcoder2 +* Qwen2 +* Qwen2MoE +* Musicgen +* MusicGen Melody +* ViT +* ViTHybrid +* ViTMAE +* ViTMSN +* VideoMAE +* wav2vec2 +* Hubert +* data2vec_audio +* Sew +* UniSpeech +* unispeech_sat +* YOLOS \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..5c52631c2389d6134316d28bd8421e1fdf1fad0a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_7.txt @@ -0,0 +1,13 @@ +FlashAttention can only be used for models with the fp16 or bf16 torch type, so make sure to cast your model to the appropriate type first. The memory-efficient attention backend is able to handle fp32 models. + +SDPA does not support certain sets of attention parameters, such as head_mask and output_attentions=True. +In that case, you should see a warning message and we will fall back to the (slower) eager implementation. + +By default, SDPA selects the most performant kernel available but you can check whether a backend is available in a given setting (hardware, problem size) with torch.backends.cuda.sdp_kernel as a context manager: + +import torch +from transformers import AutoModelForCausalLM, AutoTokenizer +tokenizer = AutoTokenizer.from_pretrained("facebook/opt-350m") +model = AutoModelForCausalLM.from_pretrained("facebook/opt-350m", torch_dtype=torch.float16).to("cuda") +input_text = "Hello my dog is cute and" +inputs = tokenizer(input_text, return_tensors="pt").to("cuda") \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..2e9a961bf8ad0a9da202b5bea8474f5f006f8019 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_8.txt @@ -0,0 +1,14 @@ +with torch.backends.cuda.sdp_kernel(enable_flash=True, enable_math=False, enable_mem_efficient=False): + outputs = model.generate(**inputs) + +print(tokenizer.decode(outputs[0], skip_special_tokens=True)) + +If you see a bug with the traceback below, try using the nightly version of PyTorch which may have broader coverage for FlashAttention: +```bash +RuntimeError: No available kernel. Aborting execution. +install PyTorch nightly +pip3 install -U --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu118 + +BetterTransformer + +Some BetterTransformer features are being upstreamed to Transformers with default support for native torch.nn.scaled_dot_product_attention. BetterTransformer still has a wider coverage than the Transformers SDPA integration, but you can expect more and more architectures to natively support SDPA in Transformers. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..4875fff8124ded960889e093adaf4862ba71f036 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_infer_gpu_one.txt_chunk_9.txt @@ -0,0 +1,6 @@ +Check out our benchmarks with BetterTransformer and scaled dot product attention in the Out of the box acceleration and memory savings of 🤗 decoder models with PyTorch 2.0 and learn more about the fastpath execution in the BetterTransformer blog post. + +BetterTransformer accelerates inference with its fastpath (native PyTorch specialized implementation of Transformer functions) execution. The two optimizations in the fastpath execution are: + +fusion, which combines multiple sequential operations into a single "kernel" to reduce the number of computation steps +skipping the inherent sparsity of padding tokens to avoid unnecessary computation with nested tensors \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..36fc67cf4e5bb0e6f9efd9e4c6da3efa722a0201 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_0.txt @@ -0,0 +1,10 @@ +Optimize inference using torch.compile() +This guide aims to provide a benchmark on the inference speed-ups introduced with torch.compile() for computer vision models in 🤗 Transformers. +Benefits of torch.compile +Depending on the model and the GPU, torch.compile() yields up to 30% speed-up during inference. To use torch.compile(), simply install any version of torch above 2.0. +Compiling a model takes time, so it's useful if you are compiling the model only once instead of every time you infer. +To compile any computer vision model of your choice, call torch.compile() on the model as shown below: + +from transformers import AutoModelForImageClassification +model = AutoModelForImageClassification.from_pretrained(MODEL_ID).to("cuda") ++ model = torch.compile(model) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..a8413bb5976cd055df3bef80976903789b54804d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_1.txt @@ -0,0 +1,19 @@ +compile() comes with multiple modes for compiling, which essentially differ in compilation time and inference overhead. max-autotune takes longer than reduce-overhead but results in faster inference. Default mode is fastest for compilation but is not as efficient compared to reduce-overhead for inference time. In this guide, we used the default mode. You can learn more about it here. +We benchmarked torch.compile with different computer vision models, tasks, types of hardware, and batch sizes on torch version 2.0.1. +Benchmarking code +Below you can find the benchmarking code for each task. We warm up the GPU before inference and take the mean time of 300 inferences, using the same image each time. +Image Classification with ViT +thon +import torch +from PIL import Image +import requests +import numpy as np +from transformers import AutoImageProcessor, AutoModelForImageClassification +url = 'http://images.cocodataset.org/val2017/000000039769.jpg' +image = Image.open(requests.get(url, stream=True).raw) +processor = AutoImageProcessor.from_pretrained("google/vit-base-patch16-224") +model = AutoModelForImageClassification.from_pretrained("google/vit-base-patch16-224").to("cuda") +model = torch.compile(model) +processed_input = processor(image, return_tensors='pt').to(device="cuda") +with torch.no_grad(): + _ = model(**processed_input) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..78400349a9daf76e450daffb6f79d11d806d1e5f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_2.txt @@ -0,0 +1,20 @@ +Object Detection with DETR +thon +from transformers import AutoImageProcessor, AutoModelForObjectDetection +processor = AutoImageProcessor.from_pretrained("facebook/detr-resnet-50") +model = AutoModelForObjectDetection.from_pretrained("facebook/detr-resnet-50").to("cuda") +model = torch.compile(model) +texts = ["a photo of a cat", "a photo of a dog"] +inputs = processor(text=texts, images=image, return_tensors="pt").to("cuda") +with torch.no_grad(): + _ = model(**inputs) + +Image Segmentation with Segformer +thon +from transformers import SegformerImageProcessor, SegformerForSemanticSegmentation +processor = SegformerImageProcessor.from_pretrained("nvidia/segformer-b0-finetuned-ade-512-512") +model = SegformerForSemanticSegmentation.from_pretrained("nvidia/segformer-b0-finetuned-ade-512-512").to("cuda") +model = torch.compile(model) +seg_inputs = processor(images=image, return_tensors="pt").to("cuda") +with torch.no_grad(): + _ = model(**seg_inputs) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..e5c40d41802a5d3395792c2f16ea4c4c5fc8e1e1 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_3.txt @@ -0,0 +1,16 @@ +Below you can find the list of the models we benchmarked. +Image Classification +- google/vit-base-patch16-224 +- microsoft/beit-base-patch16-224-pt22k-ft22k +- facebook/convnext-large-224 +- microsoft/resnet-50 +Image Segmentation +- nvidia/segformer-b0-finetuned-ade-512-512 +- facebook/mask2former-swin-tiny-coco-panoptic +- facebook/maskformer-swin-base-ade +- google/deeplabv3_mobilenet_v2_1.0_513 +Object Detection +- google/owlvit-base-patch32 +- facebook/detr-resnet-101 +- microsoft/conditional-detr-resnet-50 +Below you can find visualization of inference durations with and without torch.compile() and percentage improvements for each model in different hardware and batch sizes. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..3e7eafa6f3ba7859eb08a1dbe7dc8e98a36cd46c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_torch_compile.txt_chunk_4.txt @@ -0,0 +1,183 @@ +Below you can find inference durations in milliseconds for each model with and without compile(). Note that OwlViT results in OOM in larger batch sizes. +A100 (batch size: 1) +| Task/Model | torch 2.0 - no compile | torch 2.0 - compile | +|:---:|:---:|:---:| +| Image Classification/ViT | 9.325 | 7.584 | +| Image Segmentation/Segformer | 11.759 | 10.500 | +| Object Detection/OwlViT | 24.978 | 18.420 | +| Image Classification/BeiT | 11.282 | 8.448 | +| Object Detection/DETR | 34.619 | 19.040 | +| Image Classification/ConvNeXT | 10.410 | 10.208 | +| Image Classification/ResNet | 6.531 | 4.124 | +| Image Segmentation/Mask2former | 60.188 | 49.117 | +| Image Segmentation/Maskformer | 75.764 | 59.487 | +| Image Segmentation/MobileNet | 8.583 | 3.974 | +| Object Detection/Resnet-101 | 36.276 | 18.197 | +| Object Detection/Conditional-DETR | 31.219 | 17.993 | +A100 (batch size: 4) +| Task/Model | torch 2.0 - no compile | torch 2.0 - compile | +|:---:|:---:|:---:| +| Image Classification/ViT | 14.832 | 14.499 | +| Image Segmentation/Segformer | 18.838 | 16.476 | +| Image Classification/BeiT | 13.205 | 13.048 | +| Object Detection/DETR | 48.657 | 32.418| +| Image Classification/ConvNeXT | 22.940 | 21.631 | +| Image Classification/ResNet | 6.657 | 4.268 | +| Image Segmentation/Mask2former | 74.277 | 61.781 | +| Image Segmentation/Maskformer | 180.700 | 159.116 | +| Image Segmentation/MobileNet | 14.174 | 8.515 | +| Object Detection/Resnet-101 | 68.101 | 44.998 | +| Object Detection/Conditional-DETR | 56.470 | 35.552 | +A100 (batch size: 16) +| Task/Model | torch 2.0 - no compile | torch 2.0 - compile | +|:---:|:---:|:---:| +| Image Classification/ViT | 40.944 | 40.010 | +| Image Segmentation/Segformer | 37.005 | 31.144 | +| Image Classification/BeiT | 41.854 | 41.048 | +| Object Detection/DETR | 164.382 | 161.902 | +| Image Classification/ConvNeXT | 82.258 | 75.561 | +| Image Classification/ResNet | 7.018 | 5.024 | +| Image Segmentation/Mask2former | 178.945 | 154.814 | +| Image Segmentation/Maskformer | 638.570 | 579.826 | +| Image Segmentation/MobileNet | 51.693 | 30.310 | +| Object Detection/Resnet-101 | 232.887 | 155.021 | +| Object Detection/Conditional-DETR | 180.491 | 124.032 | +V100 (batch size: 1) +| Task/Model | torch 2.0 - no compile | torch 2.0 - compile | +|:---:|:---:|:---:| +| Image Classification/ViT | 10.495 | 6.00 | +| Image Segmentation/Segformer | 13.321 | 5.862 | +| Object Detection/OwlViT | 25.769 | 22.395 | +| Image Classification/BeiT | 11.347 | 7.234 | +| Object Detection/DETR | 33.951 | 19.388 | +| Image Classification/ConvNeXT | 11.623 | 10.412 | +| Image Classification/ResNet | 6.484 | 3.820 | +| Image Segmentation/Mask2former | 64.640 | 49.873 | +| Image Segmentation/Maskformer | 95.532 | 72.207 | +| Image Segmentation/MobileNet | 9.217 | 4.753 | +| Object Detection/Resnet-101 | 52.818 | 28.367 | +| Object Detection/Conditional-DETR | 39.512 | 20.816 | +V100 (batch size: 4) +| Task/Model | torch 2.0 - no compile | torch 2.0 - compile | +|:---:|:---:|:---:| +| Image Classification/ViT | 15.181 | 14.501 | +| Image Segmentation/Segformer | 16.787 | 16.188 | +| Image Classification/BeiT | 15.171 | 14.753 | +| Object Detection/DETR | 88.529 | 64.195 | +| Image Classification/ConvNeXT | 29.574 | 27.085 | +| Image Classification/ResNet | 6.109 | 4.731 | +| Image Segmentation/Mask2former | 90.402 | 76.926 | +| Image Segmentation/Maskformer | 234.261 | 205.456 | +| Image Segmentation/MobileNet | 24.623 | 14.816 | +| Object Detection/Resnet-101 | 134.672 | 101.304 | +| Object Detection/Conditional-DETR | 97.464 | 69.739 | +V100 (batch size: 16) +| Task/Model | torch 2.0 - no compile | torch 2.0 - compile | +|:---:|:---:|:---:| +| Image Classification/ViT | 52.209 | 51.633 | +| Image Segmentation/Segformer | 61.013 | 55.499 | +| Image Classification/BeiT | 53.938 | 53.581 | +| Object Detection/DETR | OOM | OOM | +| Image Classification/ConvNeXT | 109.682 | 100.771 | +| Image Classification/ResNet | 14.857 | 12.089 | +| Image Segmentation/Mask2former | 249.605 | 222.801 | +| Image Segmentation/Maskformer | 831.142 | 743.645 | +| Image Segmentation/MobileNet | 93.129 | 55.365 | +| Object Detection/Resnet-101 | 482.425 | 361.843 | +| Object Detection/Conditional-DETR | 344.661 | 255.298 | +T4 (batch size: 1) +| Task/Model | torch 2.0 - no compile | torch 2.0 - compile | +|:---:|:---:|:---:| +| Image Classification/ViT | 16.520 | 15.786 | +| Image Segmentation/Segformer | 16.116 | 14.205 | +| Object Detection/OwlViT | 53.634 | 51.105 | +| Image Classification/BeiT | 16.464 | 15.710 | +| Object Detection/DETR | 73.100 | 53.99 | +| Image Classification/ConvNeXT | 32.932 | 30.845 | +| Image Classification/ResNet | 6.031 | 4.321 | +| Image Segmentation/Mask2former | 79.192 | 66.815 | +| Image Segmentation/Maskformer | 200.026 | 188.268 | +| Image Segmentation/MobileNet | 18.908 | 11.997 | +| Object Detection/Resnet-101 | 106.622 | 82.566 | +| Object Detection/Conditional-DETR | 77.594 | 56.984 | +T4 (batch size: 4) +| Task/Model | torch 2.0 - no compile | torch 2.0 - compile | +|:---:|:---:|:---:| +| Image Classification/ViT | 43.653 | 43.626 | +| Image Segmentation/Segformer | 45.327 | 42.445 | +| Image Classification/BeiT | 52.007 | 51.354 | +| Object Detection/DETR | 277.850 | 268.003 | +| Image Classification/ConvNeXT | 119.259 | 105.580 | +| Image Classification/ResNet | 13.039 | 11.388 | +| Image Segmentation/Mask2former | 201.540 | 184.670 | +| Image Segmentation/Maskformer | 764.052 | 711.280 | +| Image Segmentation/MobileNet | 74.289 | 48.677 | +| Object Detection/Resnet-101 | 421.859 | 357.614 | +| Object Detection/Conditional-DETR | 289.002 | 226.945 | +T4 (batch size: 16) +| Task/Model | torch 2.0 - no compile | torch 2.0 - compile | +|:---:|:---:|:---:| +| Image Classification/ViT | 163.914 | 160.907 | +| Image Segmentation/Segformer | 192.412 | 163.620 | +| Image Classification/BeiT | 188.978 | 187.976 | +| Object Detection/DETR | OOM | OOM | +| Image Classification/ConvNeXT | 422.886 | 388.078 | +| Image Classification/ResNet | 44.114 | 37.604 | +| Image Segmentation/Mask2former | 756.337 | 695.291 | +| Image Segmentation/Maskformer | 2842.940 | 2656.88 | +| Image Segmentation/MobileNet | 299.003 | 201.942 | +| Object Detection/Resnet-101 | 1619.505 | 1262.758 | +| Object Detection/Conditional-DETR | 1137.513 | 897.390| +PyTorch Nightly +We also benchmarked on PyTorch nightly (2.1.0dev, find the wheel here) and observed improvement in latency both for uncompiled and compiled models. +A100 +| Task/Model | Batch Size | torch 2.0 - no compile | torch 2.0 - compile | +|:---:|:---:|:---:|:---:| +| Image Classification/BeiT | Unbatched | 12.462 | 6.954 | +| Image Classification/BeiT | 4 | 14.109 | 12.851 | +| Image Classification/BeiT | 16 | 42.179 | 42.147 | +| Object Detection/DETR | Unbatched | 30.484 | 15.221 | +| Object Detection/DETR | 4 | 46.816 | 30.942 | +| Object Detection/DETR | 16 | 163.749 | 163.706 | +T4 +| Task/Model | Batch Size | torch 2.0 - no compile | torch 2.0 - compile | +|:---:|:---:|:---:|:---:| +| Image Classification/BeiT | Unbatched | 14.408 | 14.052 | +| Image Classification/BeiT | 4 | 47.381 | 46.604 | +| Image Classification/BeiT | 16 | 42.179 | 42.147 | +| Object Detection/DETR | Unbatched | 68.382 | 53.481 | +| Object Detection/DETR | 4 | 269.615 | 204.785 | +| Object Detection/DETR | 16 | OOM | OOM | +V100 +| Task/Model | Batch Size | torch 2.0 - no compile | torch 2.0 - compile | +|:---:|:---:|:---:|:---:| +| Image Classification/BeiT | Unbatched | 13.477 | 7.926 | +| Image Classification/BeiT | 4 | 15.103 | 14.378 | +| Image Classification/BeiT | 16 | 52.517 | 51.691 | +| Object Detection/DETR | Unbatched | 28.706 | 19.077 | +| Object Detection/DETR | 4 | 88.402 | 62.949| +| Object Detection/DETR | 16 | OOM | OOM | +Reduce Overhead +We benchmarked reduce-overhead compilation mode for A100 and T4 in Nightly. +A100 +| Task/Model | Batch Size | torch 2.0 - no compile | torch 2.0 - compile | +|:---:|:---:|:---:|:---:| +| Image Classification/ConvNeXT | Unbatched | 11.758 | 7.335 | +| Image Classification/ConvNeXT | 4 | 23.171 | 21.490 | +| Image Classification/ResNet | Unbatched | 7.435 | 3.801 | +| Image Classification/ResNet | 4 | 7.261 | 2.187 | +| Object Detection/Conditional-DETR | Unbatched | 32.823 | 11.627 | +| Object Detection/Conditional-DETR | 4 | 50.622 | 33.831 | +| Image Segmentation/MobileNet | Unbatched | 9.869 | 4.244 | +| Image Segmentation/MobileNet | 4 | 14.385 | 7.946 | +T4 +| Task/Model | Batch Size | torch 2.0 - no compile | torch 2.0 - compile | +|:---:|:---:|:---:|:---:| +| Image Classification/ConvNeXT | Unbatched | 32.137 | 31.84 | +| Image Classification/ConvNeXT | 4 | 120.944 | 110.209 | +| Image Classification/ResNet | Unbatched | 9.761 | 7.698 | +| Image Classification/ResNet | 4 | 15.215 | 13.871 | +| Object Detection/Conditional-DETR | Unbatched | 72.150 | 57.660 | +| Object Detection/Conditional-DETR | 4 | 301.494 | 247.543 | +| Image Segmentation/MobileNet | Unbatched | 22.266 | 19.339 | +| Image Segmentation/MobileNet | 4 | 78.311 | 50.983 | \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..027ea679797de32a8e02350093db63275786a56c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu.txt_chunk_0.txt @@ -0,0 +1,16 @@ +Efficient Training on CPU +This guide focuses on training large models efficiently on CPU. +Mixed precision with IPEX +Mixed precision uses single (fp32) and half-precision (bf16/fp16) data types in a model to accelerate training or inference while still preserving much of the single-precision accuracy. Modern CPUs such as 3rd and 4th Gen Intel® Xeon® Scalable processors natively support bf16, so you should get more performance out of the box by enabling mixed precision training with bf16. +To further maximize training performance, you can use Intel® Extension for PyTorch (IPEX), which is a library built on PyTorch and adds additional CPU instruction level architecture (ISA) level support such as Intel® Advanced Vector Extensions 512 Vector Neural Network Instructions (Intel® AVX512-VNNI), and Intel® Advanced Matrix Extensions (Intel® AMX) for an extra performance boost on Intel CPUs. However, CPUs with only AVX2 (e.g., AMD or older Intel CPUs) are not guaranteed to have better performance under IPEX. +Auto Mixed Precision (AMP) for CPU backends has been enabled since PyTorch 1.10. AMP support for bf16 on CPUs and bf16 operator optimization is also supported in IPEX and partially upstreamed to the main PyTorch branch. You can get better performance and user experience with IPEX AMP. +Check more detailed information for Auto Mixed Precision. +IPEX installation: +IPEX release is following PyTorch, to install via pip: +| PyTorch Version | IPEX version | +| :---------------: | :----------: | +| 2.1.x | 2.1.100+cpu | +| 2.0.x | 2.0.100+cpu | +| 1.13 | 1.13.0+cpu | +| 1.12 | 1.12.300+cpu | +Please run pip list | grep torch to get your pytorch_version, so you can get the IPEX version_name. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..952b2ce80fd2f1e4247bfe9611b18964a165949f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu.txt_chunk_1.txt @@ -0,0 +1,8 @@ +pip install intel_extension_for_pytorch== -f https://developer.intel.com/ipex-whl-stable-cpu +You can check the latest versions in ipex-whl-stable-cpu if needed. +Check more approaches for IPEX installation. +Usage in Trainer +To enable auto mixed precision with IPEX in Trainer, users should add use_ipex, bf16 and no_cuda in training command arguments. +Take an example of the use cases on Transformers question-answering + +Training with IPEX using BF16 auto mixed precision on CPU: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..2dc74b2dcb3c4f5007001b23e1ee9e1216df3de1 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu.txt_chunk_2.txt @@ -0,0 +1,27 @@ +Training with IPEX using BF16 auto mixed precision on CPU: + + python run_qa.py \ +--model_name_or_path google-bert/bert-base-uncased \ +--dataset_name squad \ +--do_train \ +--do_eval \ +--per_device_train_batch_size 12 \ +--learning_rate 3e-5 \ +--num_train_epochs 2 \ +--max_seq_length 384 \ +--doc_stride 128 \ +--output_dir /tmp/debug_squad/ \ +--use_ipex \ +--bf16 \ +--use_cpu +If you want to enable use_ipex and bf16 in your script, add these parameters to TrainingArguments like this: +diff +training_args = TrainingArguments( + output_dir=args.output_path, ++ bf16=True, ++ use_ipex=True, ++ use_cpu=True, + **kwargs +) +Practice example +Blog: Accelerating PyTorch Transformers with Intel Sapphire Rapids \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..aebd71a9d89e7736e7d9a4375f6e230961303dfc --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_0.txt @@ -0,0 +1,17 @@ +Efficient Training on Multiple CPUs +When training on a single CPU is too slow, we can use multiple CPUs. This guide focuses on PyTorch-based DDP enabling +distributed CPU training efficiently on bare metal and Kubernetes. +Intel® oneCCL Bindings for PyTorch +Intel® oneCCL (collective communications library) is a library for efficient distributed deep learning training implementing such collectives like allreduce, allgather, alltoall. For more information on oneCCL, please refer to the oneCCL documentation and oneCCL specification. +Module oneccl_bindings_for_pytorch (torch_ccl before version 1.12) implements PyTorch C10D ProcessGroup API and can be dynamically loaded as external ProcessGroup and only works on Linux platform now +Check more detailed information for oneccl_bind_pt. +Intel® oneCCL Bindings for PyTorch installation +Wheel files are available for the following Python versions: +| Extension Version | Python 3.6 | Python 3.7 | Python 3.8 | Python 3.9 | Python 3.10 | +| :---------------: | :--------: | :--------: | :--------: | :--------: | :---------: | +| 2.1.0 | | √ | √ | √ | √ | +| 2.0.0 | | √ | √ | √ | √ | +| 1.13.0 | | √ | √ | √ | √ | +| 1.12.100 | | √ | √ | √ | √ | +| 1.12.0 | | √ | √ | √ | √ | +Please run pip list | grep torch to get your pytorch_version. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..b8fa9d9248968d237095aff01e7f47b9dcc9d20f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_1.txt @@ -0,0 +1,12 @@ +pip install oneccl_bind_pt=={pytorch_version} -f https://developer.intel.com/ipex-whl-stable-cpu +where {pytorch_version} should be your PyTorch version, for instance 2.1.0. +Check more approaches for oneccl_bind_pt installation. +Versions of oneCCL and PyTorch must match. + +oneccl_bindings_for_pytorch 1.12.0 prebuilt wheel does not work with PyTorch 1.12.1 (it is for PyTorch 1.12.0) +PyTorch 1.12.1 should work with oneccl_bindings_for_pytorch 1.12.100 + +Intel® MPI library +Use this standards-based MPI implementation to deliver flexible, efficient, scalable cluster messaging on Intel® architecture. This component is part of the Intel® oneAPI HPC Toolkit. +oneccl_bindings_for_pytorch is installed along with the MPI tool set. Need to source the environment before using it. +for Intel® oneCCL >= 1.12.0 \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..89216e89d5fb200dd2652a18af7709f84e73a03f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_2.txt @@ -0,0 +1,3 @@ +oneccl_bindings_for_pytorch_path=$(python -c "from oneccl_bindings_for_pytorch import cwd; print(cwd)") +source $oneccl_bindings_for_pytorch_path/env/setvars.sh +for Intel® oneCCL whose version < 1.12.0 \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..48f76ee094b94f08584c43d78d190ffd94b5bb5e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_3.txt @@ -0,0 +1,76 @@ +torch_ccl_path=$(python -c "import torch; import torch_ccl; import os; print(os.path.abspath(os.path.dirname(torch_ccl.__file__)))") +source $torch_ccl_path/env/setvars.sh +Intel® Extension for PyTorch installation +Intel Extension for PyTorch (IPEX) provides performance optimizations for CPU training with both Float32 and BFloat16 (refer to the single CPU section to learn more). +The following "Usage in Trainer" takes mpirun in Intel® MPI library as an example. +Usage in Trainer +To enable multi CPU distributed training in the Trainer with the ccl backend, users should add --ddp_backend ccl in the command arguments. +Let's see an example with the question-answering example +The following command enables training with 2 processes on one Xeon node, with one process running per one socket. The variables OMP_NUM_THREADS/CCL_WORKER_COUNT can be tuned for optimal performance. +shell script + export CCL_WORKER_COUNT=1 + export MASTER_ADDR=127.0.0.1 + mpirun -n 2 -genv OMP_NUM_THREADS=23 \ + python3 run_qa.py \ + --model_name_or_path google-bert/bert-large-uncased \ + --dataset_name squad \ + --do_train \ + --do_eval \ + --per_device_train_batch_size 12 \ + --learning_rate 3e-5 \ + --num_train_epochs 2 \ + --max_seq_length 384 \ + --doc_stride 128 \ + --output_dir /tmp/debug_squad/ \ + --no_cuda \ + --ddp_backend ccl \ + --use_ipex +The following command enables training with a total of four processes on two Xeons (node0 and node1, taking node0 as the main process), ppn (processes per node) is set to 2, with one process running per one socket. The variables OMP_NUM_THREADS/CCL_WORKER_COUNT can be tuned for optimal performance. +In node0, you need to create a configuration file which contains the IP addresses of each node (for example hostfile) and pass that configuration file path as an argument. +shell script + cat hostfile + xxx.xxx.xxx.xxx #node0 ip + xxx.xxx.xxx.xxx #node1 ip +Now, run the following command in node0 and 4DDP will be enabled in node0 and node1 with BF16 auto mixed precision: +shell script + export CCL_WORKER_COUNT=1 + export MASTER_ADDR=xxx.xxx.xxx.xxx #node0 ip + mpirun -f hostfile -n 4 -ppn 2 \ + -genv OMP_NUM_THREADS=23 \ + python3 run_qa.py \ + --model_name_or_path google-bert/bert-large-uncased \ + --dataset_name squad \ + --do_train \ + --do_eval \ + --per_device_train_batch_size 12 \ + --learning_rate 3e-5 \ + --num_train_epochs 2 \ + --max_seq_length 384 \ + --doc_stride 128 \ + --output_dir /tmp/debug_squad/ \ + --no_cuda \ + --ddp_backend ccl \ + --use_ipex \ + --bf16 +Usage with Kubernetes +The same distributed training job from the previous section can be deployed to a Kubernetes cluster using the +Kubeflow PyTorchJob training operator. +Setup +This example assumes that you have: +* Access to a Kubernetes cluster with Kubeflow installed +* kubectl installed and configured to access the Kubernetes cluster +* A Persistent Volume Claim (PVC) that can be used + to store datasets and model files. There are multiple options for setting up the PVC including using an NFS + storage class or a cloud storage bucket. +* A Docker container that includes your model training script and all the dependencies needed to run the script. For + distributed CPU training jobs, this typically includes PyTorch, Transformers, Intel Extension for PyTorch, Intel + oneCCL Bindings for PyTorch, and OpenSSH to communicate between the containers. +The snippet below is an example of a Dockerfile that uses a base image that supports distributed CPU training and then +extracts a Transformers release to the /workspace directory, so that the example scripts are included in the image: +```dockerfile +FROM intel/ai-workflows:torch-2.0.1-huggingface-multinode-py3.9 +WORKDIR /workspace +Download and extract the transformers code +ARG HF_TRANSFORMERS_VER="4.35.2" +RUN mkdir transformers && \ + curl -sSL --retry 5 https://github.com/huggingface/transformers/archive/refs/tags/v${HF_TRANSFORMERS_VER}.tar.gz | tar -C transformers --strip-components=1 -xzf - \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..5e4bca254425e4ed1176a53d5e1785acc61337dd --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_4.txt @@ -0,0 +1,76 @@ +The image needs to be built and copied to the cluster's nodes or pushed to a container registry prior to deploying the +PyTorchJob to the cluster. +PyTorchJob Specification File +The Kubeflow PyTorchJob is used to run the distributed +training job on the cluster. The yaml file for the PyTorchJob defines parameters such as: + * The name of the PyTorchJob + * The number of replicas (workers) + * The python script and it's parameters that will be used to run the training job + * The types of resources (node selector, memory, and CPU) needed for each worker + * The image/tag for the Docker container to use + * Environment variables + * A volume mount for the PVC +The volume mount defines a path where the PVC will be mounted in the container for each worker pod. This location can be +used for the dataset, checkpoint files, and the saved model after training completes. +The snippet below is an example of a yaml file for a PyTorchJob with 4 workers running the +question-answering example. +yaml +apiVersion: "kubeflow.org/v1" +kind: PyTorchJob +metadata: + name: transformers-pytorchjob + namespace: kubeflow +spec: + elasticPolicy: + rdzvBackend: c10d + minReplicas: 1 + maxReplicas: 4 + maxRestarts: 10 + pytorchReplicaSpecs: + Worker: + replicas: 4 # The number of worker pods + restartPolicy: OnFailure + template: + spec: + containers: + - name: pytorch + image: : # Specify the docker image to use for the worker pods + imagePullPolicy: IfNotPresent + command: + - torchrun + - /workspace/transformers/examples/pytorch/question-answering/run_qa.py + - --model_name_or_path + - "google-bert/bert-large-uncased" + - --dataset_name + - "squad" + - --do_train + - --do_eval + - --per_device_train_batch_size + - "12" + - --learning_rate + - "3e-5" + - --num_train_epochs + - "2" + - --max_seq_length + - "384" + - --doc_stride + - "128" + - --output_dir + - "/tmp/pvc-mount/output" + - --no_cuda + - --ddp_backend + - "ccl" + - --use_ipex + - --bf16 # Specify --bf16 if your hardware supports bfloat16 + env: + - name: LD_PRELOAD + value: "/usr/lib/x86_64-linux-gnu/libtcmalloc.so.4.5.9:/usr/local/lib/libiomp5.so" + - name: TRANSFORMERS_CACHE + value: "/tmp/pvc-mount/transformers_cache" + - name: HF_DATASETS_CACHE + value: "/tmp/pvc-mount/hf_datasets_cache" + - name: LOGLEVEL + value: "INFO" + - name: CCL_WORKER_COUNT + value: "1" + - name: OMP_NUM_THREADS # Can be tuned for optimal performance \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..5f635b2893ffdd58028f0d20fde0acc271b64b0e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_5.txt @@ -0,0 +1,23 @@ +resources: + limits: + cpu: 200 # Update the CPU and memory limit values based on your nodes + memory: 128Gi + requests: + cpu: 200 # Update the CPU and memory request values based on your nodes + memory: 128Gi + volumeMounts: + - name: pvc-volume + mountPath: /tmp/pvc-mount + - mountPath: /dev/shm + name: dshm + restartPolicy: Never + nodeSelector: # Optionally use the node selector to specify what types of nodes to use for the workers + node-type: spr + volumes: + - name: pvc-volume + persistentVolumeClaim: + claimName: transformers-pvc + - name: dshm + emptyDir: + medium: Memory +To run this example, update the yaml based on your training script and the nodes in your cluster. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..ed9b6f04952bb2e4757e3483364b10c9ad332281 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_6.txt @@ -0,0 +1,11 @@ +The CPU resource limits/requests in the yaml are defined in cpu units +where 1 CPU unit is equivalent to 1 physical CPU core or 1 virtual core (depending on whether the node is a physical +host or a VM). The amount of CPU and memory limits/requests defined in the yaml should be less than the amount of +available CPU/memory capacity on a single machine. It is usually a good idea to not use the entire machine's capacity in +order to leave some resources for the kubelet and OS. In order to get "guaranteed" +quality of service for the worker pods, +set the same CPU and memory amounts for both the resource limits and requests. + +Deploy +After the PyTorchJob spec has been updated with values appropriate for your cluster and training job, it can be deployed +to the cluster using: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..b2ea4fe48e9d09460079c11c3ebc81e8a940e670 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_7.txt @@ -0,0 +1,10 @@ +kubectl create -f pytorchjob.yaml +The kubectl get pods -n kubeflow command can then be used to list the pods in the kubeflow namespace. You should see +the worker pods for the PyTorchJob that was just deployed. At first, they will probably have a status of "Pending" as +the containers get pulled and created, then the status should change to "Running". +NAME READY STATUS RESTARTS AGE + +transformers-pytorchjob-worker-0 1/1 Running 0 7m37s +transformers-pytorchjob-worker-1 1/1 Running 0 7m37s +transformers-pytorchjob-worker-2 1/1 Running 0 7m37s +transformers-pytorchjob-worker-3 1/1 Running 0 7m37s \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..8b20eba7ad3adeffecaa1e2df05ecf89a57fce12 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_cpu_many.txt_chunk_8.txt @@ -0,0 +1,9 @@ +The logs for worker can be viewed using kubectl logs -n kubeflow . Add -f to stream the logs, for example: + +kubectl logs -n kubeflow transformers-pytorchjob-worker-0 -f +After the training job completes, the trained model can be copied from the PVC or storage location. When you are done +with the job, the PyTorchJob resource can be deleted from the cluster using kubectl delete -f pytorchjob.yaml. +Summary +This guide covered running distributed PyTorch training jobs using multiple CPUs on bare metal and on a Kubernetes +cluster. Both cases utilize Intel Extension for PyTorch and Intel oneCCL Bindings for PyTorch for optimal training +performance, and can be used as a template to run your own workload on multiple nodes. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..160e58d1831971c480005f44dbd05f0c80be82f9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_0.txt @@ -0,0 +1,13 @@ +Efficient Training on Multiple GPUs +If training a model on a single GPU is too slow or if the model's weights do not fit in a single GPU's memory, transitioning +to a multi-GPU setup may be a viable option. Prior to making this transition, thoroughly explore all the strategies covered +in the Methods and tools for efficient training on a single GPU as they are universally applicable +to model training on any number of GPUs. Once you have employed those strategies and found them insufficient for your +case on a single GPU, consider moving to multiple GPUs. +Transitioning from a single GPU to multiple GPUs requires the introduction of some form of parallelism, as the workload +must be distributed across the resources. Multiple techniques can be employed to achieve parallelism, such as data +parallelism, tensor parallelism, and pipeline parallelism. It's important to note that there isn't a one-size-fits-all +solution, and the optimal settings depend on the specific hardware configuration you are using. +This guide offers an in-depth overview of individual types of parallelism, as well as guidance on ways to combine +techniques and choosing an appropriate approach. For step-by-step tutorials on distributed training, please refer to +the 🤗 Accelerate documentation. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..4d29dc3178546597f5cac2f87d7b77b42d4c89a9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_1.txt @@ -0,0 +1,14 @@ +While the main concepts discussed in this guide are likely applicable across frameworks, here we focus on +PyTorch-based implementations. + +Before diving deeper into the specifics of each technique, let's go over the rough decision process when training +large models on a large infrastructure. +Scalability strategy +Begin by estimating how much vRAM is required to train your model. For models hosted on the 🤗 Hub, use our +Model Memory Calculator, which gives you +accurate calculations within a few percent margin. +Parallelization strategy for a single Node / multi-GPU setup +When training a model on a single node with multiple GPUs, your choice of parallelization strategy can significantly +impact performance. Here's a breakdown of your options: +Case 1: Your model fits onto a single GPU +If your model can comfortably fit onto a single GPU, you have two primary options: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_10.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_10.txt new file mode 100644 index 0000000000000000000000000000000000000000..d49dcb04f29f5c492d90250b6745b900da2e600e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_10.txt @@ -0,0 +1,25 @@ +While it may appear complex, it is a very similar concept to DataParallel (DP). The difference is that instead of +replicating the full model parameters, gradients and optimizer states, each GPU stores only a slice of it. Then, at +run-time when the full layer parameters are needed just for the given layer, all GPUs synchronize to give each other +parts that they miss. +To illustrate this idea, consider a simple model with 3 layers (La, Lb, and Lc), where each layer has 3 parameters. +Layer La, for example, has weights a0, a1 and a2: +La | Lb | Lc +---|----|--- +a0 | b0 | c0 +a1 | b1 | c1 +a2 | b2 | c2 +If we have 3 GPUs, ZeRO-DP splits the model onto 3 GPUs like so: + +GPU0: +La | Lb | Lc +---|----|--- +a0 | b0 | c0 +GPU1: +La | Lb | Lc +---|----|--- +a1 | b1 | c1 +GPU2: +La | Lb | Lc +---|----|--- +a2 | b2 | c2 \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_11.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_11.txt new file mode 100644 index 0000000000000000000000000000000000000000..da321ec4d7ae7ddf9f6d1e1ebc3c7574475c176a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_11.txt @@ -0,0 +1,16 @@ +In a way, this is the same horizontal slicing as tensor parallelism, as opposed to Vertical +slicing, where one puts whole layer-groups on different GPUs. Now let's see how this works: +Each of these GPUs will get the usual mini-batch as it works in DP: +x0 => GPU0 +x1 => GPU1 +x2 => GPU2 +The inputs are passed without modifications as if they would be processed by the original model. +First, the inputs get to the layer La. What happens at this point? +On GPU0: the x0 mini-batch requires the a0, a1, a2 parameters to do its forward path through the layer, but the GPU0 has only a0. +It will get a1 from GPU1 and a2 from GPU2, bringing all the pieces of the model together. +In parallel, GPU1 gets another mini-batch - x1. GPU1 has the a1 parameter, but needs a0 and a2, so it gets those from GPU0 and GPU2. +Same happens to GPU2 that gets the mini-batch x2. It gets a0 and a1 from GPU0 and GPU1. +This way each of the 3 GPUs gets the full tensors reconstructed and makes a forward pass with its own mini-batch. +As soon as the calculation is done, the data that is no longer needed gets dropped - it's only used during the calculation. +The reconstruction is done efficiently via a pre-fetch. +Then the whole process is repeated for layer Lb, then Lc forward-wise, and then backward Lc -> Lb -> La. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_12.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_12.txt new file mode 100644 index 0000000000000000000000000000000000000000..ce486a0fce1e56c31922beece45fed7aa7991cb0 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_12.txt @@ -0,0 +1,11 @@ +This mechanism is similar to an efficient group backpacking strategy: person A carries the tent, person B carries the stove, +and person C carries the axe. Each night they all share what they have with others and get from others what they don't have, +and in the morning they pack up their allocated type of gear and continue on their way. This is what ZeRO DP/Sharded DDP is. +Compare this strategy to the simple one where each person has to carry their own tent, stove and axe (similar to +DataParallel (DP and DDP) in PyTorch), which would be far more inefficient. + +While reading the literature on this topic you may encounter the following synonyms: Sharded, Partitioned. +If you pay close attention the way ZeRO partitions the model's weights - it looks very similar to tensor parallelism +which will be discussed later. This is because it partitions/shards each layer's weights, unlike vertical model parallelism +which is discussed next. +Implementations: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_13.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_13.txt new file mode 100644 index 0000000000000000000000000000000000000000..a15ae06bf0ca2ee943f80aa1da6b280ce23a1412 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_13.txt @@ -0,0 +1,24 @@ +DeepSpeed ZeRO-DP stages 1+2+3 +Accelerate integration +transformers integration + +From Naive Model Parallelism to Pipeline Parallelism +To explain Pipeline parallelism, we'll first look into Naive Model Parallelism (MP), also known as Vertical MP. This approach +involves distributing groups of model layers across multiple GPUs by assigning specific layers to specific GPUs with .to(). +As data flows through these layers, it is moved to the same GPU as the layer, while the other layers remain untouched. +We refer to this Model parallelism as "Vertical" because of how models are typically visualized. For example, the +following diagram shows an 8-layer model split vertically into two slices, placing layers 0-3 onto +GPU0 and 4-7 to GPU1: + +| Layer | | +| 0 | | +| 1 | GPU0 | +| 2 | | +| 3 | | +================ +| Layer | | +| 4 | | +| 5 | GPU1 | +| 6 | | +| 7 | | +================ \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_14.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_14.txt new file mode 100644 index 0000000000000000000000000000000000000000..d73dea609a7bd4b43d0d070667600d4d436a47d9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_14.txt @@ -0,0 +1,16 @@ +In this example, when data moves from layer 0 to 3, it's no different from regular forward pass. However, passing data +from layer 3 to 4 requires moving it from GPU0 to GPU1, introducing a communication overhead. If the participating +GPUs are on the same compute node (e.g. same physical machine) this copying is fast, but if the GPUs are distributed +across different compute nodes (e.g. multiple machines), the communication overhead could be substantially greater. +Following that, layers 4 to 7 work as they would in the original model. Upon completion of the 7th layer, there is often +a need to send the data back to layer 0 where the labels are (or alternatively send the labels to the last layer). Now the loss can be +computed and the optimizer can do its work. +Naive Model Parallelism comes several shortcomings: +- All but one GPU are idle at any given moment: if 4 GPUs are used, it's nearly identical to quadrupling the amount of memory of a single GPU, and ignoring the rest of the hardware. +- Overhead in data transfer between devices: E.g. 4x 6GB cards will be able to accommodate the same size as 1x 24GB card using naive MP, but a single 24GB card will complete the training faster, because it doesn't have the data copying overhead. But, say, if you have 40GB cards and need to fit a 45GB model you can with 4x 40GB cards (but barely because of the gradient and optimizer states) +- Copying shared embeddings: Shared embeddings may need to get copied back and forth between GPUs. +Now that you are familiar with how the naive approach to model parallelism works and its shortcomings, let's look at Pipeline Parallelism (PP). +PP is almost identical to a naive MP, but it solves the GPU idling problem by chunking the incoming batch into micro-batches +and artificially creating a pipeline, which allows different GPUs to concurrently participate in the computation process. +The following illustration from the GPipe paper +shows the naive MP on the top, and PP on the bottom: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_15.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_15.txt new file mode 100644 index 0000000000000000000000000000000000000000..ed4e9a3d3ebe23290143c93dd204278e5f025be6 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_15.txt @@ -0,0 +1,49 @@ +At the bottom of the diagram, you can observe that the Pipeline Parallelism (PP) approach minimizes the number of idle +GPU zones, referred to as 'bubbles'. Both parts of the diagram show a parallelism level of degree 4, meaning that 4 GPUs +are involved in the pipeline. You can see that there's a forward path of 4 pipe stages (F0, F1, F2 and F3) followed by +a backward path in reverse order (B3, B2, B1, and B0). +PP introduces a new hyperparameter to tune - chunks, which determines how many data chunks are sent in a sequence +through the same pipe stage. For example, in the bottom diagram you can see chunks=4. GPU0 performs the same +forward path on chunk 0, 1, 2 and 3 (F0,0, F0,1, F0,2, F0,3) and then it waits for other GPUs to do complete their work. +Only when the other GPUs begin to complete their work, GPU0 starts to work again doing the backward path for chunks +3, 2, 1 and 0 (B0,3, B0,2, B0,1, B0,0). +Note that this is the same concept as gradient accumulation steps. PyTorch uses chunks, while DeepSpeed refers +to the same hyperparameter as gradient accumulation steps. +Because of the chunks, PP introduces the notion of micro-batches (MBS). DP splits the global data batch size into +mini-batches, so if you have a DP degree of 4, a global batch size of 1024 gets split up into 4 mini-batches of +256 each (1024/4). And if the number of chunks (or GAS) is 32 we end up with a micro-batch size of 8 (256/32). Each +Pipeline stage works with a single micro-batch at a time. To calculate the global batch size of the DP + PP setup, +use the formula: mbs * chunks * dp_degree (8 * 32 * 4 = 1024). +With chunks=1 you end up with the naive MP, which is inefficient. With a large chunks value you end up with +tiny micro-batch sizes which is also inefficient. For this reason, we encourage to experiment with the chunks value to +find the one that leads to the most efficient GPUs utilization. +You may notice a bubble of "dead" time on the diagram that can't be parallelized because the last forward stage +has to wait for backward to complete the pipeline. The purpose of finding the best value for chunks is to enable a high +concurrent GPU utilization across all participating GPUs which translates to minimizing the size of the bubble. +Pipeline API solutions have been implemented in: +- PyTorch +- DeepSpeed +- Megatron-LM +These come with some shortcomings: +- They have to modify the model quite heavily, because Pipeline requires one to rewrite the normal flow of modules into a nn.Sequential sequence of the same, which may require changes to the design of the model. +- Currently the Pipeline API is very restricted. If you had a bunch of Python variables being passed in the very first stage of the Pipeline, you will have to find a way around it. Currently, the pipeline interface requires either a single Tensor or a tuple of Tensors as the only input and output. These tensors must have a batch size as the very first dimension, since pipeline is going to chunk the mini batch into micro-batches. Possible improvements are being discussed here https://github.com/pytorch/pytorch/pull/50693 +- Conditional control flow at the level of pipe stages is not possible - e.g., Encoder-Decoder models like T5 require special workarounds to handle a conditional encoder stage. +- They have to arrange each layer so that the output of one layer becomes an input to the other layer. +More recent solutions include: +- Varuna +- Sagemaker +We have not experimented with Varuna and SageMaker but their papers report that they have overcome the list of problems +mentioned above and that they require smaller changes to the user's model. +Implementations: +- PyTorch (initial support in pytorch-1.8, and progressively getting improved in 1.9 and more so in 1.10). Some examples +- DeepSpeed +- Megatron-LM has an internal implementation - no API. +- Varuna +- SageMaker - this is a proprietary solution that can only be used on AWS. +- OSLO - this is implemented based on the Hugging Face Transformers. +🤗 Transformers status: as of this writing none of the models supports full-PP. GPT2 and T5 models have naive MP support. +The main obstacle is being unable to convert the models to nn.Sequential and have all the inputs to be Tensors. This +is because currently the models include many features that make the conversion very complicated, and will need to be removed to accomplish that. +DeepSpeed and Megatron-LM integrations are available in 🤗 Accelerate +Other approaches: +DeepSpeed, Varuna and SageMaker use the concept of an Interleaved Pipeline \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_16.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_16.txt new file mode 100644 index 0000000000000000000000000000000000000000..72e2bd7273857e8dbf072d526ac42e339cd8e119 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_16.txt @@ -0,0 +1,11 @@ +Here the bubble (idle time) is further minimized by prioritizing backward passes. Varuna further attempts to improve the +schedule by using simulations to discover the most efficient scheduling. +OSLO has pipeline parallelism implementation based on the Transformers without nn.Sequential conversion. +Tensor Parallelism +In Tensor Parallelism, each GPU processes a slice of a tensor and only aggregates the full tensor for operations requiring it. +To describe this method, this section of the guide relies on the concepts and diagrams from the Megatron-LM +paper: Efficient Large-Scale Language Model Training on GPU Clusters. +The main building block of any transformer is a fully connected nn.Linear followed by a nonlinear activation GeLU. +The dot dot-product part of it, following the Megatron's paper notation, can be written as Y = GeLU(XA), where X is +an input vector, Y is the output vector, and A is the weight matrix. +If we look at the computation in matrix form, you can see how the matrix multiplication can be split between multiple GPUs: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_17.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_17.txt new file mode 100644 index 0000000000000000000000000000000000000000..a05e1f39f6d77d8fec5c1370eb4b3f4b793ad449 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_17.txt @@ -0,0 +1,9 @@ +If we split the weight matrix A column-wise across N GPUs and perform matrix multiplications XA_1 through XA_n in parallel, +then we will end up with N output vectors Y_1, Y_2, , Y_n which can be fed into GeLU independently: + +Using this principle, we can update a multi-layer perceptron of arbitrary depth, without the need for any synchronization +between GPUs until the very end, where we need to reconstruct the output vector from shards. The Megatron-LM paper authors +provide a helpful illustration for that: + +Parallelizing the multi-headed attention layers is even simpler, since they are already inherently parallel, due to having +multiple independent heads! \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_18.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_18.txt new file mode 100644 index 0000000000000000000000000000000000000000..5fd295bd6328cc05a0bbbfe87180ab498083c17b --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_18.txt @@ -0,0 +1,21 @@ +Special considerations: TP requires very fast network, and therefore it's not advisable to do TP across more than one node. +Practically, if a node has 4 GPUs, the highest TP degree is therefore 4. If you need a TP degree of 8, you need to use +nodes that have at least 8 GPUs. +This section is based on the original much more detailed TP overview. +by @anton-l. +Alternative names: +- DeepSpeed calls it tensor slicing +Implementations: +- Megatron-LM has an internal implementation, as it's very model-specific +- parallelformers (only inference at the moment) +- SageMaker - this is a proprietary solution that can only be used on AWS. +- OSLO has the tensor parallelism implementation based on the Transformers. +SageMaker combines TP with DP for a more efficient processing. +🤗 Transformers status: +- core: not yet implemented in the core +- but if you want inference parallelformers provides this support for most of our models. So until this is implemented in the core you can use theirs. And hopefully training mode will be supported too. +- Deepspeed-Inference also supports our BERT, GPT-2, and GPT-Neo models in their super-fast CUDA-kernel-based inference mode, see more here +🤗 Accelerate integrates with TP from Megatron-LM. +Data Parallelism + Pipeline Parallelism +The following diagram from the DeepSpeed pipeline tutorial demonstrates +how one can combine DP with PP. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_19.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_19.txt new file mode 100644 index 0000000000000000000000000000000000000000..ae0d9da4c36f85183f4ff0c2aa5d8717416c6ea0 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_19.txt @@ -0,0 +1,13 @@ +Here it's important to see how DP rank 0 doesn't see GPU2 and DP rank 1 doesn't see GPU3. To DP there is just GPUs 0 +and 1 where it feeds data as if there were just 2 GPUs. GPU0 "secretly" offloads some of its load to GPU2 using PP. +And GPU1 does the same by enlisting GPU3 to its aid. +Since each dimension requires at least 2 GPUs, here you'd need at least 4 GPUs. +Implementations: +- DeepSpeed +- Megatron-LM +- Varuna +- SageMaker +- OSLO +🤗 Transformers status: not yet implemented +Data Parallelism + Pipeline Parallelism + Tensor Parallelism +To get an even more efficient training a 3D parallelism is used where PP is combined with TP and DP. This can be seen in the following diagram. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..7b963d53da1b830c5fbb5ed01970f4dc201299de --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_2.txt @@ -0,0 +1,15 @@ +DDP - Distributed DataParallel +Zero Redundancy Optimizer (ZeRO) - depending on the situation and configuration used, this method may or may not be faster, however, it's worth experimenting with it. + +Case 2: Your model doesn't fit onto a single GPU: +If your model is too large for a single GPU, you have several alternatives to consider: + +PipelineParallel (PP) +ZeRO +TensorParallel (TP) + +With very fast inter-node connectivity (e.g., NVLINK or NVSwitch) all three strategies (PP, ZeRO, TP) should result in +similar performance. However, without these, PP will be faster than TP or ZeRO. The degree of TP may also +make a difference. It's best to experiment with your specific setup to determine the most suitable strategy. +TP is almost always used within a single node. That is TP size <= GPUs per node. +Case 3: Largest layer of your model does not fit onto a single GPU \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_20.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_20.txt new file mode 100644 index 0000000000000000000000000000000000000000..0eea8bba6581daf1a850db396b4a49cc3f064838 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_20.txt @@ -0,0 +1,27 @@ +This diagram is from a blog post 3D parallelism: Scaling to trillion-parameter models, which is a good read as well. +Since each dimension requires at least 2 GPUs, here you'd need at least 8 GPUs. +Implementations: +- DeepSpeed - DeepSpeed also includes an even more efficient DP, which they call ZeRO-DP. +- Megatron-LM +- Varuna +- SageMaker +- OSLO +🤗 Transformers status: not yet implemented, since we have no PP and TP. +ZeRO Data Parallelism + Pipeline Parallelism + Tensor Parallelism +One of the main features of DeepSpeed is ZeRO, which is a super-scalable extension of DP. It has already been +discussed in ZeRO Data Parallelism. Normally it's a standalone feature that doesn't require PP or TP. +But it can be combined with PP and TP. +When ZeRO-DP is combined with PP (and optionally TP) it typically enables only ZeRO stage 1 (optimizer sharding). +While it's theoretically possible to use ZeRO stage 2 (gradient sharding) with Pipeline Parallelism, it will have negative +performance impacts. There would need to be an additional reduce-scatter collective for every micro-batch to aggregate +the gradients before sharding, which adds a potentially significant communication overhead. By nature of Pipeline Parallelism, +small micro-batches are used and instead the focus is on trying to balance arithmetic intensity (micro-batch size) with +minimizing the Pipeline bubble (number of micro-batches). Therefore those communication costs are going to impact the performance. +In addition, there are already fewer layers than normal due to PP and so the memory savings won't be huge. PP already +reduces gradient size by 1/PP, and so gradient sharding savings on top of that are less significant than pure DP. +ZeRO stage 3 is not a good choice either for the same reason - more inter-node communications required. +And since we have ZeRO, the other benefit is ZeRO-Offload. Since this is stage 1 optimizer states can be offloaded to CPU. +Implementations: +- Megatron-DeepSpeed and Megatron-Deepspeed from BigScience, which is the fork of the former repo. +- OSLO +Important papers: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_21.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_21.txt new file mode 100644 index 0000000000000000000000000000000000000000..90c1342eaa1eaba1b5cca685cea974089eb41bb9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_21.txt @@ -0,0 +1,18 @@ +Using DeepSpeed and Megatron to Train Megatron-Turing NLG 530B, A Large-Scale Generative Language Model + +🤗 Transformers status: not yet implemented, since we have no PP and TP. +FlexFlow +FlexFlow also solves the parallelization problem in a slightly different approach. +Paper: "Beyond Data and Model Parallelism for Deep Neural Networks" by Zhihao Jia, Matei Zaharia, Alex Aiken +It performs a sort of 4D Parallelism over Sample-Operator-Attribute-Parameter. + +Sample = Data Parallelism (sample-wise parallel) +Operator = Parallelize a single operation into several sub-operations +Attribute = Data Parallelism (length-wise parallel) +Parameter = Model Parallelism (regardless of dimension - horizontal or vertical) + +Examples: +* Sample +Let's take 10 batches of sequence length 512. If we parallelize them by sample dimension into 2 devices, we get 10 x 512 which becomes be 5 x 2 x 512. + +Operator \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_22.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_22.txt new file mode 100644 index 0000000000000000000000000000000000000000..e01e026cd0eea6feda3251469e6b8752d7daafa1 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_22.txt @@ -0,0 +1,13 @@ +Operator + +If we perform layer normalization, we compute std first and mean second, and then we can normalize data. +Operator parallelism allows computing std and mean in parallel. So if we parallelize them by operator dimension into 2 +devices (cuda:0, cuda:1), first we copy input data into both devices, and cuda:0 computes std, cuda:1 computes mean at the same time. + +Attribute + +We have 10 batches of 512 length. If we parallelize them by attribute dimension into 2 devices, 10 x 512 will be 10 x 2 x 256. + +Parameter + +It is similar with tensor model parallelism or naive layer-wise model parallelism. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_23.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_23.txt new file mode 100644 index 0000000000000000000000000000000000000000..897c2735b6612c1a634f7e12a8fda1dcb5cff63e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_23.txt @@ -0,0 +1,14 @@ +The significance of this framework is that it takes resources like (1) GPU/TPU/CPU vs. (2) RAM/DRAM vs. (3) +fast-intra-connect/slow-inter-connect and it automatically optimizes all these algorithmically deciding which +parallelisation to use where. +One very important aspect is that FlexFlow is designed for optimizing DNN parallelizations for models with static and +fixed workloads, since models with dynamic behavior may prefer different parallelization strategies across iterations. +So the promise is very attractive - it runs a 30min simulation on the cluster of choice and it comes up with the best +strategy to utilise this specific environment. If you add/remove/replace any parts it'll run and re-optimize the plan +for that. And then you can train. A different setup will have its own custom optimization. +🤗 Transformers status: Transformers models are FX-trace-able via transformers.utils.fx, +which is a prerequisite for FlexFlow, however, changes are required on the FlexFlow side to make it work with Transformers models. +GPU selection +When training on multiple GPUs, you can specify the number of GPUs to use and in what order. This can be useful for instance when you have GPUs with different computing power and want to use the faster GPU first. The selection process works for both DistributedDataParallel and DataParallel to use only a subset of the available GPUs, and you don't need Accelerate or the DeepSpeed integration. +Number of GPUs +For example, if you have 4 GPUs and you only want to use the first 2: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_24.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_24.txt new file mode 100644 index 0000000000000000000000000000000000000000..5afce856a5f4d0d762107bda37a5bb36ce018c85 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_24.txt @@ -0,0 +1,17 @@ +Use the --nproc_per_node to select how many GPUs to use. + +torchrun --nproc_per_node=2 trainer-program.py + +Use --num_processes to select how many GPUs to use. + +accelerate launch --num_processes 2 trainer-program.py + +Use --num_gpus to select how many GPUs to use. + +deepspeed --num_gpus 2 trainer-program.py + +Order of GPUs +Now, to select which GPUs to use and their order, you'll use the CUDA_VISIBLE_DEVICES environment variable. It is easiest to set the environment variable in a ~/bashrc or another startup config file. CUDA_VISIBLE_DEVICES is used to map which GPUs are used. For example, if you have 4 GPUs (0, 1, 2, 3) and you only want to run GPUs 0 and 2: + +CUDA_VISIBLE_DEVICES=0,2 torchrun trainer-program.py +Only the 2 physical GPUs (0 and 2) are "visible" to PyTorch and these are mapped to cuda:0 and cuda:1 respectively. You can also reverse the order of the GPUs to use 2 first. Now, the mapping is cuda:1 for GPU 0 and cuda:0 for GPU 2. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_25.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_25.txt new file mode 100644 index 0000000000000000000000000000000000000000..bbf6f3e5ffb3c0139fb82c95df6a629ceec00c54 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_25.txt @@ -0,0 +1,14 @@ +CUDA_VISIBLE_DEVICES=2,0 torchrun trainer-program.py +You can also set the CUDA_VISIBLE_DEVICES environment variable to an empty value to create an environment without GPUs. + +CUDA_VISIBLE_DEVICES= python trainer-program.py + +As with any environment variable, they can be exported instead of being added to the command line. However, this is not recommended because it can be confusing if you forget how the environment variable was setup and you end up using the wrong GPUs. Instead, it is common practice to set the environment variable for a specific training run on the same command line. + +CUDA_DEVICE_ORDER is an alternative environment variable you can use to control how the GPUs are ordered. You can either order them by: + +PCIe bus ID's that matches the order of nvidia-smi and rocm-smi for NVIDIA and AMD GPUs respectively + +export CUDA_DEVICE_ORDER=PCI_BUS_ID + +GPU compute ability \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_26.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_26.txt new file mode 100644 index 0000000000000000000000000000000000000000..91d7164eb8dce02a14a3310a525ac692780a9382 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_26.txt @@ -0,0 +1,6 @@ +export CUDA_DEVICE_ORDER=PCI_BUS_ID + +GPU compute ability + +export CUDA_DEVICE_ORDER=FASTEST_FIRST +The CUDA_DEVICE_ORDER is especially useful if your training setup consists of an older and newer GPU, where the older GPU appears first, but you cannot physically swap the cards to make the newer GPU appear first. In this case, set CUDA_DEVICE_ORDER=FASTEST_FIRST to always use the newer and faster GPU first (nvidia-smi or rocm-smi still reports the GPUs in their PCIe order). Or you could also set export CUDA_VISIBLE_DEVICES=1,0. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..a05a0694c63e6c52b4c39f553fcbabda5ef04b4a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_3.txt @@ -0,0 +1,13 @@ +If you are not using ZeRO, you have to use TensorParallel (TP), because PipelineParallel (PP) alone won't be sufficient to accommodate the large layer. +If you are using ZeRO, additionally adopt techniques from the Methods and tools for efficient training on a single GPU. + +Parallelization strategy for a multi-Node / multi-GPU setup + +When you have fast inter-node connectivity (e.g., NVLINK or NVSwitch) consider using one of these options: + +ZeRO - as it requires close to no modifications to the model +A combination of PipelineParallel(PP) with TensorParallel(TP) and DataParallel(DP) - this approach will result in fewer communications, but requires significant changes to the model + +When you have slow inter-node connectivity and still low on GPU memory: + +Employ a combination of DataParallel(DP) with PipelineParallel(PP), TensorParallel(TP), and ZeRO. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..5f0d83c2cdc024743f50e13a63ceca5d92a43efc --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_4.txt @@ -0,0 +1,12 @@ +Employ a combination of DataParallel(DP) with PipelineParallel(PP), TensorParallel(TP), and ZeRO. + +In the following sections of this guide we dig deeper into how these different parallelism methods work. +Data Parallelism +Even with only 2 GPUs, you can readily leverage the accelerated training capabilities offered by PyTorch's built-in features, +such as DataParallel (DP) and DistributedDataParallel (DDP). Note that +PyTorch documentation recommends to prefer +DistributedDataParallel (DDP) over DataParallel (DP) for multi-GPU training as it works for all models. +Let's take a look at how these two methods work and what makes them different. +DataParallel vs DistributedDataParallel +To understand the key differences in inter-GPU communication overhead between the two methods, let's review the processes per batch: +DDP: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..59993883e19c3992a6dced39b4a8157e7737f5c9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_5.txt @@ -0,0 +1,4 @@ +At the start time the main process replicates the model once from GPU 0 to the rest of GPUs +Then for each batch: +Each GPU directly consumes its mini-batch of data. +During backward, once the local gradients are ready, they are averaged across all processes. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..ba653cfd520ce152c9e9cc7a06293e799f4eb90e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_6.txt @@ -0,0 +1,17 @@ +DP: +For each batch: + 1. GPU 0 reads the batch of data and then sends a mini-batch to each GPU. + 2. The up-to-date model is replicated from GPU 0 to each GPU. + 3. forward is executed, and output from each GPU is sent to GPU 0 to compute the loss. + 4. The loss is distributed from GPU 0 to all GPUs, and backward is run. + 5. Gradients from each GPU are sent to GPU 0 and averaged. +Key differences include: +1. DDP performs only a single communication per batch - sending gradients, while DP performs five different data exchanges per batch. +DDP copies data using torch.distributed, while DP copies data within +the process via Python threads (which introduces limitations associated with GIL). As a result, DistributedDataParallel (DDP) is generally faster than DataParallel (DP) unless you have slow GPU card inter-connectivity. +2. Under DP, GPU 0 performs significantly more work than other GPUs, resulting in GPU under-utilization. +3. DDP supports distributed training across multiple machines, whereas DP does not. +This is not an exhaustive list of differences between DP and DDP, however, other nuances are out of scope of this guide. +You can get a deeper understanding of these methods by reading this article. +Let's illustrate the differences between DP and DDP with an experiment. We'll benchmark the differences between DP and +DDP with an added context of NVLink presence: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..fe523b1ef567f0934ae68a78cae028a8ad5e5a7e --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_7.txt @@ -0,0 +1,12 @@ +Hardware: 2x TITAN RTX 24GB each + NVlink with 2 NVLinks (NV2 in nvidia-smi topo -m). +Software: pytorch-1.8-to-be + cuda-11.0 / transformers==4.3.0.dev0. + +To disable the NVLink feature on one of the benchmarks, we use NCCL_P2P_DISABLE=1. +Here is the benchmarking code and outputs: +DP +```bash +rm -r /tmp/test-clm; CUDA_VISIBLE_DEVICES=0,1 \ +python examples/pytorch/language-modeling/run_clm.py \ +--model_name_or_path openai-community/gpt2 --dataset_name wikitext --dataset_config_name wikitext-2-raw-v1 \ +--do_train --output_dir /tmp/test-clm --per_device_train_batch_size 4 --max_steps 200 +{'train_runtime': 110.5948, 'train_samples_per_second': 1.808, 'epoch': 0.69} \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..0f473e04d7ba7bd7fc0b9cceb17d7627485df90f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_8.txt @@ -0,0 +1,15 @@ +DDP w/ NVlink +```bash +rm -r /tmp/test-clm; CUDA_VISIBLE_DEVICES=0,1 \ +torchrun --nproc_per_node 2 examples/pytorch/language-modeling/run_clm.py \ +--model_name_or_path openai-community/gpt2 --dataset_name wikitext --dataset_config_name wikitext-2-raw-v1 \ +--do_train --output_dir /tmp/test-clm --per_device_train_batch_size 4 --max_steps 200 +{'train_runtime': 101.9003, 'train_samples_per_second': 1.963, 'epoch': 0.69} + +DDP w/o NVlink +```bash +rm -r /tmp/test-clm; NCCL_P2P_DISABLE=1 CUDA_VISIBLE_DEVICES=0,1 \ +torchrun --nproc_per_node 2 examples/pytorch/language-modeling/run_clm.py \ +--model_name_or_path openai-community/gpt2 --dataset_name wikitext --dataset_config_name wikitext-2-raw-v1 \ +--do_train --output_dir /tmp/test-clm --per_device_train_batch_size 4 --max_steps 200 +{'train_runtime': 131.4367, 'train_samples_per_second': 1.522, 'epoch': 0.69} \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..c7cb3465c0b6a2972a19b624116e459fd0ced594 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_many.txt_chunk_9.txt @@ -0,0 +1,11 @@ +Here are the same benchmarking results gathered in a table for convenience: +| Type | NVlink | Time | +| :----- | ----- | ---: | +| 2:DP | Y | 110s | +| 2:DDP | Y | 101s | +| 2:DDP | N | 131s | +As you can see, in this case DP is ~10% slower than DDP with NVlink, but ~15% faster than DDP without NVlink. +The real difference will depend on how much data each GPU needs to sync with the others - the more there is to sync, +the more a slow link will impede the overall runtime. +ZeRO Data Parallelism +ZeRO-powered data parallelism (ZeRO-DP) is illustrated in the following diagram from this blog post. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..17e2cee01ab9b8baea794d3b14d5763a3fb60f09 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_0.txt @@ -0,0 +1,12 @@ +Methods and tools for efficient training on a single GPU +This guide demonstrates practical techniques that you can use to increase the efficiency of your model's training by +optimizing memory utilization, speeding up the training, or both. If you'd like to understand how GPU is utilized during +training, please refer to the Model training anatomy conceptual guide first. This guide +focuses on practical techniques. + +If you have access to a machine with multiple GPUs, these approaches are still valid, plus you can leverage additional methods outlined in the multi-GPU section. + +When training large models, there are two aspects that should be considered at the same time: + +Data throughput/training time +Model performance \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..4aa7a0bc856139e35291af0efa67c99801561a8f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_1.txt @@ -0,0 +1,18 @@ +Maximizing the throughput (samples/second) leads to lower training cost. This is generally achieved by utilizing the GPU +as much as possible and thus filling GPU memory to its limit. If the desired batch size exceeds the limits of the GPU memory, +the memory optimization techniques, such as gradient accumulation, can help. +However, if the preferred batch size fits into memory, there's no reason to apply memory-optimizing techniques because they can +slow down the training. Just because one can use a large batch size, does not necessarily mean they should. As part of +hyperparameter tuning, you should determine which batch size yields the best results and then optimize resources accordingly. +The methods and tools covered in this guide can be classified based on the effect they have on the training process: +| Method/tool | Improves training speed | Optimizes memory utilization | +|:-----------------------------------------------------------|:------------------------|:-----------------------------| +| Batch size choice | Yes | Yes | +| Gradient accumulation | No | Yes | +| Gradient checkpointing | No | Yes | +| Mixed precision training | Yes | (No) | +| Optimizer choice | Yes | Yes | +| Data preloading | Yes | No | +| DeepSpeed Zero | No | Yes | +| torch.compile | Yes | No | +| Parameter-Efficient Fine Tuning (PEFT) | No | Yes | \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_10.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_10.txt new file mode 100644 index 0000000000000000000000000000000000000000..e60c9596aac6892d7caa9df36588825d88d21aa9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_10.txt @@ -0,0 +1,2 @@ +DataLoader(pin_memory=True, ) - ensures the data gets preloaded into the pinned memory on CPU and typically leads to much faster transfers from CPU to GPU memory. +DataLoader(num_workers=4, ) - spawn several workers to preload data faster. During training, watch the GPU utilization stats; if it's far from 100%, experiment with increasing the number of workers. Of course, the problem could be elsewhere, so many workers won't necessarily lead to better performance. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_11.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_11.txt new file mode 100644 index 0000000000000000000000000000000000000000..bdfab93d17c76f2c5f2d9704398932a0847fd343 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_11.txt @@ -0,0 +1,10 @@ +When using [Trainer], the corresponding [TrainingArguments] are: dataloader_pin_memory (True by default), and dataloader_num_workers (defaults to 0). +DeepSpeed ZeRO +DeepSpeed is an open-source deep learning optimization library that is integrated with 🤗 Transformers and 🤗 Accelerate. +It provides a wide range of features and optimizations designed to improve the efficiency and scalability of large-scale +deep learning training. +If your model fits onto a single GPU and you have enough space to fit a small batch size, you don't need to use DeepSpeed +as it'll only slow things down. However, if the model doesn't fit onto a single GPU or you can't fit a small batch, you can +leverage DeepSpeed ZeRO + CPU Offload, or NVMe Offload for much larger models. In this case, you need to separately +install the library, then follow one of the guides to create a configuration file +and launch DeepSpeed: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_12.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_12.txt new file mode 100644 index 0000000000000000000000000000000000000000..c02217ea2818416f86c6cdfa54e3792bb7ecfa30 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_12.txt @@ -0,0 +1,3 @@ +For an in-depth guide on DeepSpeed integration with [Trainer], review the corresponding documentation, specifically the +section for a single GPU. Some adjustments are required to use DeepSpeed in a notebook; please take a look at the corresponding guide. +If you prefer to use 🤗 Accelerate, refer to 🤗 Accelerate DeepSpeed guide. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_13.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_13.txt new file mode 100644 index 0000000000000000000000000000000000000000..a56cec5e66dfb2f33e84c9a86f48510dfa6f55eb --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_13.txt @@ -0,0 +1,49 @@ +Using torch.compile +PyTorch 2.0 introduced a new compile function that doesn't require any modification to existing PyTorch code but can +optimize your code by adding a single line of code: model = torch.compile(model). +If using [Trainer], you only need to pass the torch_compile option in the [TrainingArguments]: +python +training_args = TrainingArguments(torch_compile=True, **default_args) +torch.compile uses Python's frame evaluation API to automatically create a graph from existing PyTorch programs. After +capturing the graph, different backends can be deployed to lower the graph to an optimized engine. +You can find more details and benchmarks in PyTorch documentation. +torch.compile has a growing list of backends, which can be found in by calling torchdynamo.list_backends(), each of which with its optional dependencies. +Choose which backend to use by specifying it via torch_compile_backend in the [TrainingArguments]. Some of the most commonly used backends are: +Debugging backends: +* dynamo.optimize("eager") - Uses PyTorch to run the extracted GraphModule. This is quite useful in debugging TorchDynamo issues. +* dynamo.optimize("aot_eager") - Uses AotAutograd with no compiler, i.e, just using PyTorch eager for the AotAutograd's extracted forward and backward graphs. This is useful for debugging, and unlikely to give speedups. +Training & inference backends: +* dynamo.optimize("inductor") - Uses TorchInductor backend with AotAutograd and cudagraphs by leveraging codegened Triton kernels Read more +* dynamo.optimize("nvfuser") - nvFuser with TorchScript. Read more +* dynamo.optimize("aot_nvfuser") - nvFuser with AotAutograd. Read more +* dynamo.optimize("aot_cudagraphs") - cudagraphs with AotAutograd. Read more +Inference-only backends: +* dynamo.optimize("ofi") - Uses Torchscript optimize_for_inference. Read more +* dynamo.optimize("fx2trt") - Uses NVIDIA TensorRT for inference optimizations. Read more +* dynamo.optimize("onnxrt") - Uses ONNXRT for inference on CPU/GPU. Read more +* dynamo.optimize("ipex") - Uses IPEX for inference on CPU. Read more +For an example of using torch.compile with 🤗 Transformers, check out this blog post on fine-tuning a BERT model for Text Classification using the newest PyTorch 2.0 features +Using 🤗 PEFT +Parameter-Efficient Fine Tuning (PEFT) methods freeze the pretrained model parameters during fine-tuning and add a small number of trainable parameters (the adapters) on top of it. +As a result the memory associated to the optimizer states and gradients are greatly reduced. +For example with a vanilla AdamW, the memory requirement for the optimizer state would be: +* fp32 copy of parameters: 4 bytes/param +* Momentum: 4 bytes/param +* Variance: 4 bytes/param +Suppose a model with 7B parameters and 200 millions parameters injected with Low Rank Adapters. +The memory requirement for the optimizer state of the plain model would be 12 * 7 = 84 GB (assuming 7B trainable parameters). +Adding Lora increases slightly the memory associated to the model weights and substantially decreases memory requirement for the optimizer state to 12 * 0.2 = 2.4GB. +Read more about PEFT and its detailed usage in the PEFT documentation or PEFT repository. +Using 🤗 Accelerate +With 🤗 Accelerate you can use the above methods while gaining full +control over the training loop and can essentially write the loop in pure PyTorch with some minor modifications. +Suppose you have combined the methods in the [TrainingArguments] like so: +py +training_args = TrainingArguments( + per_device_train_batch_size=1, + gradient_accumulation_steps=4, + gradient_checkpointing=True, + fp16=True, + **default_args, +) +The full example training loop with 🤗 Accelerate is only a handful of lines of code long: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_14.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_14.txt new file mode 100644 index 0000000000000000000000000000000000000000..99453f15d14b4fcd96f2b26374064282f7dd537b --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_14.txt @@ -0,0 +1,15 @@ +from accelerate import Accelerator +from torch.utils.data.dataloader import DataLoader +dataloader = DataLoader(ds, batch_size=training_args.per_device_train_batch_size) +if training_args.gradient_checkpointing: + model.gradient_checkpointing_enable() +accelerator = Accelerator(fp16=training_args.fp16) +model, optimizer, dataloader = accelerator.prepare(model, adam_bnb_optim, dataloader) +model.train() +for step, batch in enumerate(dataloader, start=1): + loss = model(**batch).loss + loss = loss / training_args.gradient_accumulation_steps + accelerator.backward(loss) + if step % training_args.gradient_accumulation_steps == 0: + optimizer.step() + optimizer.zero_grad() \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_15.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_15.txt new file mode 100644 index 0000000000000000000000000000000000000000..4a425ed6889fb428081f84643bcbdb4e77df41ce --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_15.txt @@ -0,0 +1,32 @@ +First we wrap the dataset in a DataLoader. +Then we can enable gradient checkpointing by calling the model's [~PreTrainedModel.gradient_checkpointing_enable] method. +When we initialize the Accelerator +we can specify if we want to use mixed precision training and it will take care of it for us in the [prepare] call. +During the prepare +call the dataloader will also be distributed across workers should we use multiple GPUs. We use the same 8-bit optimizer from the earlier example. +Finally, we can add the main training loop. Note that the backward call is handled by 🤗 Accelerate. We can also see +how gradient accumulation works: we normalize the loss, so we get the average at the end of accumulation and once we have +enough steps we run the optimization. +Implementing these optimization techniques with 🤗 Accelerate only takes a handful of lines of code and comes with the +benefit of more flexibility in the training loop. For a full documentation of all features have a look at the +Accelerate documentation. +Efficient Software Prebuilds +PyTorch's pip and conda builds come prebuilt with the cuda toolkit +which is enough to run PyTorch, but it is insufficient if you need to build cuda extensions. +At times, additional efforts may be required to pre-build some components. For instance, if you're using libraries like apex that +don't come pre-compiled. In other situations figuring out how to install the right cuda toolkit system-wide can be complicated. +To address these scenarios PyTorch and NVIDIA released a new version of NGC docker container which already comes with +everything prebuilt. You just need to install your programs on it, and it will run out of the box. +This approach is also useful if you want to tweak the pytorch source and/or make a new customized build. +To find the docker image version you want start with PyTorch release notes, +choose one of the latest monthly releases. Go into the release's notes for the desired release, check that the environment's +components are matching your needs (including NVIDIA Driver requirements!) and then at the very top of that document go +to the corresponding NGC page. If for some reason you get lost, here is the index of all PyTorch NGC images. +Next follow the instructions to download and deploy the docker image. +Mixture of Experts +Some recent papers reported a 4-5x training speedup and a faster inference by integrating +Mixture of Experts (MoE) into the Transformer models. +Since it has been discovered that more parameters lead to better performance, this technique allows to increase the +number of parameters by an order of magnitude without increasing training costs. +In this approach every other FFN layer is replaced with a MoE Layer which consists of many experts, with a gated function +that trains each expert in a balanced way depending on the input token's position in a sequence. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_16.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_16.txt new file mode 100644 index 0000000000000000000000000000000000000000..f508fc17d2a8288fc0c8e808c57a315be3cacb0a --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_16.txt @@ -0,0 +1,12 @@ +(source: GLAM) +You can find exhaustive details and comparison tables in the papers listed at the end of this section. +The main drawback of this approach is that it requires staggering amounts of GPU memory - almost an order of magnitude +larger than its dense equivalent. Various distillation and approaches are proposed to how to overcome the much higher memory requirements. +There is direct trade-off though, you can use just a few experts with a 2-3x smaller base model instead of dozens or +hundreds experts leading to a 5x smaller model and thus increase the training speed moderately while increasing the +memory requirements moderately as well. +Most related papers and implementations are built around Tensorflow/TPUs: + +GShard: Scaling Giant Models with Conditional Computation and Automatic Sharding +Switch Transformers: Scaling to Trillion Parameter Models with Simple and Efficient Sparsity +GLaM: Generalist Language Model (GLaM) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_17.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_17.txt new file mode 100644 index 0000000000000000000000000000000000000000..d18ecf7075dd816c34b5e4d22ffef026ebe79090 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_17.txt @@ -0,0 +1,4 @@ +And for Pytorch DeepSpeed has built one as well: DeepSpeed-MoE: Advancing Mixture-of-Experts Inference and Training to Power Next-Generation AI Scale, Mixture of Experts - blog posts: 1, 2 and specific deployment with large transformer-based natural language generation models: blog post, Megatron-Deepspeed branch. +Using PyTorch native attention and Flash Attention +PyTorch's torch.nn.functional.scaled_dot_product_attention (SDPA) can also call FlashAttention and memory-efficient attention kernels under the hood. SDPA support is currently being added natively in Transformers and is used by default for torch>=2.1.1 when an implementation is available. Please refer to PyTorch scaled dot product attention for a list of supported models and more details. +Check out this blogpost to learn more about acceleration and memory-savings with SDPA. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..5d5b559f7b9940724fcec35349d4b4a8183bcad8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_2.txt @@ -0,0 +1,2 @@ +Note: when using mixed precision with a small model and a large batch size, there will be some memory savings but with a +large model and a small batch size, the memory use will be larger. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..1e5fcf1e748d91043e9582c993a69f845fccbe3f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_3.txt @@ -0,0 +1,59 @@ +You can combine the above methods to get a cumulative effect. These techniques are available to you whether you are +training your model with [Trainer] or writing a pure PyTorch loop, in which case you can configure these optimizations +with 🤗 Accelerate. +If these methods do not result in sufficient gains, you can explore the following options: +* Look into building your own custom Docker container with efficient software prebuilds +* Consider a model that uses Mixture of Experts (MoE) +* Convert your model to BetterTransformer to leverage PyTorch native attention +Finally, if all of the above is still not enough, even after switching to a server-grade GPU like A100, consider moving +to a multi-GPU setup. All these approaches are still valid in a multi-GPU setup, plus you can leverage additional parallelism +techniques outlined in the multi-GPU section. +Batch size choice +To achieve optimal performance, start by identifying the appropriate batch size. It is recommended to use batch sizes and +input/output neuron counts that are of size 2^N. Often it's a multiple of 8, but it can be +higher depending on the hardware being used and the model's dtype. +For reference, check out NVIDIA's recommendation for input/output neuron counts and +batch size for +fully connected layers (which are involved in GEMMs (General Matrix Multiplications)). +Tensor Core Requirements +define the multiplier based on the dtype and the hardware. For instance, for fp16 data type a multiple of 8 is recommended, unless +it's an A100 GPU, in which case use multiples of 64. +For parameters that are small, consider also Dimension Quantization Effects. +This is where tiling happens and the right multiplier can have a significant speedup. +Gradient Accumulation +The gradient accumulation method aims to calculate gradients in smaller increments instead of computing them for the +entire batch at once. This approach involves iteratively calculating gradients in smaller batches by performing forward +and backward passes through the model and accumulating the gradients during the process. Once a sufficient number of +gradients have been accumulated, the model's optimization step is executed. By employing gradient accumulation, it +becomes possible to increase the effective batch size beyond the limitations imposed by the GPU's memory capacity. +However, it is important to note that the additional forward and backward passes introduced by gradient accumulation can +slow down the training process. +You can enable gradient accumulation by adding the gradient_accumulation_steps argument to [TrainingArguments]: +py +training_args = TrainingArguments(per_device_train_batch_size=1, gradient_accumulation_steps=4, **default_args) +In the above example, your effective batch size becomes 4. +Alternatively, use 🤗 Accelerate to gain full control over the training loop. Find the 🤗 Accelerate example +further down in this guide. +While it is advised to max out GPU usage as much as possible, a high number of gradient accumulation steps can +result in a more pronounced training slowdown. Consider the following example. Let's say, the per_device_train_batch_size=4 +without gradient accumulation hits the GPU's limit. If you would like to train with batches of size 64, do not set the +per_device_train_batch_size to 1 and gradient_accumulation_steps to 64. Instead, keep per_device_train_batch_size=4 +and set gradient_accumulation_steps=16. This results in the same effective batch size while making better use of +the available GPU resources. +For additional information, please refer to batch size and gradient accumulation benchmarks for RTX-3090 +and A100. +Gradient Checkpointing +Some large models may still face memory issues even when the batch size is set to 1 and gradient accumulation is used. +This is because there are other components that also require memory storage. +Saving all activations from the forward pass in order to compute the gradients during the backward pass can result in +significant memory overhead. The alternative approach of discarding the activations and recalculating them when needed +during the backward pass, would introduce a considerable computational overhead and slow down the training process. +Gradient checkpointing offers a compromise between these two approaches and saves strategically selected activations +throughout the computational graph so only a fraction of the activations need to be re-computed for the gradients. For +an in-depth explanation of gradient checkpointing, refer to this great article. +To enable gradient checkpointing in the [Trainer], pass the corresponding a flag to [TrainingArguments]: +py +training_args = TrainingArguments( + per_device_train_batch_size=1, gradient_accumulation_steps=4, gradient_checkpointing=True, **default_args +) +Alternatively, use 🤗 Accelerate - find the 🤗 Accelerate example further in this guide. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..a78c2350bdcb205c81a55e83da9f656c64d4823d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_4.txt @@ -0,0 +1 @@ +While gradient checkpointing may improve memory efficiency, it slows training by approximately 20%. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..44dc747b90bb6b6ffbcebf50ea57db7f8e828b7b --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_5.txt @@ -0,0 +1,45 @@ +Mixed precision training +Mixed precision training is a technique that aims to optimize the computational efficiency of training models by +utilizing lower-precision numerical formats for certain variables. Traditionally, most models use 32-bit floating point +precision (fp32 or float32) to represent and process variables. However, not all variables require this high precision +level to achieve accurate results. By reducing the precision of certain variables to lower numerical formats like 16-bit +floating point (fp16 or float16), we can speed up the computations. Because in this approach some computations are performed +in half-precision, while some are still in full precision, the approach is called mixed precision training. +Most commonly mixed precision training is achieved by using fp16 (float16) data types, however, some GPU architectures +(such as the Ampere architecture) offer bf16 and tf32 (CUDA internal data type) data types. Check +out the NVIDIA Blog to learn more about +the differences between these data types. +fp16 +The main advantage of mixed precision training comes from saving the activations in half precision (fp16). +Although the gradients are also computed in half precision they are converted back to full precision for the optimization +step so no memory is saved here. +While mixed precision training results in faster computations, it can also lead to more GPU memory being utilized, especially for small batch sizes. +This is because the model is now present on the GPU in both 16-bit and 32-bit precision (1.5x the original model on the GPU). +To enable mixed precision training, set the fp16 flag to True: +py +training_args = TrainingArguments(per_device_train_batch_size=4, fp16=True, **default_args) +If you prefer to use 🤗 Accelerate, find the 🤗 Accelerate example further in this guide. +BF16 +If you have access to an Ampere or newer hardware you can use bf16 for mixed precision training and evaluation. While +bf16 has a worse precision than fp16, it has a much bigger dynamic range. In fp16 the biggest number you can have +is 65535 and any number above that will result in an overflow. A bf16 number can be as large as 3.39e+38 (!) which +is about the same as fp32 - because both have 8-bits used for the numerical range. +You can enable BF16 in the 🤗 Trainer with: +python +training_args = TrainingArguments(bf16=True, **default_args) +TF32 +The Ampere hardware uses a magical data type called tf32. It has the same numerical range as fp32 (8-bits), but instead +of 23 bits precision it has only 10 bits (same as fp16) and uses only 19 bits in total. It's "magical" in the sense that +you can use the normal fp32 training and/or inference code and by enabling tf32 support you can get up to 3x throughput +improvement. All you need to do is to add the following to your code: +python +import torch +torch.backends.cuda.matmul.allow_tf32 = True +torch.backends.cudnn.allow_tf32 = True +CUDA will automatically switch to using tf32 instead of fp32 where possible, assuming that the used GPU is from the Ampere series. +According to NVIDIA research, the +majority of machine learning training workloads show the same perplexity and convergence with tf32 training as with fp32. +If you're already using fp16 or bf16 mixed precision it may help with the throughput as well. +You can enable this mode in the 🤗 Trainer: +python +TrainingArguments(tf32=True, **default_args) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..6d499106c57b0a0eee1de6d4b92d17563de8ee86 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_6.txt @@ -0,0 +1 @@ +tf32 can't be accessed directly via tensor.to(dtype=torch.tf32) because it is an internal CUDA data type. You need torch>=1.7 to use tf32 data types. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..ea7e20d25d23e99d2c66385108980ec5ee3d6968 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_7.txt @@ -0,0 +1,43 @@ +For additional information on tf32 vs other precisions, please refer to the following benchmarks: +RTX-3090 and +A100. +Flash Attention 2 +You can speedup the training throughput by using Flash Attention 2 integration in transformers. Check out the appropriate section in the single GPU section to learn more about how to load a model with Flash Attention 2 modules. +Optimizer choice +The most common optimizer used to train transformer models is Adam or AdamW (Adam with weight decay). Adam achieves +good convergence by storing the rolling average of the previous gradients; however, it adds an additional memory +footprint of the order of the number of model parameters. To remedy this, you can use an alternative optimizer. +For example if you have NVIDIA/apex installed for NVIDIA GPUs, or ROCmSoftwarePlatform/apex for AMD GPUs, adamw_apex_fused will give you the +fastest training experience among all supported AdamW optimizers. +[Trainer] integrates a variety of optimizers that can be used out of box: adamw_hf, adamw_torch, adamw_torch_fused, +adamw_apex_fused, adamw_anyprecision, adafactor, or adamw_bnb_8bit. More optimizers can be plugged in via a third-party implementation. +Let's take a closer look at two alternatives to AdamW optimizer: +1. adafactor which is available in [Trainer] +2. adamw_bnb_8bit is also available in Trainer, but a third-party integration is provided below for demonstration. +For comparison, for a 3B-parameter model, like “google-t5/t5-3bâ€: +* A standard AdamW optimizer will need 24GB of GPU memory because it uses 8 bytes for each parameter (83 => 24GB) +* Adafactor optimizer will need more than 12GB. It uses slightly more than 4 bytes for each parameter, so 43 and then some extra. +* 8bit BNB quantized optimizer will use only (2*3) 6GB if all optimizer states are quantized. +Adafactor +Adafactor doesn't store rolling averages for each element in weight matrices. Instead, it keeps aggregated information +(sums of rolling averages row- and column-wise), significantly reducing its footprint. However, compared to Adam, +Adafactor may have slower convergence in certain cases. +You can switch to Adafactor by setting optim="adafactor" in [TrainingArguments]: +py +training_args = TrainingArguments(per_device_train_batch_size=4, optim="adafactor", **default_args) +Combined with other approaches (gradient accumulation, gradient checkpointing, and mixed precision training) +you can notice up to 3x improvement while maintaining the throughput! However, as mentioned before, the convergence of +Adafactor can be worse than Adam. +8-bit Adam +Instead of aggregating optimizer states like Adafactor, 8-bit Adam keeps the full state and quantizes it. Quantization +means that it stores the state with lower precision and dequantizes it only for the optimization. This is similar to the +idea behind mixed precision training. +To use adamw_bnb_8bit, you simply need to set optim="adamw_bnb_8bit" in [TrainingArguments]: +py +training_args = TrainingArguments(per_device_train_batch_size=4, optim="adamw_bnb_8bit", **default_args) +However, we can also use a third-party implementation of the 8-bit optimizer for demonstration purposes to see how that can be integrated. +First, follow the installation guide in the GitHub repo to install the bitsandbytes library +that implements the 8-bit Adam optimizer. +Next you need to initialize the optimizer. This involves two steps: +* First, group the model's parameters into two groups - one where weight decay should be applied, and the other one where it should not. Usually, biases and layer norm parameters are not weight decayed. +* Then do some argument housekeeping to use the same parameters as the previously used AdamW optimizer. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..98143e8a36c8c8d9dbe5fd8f4c3b1d3d1cdda9ee --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_8.txt @@ -0,0 +1,27 @@ +import bitsandbytes as bnb +from torch import nn +from transformers.trainer_pt_utils import get_parameter_names +training_args = TrainingArguments(per_device_train_batch_size=4, **default_args) +decay_parameters = get_parameter_names(model, [nn.LayerNorm]) +decay_parameters = [name for name in decay_parameters if "bias" not in name] +optimizer_grouped_parameters = [ + { + "params": [p for n, p in model.named_parameters() if n in decay_parameters], + "weight_decay": training_args.weight_decay, + }, + { + "params": [p for n, p in model.named_parameters() if n not in decay_parameters], + "weight_decay": 0.0, + }, +] +optimizer_kwargs = { + "betas": (training_args.adam_beta1, training_args.adam_beta2), + "eps": training_args.adam_epsilon, +} +optimizer_kwargs["lr"] = training_args.learning_rate +adam_bnb_optim = bnb.optim.Adam8bit( + optimizer_grouped_parameters, + betas=(training_args.adam_beta1, training_args.adam_beta2), + eps=training_args.adam_epsilon, + lr=training_args.learning_rate, +) \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_9.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_9.txt new file mode 100644 index 0000000000000000000000000000000000000000..850a2cb646becbb9fcd91a9d57b81517cd167b42 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_gpu_one.txt_chunk_9.txt @@ -0,0 +1,12 @@ +Finally, pass the custom optimizer as an argument to the Trainer: +py +trainer = Trainer(model=model, args=training_args, train_dataset=ds, optimizers=(adam_bnb_optim, None)) +Combined with other approaches (gradient accumulation, gradient checkpointing, and mixed precision training), +you can expect to get about a 3x memory improvement and even slightly higher throughput as using Adafactor. +multi_tensor +pytorch-nightly introduced torch.optim._multi_tensor which should significantly speed up the optimizers for situations +with lots of small feature tensors. It should eventually become the default, but if you want to experiment with it sooner, take a look at this GitHub issue. +Data preloading +One of the important requirements to reach great training speed is the ability to feed the GPU at the maximum speed it +can handle. By default, everything happens in the main process, and it might not be able to read the data from disk fast +enough, and thus create a bottleneck, leading to GPU under-utilization. Configure the following arguments to reduce the bottleneck: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_special.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_special.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..78b1b75fe3f9b3fe3fcfa08b84987f82817736cb --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_special.txt_chunk_0.txt @@ -0,0 +1,8 @@ +PyTorch training on Apple silicon +Previously, training models on a Mac was limited to the CPU only. With the release of PyTorch v1.12, you can take advantage of training models with Apple's silicon GPUs for significantly faster performance and training. This is powered in PyTorch by integrating Apple's Metal Performance Shaders (MPS) as a backend. The MPS backend implements PyTorch operations as custom Metal shaders and places these modules on a mps device. + +Some PyTorch operations are not implemented in MPS yet and will throw an error. To avoid this, you should set the environment variable PYTORCH_ENABLE_MPS_FALLBACK=1 to use the CPU kernels instead (you'll still see a UserWarning). + +If you run into any other errors, please open an issue in the PyTorch repository because the [Trainer] only integrates the MPS backend. + +With the mps device set, you can: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_special.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_special.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..8faadb6c8b0044430f6d6762b12d57df9697b3d8 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_special.txt_chunk_1.txt @@ -0,0 +1,10 @@ +With the mps device set, you can: + +train larger networks or batch sizes locally +reduce data retrieval latency because the GPU's unified memory architecture allows direct access to the full memory store +reduce costs because you don't need to train on cloud-based GPUs or add additional local GPUs + +Get started by making sure you have PyTorch installed. MPS acceleration is supported on macOS 12.3+. + +pip install torch torchvision torchaudio +[TrainingArguments] uses the mps device by default if it's available which means you don't need to explicitly set the device. For example, you can run the run_glue.py script with the MPS backend automatically enabled without making any changes. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_special.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_special.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..1264eb2ec63d2ac9d0eed45625ff4950bf041b45 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_special.txt_chunk_2.txt @@ -0,0 +1,16 @@ +export TASK_NAME=mrpc +python examples/pytorch/text-classification/run_glue.py \ + --model_name_or_path google-bert/bert-base-cased \ + --task_name $TASK_NAME \ +- --use_mps_device \ + --do_train \ + --do_eval \ + --max_seq_length 128 \ + --per_device_train_batch_size 32 \ + --learning_rate 2e-5 \ + --num_train_epochs 3 \ + --output_dir /tmp/$TASK_NAME/ \ + --overwrite_output_dir + +Backends for distributed setups like gloo and nccl are not supported by the mps device which means you can only train on a single GPU with the MPS backend. +You can learn more about the MPS backend in the Introducing Accelerated PyTorch Training on Mac blog post. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..1e07187c9d8989e7ca5774f47540611deeab88d9 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_0.txt @@ -0,0 +1,3 @@ +Training on TPU with TensorFlow + +If you don't need long explanations and just want TPU code samples to get started with, check out our TPU example notebook! \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..6cb2387aa4ccd602fdd0e2da0c3979c6d645f432 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_1.txt @@ -0,0 +1,7 @@ +What is a TPU? +A TPU is a Tensor Processing Unit. They are hardware designed by Google, which are used to greatly speed up the tensor computations within neural networks, much like GPUs. They can be used for both network training and inference. They are generally accessed through Google’s cloud services, but small TPUs can also be accessed directly for free through Google Colab and Kaggle Kernels. +Because all TensorFlow models in 🤗 Transformers are Keras models, most of the methods in this document are generally applicable to TPU training for any Keras model! However, there are a few points that are specific to the HuggingFace ecosystem (hug-o-system?) of Transformers and Datasets, and we’ll make sure to flag them up when we get to them. +What kinds of TPU are available? +New users are often very confused by the range of TPUs, and the different ways to access them. The first key distinction to understand is the difference between TPU Nodes and TPU VMs. +When you use a TPU Node, you are effectively indirectly accessing a remote TPU. You will need a separate VM, which will initialize your network and data pipeline and then forward them to the remote node. When you use a TPU on Google Colab, you are accessing it in the TPU Node style. +Using TPU Nodes can have some quite unexpected behaviour for people who aren’t used to them! In particular, because the TPU is located on a physically different system to the machine you’re running your Python code on, your data cannot be local to your machine - any data pipeline that loads from your machine’s internal storage will totally fail! Instead, data must be stored in Google Cloud Storage where your data pipeline can still access it, even when the pipeline is running on the remote TPU node. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..b24447026a323fe842384339a1b4f9c507df782d --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_2.txt @@ -0,0 +1,3 @@ +If you can fit all your data in memory as np.ndarray or tf.Tensor, then you can fit() on that data even when using Colab or a TPU Node, without needing to upload it to Google Cloud Storage. + +🤗Specific Hugging Face Tip🤗: The methods Dataset.to_tf_dataset() and its higher-level wrapper model.prepare_tf_dataset() , which you will see throughout our TF code examples, will both fail on a TPU Node. The reason for this is that even though they create a tf.data.Dataset it is not a “pure†tf.data pipeline and uses tf.numpy_function or Dataset.from_generator() to stream data from the underlying HuggingFace Dataset. This HuggingFace Dataset is backed by data that is on a local disc and which the remote TPU Node will not be able to read. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_3.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_3.txt new file mode 100644 index 0000000000000000000000000000000000000000..3a724dbf6970d241b6aa305e367940ad3866b188 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_3.txt @@ -0,0 +1,8 @@ +The second way to access a TPU is via a TPU VM. When using a TPU VM, you connect directly to the machine that the TPU is attached to, much like training on a GPU VM. TPU VMs are generally easier to work with, particularly when it comes to your data pipeline. All of the above warnings do not apply to TPU VMs! +This is an opinionated document, so here’s our opinion: Avoid using TPU Node if possible. It is more confusing and more difficult to debug than TPU VMs. It is also likely to be unsupported in future - Google’s latest TPU, TPUv4, can only be accessed as a TPU VM, which suggests that TPU Nodes are increasingly going to become a “legacy†access method. However, we understand that the only free TPU access is on Colab and Kaggle Kernels, which uses TPU Node - so we’ll try to explain how to handle it if you have to! Check the TPU example notebook for code samples that explain this in more detail. +What sizes of TPU are available? +A single TPU (a v2-8/v3-8/v4-8) runs 8 replicas. TPUs exist in pods that can run hundreds or thousands of replicas simultaneously. When you use more than a single TPU but less than a whole pod (for example, a v3-32), your TPU fleet is referred to as a pod slice. +When you access a free TPU via Colab, you generally get a single v2-8 TPU. +I keep hearing about this XLA thing. What’s XLA, and how does it relate to TPUs? +XLA is an optimizing compiler, used by both TensorFlow and JAX. In JAX it is the only compiler, whereas in TensorFlow it is optional (but mandatory on TPU!). The easiest way to enable it when training a Keras model is to pass the argument jit_compile=True to model.compile(). If you don’t get any errors and performance is good, that’s a great sign that you’re ready to move to TPU! +Debugging on TPU is generally a bit harder than on CPU/GPU, so we recommend getting your code running on CPU/GPU with XLA first before trying it on TPU. You don’t have to train for long, of course - just for a few steps to make sure that your model and data pipeline are working like you expect them to. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_4.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_4.txt new file mode 100644 index 0000000000000000000000000000000000000000..bec0ca07a28c1ac5aa60d885ba44577708920ac0 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_4.txt @@ -0,0 +1,6 @@ +XLA compiled code is usually faster - so even if you’re not planning to run on TPU, adding jit_compile=True can improve your performance. Be sure to note the caveats below about XLA compatibility, though! + +Tip born of painful experience: Although using jit_compile=True is a good way to get a speed boost and test if your CPU/GPU code is XLA-compatible, it can actually cause a lot of problems if you leave it in when actually training on TPU. XLA compilation will happen implicitly on TPU, so remember to remove that line before actually running your code on a TPU! + +How do I make my model XLA compatible? +In many cases, your code is probably XLA-compatible already! However, there are a few things that work in normal TensorFlow that don’t work in XLA. We’ve distilled them into three core rules below: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_5.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_5.txt new file mode 100644 index 0000000000000000000000000000000000000000..5a8109cb5cd0efae9f74abba23e4e37808879fb1 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_5.txt @@ -0,0 +1 @@ +🤗Specific HuggingFace Tip🤗: We’ve put a lot of effort into rewriting our TensorFlow models and loss functions to be XLA-compatible. Our models and loss functions generally obey rule #1 and #2 by default, so you can skip over them if you’re using transformers models. Don’t forget about these rules when writing your own models and loss functions, though! \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_6.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_6.txt new file mode 100644 index 0000000000000000000000000000000000000000..1a2999cfc12aa301b95dafea6eeed9fb93bc3f29 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_6.txt @@ -0,0 +1,30 @@ +XLA Rule #1: Your code cannot have “data-dependent conditionals†+What that means is that any if statement cannot depend on values inside a tf.Tensor. For example, this code block cannot be compiled with XLA! +python +if tf.reduce_sum(tensor) > 10: + tensor = tensor / 2.0 +This might seem very restrictive at first, but most neural net code doesn’t need to do this. You can often get around this restriction by using tf.cond (see the documentation here) or by removing the conditional and finding a clever math trick with indicator variables instead, like so: +python +sum_over_10 = tf.cast(tf.reduce_sum(tensor) > 10, tf.float32) +tensor = tensor / (1.0 + sum_over_10) +This code has exactly the same effect as the code above, but by avoiding a conditional, we ensure it will compile with XLA without problems! +XLA Rule #2: Your code cannot have “data-dependent shapes†+What this means is that the shape of all of the tf.Tensor objects in your code cannot depend on their values. For example, the function tf.unique cannot be compiled with XLA, because it returns a tensor containing one instance of each unique value in the input. The shape of this output will obviously be different depending on how repetitive the input Tensor was, and so XLA refuses to handle it! +In general, most neural network code obeys rule #2 by default. However, there are a few common cases where it becomes a problem. One very common one is when you use label masking, setting your labels to a negative value to indicate that those positions should be ignored when computing the loss. If you look at NumPy or PyTorch loss functions that support label masking, you will often see code like this that uses boolean indexing: +python +label_mask = labels >= 0 +masked_outputs = outputs[label_mask] +masked_labels = labels[label_mask] +loss = compute_loss(masked_outputs, masked_labels) +mean_loss = torch.mean(loss) +This code is totally fine in NumPy or PyTorch, but it breaks in XLA! Why? Because the shape of masked_outputs and masked_labels depends on how many positions are masked - that makes it a data-dependent shape. However, just like for rule #1, we can often rewrite this code to yield exactly the same output without any data-dependent shapes. +python +label_mask = tf.cast(labels >= 0, tf.float32) +loss = compute_loss(outputs, labels) +loss = loss * label_mask # Set negative label positions to 0 +mean_loss = tf.reduce_sum(loss) / tf.reduce_sum(label_mask) +Here, we avoid data-dependent shapes by computing the loss for every position, but zeroing out the masked positions in both the numerator and denominator when we calculate the mean, which yields exactly the same result as the first block while maintaining XLA compatibility. Note that we use the same trick as in rule #1 - converting a tf.bool to tf.float32 and using it as an indicator variable. This is a really useful trick, so remember it if you need to convert your own code to XLA! +XLA Rule #3: XLA will need to recompile your model for every different input shape it sees +This is the big one. What this means is that if your input shapes are very variable, XLA will have to recompile your model over and over, which will create huge performance problems. This commonly arises in NLP models, where input texts have variable lengths after tokenization. In other modalities, static shapes are more common and this rule is much less of a problem. +How can you get around rule #3? The key is padding - if you pad all your inputs to the same length, and then use an attention_mask, you can get the same results as you’d get from variable shapes, but without any XLA issues. However, excessive padding can cause severe slowdown too - if you pad all your samples to the maximum length in the whole dataset, you might end up with batches consisting endless padding tokens, which will waste a lot of compute and memory! +There isn’t a perfect solution to this problem. However, you can try some tricks. One very useful trick is to pad batches of samples up to a multiple of a number like 32 or 64 tokens. This often only increases the number of tokens by a small amount, but it hugely reduces the number of unique input shapes, because every input shape now has to be a multiple of 32 or 64. Fewer unique input shapes means fewer XLA compilations! \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_7.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_7.txt new file mode 100644 index 0000000000000000000000000000000000000000..abf165fb79376c7837470de11aae13b4a6876d35 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_7.txt @@ -0,0 +1,6 @@ +🤗Specific HuggingFace Tip🤗: Our tokenizers and data collators have methods that can help you here. You can use padding="max_length" or padding="longest" when calling tokenizers to get them to output padded data. Our tokenizers and data collators also have a pad_to_multiple_of argument that you can use to reduce the number of unique input shapes you see! + +How do I actually train my model on TPU? +Once your training is XLA-compatible and (if you’re using TPU Node / Colab) your dataset has been prepared appropriately, running on TPU is surprisingly easy! All you really need to change in your code is to add a few lines to initialize your TPU, and to ensure that your model and dataset are created inside a TPUStrategy scope. Take a look at our TPU example notebook to see this in action! +Summary +There was a lot in here, so let’s summarize with a quick checklist you can follow when you want to get your model ready for TPU training: \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_8.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_8.txt new file mode 100644 index 0000000000000000000000000000000000000000..9689fe76f26d1388c15e7a9cc0d6b1ae2b1ba505 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perf_train_tpu_tf.txt_chunk_8.txt @@ -0,0 +1,10 @@ +Make sure your code follows the three rules of XLA +Compile your model with jit_compile=True on CPU/GPU and confirm that you can train it with XLA +Either load your dataset into memory or use a TPU-compatible dataset loading approach (see notebook) +Migrate your code either to Colab (with accelerator set to “TPUâ€) or a TPU VM on Google Cloud +Add TPU initializer code (see notebook) +Create your TPUStrategy and make sure dataset loading and model creation are inside the strategy.scope() (see notebook) +Don’t forget to take jit_compile=True out again when you move to TPU! +ðŸ™ðŸ™ðŸ™ðŸ¥ºðŸ¥ºðŸ¥º +Call model.fit() +You did it! \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_performance.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_performance.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..c3a83a7b76a2b6fc4f7e31f0889d4fce4ade557c --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_performance.txt_chunk_0.txt @@ -0,0 +1,14 @@ +Performance and Scalability +Training large transformer models and deploying them to production present various challenges. +During training, the model may require more GPU memory than available or exhibit slow training speed. In the deployment +phase, the model can struggle to handle the required throughput in a production environment. +This documentation aims to assist you in overcoming these challenges and finding the optimal setting for your use-case. +The guides are divided into training and inference sections, as each comes with different challenges and solutions. +Within each section you'll find separate guides for different hardware configurations, such as single GPU vs. multi-GPU +for training or CPU vs. GPU for inference. +Use this document as your starting point to navigate further to the methods that match your scenario. +Training +Training large transformer models efficiently requires an accelerator such as a GPU or TPU. The most common case is where +you have a single GPU. The methods that you can apply to improve training efficiency on a single GPU extend to other setups +such as multiple GPU. However, there are also techniques that are specific to multi-GPU or CPU training. We cover them in +separate sections. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_performance.txt_chunk_1.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_performance.txt_chunk_1.txt new file mode 100644 index 0000000000000000000000000000000000000000..5dff2404ea0ccfa6fa14bb79c80ccad72faacf85 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_performance.txt_chunk_1.txt @@ -0,0 +1,11 @@ +Methods and tools for efficient training on a single GPU: start here to learn common approaches that can help optimize GPU memory utilization, speed up the training, or both. +Multi-GPU training section: explore this section to learn about further optimization methods that apply to a multi-GPU settings, such as data, tensor, and pipeline parallelism. +CPU training section: learn about mixed precision training on CPU. +Efficient Training on Multiple CPUs: learn about distributed CPU training. +Training on TPU with TensorFlow: if you are new to TPUs, refer to this section for an opinionated introduction to training on TPUs and using XLA. +Custom hardware for training: find tips and tricks when building your own deep learning rig. +Hyperparameter Search using Trainer API + +Inference +Efficient inference with large models in a production environment can be as challenging as training them. In the following +sections we go through the steps to run inference on CPU and single/multi-GPU setups. \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_performance.txt_chunk_2.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_performance.txt_chunk_2.txt new file mode 100644 index 0000000000000000000000000000000000000000..9f5ca6c12a829b331d9aac244161163639c0928f --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_performance.txt_chunk_2.txt @@ -0,0 +1,16 @@ +Inference on a single CPU +Inference on a single GPU +Multi-GPU inference +XLA Integration for TensorFlow Models + +Training and inference +Here you'll find techniques, tips and tricks that apply whether you are training a model, or running inference with it. + +Instantiating a big model +Troubleshooting performance issues + +Contribute +This document is far from being complete and a lot more needs to be added, so if you have additions or corrections to +make please don't hesitate to open a PR or if you aren't sure start an Issue and we can discuss the details there. +When making contributions that A is better than B, please try to include a reproducible benchmark and/or a link to the +source of that information (unless it comes directly from you). \ No newline at end of file diff --git a/BAAI_bge-large-en-v1.5/fixed_chunks/_perplexity.txt_chunk_0.txt b/BAAI_bge-large-en-v1.5/fixed_chunks/_perplexity.txt_chunk_0.txt new file mode 100644 index 0000000000000000000000000000000000000000..404ea13313e123384d90c48bfa8157d2ef0ab5d3 --- /dev/null +++ b/BAAI_bge-large-en-v1.5/fixed_chunks/_perplexity.txt_chunk_0.txt @@ -0,0 +1,15 @@ +Perplexity of fixed-length models +[[open-in-colab]] +Perplexity (PPL) is one of the most common metrics for evaluating language models. Before diving in, we should note +that the metric applies specifically to classical language models (sometimes called autoregressive or causal language +models) and is not well defined for masked language models like BERT (see summary of the models). +Perplexity is defined as the exponentiated average negative log-likelihood of a sequence. If we have a tokenized +sequence \(X = (x_0, x_1, \dots, x_t)\), then the perplexity of \(X\) is, +$$\text{PPL}(X) = \exp \left{ {-\frac{1}{t}\sum_i^t \log p_\theta (x_i|x_{