diff --git a/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/INSTALLER b/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..a1b589e38a32041e49332e5e81c2d363dc418d68 --- /dev/null +++ b/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/INSTALLER @@ -0,0 +1 @@ +pip diff --git a/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/LICENSE.rst b/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/LICENSE.rst new file mode 100644 index 0000000000000000000000000000000000000000..191ddaf31642db9d52a7f32826043c6550c299d8 --- /dev/null +++ b/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/LICENSE.rst @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2017 Laurent LAPORTE + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/METADATA b/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..86dc1909809bbd0a14101b42d8fa3cedf6ba6703 --- /dev/null +++ b/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/METADATA @@ -0,0 +1,195 @@ +Metadata-Version: 2.2 +Name: Deprecated +Version: 1.2.18 +Summary: Python @deprecated decorator to deprecate old python classes, functions or methods. +Home-page: https://github.com/laurent-laporte-pro/deprecated +Author: Laurent LAPORTE +Author-email: laurent.laporte.pro@gmail.com +License: MIT +Project-URL: Documentation, https://deprecated.readthedocs.io/en/latest/ +Project-URL: Source, https://github.com/laurent-laporte-pro/deprecated +Project-URL: Bug Tracker, https://github.com/laurent-laporte-pro/deprecated/issues +Keywords: deprecate,deprecated,deprecation,warning,warn,decorator +Platform: any +Classifier: Development Status :: 5 - Production/Stable +Classifier: Environment :: Web Environment +Classifier: Intended Audience :: Developers +Classifier: License :: OSI Approved :: MIT License +Classifier: Operating System :: OS Independent +Classifier: Programming Language :: Python +Classifier: Programming Language :: Python :: 2 +Classifier: Programming Language :: Python :: 2.7 +Classifier: Programming Language :: Python :: 3 +Classifier: Programming Language :: Python :: 3.4 +Classifier: Programming Language :: Python :: 3.5 +Classifier: Programming Language :: Python :: 3.6 +Classifier: Programming Language :: Python :: 3.7 +Classifier: Programming Language :: Python :: 3.8 +Classifier: Programming Language :: Python :: 3.9 +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 +Classifier: Programming Language :: Python :: 3.12 +Classifier: Topic :: Software Development :: Libraries :: Python Modules +Requires-Python: >=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.* +Description-Content-Type: text/x-rst +License-File: LICENSE.rst +Requires-Dist: wrapt<2,>=1.10 +Provides-Extra: dev +Requires-Dist: tox; extra == "dev" +Requires-Dist: PyTest; extra == "dev" +Requires-Dist: PyTest-Cov; extra == "dev" +Requires-Dist: bump2version<1; extra == "dev" +Requires-Dist: setuptools; python_version >= "3.12" and extra == "dev" +Dynamic: author +Dynamic: author-email +Dynamic: classifier +Dynamic: description +Dynamic: description-content-type +Dynamic: home-page +Dynamic: keywords +Dynamic: license +Dynamic: platform +Dynamic: project-url +Dynamic: provides-extra +Dynamic: requires-dist +Dynamic: requires-python +Dynamic: summary + + +Deprecated Library +------------------ + +Deprecated is Easy to Use +````````````````````````` + +If you need to mark a function or a method as deprecated, +you can use the ``@deprecated`` decorator: + +Save in a hello.py: + +.. code:: python + + from deprecated import deprecated + + + @deprecated(version='1.2.1', reason="You should use another function") + def some_old_function(x, y): + return x + y + + + class SomeClass(object): + @deprecated(version='1.3.0', reason="This method is deprecated") + def some_old_method(self, x, y): + return x + y + + + some_old_function(12, 34) + obj = SomeClass() + obj.some_old_method(5, 8) + + +And Easy to Setup +````````````````` + +And run it: + +.. code:: bash + + $ pip install Deprecated + $ python hello.py + hello.py:15: DeprecationWarning: Call to deprecated function (or staticmethod) some_old_function. + (You should use another function) -- Deprecated since version 1.2.0. + some_old_function(12, 34) + hello.py:17: DeprecationWarning: Call to deprecated method some_old_method. + (This method is deprecated) -- Deprecated since version 1.3.0. + obj.some_old_method(5, 8) + + +You can document your code +`````````````````````````` + +Have you ever wonder how to document that some functions, classes, methods, etc. are deprecated? +This is now possible with the integrated Sphinx directives: + +For instance, in hello_sphinx.py: + +.. code:: python + + from deprecated.sphinx import deprecated + from deprecated.sphinx import versionadded + from deprecated.sphinx import versionchanged + + + @versionadded(version='1.0', reason="This function is new") + def function_one(): + '''This is the function one''' + + + @versionchanged(version='1.0', reason="This function is modified") + def function_two(): + '''This is the function two''' + + + @deprecated(version='1.0', reason="This function will be removed soon") + def function_three(): + '''This is the function three''' + + + function_one() + function_two() + function_three() # warns + + help(function_one) + help(function_two) + help(function_three) + + +The result it immediate +``````````````````````` + +Run it: + +.. code:: bash + + $ python hello_sphinx.py + + hello_sphinx.py:23: DeprecationWarning: Call to deprecated function (or staticmethod) function_three. + (This function will be removed soon) -- Deprecated since version 1.0. + function_three() # warns + + Help on function function_one in module __main__: + + function_one() + This is the function one + + .. versionadded:: 1.0 + This function is new + + Help on function function_two in module __main__: + + function_two() + This is the function two + + .. versionchanged:: 1.0 + This function is modified + + Help on function function_three in module __main__: + + function_three() + This is the function three + + .. deprecated:: 1.0 + This function will be removed soon + + +Links +````` + +* `Python package index (PyPi) `_ +* `GitHub website `_ +* `Read The Docs `_ +* `EBook on Lulu.com `_ +* `StackOverFlow Q&A `_ +* `Development version + `_ + diff --git a/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/RECORD b/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..a6578c4734b87ec6dbbc826ecafe96fb1280fb16 --- /dev/null +++ b/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/RECORD @@ -0,0 +1,12 @@ +Deprecated-1.2.18.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +Deprecated-1.2.18.dist-info/LICENSE.rst,sha256=HoPt0VvkGbXVveNy4yXlJ_9PmRX1SOfHUxS0H2aZ6Dw,1081 +Deprecated-1.2.18.dist-info/METADATA,sha256=4CrUw5Bl8_NsBuZYe0Nw-mIwQnVpT1CnmBYU9BqOuq8,5725 +Deprecated-1.2.18.dist-info/RECORD,, +Deprecated-1.2.18.dist-info/WHEEL,sha256=9Hm2OB-j1QcCUq9Jguht7ayGIIZBRTdOXD1qg9cCgPM,109 +Deprecated-1.2.18.dist-info/top_level.txt,sha256=nHbOYawKPQQE5lQl-toUB1JBRJjUyn_m_Mb8RVJ0RjA,11 +deprecated/__init__.py,sha256=yZNbmDKXF4PLtp_Ikdb_9ObJLkHuFSUHvqidFTKKGFM,351 +deprecated/__pycache__/__init__.cpython-310.pyc,, +deprecated/__pycache__/classic.cpython-310.pyc,, +deprecated/__pycache__/sphinx.cpython-310.pyc,, +deprecated/classic.py,sha256=7WXOt4Vf1NhrUznm8ypjS50CMyAdZwrGT58Lhb8fW14,10609 +deprecated/sphinx.py,sha256=cOKnXbDyFAwDr5O7HBEpgQrx-J-qfp57sfdK_LabDxs,11109 diff --git a/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/WHEEL b/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..eaea6f3b57e8165ab7d2673900a9939348ee5e42 --- /dev/null +++ b/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/WHEEL @@ -0,0 +1,6 @@ +Wheel-Version: 1.0 +Generator: setuptools (75.8.0) +Root-Is-Purelib: true +Tag: py2-none-any +Tag: py3-none-any + diff --git a/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/top_level.txt b/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/top_level.txt new file mode 100644 index 0000000000000000000000000000000000000000..9f8d5502dae589d488c5107e99768ae5023bb4ea --- /dev/null +++ b/venv/lib/python3.10/site-packages/Deprecated-1.2.18.dist-info/top_level.txt @@ -0,0 +1 @@ +deprecated diff --git a/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/INSTALLER b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..a1b589e38a32041e49332e5e81c2d363dc418d68 --- /dev/null +++ b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/INSTALLER @@ -0,0 +1 @@ +pip diff --git a/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/LICENSE b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..05b63bab038348c8188a4c9738b39caebcce64c3 --- /dev/null +++ b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright 2023 Yann Dubois and Xuechen Li and Rohan Taori and Tianyi Zhang and Ishaan Gulrajani + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. \ No newline at end of file diff --git a/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/METADATA b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..3a803ed778df9ec602cd4847c3a12915b7af2571 --- /dev/null +++ b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/METADATA @@ -0,0 +1,1377 @@ +Metadata-Version: 2.1 +Name: alpaca-eval +Version: 0.2.6 +Summary: AlpacaEval : An Automatic Evaluator of Instruction-following Models +Author: The Alpaca Team +Classifier: Intended Audience :: Developers +Classifier: Intended Audience :: Education +Classifier: Intended Audience :: Science/Research +Classifier: License :: OSI Approved :: Apache Software License +Classifier: Operating System :: OS Independent +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 +Classifier: Programming Language :: Python :: 3.12 +Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence +Requires-Python: >=3.10 +Description-Content-Type: text/markdown +License-File: LICENSE +Requires-Dist: python-dotenv +Requires-Dist: datasets +Requires-Dist: openai +Requires-Dist: pandas +Requires-Dist: tiktoken (>=0.3.2) +Requires-Dist: fire +Provides-Extra: all +Requires-Dist: accelerate ; extra == 'all' +Requires-Dist: transformers ; extra == 'all' +Requires-Dist: bitsandbytes ; extra == 'all' +Requires-Dist: xformers ; extra == 'all' +Requires-Dist: peft ; extra == 'all' +Requires-Dist: optimum ; extra == 'all' +Requires-Dist: scipy ; extra == 'all' +Requires-Dist: einops ; extra == 'all' +Requires-Dist: anthropic (>=0.3.3) ; extra == 'all' +Requires-Dist: huggingface-hub ; extra == 'all' +Requires-Dist: cohere ; extra == 'all' +Requires-Dist: replicate ; extra == 'all' +Requires-Dist: seaborn ; extra == 'all' +Requires-Dist: matplotlib ; extra == 'all' +Requires-Dist: jupyterlab ; extra == 'all' +Requires-Dist: pre-commit (>=3.2.0) ; extra == 'all' +Requires-Dist: black (>=23.1.0) ; extra == 'all' +Requires-Dist: isort ; extra == 'all' +Requires-Dist: pytest ; extra == 'all' +Requires-Dist: pytest-mock ; extra == 'all' +Requires-Dist: pytest-skip-slow ; extra == 'all' +Requires-Dist: python-dotenv ; extra == 'all' +Provides-Extra: analysis +Requires-Dist: seaborn ; extra == 'analysis' +Requires-Dist: matplotlib ; extra == 'analysis' +Requires-Dist: jupyterlab ; extra == 'analysis' +Provides-Extra: api +Requires-Dist: anthropic (>=0.3.3) ; extra == 'api' +Requires-Dist: huggingface-hub ; extra == 'api' +Requires-Dist: cohere ; extra == 'api' +Requires-Dist: replicate ; extra == 'api' +Provides-Extra: dev +Requires-Dist: pre-commit (>=3.2.0) ; extra == 'dev' +Requires-Dist: black (>=23.1.0) ; extra == 'dev' +Requires-Dist: isort ; extra == 'dev' +Requires-Dist: pytest ; extra == 'dev' +Requires-Dist: pytest-mock ; extra == 'dev' +Requires-Dist: pytest-skip-slow ; extra == 'dev' +Requires-Dist: python-dotenv ; extra == 'dev' +Provides-Extra: local +Requires-Dist: accelerate ; extra == 'local' +Requires-Dist: transformers ; extra == 'local' +Requires-Dist: bitsandbytes ; extra == 'local' +Requires-Dist: xformers ; extra == 'local' +Requires-Dist: peft ; extra == 'local' +Requires-Dist: optimum ; extra == 'local' +Requires-Dist: scipy ; extra == 'local' +Requires-Dist: einops ; extra == 'local' + +# [AlpacaEval](https://tatsu-lab.github.io/alpaca_eval/) : An Automatic Evaluator for Instruction-following Language Models + +[![Code License](https://img.shields.io/badge/Code%20License-Apache_2.0-green.svg)](https://github.com/tatsu-lab/alpaca_farm/blob/main/LICENSE) +[![Data License](https://img.shields.io/badge/Data%20License-CC%20By%20NC%204.0-red.svg)](https://github.com/tatsu-lab/alpaca_farm/blob/main/DATA_LICENSE) +[![Python 3.10+](https://img.shields.io/badge/python-3.10+-blue.svg)](https://www.python.org/downloads/release/python-3100/) +[![discord](https://img.shields.io/badge/discord-server-blue?logo=discord&logoColor=white)](https://discord.gg/GJMxJSVZZM) + +Evaluation of instruction-following models (e.g., ChatGPT) typically requires human interactions. This is +time-consuming, expensive, and hard to replicate. AlpacaEval in an LLM-based automatic evaluation that is fast, cheap, +replicable, and validated against 20K human annotations. +It is particularly useful for model development. +Although we improved over prior automatic evaluation pipelines, there are still fundamental [limitations](#limitations) like the preference for longer outputs. +AlpacaEval provides the following: + +- [**Leaderboard**](https://tatsu-lab.github.io/alpaca_eval/): a leaderboard of common models on the AlpacaEval + evaluation set. **Caution**: Automatic evaluator (e.g. GPT4) may be biased towards models that generate longer outputs and/or that were fine-tuned on the model underlying the evaluator (e.g. GPT4). +- [**Automatic evaluator**](#evaluators): an automatic evaluator that has high agreement with humans (validated on 20K + annotations). We evaluate a + model by + measuring the fraction of times an powerful LLM (e.g. GPT 4 or Claude or ChatGPT) prefers the outputs from that model + over + outputs from a reference model. Our evaluators enable caching and output randomization by default. +- [**Toolkit for building automatic evaluators**](#analysis): a simple interface for + building advanced automatic evaluators (e.g. with caching, batching, or multi-annotators) and analyzing them (quality, + price, speed, statistical power, bias, variance etc). +- [**Human evaluation data**](#data-release): 20K human preferences between a given and reference model + on the [AlpacaFarm](https://github.com/tatsu-lab/alpaca_farm/tree/main) + evaluation set. 2.5K of these are cross-annotations (4 humans annotating the same 650 examples). +- [**AlpacaEval dataset**](#data-release): a simplification + of [AlpacaFarm's](https://github.com/tatsu-lab/alpaca_farm/tree/main) evaluation set, where "instructions" and " + inputs" are merged + into one field, and reference outputs are longer. + +**When to use AlpacaEval?** Our automatic evaluator is a quick and cheap proxy for human evaluation of simple +instruction-following tasks. +It is useful if you +have to run many evaluations quickly, e.g., during model development. + +**When not to use AlpacaEval?** +As any other automatic evaluator, AlpacaEval should **not replace human evaluation in +high-stake decision-making**, e.g., to decide on model release. In particular, AlpacaEval is limited by the fact +that (1) the instructions in the eval set might not be representative of advanced usage of LLMs; (2) automatic +evaluators may have biases such as favoring style over +factuality of the answer; and (3) AlpacaEval does not measure the risks that a model could cause. +Details in [limitations](#limitations). + +
+ Table of Contents + +1. [Quick Start](#quick-start) +2. [Leaderboards and how to interpret them](#leaderboards-and-how-to-interpret-them) + - [Models](#models) + - [Evaluators](#evaluators) +3. [Use-cases](#use-cases) + - [Evaluating a model](#evaluating-a-model) + - [Making a new leaderboard](#making-a-new-leaderboard) + - [Making a new evaluator](#making-a-new-evaluator) +4. [Analysis](#additional-analysis-and-plots) + - [Analyzing an evaluator](#analyzing-an-evaluator) + - [Analyzing an eval set](#analyzing-an-eval-set) +5. [Contributing](#contributing) + - [Contributing a model](#contributing-a-model) + - [Contributing an evaluator](#contributing-an-evaluator) + - [Contributing an eval set](#contributing-an-eval-set) +6. [Limitations](#limitations) +7. [Citation](#citation) +8. [Additional information](#additional-information) + - [Data Release](#data-release) + - [Differences with AlpacaFarm](#differences-with-alpacafarm) + - [Related work](#related-work) + - [Major updates](#major-updates) + +
+ +# Quick Start + +To install the stable release, run + +```bash +pip install alpaca-eval +``` + +To install the nightly version, run + +```bash +pip install git+https://github.com/tatsu-lab/alpaca_eval +``` + +Then you can use it as follows: + +```bash +export OPENAI_API_KEY= +export OPENAI_ORGANIZATION_IDS= # Optional; if not set, this will be your default org id. +alpaca_eval --model_outputs 'example/outputs.json' +``` + +This will print the leaderboard to the console, and save both the leaderboard and the annotations to the same directory as the `model_outputs` file. Important parameters are the following: + +- **model_outputs** : A path to a json file for the outputs of the model to add to the leaderboard. Each dictionary + should + contain the keys `instruction` and `output`. +- **annotators_config**: This is the annotator to use (e.g., `alpaca_eval_gpt4` or `claude` + or `chatgpt_fn`). `alpaca_eval_gpt4` ( + default) has the + highest agreement rate with our human annotation data. `claude` has a decent agreement and is free for + academics. `chatgpt_fn` is the worst of the three, but is available to everyone, cheap, and has 2x larger context + window (16K tokens). For a comparison of annotators see [here](#evaluators). +- **reference_outputs**: The outputs of the reference model. Same format as `model_outputs`. By default, this + is `text-davinci003` outputs on + AlpacaEval dataset. +- **output_path**: Path for saving annotations and leaderboard. + +If you don't have the model outputs, you can +use [`evaluate_from_model`](https://github.com/tatsu-lab/alpaca_eval/tree/main#evaluating-a-model) and +pass a local path or a name of a +HuggingFace +model, or a model from a standard API (OpenAI, Anthropic, Cohere). Other commands: + +
+ >>> alpaca_eval -- --help + +``` +SYNOPSIS + alpaca_eval COMMAND + +COMMANDS + COMMAND is one of the following: + + evaluate + Evaluate a model based on its outputs. This is the default entrypoint if no command is specified. + + evaluate_from_model + Evaluate a model from HuggingFace or an API provider. This is a wrapper around `evaluate` which includes generating from a desired model. + + make_leaderboard + Precompute and save an entire leaderboard for a given dataset / evaluator / set of models generations. + + analyze_evaluators + Analyze an evaluator (agreement with human, speed, price,...). +``` + +
+ +For more information about each function use `alpaca_eval -- --help`. + +# Leaderboards and how to interpret them + +## Models + +Our leaderboards are computed on the [AlpacaEval dataset](https://huggingface.co/datasets/tatsu-lab/alpaca_eval). +We precomputed the leaderboard for important models using `alpaca_eval_gpt4` (best quality), `claude` (free for +academics, and high quality), and `chatgpt_fn` (cheap and available for everyone). Our full leaderboards can be found +at [on this page](https://tatsu-lab.github.io/alpaca_eval/), but +we give minimal leaderboards below. +Later we also show how to [add your model](https://github.com/tatsu-lab/alpaca_eval#evaluating-a-model) to the +leaderboard and how to make +a [new leaderboard for your evaluator/dataset](https://github.com/tatsu-lab/alpaca_eval#making-a-new-leaderboard). +See [here](https://github.com/tatsu-lab/alpaca_eval/tree/main/src/alpaca_eval/models_configs) for the configs of all +models that are available out of the box. + +**`alpaca_eval_gpt4` minimal leaderboard**: + +| | Win Rate | Std Error | +|:----------------------|---------:|----------:| +| gpt4 | 95.3 | 0.7 | +| claude | 88.4 | 1.1 | +| chatgpt | 86.1 | 1.2 | +| wizardlm-13b | 75.3 | 1.5 | +| guanaco-65b | 71.8 | 1.6 | +| vicuna-13b | 70.4 | 1.6 | +| oasst-rlhf-llama-33b | 66.5 | 1.7 | +| text_davinci_003 | 50.0 | 0.0 | +| falcon-40b-instruct | 45.7 | 1.8 | +| alpaca-farm-ppo-human | 41.2 | 1.7 | +| alpaca-7b | 26.5 | 1.5 | +| text_davinci_001 | 15.2 | 1.2 | + +
+ How exactly are those metrics computed? + +**Win Rate**: the win rate measures the fraction of time the model's output is preferred over text-davinci-003 outputs ( +i.e. the reference). +More specifically, to compute the win rate we collect pairs of outputs of the desired model on every instruction from +the +ApacaEval dataset. +We then pair each output with the output of our reference model (`text-davinci-003`) on the same instruction. +We then ask our automatic evaluator which output they prefer. +See [here](https://github.com/tatsu-lab/alpaca_eval/tree/main/src/alpaca_eval/evaluators_configs/alpaca_eval_gpt4) +and [here](https://github.com/tatsu-lab/alpaca_eval/tree/main/src/alpaca_eval/evaluators_configs/claude) for the exact +prompts and configs for GPT4 and Claude, in particular we randomize the order of +outputs to avoid position bias. +We then average the preferences over all instructions in the dataset to get the win rate of the model over +text-davinci-003. +If both outputs are exactly the same we use a half preference for both models. + +**Standard error**: this is the standard error (normalized by N-1) of the win rate, i.e., the preferences averaged over +the different instructions. + +[//]: # (The standard error measures the uncertainty over instructions and sampling from the evaluator.) + +
+ +
+ Details about alpaca_eval_gpt4 + +Our `alpaca_eval_gpt4` ( +see [configs](#https://github.com/tatsu-lab/alpaca_eval/blob/main/src/alpaca_eval/evaluators_configs/alpaca_eval_gpt4/configs.yaml#L5)) +annotator averages over preferences, where preferences are obtained as follows: + +1. it takes in an instruction and a pair of outputs (from the desired model and the reference model) +2. if a preference was this triple was already computed, it returns it (i.e. it uses caching) +3. it randomizes the order of the outputs to avoid position bias +4. it formats the instruction and outputs into + the [following zero-shot prompt](https://github.com/tatsu-lab/alpaca_eval/blob/main/src/alpaca_eval/evaluators_configs/alpaca_eval_gpt4/alpaca_eval.txt), + which asks to order the outputs in order of preference +5. it completes the prompt using GPT4 with `temperature=0` +6. it parses the preference from the completions and returns it + +The annotator is a mix between (and was highly influenced by) [AlpacaFarm](https://github.com/tatsu-lab/alpaca_farm) +and [Aviary](https://github.com/ray-project/aviary/tree/master) evaluators. +In particular, we use the same code as for AlpacaFarm (caching/randomization/hyperparameters) but use a ranking prompt +similar to that of Aviary. +We make changes to Aviary's prompt to decrease the bias for longer outputs. +Details in [Related work](#related-work). + +
+ +
+ claude minimal leaderboard + +| | Win Rate | Std Error | +|:----------------------|---------:|----------:| +| gpt4 | 77.0 | 1.5 | +| claude | 75.8 | 1.5 | +| chatgpt | 67.7 | 1.6 | +| wizardlm-13b | 66.1 | 1.7 | +| vicuna-13b | 63.2 | 1.7 | +| guanaco-65b | 62.6 | 1.7 | +| oasst-rlhf-llama-33b | 57.3 | 1.7 | +| text_davinci_003 | 50.0 | 0.0 | +| falcon-40b-instruct | 46.7 | 1.8 | +| alpaca-farm-ppo-human | 46.5 | 1.8 | +| alpaca-7b | 32.3 | 1.6 | +| text_davinci_001 | 21.5 | 1.4 | + +
+ +
+ chatgpt_fn minimal leaderboard + +| | Win Rate | Std Err. | +|:----------------------|---------:|---------:| +| gpt4 | 73.8 | 1.5 | +| claude | 70.4 | 1.6 | +| chatgpt | 66.1 | 1.7 | +| wizardlm-13b | 65.2 | 1.7 | +| vicuna-13b | 64.1 | 1.7 | +| guanaco-65b | 62.4 | 1.7 | +| oasst-rlhf-llama-33b | 62.0 | 1.7 | +| alpaca-farm-ppo-human | 60.2 | 1.7 | +| falcon-40b-instruct | 56.5 | 1.7 | +| text_davinci_003 | 50.0 | 0.0 | +| alpaca-7b | 45.2 | 1.7 | +| text_davinci_001 | 28.1 | 1.6 | + +
+ +## Evaluators + +We evaluate different automatic annotators on the AlpacaEval set by comparing to +2.5K [human annotations](https://huggingface.co/datasets/tatsu-lab/alpaca_eval/blob/main/alpaca_farm_human_crossannotations.json) +we collected (~650 instructions each with 4 human annotations). +Below we show metrics for our suggested evaluator (`alpaca_eval_gpt4`), for prior +automatic +evaluators ([`alpaca_farm_greedy_gpt4`](https://github.com/tatsu-lab/alpaca_farm),[`aviary_gpt4`](https://aviary.anyscale.com/),[`lmsys_gpt4`](https://chat.lmsys.org/)), +for humans (`humans`), and for different base models with essentially the same +prompt (`gpt4`,`claude`,`text_davinci_003`,`chatgpt_fn`,`guanaco_33b`, `chatgpt`). +See [here](https://github.com/tatsu-lab/alpaca_eval/tree/main/src/alpaca_eval/evaluators_configs) for the configs of all +evaluators that are available out of the box and their associated metrics. + +| | Human agreement [%] | Price [$/1000 examples] | Time [seconds/1000 examples] | Bias | Variance | Proba. prefer longer | +|:------------------------|--------------------:|------------------------:|-----------------------------:|-----:|---------:|---------------------:| +| alpaca_eval_gpt4 | 69.2 | 13.6 | 1455 | 28.4 | 14.6 | 0.68 | +| aviary_gpt4 | 69.1 | 12.8 | 1869 | 29.5 | 13.1 | 0.70 | +| gpt4 | 66.9 | 12.5 | 1037 | 31.5 | 14.6 | 0.65 | +| alpaca_farm_greedy_gpt4 | 66.4 | 15.3 | 878 | 30.2 | 19.3 | 0.60 | +| humans | 65.7 | 300.0 | 36800 | 0.0 | 34.3 | 0.64 | +| claude | 65.5 | 11.1 | 173 | 31.9 | 18.0 | 0.62 | +| text_davinci_003 | 64.1 | 8.7 | 121 | 33.8 | 22.7 | 0.70 | +| lmsys_gpt4 | 63.2 | 13.9 | 17982 | 34.7 | 16.1 | 0.74 | +| chatgpt_fn | 60.0 | 1.0 | 530 | 36.9 | 27.7 | 0.62 | +| chatgpt | 57.2 | 0.8 | 285 | 39.4 | 34.1 | 0.59 | + +
+ How exactly are those metrics computed? + +We now explain in words how we compute the metrics in the table +above. [The code is here](https://github.com/tatsu-lab/alpaca_eval/blob/f05cbd651b79ac93906b19d01fe443b45828b0f2/src/alpaca_eval/analyze.py#L366). + +**Human agreement [%]**: this measures the agreement between the current annotator and the majority preferences of +humans on +our +~650 annotations from +our [cross-annotation set](https://huggingface.co/datasets/tatsu-lab/alpaca_eval/blob/main/alpaca_farm_human_crossannotations.json), +which contains 4 human annotations per example. +To estimate the agreement between a single human (`humans` row in the table above) and the majority of humans, we take +one of the 4 annotations and compute the accuracy that it has when predicting the mode of the other 3 annotations. +We then average this accuracy over all 4 annotations and over the 650 instructions to get the human agreement, i.e., we +compute the expected (over humans and samples) +leave-one-out agreement. +If the mode is not unique, we take one of the modes at random. +We perform exactly the same computation for the automatic annotators, so that the final numbers are comparable. + +[//]: # ($$agreement = E[E_i[I[z_i == mode({z^*_j}_{j \neq i})]]]$$) + +**Price [$/1000 examples]**: this is the average price of every 1000 annotations. +For humans, it is the price that [we paid Mechanical Turkers](https://arxiv.org/abs/2305.14387) to collect those +annotations ($18/hour). +If the price depends on the machine used to compute the annotations (e.g. Guanaco) we leave it empty. + +**Time [seconds/1000 examples]**: this is the average time it takes to compute 1000 annotations. +For humans, it is the estimated median time that each Mechanical Turker took to annotate 1000 examples. +For automatic annotators, it is the average time that it took us when running the annotations. Note that this can depend +on API limits that are different for different users and the number of requests that the clusters are +processing. + +**Bias**: agreement between the most likely human label and the most likely automatic one. +For automatic annotators we estimate it by sampling 4 different annotations for each example. +The randomness here comes from the order of the outputs in the prompt, sampling from the LLM, and if applicable the +order of the instruction in the batch and the choice of annotator in the pool. +We then take the mode of the 4 annotations and compute the accuracy of the mode when predicting the mode of the 4 human +annotations. +Note that this is likely an overestimate on the real bias that we would get if we had an "infinite" number of +cross-annotations. +A low bias means that the annotator has in expectation the same preferences as humans. +For the case of humans, the bias is zero by definition. +Note that this is related to but not the standard statistical bias, because we take the mode instead of average over +annotations and we consider 0-1 loss instead of squared loss. + +[//]: # ($$agreement = 1 - E[E_i[I[mode({z_j}_{j \neq i} == mode({z^*_j}_{j \neq i})]]]$$) + +**Variance**: expected agreement a single automatic preference and the most likely one. +We estimate it the same way as we estimated "human agreement" for humans, i.e., we take the expected leave one out error +when predicting the mode of the 3 annotations using the 4th annotation. +A low variance means that the annotator is consistent with its preference, i.e., if you sample from it with different +seeds it will give the same result. +As with the bias, this is not exactly the standard statistical variance, because we take the mode instead of average +over annotations and we +consider 0-1 loss instead of squared loss. + +Note that the "human agreement" is tightly related to the bias and variance. In particular, the variance +measures the error due to the fact that we only use a single annotation while the bias aims to measure the irreducible +error +for the current annotator. + +[//]: # (More specifically we have that `agreement ≈ (1 - bias)*(1 - variance) + bias*variance`.) + +[//]: # (Where the first term measures the agreement due to having no errors from bias and variance, while the second term) + +[//]: # (measures the accuracy due to having errors caused from both the bias and variance.) + +[//]: # ($$agreement = 1 - E[E_i[I[z_i == mode({z_j}_{j \neq i})]]]$$) + +**Proba. prefer longer**: this is the probability that the annotator prefers the longer output when one of the two +outputs is significantly longer than the other (more than 30 characters difference). + +In the [full table](https://github.com/tatsu-lab/alpaca_eval/blob/main/src/alpaca_eval/evaluators_configs/README.md) we +also provide the following metrics: + +**Proba. prefer lists**: this is the probability that the annotator prefers the output that contains a list/bullet +points when one output does but not the other. + +**Proba. prefer 1**: this is the probability that the annotator prefers the first of the pair of outputs. All our +proposed annotators randomize over outputs in the prompt, so this should be 0.5. Prior annotators, such as `lmsys` +and `aviary`, do not. + +**# parsed**: this is the number of examples that the annotator was able to parse. + +Note that if the variance and bias is empty, it means that we only performed one single annotation for each 648 example +due to resource (time and price) constraints. This explains why the #parsed is 648, otherwise it should be 2592. + +
+ +
+ Tips for choosing evaluators + +Overall we recommend using `annotators_config=alpaca_eval_gpt4` if you want the highest agreement with humans, +`annotators_config=claude` if you have academic (free) access to Claude and have a low budget, and +`annotators_config=chatgpt_fn` if you don't have access to the other two models. + +When choosing an annotator we recommend you to consider the following (the first three are obvious): + +- `"Human agreement [%]"` +- `"Price [$/1000 examples]"` +- `"Time [seconds/1000 examples]"` +- `"Proba. prefer longer"` approx. < 0.7. Indeed, we found see that the majority of preference of human annotators have + strong bias for longer answers (as shown by the + high [performance=62.2](https://github.com/tatsu-lab/alpaca_eval/blob/main/src/alpaca_eval/evaluators_configs/README.md) + of + the `"longest"` evaluator that always + prefers the longest output). This suggests that it might more of a bias with the human annotators. In order to avoid + having leaderboards with strong biases for length, we suggest using automatic annotators with less than 0.7 "Proba. + prefer longer". +- `"Variance"` approx. < 0.2. We believe that a good evaluator should have as little variance as possible so that + results are mostly reproducible. Note that variance can be desirable in the case where we are simulating humans + as shown in [AlpacaFarm](https://arxiv.org/abs/2305.14387). + +We filtered the annotators that do not satisfy those requirements in the table above (besides humans / ChatGPT / 003 / +lmsys for +reference purposes). For +all +results see [here](https://github.com/tatsu-lab/alpaca_eval/blob/main/src/alpaca_eval/evaluators_configs/README.md). +In general, we found `alpaca_eval_gpt4` to be a good trade-off between quality / price / time / +variance / length bias. + +
+ +The above metrics are computed with respect to annotations from crowd-workers. Although useful, those annotations are +not perfect, e.g., crowd-workers often favor style +over +factuality. We thus recommend users to validate automatic evaluators on their own instructions and human annotations. +Details in [limitations](#limitations). + +# Use-cases + +[//]: # () + +[//]: # (
) + +[//]: # () + +[//]: # ( Installation from source (optional)) + +[//]: # () + +[//]: # (If you make changes to the configurations files or code, it might be easier to install `alpaca_eval` from source.) + +[//]: # (If so follow the following steps:) + +[//]: # () + +[//]: # (1. clone the repository) + +[//]: # () + +[//]: # (2. install as dev the package: `pip install -e .`) + +[//]: # () + +[//]: # (3. (optional) export) + +[//]: # () + +[//]: # ( all [API_KEYs](https://github.com/tatsu-lab/alpaca_eval/blob/main/src/alpaca_eval/constants.py#L7)) + +[//]: # () + +[//]: # (4. test your installation (assuming you have OpenAI) + +[//]: # () + +[//]: # ( key) `alpaca_eval --model_outputs 'example/outputs.json' --annotators_config 'text_davinci_003' ~~--max_instances 3~~ --caching_path None`) + +[//]: # () + +[//]: # (
) + +## Evaluating a model + +
+ >>> alpaca_eval evaluate -- --help + +``` +NAME + alpaca_eval evaluate - Evaluate a model based on its outputs. This is the default entrypoint if no command is specified. + +SYNOPSIS + alpaca_eval evaluate + +DESCRIPTION + Evaluate a model based on its outputs. This is the default entrypoint if no command is specified. + +FLAGS + --model_outputs=MODEL_OUTPUTS + Type: Optional[Union] + Default: None + The outputs of the model to add to the leaderboard. Accepts data (list of dictionary, pd.dataframe, datasets.Dataset) or a path to read those (json, csv, tsv) or a function to generate those. Each dictionary (or row of dataframe) should contain the keys that are formatted in the prompts. E.g. by default `instruction` and `output` with optional `input`. If None, we just print the leaderboard. + -r, --reference_outputs=REFERENCE_OUTPUTS + Type: Union + Defaul... + The outputs of the reference model. Same format as `model_outputs`. If None, the reference outputs are the + 003 outputs on the AlpacaEval set. + --annotators_config=ANNOTATORS_CONFIG + Type: Union + Default: 'alpaca_eval_gpt4' + The path the (or list of dict of) the annotator's config file. For details see the docstring of `PairwiseA +nnotator`. + -n, --name=NAME + Type: Optional[Optional] + Default: None + The name of the model to add to the leaderboard. If None we check if `generator is in model_outputs` if no +t we use "Current model". + -o, --output_path=OUTPUT_PATH + Type: Union + Default: 'auto' + Path to the directory where the new leaderboard and the annotations should be stored. If None we don't sav +e. If `auto` we use `model_outputs` if it is a path, and otherwise use the directory from which we call the script +. + -p, --precomputed_leaderboard=PRECOMPUTED_LEADERBOARD + Type: Union + Default: 'auto' + The precomputed leaderboard or a path to it (json, csv, or tsv). The leaderboard should contain at least t +he column `win_rate`. If `auto` we will try to use the corresponding leaderboard for the reference outputs (only i +f in CORRESPONDING_OUTPUTS_LEADERBOARDS). If `None` we won't add other models from the leaderboard. + --is_overwrite_leaderboard=IS_OVERWRITE_LEADERBOARD + Type: bool + Default: False + Whether to overwrite the leaderboard if the model is already in it. + -l, --leaderboard_mode_to_print=LEADERBOARD_MODE_TO_PRINT + Type: Optional + Default: 'minimal' + The mode of the leaderboard to use. Only used if the precomputed leaderboard has a column `mode`, in which + case it will filter the leaderboard by this mode. If None keeps all. + -c, --current_leaderboard_mode=CURRENT_LEADERBOARD_MODE + Type: str + Default: 'community' + The mode of the leaderboard for the current method. + --is_return_instead_of_print=IS_RETURN_INSTEAD_OF_PRINT + Type: bool + Default: False + Whether to return the metrics instead of printing the results. + -f, --fn_metric=FN_METRIC + Type: Union + Default: 'pairwise_to_winrate' + The function or function name in `metrics.py` that will be used to convert preference to metrics. The func +tion should take a sequence of preferences (0 for draw, 1 for base win, 2 when the model to compare wins) and retu +rn a dictionary of metrics and the key by which to sort the leaderboard. + -s, --sort_by=SORT_BY + Type: str + Default: 'win_rate' + The key by which to sort the leaderboard. + --is_cache_leaderboard=IS_CACHE_LEADERBOARD + Type: Optional + Default: None + Whether to save the result leaderboard to `precomputed_leaderboard`. If None we save only if max_instances +. A preferred way of adding models to the leaderboard is to set `precomputed_leaderboard` to the previously saved +leaderboard at `/leaderboard.csv`. + --max_instances=MAX_INSTANCES + Type: Optional[Optional] + Default: None + The maximum number of instances to annotate. Useful for testing. + --annotation_kwargs=ANNOTATION_KWARGS + Type: Optional[Optional] + Default: None + Additional arguments to pass to `PairwiseAnnotator.annotate_head2head`. + Additional flags are accepted. + Additional arguments to pass to `PairwiseAnnotator`. +``` + +
+ +
+ >>> alpaca_eval evaluate_from_model -- --help + +``` +NAME + alpaca_eval evaluate_from_model - Evaluate a model from HuggingFace or an API provider. This is a wrapper around `evaluate` which includes generating from a desired model. + +SYNOPSIS + alpaca_eval evaluate_from_model MODEL_CONFIGS + +DESCRIPTION + Evaluate a model from HuggingFace or an API provider. This is a wrapper around `evaluate` which includes generating from a desired model. + +POSITIONAL ARGUMENTS + MODEL_CONFIGS + Type: Union + A dictionary or path (relative to `models_configs`) to a yaml file containing the configuration of the model to decode from. If a directory,we search for 'configs.yaml' in it. The keys in the first dictionary should be the generator's name, and the value should be a dictionary of the generator's configuration which should have the + +FLAGS + -r, --reference_model_configs=REFERENCE_MODEL_CONFIGS + Type: Optional[Union] + Default: None + Same as in `model_configs` but for the reference model. If None, we use the same model as the one we are + -e, --evaluation_dataset=EVALUATION_DATASET + Type: Union + Defaul... + Path to the evaluation dataset or a function that returns a dataframe. If None, we use the default evaluat +ion + -a, --annotators_config=ANNOTATORS_CONFIG + Type: Union + Default: 'alpaca_eval_gpt4' + Path to the annotators configuration or a dictionary. If None, we use the default annotators configuration +. + -o, --output_path=OUTPUT_PATH + Type: Union + Default: 'auto' + Path to save the generations, annotations and leaderboard. If auto saves at `results/` + -m, --max_instances=MAX_INSTANCES + Type: Optional[int] + Default: None + Maximum number of instances to generate and evaluate. If None, we evaluate all instances. + -i, --is_strip_output=IS_STRIP_OUTPUT + Type: bool + Default: True + Whether to strip trailing and leading whitespaces from the outputs. + Additional flags are accepted. + Other kwargs to `evaluate` + +NOTES + You can also use flags syntax for POSITIONAL ARGUMENTS +``` + +
+ +To evaluate a model you need to: + +1. Choose an evaluation set and compute outputs specified as `model_outputs`. By default, we use + the 805 examples from [AlpacaEval](#data-release). To compute outputs on AlpacaEval use: + +```python +import datasets + +eval_set = datasets.load_dataset("tatsu-lab/alpaca_eval", "alpaca_eval")["eval"] +for example in eval_set: + # generate here is a placeholder for your models generations + example["output"] = generate(example["instruction"]) +``` + +if your model is a HuggingFace model or from a standard API provider (OpenAI, Anthropic, Cohere). Then you can +directly use `alpaca_eval evaluate_from_model` to also take care of generating outputs. + +2. Compute the reference outputs `reference_outputs`. By default, we use the outputs of `text-davinci-003` on + AlpacaEval. + If you + want to use a different model or a different dataset follow the same steps as (1.). +3. Choose an evaluator specified via `annotators_config`. We recommend using `alpaca_eval_gpt4` or `claude` (if you are + an + academic) or `chatgpt_fn` (if you don't have access to the other two). For options and comparisons + see [this table](#evaluators). Depending on the evaluator you might need to + set the appropriate API_KEY in your environment + or [here](https://github.com/tatsu-lab/alpaca_eval/blob/main/src/alpaca_eval/constants.py#L7). + +Running all together: + +```bash +alpaca_eval --model_outputs 'example/outputs.json' \ + --annotators_config 'alpaca_eval_gpt4' \ + --reference_outputs +``` + +If you don't have decoded outputs, you can use `evaluate_from_model` which takes care of decoding (model and reference) +for you. +Here's an +example: + +```bash +# need a GPU for local models +export ANTHROPIC_API_KEY= # let's annotate with claude +alpaca_eval evaluate_from_model \ + --model_configs 'oasst_pythia_12b' \ + --annotators_config 'claude' \ + --reference_model_configs +``` + +Here the `model_configs` and `reference_model_configs` (optional) are paths to a directory that specifies the prompt, +the model +provider (here HuggingFace) and decoding parameters. +See [this directory](https://github.com/tatsu-lab/alpaca_eval/tree/main/src/alpaca_eval/models_configs) for examples. +For all model providers that are available out-of-the-box +see [here](https://github.com/tatsu-lab/alpaca_eval/tree/main/src/alpaca_eval/decoders). + +
+ Information about annotators + +- **Caching**: by default all annotations are cached on + disk at `caching_path`. Annotations are thus never recomputed, which makes annotations faster, cheaper and allow for + reproducibility. This helps even when evaluating different models as many models + have + the same outputs. +- **Output randomization** by default, we randomize over the examples of outputs, as we found that annotators tend to + prefer the first examples + they see. +- **Batching** we provide code and examples to batch annotations, which decreases cost and time for annotations if the + prompt is long. See for + example [alpaca_farm_greedy_gpt4](https://github.com/tatsu-lab/alpaca_eval/tree/main/src/alpaca_eval/evaluators_configs/alpaca_farm_greedy_gpt4). +- **Pool of annotators** we provide code and examples to evaluate using a pool of automatic annotators, which is helpful + for replicating the variance of [human annotations](https://arxiv.org/abs/2305.14387). See for + example [alpaca_farm](https://github.com/tatsu-lab/alpaca_eval/tree/main/src/alpaca_eval/evaluators_configs/alpaca_farm). +- **Seeding based on instructions** For reproducibility and more fair comparison between models, we seed all + randomness (output order, order in batches, + examples for each annotator in a pool) based on the instruction. + +
+ +## Making a new leaderboard + +
+ >>> alpaca_eval make_leaderboard -- --help + +``` +NAME + alpaca_eval make_leaderboard - Precompute and save an entire leaderboard for a given dataset / evaluator / set of models generations. + +SYNOPSIS + alpaca_eval make_leaderboard LEADERBOARD_PATH + +DESCRIPTION + Precompute and save an entire leaderboard for a given dataset / evaluator / set of models generations. + +POSITIONAL ARGUMENTS + LEADERBOARD_PATH + Type: Union + The path to save the leaderboard to. The leaderboard will be saved as a csv file, if it already exists it will + +FLAGS + --annotators_config=ANNOTATORS_CONFIG + Type: Union + Default: 'alpaca_eval_gpt4' + The path the (or list of dict of) the annotator's config file. + --all_model_outputs=ALL_MODEL_OUTPUTS + Type: Union + Default: + +If you want to make a new leaderboard using a single command (rather than multiple `alpaca_eval` calls), for your +desired evaluation +set and evaluators, you can use the following: + +```bash +alpaca_eval make_leaderboard \ + --leaderboard_path \ + --all_model_outputs \ + --reference_outputs \ + --annotators_config +``` + +where: + +- `leaderboard_path`: path to save the leaderboard to. The leaderboard will be saved as a csv file, if it already exists + it will append. +- `all_model_outputs` : The json path to the outputs of all models to add to the leaderboard (as a single file or by + globbing multiple files). Each dictionary should contain + the keys (`instruction` and `output`) that are formatted in the prompts and a column `generator` with the name of the + current model. As an example + see [this file](https://huggingface.co/datasets/tatsu-lab/alpaca_eval/blob/main/alpaca_eval_all_outputs.json). +- `reference_outputs` the path to the outputs of the reference model. Each dictionary should contain + the keys (`instruction` and `output`) that are formatted in the prompts. By + default, the reference outputs are the 003 outputs on AlpacaEval set. +- `annotators_config`: The path to the annotator's config file. Defaults to `alpaca_eval_gpt4`. + +## Making a new evaluator + +
+ >>> alpaca_eval analyze_evaluators -- --help + +``` +NAME + alpaca_eval analyze_evaluators - Analyze an evaluator and populates the evaluators leaderboard (agreement with human, speed, price,...). + +SYNOPSIS + alpaca_eval analyze_evaluators + +DESCRIPTION + Analyze an evaluator (agreement with human, speed, price,...). + +FLAGS + --annotators_config=ANNOTATORS_CONFIG + Type: Union + Default: 'alpaca_eval_gpt4' + The path the (or list of dict of) the annotator's config file. + -A, --Annotator=ANNOTATOR + Default: + +AlpacaEval provides a simple way of making new evaluators. All you need is to make a new `configs.yaml` configuration +file, which you will then pass +as `--annotators_config ` to `alpaca_eval`. +Here are some ways you can make a new evaluator: + +- **Changing the prompt**: Write a new prompt in a text file and specify the path in `prompt_template` of the + configuration file. Paths are relative to the configuration file. +- **Changing decoding parameters**: Specify the desired parameters in `completions_kwargs` in the configuration file. To + see all available parameters refer to the docstrings of the corresponding + function [in this file](https://github.com/tatsu-lab/alpaca_eval/blob/main/src/alpaca_eval/decoders/__init__.py) + specified by `fn_completions` + in the configuration file. +- **Changing the model**: Specify the desired model in `model_name` and the corresponding + prompt in `prompt_template`. If the model comes from another provider you + will + have + to change `fn_completions` which maps to the corresponding function + in [this file](https://github.com/tatsu-lab/alpaca_eval/blob/main/src/alpaca_eval/decoders/__init__.py). We + provide `fn_completions` functions to use models from OpenAI, Anthropic, Cohere, or HuggingFace. To + install packages needed for + all providers + use `pip install alpaca_eval[all]`. + +[//]: # (- **Using multiple annotators**: Specify a list of annotators in `annotators_config` in the configuration file. For an) + +[//]: # ( example) + +[//]: # ( see [alpaca_farm configuration](https://github.com/tatsu-lab/alpaca_eval/blob/main/src/alpaca_eval/evaluators_configs/alpaca_farm/configs.yaml).) + +
+ Other parameters in the configuration file + +The easiest is to check the docstrings +of [`SinglePairwiseAnnotator`](https://github.com/tatsu-lab/alpaca_eval/blob/main/src/alpaca_eval/annotators/pairwise_evaluator.py#L537). +Here are some important ones: + +``` +Parameters +---------- +prompt_template : path + A prompt that will be given to `fn_prompter` or path to the prompts. Path is relative to + `evaluators_configs/` + +fn_completion_parser : callable or str + Function in `completion_parsers.py` to use for parsing the completions into preferences. For each completion, + the number of preferences should be equal to the batch_size if not we set all the preferences in that batch to + NaN. + +completion_parser_kwargs : dict + Kwargs for fn_completion_parser. + +fn_completions : callable or str + Function in `decoders.py` to use for decoding the output. + +completions_kwargs : dict + kwargs for fn_completions. E.g. model_name, max_tokens, temperature, top_p, top_k, stop_seq. + +is_randomize_output_order : bool + Whether to randomize output_1, output_2 when formatting. + +batch_size : int + Number of examples that will be added in a single prompt. +``` + +
+ +Once you made the evaluator you can also analyze it and add it to the _evaluator's_ [leaderboard](#evaluators) using the +following command: + +```bash +alpaca_eval analyze_evaluators --annotators_config '' +``` + +To estimate the bias and variance this evaluates every example with 4 seeds, i.e., 2.5K +evaluation. +If you want a cheaper evaluation you can use a single seed using `--is_single_annotator True` which will skip the +estimation of bias and variance. + +# Additional analysis and plots + +AlpacaEval provides a few visualization tools to help you analyze and improve your automatic evaluation pipeline. We +briefly explain +them here and provide +notebooks for more analysis. +For a description of all the metrics we consider +refer to [How exactly are those metrics computed?](https://github.com/tatsu-lab/alpaca_eval#evaluators) + +## Analyzing an evaluator + +**Analyzing evaluators:** +[![analyzing an evaluator](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/tatsu-lab/alpaca_eval/blob/main/notebooks/analyzing_annotators.ipynb) + +As we saw in [the evaluator's leaderboard](#evaluators), there are many metrics to consider when selecting an evaluator, +e.g. the quality, price, and speed. To assist with selection of the evaluator we provide a few functions to plot those +metrics. +The following shows for example the price/time/agreement of the different evaluators. + +![plot_quality_vs_price_and_time.png](figures%2Fplot_quality_vs_price_and_time.png) + +Here we see that `alpaca_eval_gpt4` performs very well and is better than humans on all the considered metrics. + +Previously we only considered the agreement with human annotators overall. +An additional validation that one could do is checking whether making a leaderboard using our +automatic annotator gives similar results as a leaderboard from humans. +To enable such analysis, we release [human +annotations](#data-release) of outputs from 22 methods from [AlpacaFarm](https://github.com/tatsu-lab/alpaca_farm) => +22*805 = ~18K annotations. As a result we +can +test +the correlation between the win-rates of the 22 models as evaluated by the humans and our automatic annotator. +Note that this is arguably a better way of selecting an automatic evaluator than using "human agreement [%]" but is +expensive given that it requires 18K +annotations. +The plot below shows such correlation for the `alpaca_eval_gpt4` evaluator. + +

+Correlation between humans and alpaca_eval_gpt4 +

+ +We see that the `alpaca_eval_gpt4` leaderboard is highly correlated (0.94 Pearson correlation) to the leaderboard from +humans, which further +suggests that automatic evaluation is a good proxy for human evaluation. +For the code and more analysis, +see [this notebook](https://github.com/tatsu-lab/alpaca_eval/blob/main/notebooks/analyzing_annotators.ipynb), or the +colab notebook above. + +## Analyzing an eval set + +**Making evaluation sets:** +[![analyzing an evaluator](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/tatsu-lab/alpaca_eval/blob/main/notebooks/analyzing_evalset.ipynb) + +When creating an evaluation set there are two main factors to consider: how much data to use? and what data? + +One way of answering those question is by considering a leaderboard of models that you believe are of different +quality and checking what and how much data is needed to distinguish between them in a statistically significant way. +We will do so below using a paired t-test to test if the difference in win-rates between every pair of models +is +statistically significant. + +First, let us consider the question of how much data to use. +Below we show the number of random samples needed from AlpacaEval for the paired t-test to give a p-value < 0.05 for +each pair of models in the minimal `alpaca_eval_gpt4` +leaderboard. +Grey cells correspond to pairs that are not significantly different on the 805 samples. +y- and x-axis are ordered by the win-rate of the first and second model respectively. + +[//]: # (![plot_paired_ttest_nsamples.png](figures%2Fplot_paired_ttest_nsamples.png)) + +

+Number of samples needed to distinguish pairs in the Claude leaderboard +

+ +We see that most models can already be distinguished with 50 samples, and that 150 samples allows distinguishing the +majority of pairs (74 out of 78). This suggests that we can decrease the evaluation set size by a factor of +4 when testing two models that have similar performance gaps as those on the +minimal `alpaca_eval_gpt4` [leaderboard](#models). + +The second question is what data to use. Again we can try to answer this question from a statistical power perspective: +what data allows to best distinguish between models. Let's consider this for all the datasets that are part of +AlpacaEval, but let us control for the size of the evaluation sets as we only care about the quality of the data. The +following plot shows the p-values from the paired t-test of each pairs of models on 80 examples of each subset of +AlpacaEval. + +![plot_paired_ttests_per_dataset.png](figures%2Fplot_paired_ttests_per_dataset.png) + +We see for example that the self-instruct dataset yields the least statistical power, which suggests that one could +remove this dataset from the evaluation set. +The exact reason should be analyzed in future work. +For the code and more analysis +see [this notebook](https://github.com/tatsu-lab/alpaca_eval/blob/main/notebooks/analyzing_evalset.ipynb), or the +colab notebook above. + +# Contributing + +We are accepting PRs for new models, evaluators, and eval sets, in addition to bug fixes. +We will update the [leaderboard website](https://tatsu-lab.github.io/alpaca_eval/) regularly with new community +contributions. +We have also created a [support discord](https://discord.gg/GJMxJSVZZM) for AlpacaEval in case you run into any issues +and +wish to ask help from the community. + +To get started, please first fork the repo, and install the package from source `pip install -e .` + +
+

Contributing a model

+ +First, you'll need to add a model config definition in the [models_configs](src/alpaca_eval/models_configs/) folder. As +an example, you can look at +the [falcon-7b-instruct yaml](src/alpaca_eval/models_configs/falcon-7b-instruct/configs.yaml). Please make sure the +folder name and key name in the yaml match exactly. + +Then, please follow the steps in [Evaluating a model](#evaluating-a-model) to run inference on the model to produce +outputs on the eval set and score the model according to one of the evaluators. +An example command may look like: + +```sh +alpaca_eval evaluate_from_model \ + --model_configs 'falcon-7b-instruct' \ + --annotators_config 'alpaca_eval_gpt4' +``` + +After running this command, you should have generated an outputs json and a new entry in the corresponding [leaderboard +file](https://github.com/tatsu-lab/alpaca_eval/tree/main/src/alpaca_eval/leaderboards/data_AlpacaEval). Please make a PR +with the +config, outputs file, and updated leaderboard. + +Concretely you should do something like: + +1. Fork the repository in github +2. Clone the forked repository `git clone ` +3. Make a model config at `src/alpaca_eval/models_configs/` and evaluate it `evaluate_from_model --model_configs ''` +4. Add the model configs, output, and leaderboard entry to the forked repository +```sh +git add src/alpaca_eval/models_configs/ +git add src/alpaca_eval/leaderboards/data_AlpacaEval +git add results//model_outputs.json +git commit -m "Add to AlpacaEval" +git push +``` +5. Create a [pull request on AlpacaEval](https://github.com/tatsu-lab/alpaca_eval/pulls) + +
+ +
+

Contributing an evaluator

+ +Please first follow the directions in [Making a new evaluator](#making-a-new-evaluator). +Once you're created the annotator config, we ask that you create a new leaderboard for the annotator by evaluating the +minimal set of models. The outputs for these models can be found by +downloading [alpaca_eval_all_outputs.json](https://huggingface.co/datasets/tatsu-lab/alpaca_eval/blob/main/alpaca_eval_all_outputs.json). + +```bash +alpaca_eval make_leaderboard \ + --leaderboard_path src/alpaca_eval/leaderboards/data_AlpacaEval/_leaderboard.csv \ + --all_model_outputs alpaca_eval_all_outputs.json \ + --annotators_config +``` + +Then, please create a PR with the annotator config and leaderboard csv. + +
+ +
+

Contributing an eval set

+ +To contribute a new eval set, you'll first need to specify a set of textual instructions. +Then, you'll need to specify a set of reference outputs (model win-rates are computed against this reference). +For ease of use, you may use the default [text-davinci-003](src/alpaca_eval/models_configs/text_davinci_003/) reference +config. + +Place these together into a json, where each entry specifies the fields `instruction`, `output`, and `generator`. You +can look to [alpaca_eval.json](https://huggingface.co/datasets/tatsu-lab/alpaca_eval/blob/main/alpaca_eval.json) as a +guide (the `dataset` field is not necessary). + +Finally, we ask that you create a minimal leaderboard on this new evaluation set. You can do this with the following: + +```bash +alpaca_eval make_leaderboard \ + --leaderboard_path \ + --all_model_outputs alpaca_eval_all_outputs.json \ + --reference_outputs +``` + +Please submit a PR with the eval set json and corresponding leaderboard csv. + +
+ +# Limitations + +The AlpacaEval evaluation pipeline, like other current evaluators have important limitations and should therefore not be +used as replacement for human evaluation in important settings, such as to decide whether a model is ready to be +deployed. +Those can broadly be clustered into 3 categories: + +1. **Instructions might not be representative of real-usage**: the AlpacaEval set contains examples from a variety of + datasets ([self-instruct](https://github.com/yizhongw/self-instruct), + [open-assistant](https://huggingface.co/datasets/OpenAssistant/oasst1/viewer/OpenAssistant--oasst1/validation), [vicuna](https://lmsys.org/blog/2023-03-30-vicuna/), [koala](https://github.com/arnav-gudibande/koala-test-set), [hh-rlhf](https://huggingface.co/datasets/Anthropic/hh-rlhf/viewer/Anthropic--hh-rlhf/test)) + which might not be representative of real-usage and advanced applications of better models like GPT4. As a + result, the gap between the top and the rest of the AlpacaEval leaderboard is likely smaller than it would be on more + complex instructions. See for + example [this blog](https://medium.com/@marcotcr/exploring-chatgpt-vs-open-source-models-on-slightly-harder-tasks-aa0395c31610) + for preliminary results on more complex instructions. + Note, however, that in [AlpacaFarm](https://arxiv.org/abs/2305.14387) we showed that win-rates on our evaluation set + are highly correlated (0.97 R2) with win-rates on instructions from user interactions with the Alpaca Demo. + Furthermore, the AlpacaEval leaderboard shows larger + gap between the open models and OpenAI models than other leaderboards ( + e.g. [lmsys](https://lmsys.org/blog/2023-03-30-vicuna/)). + +2. **Biases of automatic annotators**: the automatic annotators seem to have implicit biases. In particular, we found + that they tend to prefer longer outputs and outputs that contain lists (e.g. 0.68 / 0.69 for `alpaca_eval_gpt4` + and 0.62 / 0.58 for `claude`). + Although we found that humans have similar biases (0.64 / 0.61), we believe that this could be more of a limitation + of human annotation pipeline we used rather than a true human bias. More generally, through qualitative analysis, we + found that automatic annotators give more importance to the style + of the output than its content (e.g. factuality). + Finally, we found that automatic evaluators tend to prefer outputs from models that are similar (likely trained on + the same data) as suggested by the big difference between ChatGPT/GPT4 on `claude`'s and `alpaca_eval_gpt4`'s + leaderboard. +3. **Lack of safety evaluation**: importantly, AlpacaEval only evaluates the instruction-following capabilities of + models rather than the harm that they could cause (e.g. toxic behavior or bias). As a result the small gap between + current ChatGPT and the best open source models **should not** be interpreted as if that the latter are ready to be + deployed. + +Beyond those limitations about the evaluation pipelines, there are also limitations about our validation of the +evaluators and our [proposed approach](#analyzing-an-eval-set) to selecting evaluation sets. + +
+ Limitations about our validation pipeline + +First, our validation of evaluators based on human cross-annotations suffers from the following limitations: (1) we +qualitatively found that our crowd-workers tend to also favor style such as length and presence of lists over +factuality; +(2) this does not validate whether win-rates against a reference model is a good evaluation strategy in the first place; +(3) preferences from 16 crowd-workers are not representative of preferences of all humans. + +Second, our suggested approach to selecting evaluation sets based on statistical power suffers from the following +limitations: (1) statistical power does not ensure the right direction, e.g. you can have an unnatural set of +instructions where Alpaca "performs" better than better model; and +(2) this can push users to select data to support the hypothesis that they want to validate. + +
+ +# Citation + +Please consider citing the repo if you used the automatic annotators, code, or results. + +``` +@misc{alpaca_eval, + author = {Xuechen Li and Tianyi Zhang and Yann Dubois and Rohan Taori and Ishaan Gulrajani and Carlos Guestrin and Percy Liang and Tatsunori B. Hashimoto }, + title = {AlpacaEval: An Automatic Evaluator of Instruction-following Models}, + year = {2023}, + publisher = {GitHub}, + journal = {GitHub repository}, + howpublished = {\url{https://github.com/tatsu-lab/alpaca_eval}} +} +``` + +If you used our human annotation data, please also consider citing the [AlpacaFarm](https://arxiv.org/abs/2305.14387) +paper: + +``` +@misc{dubois2023alpacafarm, + title={AlpacaFarm: A Simulation Framework for Methods that Learn from Human Feedback}, + author={Yann Dubois and Xuechen Li and Rohan Taori and Tianyi Zhang and Ishaan Gulrajani and Jimmy Ba and Carlos Guestrin and Percy Liang and Tatsunori B. Hashimoto}, + year={2023}, + eprint={2305.14387}, + archivePrefix={arXiv}, + primaryClass={cs.LG} +} +``` + +If you use the AlpacaEval evaluation set, please cite each of the constituent +datasets: [self-instruct](https://github.com/yizhongw/self-instruct), +[open-assistant](https://huggingface.co/datasets/OpenAssistant/oasst1/viewer/OpenAssistant--oasst1/validation), [vicuna](https://lmsys.org/blog/2023-03-30-vicuna/), [koala](https://github.com/arnav-gudibande/koala-test-set), [hh-rlhf](https://huggingface.co/datasets/Anthropic/hh-rlhf/viewer/Anthropic--hh-rlhf/test). + +# More information + +
+

Data Release

+ +As part of AlpacaEval, we release the following data: + +- **Human annotations (17701)** in order to develop and understand automatic evaluators, we release all the human + pairwise + evaluation that we collected for AlpacaFarm. This contains comparisons between 22 models with the `text-davinci-003` + reference on the AlpacaFarm evaluation set. Annotations are from a pool of 16 crowd workers on Amazon Mechanical Turk. + The different models are: 6 from OpenAI, 2 SFT models from AlpacaFarm, 13 RLHF methods from AlpacaFarm, and LLaMA 7B. +- **Human cross-annotations (2596)** in order to further analyze automatic evaluators we selected (via stratified + sampling + across models and datasets) 650 examples from the AlpacaFarm evaluation set and collected 4 human annotations per + example. +- **AlpacaEval set (805)** we made slight modifications/simplification of the AlpacaFarm evaluation set. In particular, + we first merged + the instruction and input fields into a single instruction field. This affects 1/4 of the examples in the AlpacaFarm + evaluation set, all of which are from the [self-instruct evaluation set](https://arxiv.org/abs/2212.10560). Second we + regenerated the text-davinci-003 reference outputs without limiting the length of its outputs. + +For more details about the human annotations refer to the [AlpacaFarm paper](https://arxiv.org/abs/2305.14387). + +
+ +
+

Differences with AlpacaFarm

+ +AlpacaEval is an improvement and simplification of the automatic pairwise preference simulator +from [AlpacaFarm](https://github.com/tatsu-lab/alpaca_farm). +Outside AlpacaFarm, you should be using AlpacaEval. +Here are the main differences: + +- **AlpacaEval merges instructions and inputs**: The AlpacaEval evaluation is the same as the AlpacaFarm evaluation + except that the instruction and input fields are merged as `{instruction}\n\n{input}`. This affects 1/4 of the + examples in the AlpacaFarm evaluation set (the [self-instruct](https://arxiv.org/abs/2212.10560) subset). + This simplification provides a more fair comparison for models that were not trained by distinguishing between + the two fields. +- **AlpacaEval handles longer generations**: Models in AlpacaFarm were limited to a maximum number of 300 tokens for + generations. We + change this number to 2000 for AlpacaEval. Note that this also affects the reference generations (`text-davinci-003`), + so the results on AlpacaEval are not comparable to those on AlpacaFarm even for examples that had no input + field. +- **AlpacaEval removes intra- and inter-annotator variance**: The AlpacaFarm simulator replicates human annotation in + terms of both mode behavior and diversity. + In particular, AlpacaFarm's simulator uses a pool of models and prompts and adds noise to replicate human intra- and + inter-annotator variance. + If the goal is to use an automatic annotator for evaluation or simply training better models, then this variance + may not be desirable. The default annotators in AlpacaEval thus don't have this variance. We give the option to add it + back by + using `--anotators_config 'alpaca_farm'` and `--p_label_flip 0.25` when creating an evaluator. + +[//]: # (- **Different goals** The goal of AlpacaEval is to provide a package for fast, reproducible,cheap, and) + +[//]: # ( high-quality automatic evaluation of instruction-following models. As a secondary goal, we also provide simple toolkit for developing new evaluators. The goal of AlpacaFarm was to provide a simulator for studying the human-based RLHF pipeline.) + +
+ +
+

Related work

+ +There have been several work that propose new automatic annotators for instruction-following models. Here we list the +ones that we are aware of and discuss how they differ from ours. We evaluated all of those +in [our evaluator's leaderboard](https://github.com/tatsu-lab/alpaca_eval#evaluators). + +- **Vicuna/lmsys** The lmsys annotator (`lmsys_gpt4`) evaluates the pair by asking the annotator a score from 1-10 for + each output, and then selecting the output with the highest score as preferred. They do not randomize over output + order and they ask an explanation _after_ the score. Overall, we found that this annotator has strong bias towards + longer outputs (0.74) and relatively low correlation with human annotations (63.2). +- **AlpacaFarm** The best AlpacaFarm annotator (`alpaca_farm_greedy_gpt4`) evaluates the pair by directly asking the + annotator + which output it prefers. Furthermore, it batches 5 examples together to amortize the length of the prompt and + randomizes the order of outputs. Overall, we + found that this annotator has much less bias towards longer outputs (0.60) and is faster (878 seconds/1000 examples) + than others. It has a + slightly higher correlation with the majority of human annotations (66.4) than humans themselves (65.7). + However, it is more expensive ($15.3/1000 examples) and doesn't work with very long outputs given the batching. +- **Aviary** The Aviary annotator (`aviary_gpt4`) asks the annotator to order the output by its preference, rather than + simply selecting the preferred output. It does not randomize the order of outputs and uses high temperature for + decoding (0.9). Overall, we found that this annotator has relatively strong bias towards longer outputs (0.70) and + very high + correlation with human annotations (69.1). By decreasing the temperature and randomizing the order of outputs, + we [further improved](https://github.com/tatsu-lab/alpaca_eval/blob/main/src/alpaca_eval/evaluators_configs/README.md) + the correlation to 69.8 (`improved_aviary_gpt4`) but this further increased the length bias to 0.73. + +Our `alpaca_eval_gpt4` is a mix between the AlpacaFarm and Aviary annotators. It asks the annotator to order the outputs +by preference, but it uses temperature 0, randomizes over outputs, and made some modifications to the prompt to decrease +length bias to 0.68. + +Other related work include recent papers which analyze automatic evaluators. +For example: + +- [AlpacaFarm Appx C](https://arxiv.org/abs/2305.14387) + and [Large Language Models are not Fair Evaluators](https://arxiv.org/abs/2305.17926v1) both found that automatic + annotators have + a position bias. +- [AlpacaFarm Sec. 5.2.](https://arxiv.org/abs/2305.14387) + and [The False Promise of Imitating Proprietary LLMs](https://arxiv.org/abs/2305.15717) both found that + automatic + annotators favor style (e.g. use of list, tone, word choice, length) over factuality. + +
+ + +
+

Major updates

+ +- 19th June 2023: add leaderboard `chatgpt_fn` that anyone can use (no waiting lists). +- 19th June 2023: update to + use [OpenAI's function calling](https://openai.com/blog/function-calling-and-other-api-updates). + Example: [`chatgpt_fn`](https://github.com/tatsu-lab/alpaca_eval/tree/main/src/alpaca_eval/evaluators_configs/chatgpt_fn) + or [`alpaca_eval_gpt4_fn`](https://github.com/tatsu-lab/alpaca_eval/tree/main/src/alpaca_eval/evaluators_configs/alpaca_eval_gpt4_fn). + +
diff --git a/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/RECORD b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..2da58556d0504c189c552b82d51b8ea182fa5c10 --- /dev/null +++ b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/RECORD @@ -0,0 +1,166 @@ +../../../bin/alpaca_eval,sha256=BpXXPXpg_bi6kqCZzS-5UoP9l8AFATmwTBqQGx11NBA,285 +alpaca_eval-0.2.6.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +alpaca_eval-0.2.6.dist-info/LICENSE,sha256=bhdenb4mu0Leg2e_IhUwGnGz9AMkOi7vxWN4swdji-g,11409 +alpaca_eval-0.2.6.dist-info/METADATA,sha256=Vm5D-aX5wU_GWV7YuD5aAzifAL1HAbN9UD9tJ97dsp4,69528 +alpaca_eval-0.2.6.dist-info/RECORD,, +alpaca_eval-0.2.6.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +alpaca_eval-0.2.6.dist-info/WHEEL,sha256=AtBG6SXL3KF_v0NxLf0ehyVOh0cold-JbJYXNGorC6Q,92 +alpaca_eval-0.2.6.dist-info/entry_points.txt,sha256=80Fbhb475MjCZie0wJzpm3dJZXQ5_jXdIeumUSvXkHg,54 +alpaca_eval-0.2.6.dist-info/top_level.txt,sha256=k6m1kZMZ1fuDbyOuJKNqDIdgvnqsg-PcVO7-ejJXOAU,12 +alpaca_eval/__init__.py,sha256=29BtDatK9rha7K_7aWDyv15XTCWWtPpD2STcRpBLUwc,98 +alpaca_eval/__pycache__/__init__.cpython-310.pyc,, +alpaca_eval/__pycache__/analyze.cpython-310.pyc,, +alpaca_eval/__pycache__/completion_parsers.cpython-310.pyc,, +alpaca_eval/__pycache__/constants.cpython-310.pyc,, +alpaca_eval/__pycache__/main.cpython-310.pyc,, +alpaca_eval/__pycache__/metrics.cpython-310.pyc,, +alpaca_eval/__pycache__/plotting.cpython-310.pyc,, +alpaca_eval/__pycache__/processors.cpython-310.pyc,, +alpaca_eval/__pycache__/types.cpython-310.pyc,, +alpaca_eval/__pycache__/utils.cpython-310.pyc,, +alpaca_eval/analyze.py,sha256=gt-B3nKsSgTUvb_LyM_wgqA8jAEr1U6FpwSnbn8VXFc,21377 +alpaca_eval/annotators/__init__.py,sha256=1Hwqc8H9AdbPscwqM7NsPkNNSYdajZhv69ZbaXr6blY,54 +alpaca_eval/annotators/__pycache__/__init__.cpython-310.pyc,, +alpaca_eval/annotators/__pycache__/base.cpython-310.pyc,, +alpaca_eval/annotators/__pycache__/pairwise_evaluator.cpython-310.pyc,, +alpaca_eval/annotators/base.py,sha256=7STVc8KUCgT0qoiH7VGROg8KLeG6hE-q-wavO574uTI,28020 +alpaca_eval/annotators/pairwise_evaluator.py,sha256=bbXuY_QD5yW6NggAjl6cz2tqY3oeeFz4K9ELY-hoINw,15880 +alpaca_eval/completion_parsers.py,sha256=b31yToNNXCKQnMqNU_n1OUzOm_ckiAaCCxY1w_bmxY4,6482 +alpaca_eval/constants.py,sha256=s0zC5i6VrE2823CIsCR2VuonlCiVbpzVb5HJQTEB5sY,4756 +alpaca_eval/decoders/__init__.py,sha256=XvQ9VFJI1kY_aiC4seOZ-MliBMIbA0tfgS0IUmiPme0,2370 +alpaca_eval/decoders/__pycache__/__init__.cpython-310.pyc,, +alpaca_eval/decoders/__pycache__/anthropic.cpython-310.pyc,, +alpaca_eval/decoders/__pycache__/cohere.cpython-310.pyc,, +alpaca_eval/decoders/__pycache__/huggingface_api.cpython-310.pyc,, +alpaca_eval/decoders/__pycache__/huggingface_local.cpython-310.pyc,, +alpaca_eval/decoders/__pycache__/openai.cpython-310.pyc,, +alpaca_eval/decoders/__pycache__/replicate.cpython-310.pyc,, +alpaca_eval/decoders/anthropic.py,sha256=z_cdByCzGiIxglOC7Fxg2yZbKgUHYr05oiIBASILZtc,4409 +alpaca_eval/decoders/cohere.py,sha256=9jW8Pjh-_QEuJKDxZcr7RJcyw0LKZNnDyPkRHueDwxs,3423 +alpaca_eval/decoders/huggingface_api.py,sha256=SQs_MWI0d909oq5oVMXBgi02g0jLtrx8u8_Y_hIAdss,3751 +alpaca_eval/decoders/huggingface_local.py,sha256=gJ79MppXR5XcE0ar2nzwaBYF6nH1kczvv2A-abtM0FA,5090 +alpaca_eval/decoders/openai.py,sha256=_D17aF17lVCU276d2JI2zFsAdUZerNIP6i4G9K0aUzQ,12959 +alpaca_eval/decoders/replicate.py,sha256=n7rRQWDviwKT2K1oMsQb3AEDHI0kEt9wRZmZ-4e2Qrk,2440 +alpaca_eval/evaluators_configs/README.md,sha256=Y29kC7CbnnMiuT-4X6TpgWbuD6KgotFf-GiZDnKzf5c,9753 +alpaca_eval/evaluators_configs/alpaca_eval_gpt4/alpaca_eval.txt,sha256=z0us5D-mrHGUS5yiUGWHrXxQlHiiGemKOVCr-dW0Kpg,1204 +alpaca_eval/evaluators_configs/alpaca_eval_gpt4/configs.yaml,sha256=Z2cX05ktVZMH1jZh7xJxEy39YTEA90f2zo1Ypwd8Yj0,270 +alpaca_eval/evaluators_configs/alpaca_eval_gpt4_fn/alpaca_eval_fn.txt,sha256=9zTCMVT1nvo-SCQMoNHfbyAgvQVvstLML4iuuddbYFQ,905 +alpaca_eval/evaluators_configs/alpaca_eval_gpt4_fn/configs.yaml,sha256=cG3P0JjF7HNf9jTXMpmXCtkU3JmdpLu4IhFHqtO-3c8,1135 +alpaca_eval/evaluators_configs/alpaca_farm/chatml_b1_chat_v0_without_inputs.txt,sha256=4VRVSzcJpnryc8yHTx3K3aK4WWFpwZzjKB0gBQMVP1o,1650 +alpaca_eval/evaluators_configs/alpaca_farm/chatml_b1_chat_without_inputs.txt,sha256=Cll_ks6pOhHARQ0yGxFssI4C_umPPJwUxCKv6aX0TRs,5869 +alpaca_eval/evaluators_configs/alpaca_farm/chatml_b1_cot_json_without_inputs.txt,sha256=yZ7au5tYkFdFCgOzbl8gfu8VzKKqK2LMOx2-9Oyxw-A,2475 +alpaca_eval/evaluators_configs/alpaca_farm/chatml_b1_without_inputs.txt,sha256=bQe5XEzsMFMBZXmD21NJwBcf5fhVpnXAm_plQyOonJ4,3721 +alpaca_eval/evaluators_configs/alpaca_farm/chatml_b4_cot_json_without_inputs.txt,sha256=VK2beVTCnIavX-q2i0lWZrAA8cLMI0Efa4P4oaoSHxk,3423 +alpaca_eval/evaluators_configs/alpaca_farm/chatml_b5_diana_without_inputs.txt,sha256=s9T1FPC3yxAexzb0a9SZOzg9444jzrKraYRvNzDSRV0,6849 +alpaca_eval/evaluators_configs/alpaca_farm/chatml_b5_joe_without_inputs.txt,sha256=q-s4owUh0sIGwIiCfyK0Xs8IyOwLS2eHukRyH47XFpM,6797 +alpaca_eval/evaluators_configs/alpaca_farm/chatml_b5_without_inputs.txt,sha256=6gfwH7o3IaZqaOW9bqglvn2HmUzGK7IkCEVreIfGKIc,6700 +alpaca_eval/evaluators_configs/alpaca_farm/configs.yaml,sha256=Dtrmj42kXO3wjeQn5M6rBuDJcS1nIg-eFQs1RC53UuM,6045 +alpaca_eval/evaluators_configs/alpaca_farm/text_b1_v0_without_inputs.txt,sha256=24FS2HDAuG5xEcloqKnUNqdXd_dNbdW4O2_2J3UpA8Y,1016 +alpaca_eval/evaluators_configs/alpaca_farm/text_b1_without_inputs.txt,sha256=IYW9P6ETBgN2F7Ik8qjEollpWTuu92KqORcSF5KuNac,3969 +alpaca_eval/evaluators_configs/alpaca_farm/text_b4_reasoning_without_inputs.txt,sha256=RyfwflTDqRso7HTUZJs_mV0eSyfC9ybMQdT_5SO0XUg,5932 +alpaca_eval/evaluators_configs/alpaca_farm/text_b5_without_inputs.txt,sha256=cv6mHjAODbT1v9eDjI3ToOFMdKmnuUGiDR2jXaiysnI,5370 +alpaca_eval/evaluators_configs/alpaca_farm_greedy_gpt4/chatml_b5_without_inputs.txt,sha256=dr3cjE02RI2kyIKHsqOWyMzp4bwvBBguBNHVKx-tH04,7373 +alpaca_eval/evaluators_configs/alpaca_farm_greedy_gpt4/configs.yaml,sha256=U4sd7U_DNeMAM6Tn5CQM1Jt9nAzzOqypizG7w05Aiww,362 +alpaca_eval/evaluators_configs/aviary_gpt4/aviary_prompt.txt,sha256=BL867OYK2tnxjR2T65kEOtFQLQShlhtC7py8TBUZd7o,1048 +alpaca_eval/evaluators_configs/aviary_gpt4/configs.yaml,sha256=qGy-Ry647x_8jTHD8mCu83zdunWkfMD_P7mnKtdUMQc,324 +alpaca_eval/evaluators_configs/chatgpt/basic_prompt.txt,sha256=rwQQTdGqV2oCmSi9jQWia4iLAR-7vjJ8Yt26ymh_UKU,1116 +alpaca_eval/evaluators_configs/chatgpt/configs.yaml,sha256=z5rMMY7ppnDBkmlKAs0AMaeXciM3t-BL122jxVTK3fk,325 +alpaca_eval/evaluators_configs/chatgpt_fn/basic_function_prompt.txt,sha256=35qjKHOV1dy5PwpQnBY69T1HgR_u_xlx057egWH5Jwk,1197 +alpaca_eval/evaluators_configs/chatgpt_fn/configs.yaml,sha256=u4jeWyEL3YMLmZVSWQHJSF34_UtnwdmS4dX7PHjdhqI,754 +alpaca_eval/evaluators_configs/claude/basic_prompt.txt,sha256=-eqQpv17cZMhcY4NVY2VcFMzyFzkrYrgtilyzzPQvco,1137 +alpaca_eval/evaluators_configs/claude/configs.yaml,sha256=BqutKu7q1JHh3BHVQ1JnZ1LL7-FSjvqxVweQpYAkHj8,327 +alpaca_eval/evaluators_configs/claude_2/configs.yaml,sha256=-2L4ago1fqYygvzfzOyILCqXMvFo6DL3iPYBfezVg04,328 +alpaca_eval/evaluators_configs/claude_ranking/configs.yaml,sha256=fKDNFyy7sfHmlO5kegVfs5RMWxRlCC_-kOiDy5NAXLs,269 +alpaca_eval/evaluators_configs/claude_ranking/ranking_prompt.txt,sha256=OfHk_hUfoJKhH6gJCDr99pzAZlBsR53Ds02vG-Z2a08,1087 +alpaca_eval/evaluators_configs/cohere/configs.yaml,sha256=RtW7RIX_2U5DSrrJ26ZUoTwaRR4li0paw9equb0JLn4,303 +alpaca_eval/evaluators_configs/gpt4/configs.yaml,sha256=3qG3NBGx2uHev1Skl9vcXf1-MC3GY8J8UeLEblESS1M,314 +alpaca_eval/evaluators_configs/guanaco_33b/basic_prompt.txt,sha256=xBgbTZlelyXRLn_Q2X3OLLE4lV_Pg7pq20gVxCVMDdA,1298 +alpaca_eval/evaluators_configs/guanaco_33b/configs.yaml,sha256=si-gfneuNq6FVkGuvETwSeREYTx3S2_3eBh6hSCF_EM,452 +alpaca_eval/evaluators_configs/improved_aviary_gpt4/configs.yaml,sha256=HYsADbFZ_2CWMIQH4RlC0t2KX_l3Ro3gTLgOASzvj2M,322 +alpaca_eval/evaluators_configs/improved_lmsys_gpt4/configs.yaml,sha256=imCB9vrHIJCu1SIHFlGvMS6SJlv6b_M3uqpEJU4Bpik,317 +alpaca_eval/evaluators_configs/lmsys_gpt4/configs.yaml,sha256=AImjL3flznl5i8EHC-OH1CPhnDSToRf0-X9pIZV1QPU,319 +alpaca_eval/evaluators_configs/lmsys_gpt4/lmsys_prompt.txt,sha256=-uJdKpGLh316NJdWlsW3BiTnvlbSVUhZbcJxKmHQRqo,1051 +alpaca_eval/evaluators_configs/oasst_pythia_12b/basic_prompt.txt,sha256=UaRuxfczwfI1keeluht1ZBMnnNRphTIghNkhz-M_Ysk,1054 +alpaca_eval/evaluators_configs/oasst_pythia_12b/configs.yaml,sha256=4bNuCEpLUwL1xR2eOR0udE81lRhcVK4zl6BVstlwNzs,367 +alpaca_eval/evaluators_configs/test/configs.yaml,sha256=UWUcEZBhPwkb7UfPV5T_e69rdNQS2rjDv_1ZefIKhnU,329 +alpaca_eval/evaluators_configs/text_davinci_003/basic_prompt.txt,sha256=lxxVEKg3FjfxeTuJ0QpFVsRSBw4gRXLzUU04xxyUMh0,1017 +alpaca_eval/evaluators_configs/text_davinci_003/configs.yaml,sha256=UWUcEZBhPwkb7UfPV5T_e69rdNQS2rjDv_1ZefIKhnU,329 +alpaca_eval/leaderboards/data_AlpacaEval/alpaca_eval_gpt4_leaderboard.csv,sha256=B1LHUu7P2cNoYH4GaCAYlpRWOwtz-dPabcR-MdHIHEU,3615 +alpaca_eval/leaderboards/data_AlpacaEval/chatgpt_fn_leaderboard.csv,sha256=KJij6-h4bFc04YaY-OO7JSwsd6MlP2pk_DAeH_Be478,969 +alpaca_eval/leaderboards/data_AlpacaEval/claude_leaderboard.csv,sha256=7bJPSJ1J85WZZ8v_g30gJ3rZBL0Ne5i4ySKkxQ6gt2Y,2553 +alpaca_eval/leaderboards/data_AlpacaEval/text_davinci_003_leaderboard.csv,sha256=L8DQ_8Xm02hC0Gq6b-6kQtfxqqRoUC7VseR012xx6hk,351 +alpaca_eval/leaderboards/evaluators/evaluators_leaderboard.csv,sha256=yKhB6F_AMyT5F7GjXQEzjOwwxpEMy5JzuuG4-IXvS0I,2929 +alpaca_eval/main.py,sha256=f6tp808qnPedLm4kj2jojmwjpJWaKgDYcxl9Oqx33Vg,21848 +alpaca_eval/metrics.py,sha256=KcLHfvIxS0l1TLNXZnJqlSZd_rRepreMPsjG8Z2nvRk,1313 +alpaca_eval/models_configs/airoboros-33b/configs.yaml,sha256=RojwP5mDycbxowDd_vDHCOMOKa8t_Lrv34J_bo1ywuM,415 +alpaca_eval/models_configs/airoboros-33b/prompt.txt,sha256=7Len5nRwR3rPmHWgtiRZ5pGavle5XaLP2t5IwRZw2yA,171 +alpaca_eval/models_configs/airoboros-65b/configs.yaml,sha256=wCbPdu0yWeBYnvASjWgtcbm5gpZF5XU0hM54W5su1UQ,415 +alpaca_eval/models_configs/alpaca-7b/configs.yaml,sha256=k2YoxKEb9zXxN7xSGn2GZmul8JSZprU2eLwiUnYXHmE,382 +alpaca_eval/models_configs/alpaca-7b/prompt.txt,sha256=NRAbw20QmXx9km2PIffRc67GUj86V9eIIblEqJklzco,152 +alpaca_eval/models_configs/alpaca-farm-ppo-human/configs.yaml,sha256=JEOapM_OWv44Fyxm-wdBb6C1cji4cBwpl_UtuZKn_4U,433 +alpaca_eval/models_configs/alpaca-farm-ppo-sim-gpt4-20k/configs.yaml,sha256=wy5ibYQ4_BVIv0LdE63g5jc_5pIWWLSRQfsQrpD1A2o,456 +alpaca_eval/models_configs/baichuan-13b-chat/configs.yaml,sha256=t0vri-V1HE_3GQT_K0O2N0zwGumeB2C_DjwXXYHsdkY,417 +alpaca_eval/models_configs/baichuan-13b-chat/prompt.txt,sha256=hHA7taxoeGgAGyIov2caoGgST53HR8WVmsffifuxL-k,29 +alpaca_eval/models_configs/baize-v2-13b/configs.yaml,sha256=TekFFvDsDLkCPhWKgCCEU7GyPW4xQKeq6bZJCt7QmD8,394 +alpaca_eval/models_configs/baize-v2-13b/prompt.txt,sha256=49cS93u95lriRC1ArUlWyqrkbNyDWqUiPi1FFI64udc,109 +alpaca_eval/models_configs/baize-v2-7b/configs.yaml,sha256=6OZB3JFwJr35Yni-ayydjuAKtdTypfI14cPyLDrdz64,390 +alpaca_eval/models_configs/chatglm2-6b/configs.yaml,sha256=uTLieoMKeYWgqMtZIXwoM3HYjWzroPV38D9IWwEjjhM,373 +alpaca_eval/models_configs/chatglm2-6b/prompt.txt,sha256=lvZkvjA8TZb9VpaJOlu0hYMTBVl_4MyTDUUGKVyqokY,43 +alpaca_eval/models_configs/chatgpt/configs.yaml,sha256=MWphKJ1H891W6n313S4UVTfMqjRPo6m3sogiBlQgqWg,196 +alpaca_eval/models_configs/claude-2/configs.yaml,sha256=1REqiOnKxysDbP_w_RzHTzTxnrUERj3kB_GAB1fJ60E,197 +alpaca_eval/models_configs/claude/configs.yaml,sha256=3EdnA1Acpt9E5Ztvbzk4E1ePdeTvUuJcfFvVYVFrm-c,194 +alpaca_eval/models_configs/claude/prompt.txt,sha256=PvC8O9ekfFdmoh0MAWzKtEJyLz7rmqu_BC50YGd1lyc,34 +alpaca_eval/models_configs/cohere-chat/configs.yaml,sha256=ODm5vy59TgTP24YmqTIovlwxGR3m-1V13-thcRtMwjk,205 +alpaca_eval/models_configs/cohere/configs.yaml,sha256=5O301d0otk_QjF3urKF6kryULlB-FGD4DJJGJFdKBzA,199 +alpaca_eval/models_configs/cohere/prompt.txt,sha256=9kTp7EdLbsJld0AetmPMdAyzo5UgyCYsuuEA30rI5JI,13 +alpaca_eval/models_configs/falcon-40b-instruct/configs.yaml,sha256=A1-g5lZKRaMv8sjy4Fa72HwmwqbfatUQr6ctc0OnvRM,435 +alpaca_eval/models_configs/falcon-7b-instruct/configs.yaml,sha256=bS9InlAGuY-4CWvrQF2GFrxwl7_1tROsdHBN3Ot_IBc,431 +alpaca_eval/models_configs/gpt4/chatml_prompt.txt,sha256=arTl2x29spY85yctvxTqcDP3mQfjubCeiTKw-cu1Gc0,100 +alpaca_eval/models_configs/gpt4/configs.yaml,sha256=M27CIEbl5ttgzp8skuSwcDbsAPsOU868LOiJu0dwg2E,178 +alpaca_eval/models_configs/guanaco-13b/configs.yaml,sha256=4cOqkCd5WObgxDxrylD7I7xB3-C8vvN2s9lJOa2tjA4,430 +alpaca_eval/models_configs/guanaco-33b/configs.yaml,sha256=HiuZonrB3iXe3jpQUQkSKeldhBq8PTAkXlw7W_SxMuU,430 +alpaca_eval/models_configs/guanaco-65b/configs.yaml,sha256=pMLykSK0hp6UoGM3w0YLtm9ofNUMgF4_ICbjqy2XbgU,430 +alpaca_eval/models_configs/guanaco-7b/configs.yaml,sha256=vxPzRaJaTkMwHxJiuFlnfiIJBcML3RH-rBvofgxzhPg,425 +alpaca_eval/models_configs/guanaco-7b/prompt.txt,sha256=APH_lUF2II27aqsmv9WPrqqJhUZrvHYJybO-XSXhp0k,195 +alpaca_eval/models_configs/llama-2-13b-chat-hf/configs.yaml,sha256=0ZLLZfAf_lMxsT4vX5tZ6VAXxGo4doo0fBKfct4_hTI,391 +alpaca_eval/models_configs/llama-2-70b-chat-hf-replicate-noprompt/configs.yaml,sha256=vvcLhtC_WQ1_2MvO3rxCFcoocYz1lzqfeCjkfm2UdBo,432 +alpaca_eval/models_configs/llama-2-70b-chat-hf-replicate-noprompt/prompt.txt,sha256=9kTp7EdLbsJld0AetmPMdAyzo5UgyCYsuuEA30rI5JI,13 +alpaca_eval/models_configs/llama-2-70b-chat-hf-replicate/configs.yaml,sha256=-iqGWHe36lPvNyrHmkYYfxn5un4orJQ0geZ0omQc15U,404 +alpaca_eval/models_configs/llama-2-70b-chat-hf-replicate/prompt.txt,sha256=1BgAxYOHvpMoSgD1YDjPm5yAFWZbRf_uRayAhDcMgb4,30 +alpaca_eval/models_configs/llama-2-70b-chat-hf/configs.yaml,sha256=WGoXZCBk55A1bGDC6MHpnf141iv-hc6fBb2JU5YVNuw,373 +alpaca_eval/models_configs/llama-2-7b-chat-hf/configs.yaml,sha256=0R6EYKLXJMQd074Fbm5ifJImdv4STo-V7C0FcRmtBo4,388 +alpaca_eval/models_configs/llama-2-7b-chat-hf/prompt.txt,sha256=JlUi3JsCiHISbsxcmAKY0YV81uoUOgs8rNsducw6ERc,558 +alpaca_eval/models_configs/minotaur-13b/configs.yaml,sha256=MEHthFt8AloykOkY0ppsX2ibhD6njYR_TAawJSKZqxs,429 +alpaca_eval/models_configs/minotaur-13b/prompt.txt,sha256=tqN6XNRzD9DhM5wEafFYCCI2mB1_6mEENWpCOUydprM,186 +alpaca_eval/models_configs/nous-hermes-13b/configs.yaml,sha256=pn7O29arABiT8TFUTthU8oO5Mh9nDg0r-eQZSXkPw1A,407 +alpaca_eval/models_configs/nous-hermes-13b/prompt.txt,sha256=xo9TqyfhIAGjoxRYOMyFxsIwZ1k2fq9lrnnjJ0LQRmk,185 +alpaca_eval/models_configs/oasst-rlhf-llama-33b/configs.yaml,sha256=RpVH_q0JKJne6E0GHsm1er1QFPaICkIOLzLfdaBkt4M,449 +alpaca_eval/models_configs/oasst-sft-llama-33b/configs.yaml,sha256=EihXA4LnHO656XnYZoptUyjLdD9dN45yI3mtIddV8aY,436 +alpaca_eval/models_configs/oasst-sft-llama-33b/prompt.txt,sha256=e4vHUbrNTKpS68p8sK0gBd2KpVRT9HFotvL8DCVQegk,42 +alpaca_eval/models_configs/oasst-sft-pythia-12b/configs.yaml,sha256=oC7UcXtTwldBbSA7-ZpUhRjaToCBTJCOulfd5DXIhcg,458 +alpaca_eval/models_configs/oasst-sft-pythia-12b/prompt.txt,sha256=uMUj-Kfo1PWb8Fj9PHwWb2ESSUL-_lxr-YbL5Z01eCA,51 +alpaca_eval/models_configs/openchat-13b/configs.yaml,sha256=EcTbsNKyLOs2q0DEKaxFyG8UwbIdnpz0JU4g28NczI8,374 +alpaca_eval/models_configs/openchat-13b/prompt.txt,sha256=vnQBS89qcthUFp5CacV-PZ4WsKYrNo8QeUtXU_glgbs,41 +alpaca_eval/models_configs/openchat-v2-13b/configs.yaml,sha256=tNPLMnlHrmzCyQ4_D3zYc9WIh90XFho9ujDVQl4WqKo,403 +alpaca_eval/models_configs/openchat-v2-w-13b/configs.yaml,sha256=qZ8qt-JRKgprfW9Ud8IgfHuxIs7P6_M9xHTsU4R128k,407 +alpaca_eval/models_configs/openchat8192-13b/configs.yaml,sha256=Ahc5nmsaVI5vobbgUNGEB773F1M4k16nPIlOj2QYH74,387 +alpaca_eval/models_configs/opencoderplus-15b/configs.yaml,sha256=WUfx-DUulUjpdcKiLl-ih1pOqMYAUk-e6va-__NXwMM,389 +alpaca_eval/models_configs/pythia-12b-mix-sft/configs.yaml,sha256=Sq2NY9tPJnS1kckOTVNoUgcG9FQwauNQrJp_FeNR69o,438 +alpaca_eval/models_configs/text_davinci_001/configs.yaml,sha256=fK3G_pxpeHbSD3WE0knIGGZgdxBo3k12EhYZysexXkQ,211 +alpaca_eval/models_configs/text_davinci_003/configs.yaml,sha256=nNY1SiewhsPBSHliZkRP91609s2sGHUsyOnk5CRv_Mc,211 +alpaca_eval/models_configs/text_davinci_003/prompt.txt,sha256=ItEGOBsJHb4frai68-HdKRxNQqTsFLwpuxkpIlAKBgU,34 +alpaca_eval/models_configs/ultralm-13b/configs.yaml,sha256=TIfJyJzBGgN2Bpreev2hRDcubPLMvmHtazSMBtwa6-g,401 +alpaca_eval/models_configs/ultralm-13b/prompt.txt,sha256=Sm-9tJ-a_a__SFOWvxTUdoPX9xzcoQ0Bmi7Q_VbO37A,271 +alpaca_eval/models_configs/vicuna-13b-v1.3/configs.yaml,sha256=CZq9E2298VCSs54tUvc-1lZPsoSeQuNC1xhUj1hTjgE,387 +alpaca_eval/models_configs/vicuna-13b/configs.yaml,sha256=8Hym23QJExR043vS1uH4iiXjNJarh0wYcEogcnD9UkI,387 +alpaca_eval/models_configs/vicuna-33b-v1.3/configs.yaml,sha256=d0bZ6b5TPRZEBFS1qWZoONghW9wNNxbasxvUnF7h1f4,387 +alpaca_eval/models_configs/vicuna-7b-v1.3/configs.yaml,sha256=UrmUKNcTIj3rzqS1Ht3lomsqX3_RLCJZjobaEe6hJA0,383 +alpaca_eval/models_configs/vicuna-7b/configs.yaml,sha256=3q2N5Vr09-0ImFh6Ux2IlUU8VU6U6UBu6McoikE2ZZ8,383 +alpaca_eval/models_configs/vicuna-7b/prompt.txt,sha256=xo9TqyfhIAGjoxRYOMyFxsIwZ1k2fq9lrnnjJ0LQRmk,185 +alpaca_eval/models_configs/wizardlm-13b-v1.1/configs.yaml,sha256=MfAQB3jv4-iQEkmxrUGi7gx6rL5XpSIcWiFcPhk0MIs,410 +alpaca_eval/models_configs/wizardlm-13b/configs.yaml,sha256=7cQAwmaRjSxhD80NfKFMtEhYZzsnwRT0XXbgeRNsvDA,394 +alpaca_eval/models_configs/wizardlm-13b/prompt.txt,sha256=xo9TqyfhIAGjoxRYOMyFxsIwZ1k2fq9lrnnjJ0LQRmk,185 +alpaca_eval/plotting.py,sha256=Szsn9WumQn4mcmDYiHDfjeCFaVvN37mpIv_FMULMJ8Q,20680 +alpaca_eval/processors.py,sha256=Gu5kfoZ0vx53JcEbq8n2RGXQbnn3_0w4GreA-e7PfYU,7900 +alpaca_eval/types.py,sha256=3fbYWKPYn6xMFPD80jqRMKdQuYWPONtmoV3yRwJK9wE,283 +alpaca_eval/utils.py,sha256=b6S5diOn3Lz2dLqUcr6Xk8UnKXbmAPucuTVwh9KS53Y,15351 diff --git a/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/REQUESTED b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/WHEEL b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..d272f6ed555bf206d2a9572524bfa3c0b500fe8d --- /dev/null +++ b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/WHEEL @@ -0,0 +1,5 @@ +Wheel-Version: 1.0 +Generator: bdist_wheel (0.41.0) +Root-Is-Purelib: true +Tag: py3-none-any + diff --git a/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/entry_points.txt b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/entry_points.txt new file mode 100644 index 0000000000000000000000000000000000000000..6eb74b5a6fcd166477330cf58aaa2e20cf91f250 --- /dev/null +++ b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/entry_points.txt @@ -0,0 +1,2 @@ +[console_scripts] +alpaca_eval = alpaca_eval.main:main diff --git a/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/top_level.txt b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/top_level.txt new file mode 100644 index 0000000000000000000000000000000000000000..2bc70b53ad2f6134bc79474407ff69d81eefe4f6 --- /dev/null +++ b/venv/lib/python3.10/site-packages/alpaca_eval-0.2.6.dist-info/top_level.txt @@ -0,0 +1 @@ +alpaca_eval diff --git a/venv/lib/python3.10/site-packages/apiclient/__init__.py b/venv/lib/python3.10/site-packages/apiclient/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..e7f205af3d768a6d700cbac62509e21d2b47cd63 --- /dev/null +++ b/venv/lib/python3.10/site-packages/apiclient/__init__.py @@ -0,0 +1,27 @@ +"""Retain apiclient as an alias for googleapiclient.""" + +from googleapiclient import channel, discovery, errors, http, mimeparse, model + +try: + from googleapiclient import sample_tools +except ImportError: + # Silently ignore, because the vast majority of consumers won't use it and + # it has deep dependence on oauth2client, an optional dependency. + sample_tools = None +from googleapiclient import schema + +_SUBMODULES = { + "channel": channel, + "discovery": discovery, + "errors": errors, + "http": http, + "mimeparse": mimeparse, + "model": model, + "sample_tools": sample_tools, + "schema": schema, +} + +import sys + +for module_name, module in _SUBMODULES.items(): + sys.modules["apiclient.%s" % module_name] = module diff --git a/venv/lib/python3.10/site-packages/apiclient/__pycache__/__init__.cpython-310.pyc b/venv/lib/python3.10/site-packages/apiclient/__pycache__/__init__.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..d01dab6771aa9b5e07978cf91281e06c10f0fe2a Binary files /dev/null and b/venv/lib/python3.10/site-packages/apiclient/__pycache__/__init__.cpython-310.pyc differ diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/ISSUE_TEMPLATE/bug_report.md b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 0000000000000000000000000000000000000000..8165ec95fcc0feb4e308b4f5decce9a646d5ccaf --- /dev/null +++ b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,23 @@ +--- +name: Bug report +about: Create a bug report to help us improve CUTLASS +title: "[BUG]" +labels: "? - Needs Triage, bug" +assignees: '' + +--- + +**Describe the bug** +A clear and concise description of what the bug is. + +**Steps/Code to reproduce bug** +Follow this guide http://matthewrocklin.com/blog/work/2018/02/28/minimal-bug-reports to craft a minimal bug report. This helps us reproduce the issue you're having and resolve the issue more quickly. + +**Expected behavior** +A clear and concise description of what you expected to happen. + +**Environment details (please complete the following information):** + - Environment location: [Bare-metal, Docker, Cloud(specify cloud provider)] + +**Additional context** +Add any other context about the problem here. diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/ISSUE_TEMPLATE/documentation_request.md b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/ISSUE_TEMPLATE/documentation_request.md new file mode 100644 index 0000000000000000000000000000000000000000..c9fa21fac936434d6b526de631879e6acd811fc0 --- /dev/null +++ b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/ISSUE_TEMPLATE/documentation_request.md @@ -0,0 +1,35 @@ +--- +name: Documentation request +about: Report incorrect or needed documentation to improve CUTLASS +title: "[DOC]" +labels: "? - Needs Triage, documentation" +assignees: '' + +--- + +## Report incorrect documentation + +**Location of incorrect documentation** +Provide links and line numbers if applicable. + +**Describe the problems or issues found in the documentation** +A clear and concise description of what you found to be incorrect. + +**Steps taken to verify documentation is incorrect** +List any steps you have taken: + +**Suggested fix for documentation** +Detail proposed changes to fix the documentation if you have any. + +--- + +## Report needed documentation + +**Report needed documentation** +A clear and concise description of what documentation you believe it is needed and why. + +**Describe the documentation you'd like** +A clear and concise description of what you want to happen. + +**Steps taken to search for needed documentation** +List any steps you have taken: diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/ISSUE_TEMPLATE/feature_request.md b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 0000000000000000000000000000000000000000..9ea8e6de070d7f3e9ae348670e311ff3014151b5 --- /dev/null +++ b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,20 @@ +--- +name: Feature request +about: Suggest an idea for CUTLASS +title: "[FEA]" +labels: "? - Needs Triage, feature request" +assignees: '' + +--- + +**Is your feature request related to a problem? Please describe.** +A clear and concise description of what the problem is. Ex. I wish I could use CUTLASS to do [...] + +**Describe the solution you'd like** +A clear and concise description of what you want to happen. + +**Describe alternatives you've considered** +A clear and concise description of any alternative solutions or features you've considered. + +**Additional context** +Add any other context, code examples, or references to existing implementations about the feature request here. diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/ISSUE_TEMPLATE/submit_question.md b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/ISSUE_TEMPLATE/submit_question.md new file mode 100644 index 0000000000000000000000000000000000000000..5aa2a672d2fcf1447665a4db010f8dd3fa21843a --- /dev/null +++ b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/ISSUE_TEMPLATE/submit_question.md @@ -0,0 +1,10 @@ +--- +name: Submit question +about: Ask a general question about CUTLASS +title: "[QST]" +labels: "? - Needs Triage, question" +assignees: '' + +--- + +**What is your question?** diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/workflows/labeler.yml b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/workflows/labeler.yml new file mode 100644 index 0000000000000000000000000000000000000000..23956a02fbdce28965ed47010d0441a12bea2b79 --- /dev/null +++ b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/workflows/labeler.yml @@ -0,0 +1,11 @@ +name: "Pull Request Labeler" +on: +- pull_request_target + +jobs: + triage: + runs-on: ubuntu-latest + steps: + - uses: actions/labeler@main + with: + repo-token: "${{ secrets.GITHUB_TOKEN }}" diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/workflows/new-issues-to-triage-projects.yml b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/workflows/new-issues-to-triage-projects.yml new file mode 100644 index 0000000000000000000000000000000000000000..a963cb2f89f268f2d3d7f8b661cbe0446debb2c8 --- /dev/null +++ b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/workflows/new-issues-to-triage-projects.yml @@ -0,0 +1,35 @@ +name: Auto Assign New Issues to Triage Project + +on: + issues: + types: [opened] + +env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + +jobs: + assign_one_project: + runs-on: ubuntu-latest + name: Assign to New Issues to Triage Project + steps: + - name: Process bug issues + uses: docker://takanabe/github-actions-automate-projects:v0.0.1 + if: contains(github.event.issue.labels.*.name, 'bug') && contains(github.event.issue.labels.*.name, '? - Needs Triage') + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITHUB_PROJECT_URL: https://github.com/NVIDIA/cutlass + GITHUB_PROJECT_COLUMN_NAME: 'Needs prioritizing' + - name: Process feature issues + uses: docker://takanabe/github-actions-automate-projects:v0.0.1 + if: contains(github.event.issue.labels.*.name, 'feature request') && contains(github.event.issue.labels.*.name, '? - Needs Triage') + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITHUB_PROJECT_URL: https://github.com/NVIDIA/cutlass + GITHUB_PROJECT_COLUMN_NAME: 'Needs prioritizing' + - name: Process other issues + uses: docker://takanabe/github-actions-automate-projects:v0.0.1 + if: contains(github.event.issue.labels.*.name, '? - Needs Triage') && (!contains(github.event.issue.labels.*.name, 'bug') && !contains(github.event.issue.labels.*.name, 'feature request')) + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITHUB_PROJECT_URL: https://github.com/NVIDIA/cutlass + GITHUB_PROJECT_COLUMN_NAME: 'Needs prioritizing' diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/workflows/stale.yml b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/workflows/stale.yml new file mode 100644 index 0000000000000000000000000000000000000000..8b65da69aa2f00bd0c8a67843e934a5f4141e593 --- /dev/null +++ b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.github/workflows/stale.yml @@ -0,0 +1,57 @@ +name: Mark inactive issues and pull requests + +on: + schedule: + - cron: "0 * * * *" + +jobs: + mark-inactive-30d: + runs-on: ubuntu-latest + steps: + - name: Mark 30 day inactive issues and pull requests + uses: actions/stale@v3 + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} + stale-issue-message: > + This issue has been labeled `inactive-30d` due to no recent activity in the past 30 days. + Please close this issue if no further response or action is needed. + Otherwise, please respond with a comment indicating any updates or changes to the original issue and/or confirm this issue still needs to be addressed. + This issue will be labeled `inactive-90d` if there is no activity in the next 60 days. + stale-issue-label: "inactive-30d" + exempt-issue-labels: "0 - Blocked,0 - Backlog,good first issue" + days-before-issue-stale: 30 + days-before-issue-close: -1 + stale-pr-message: > + This PR has been labeled `inactive-30d` due to no recent activity in the past 30 days. + Please close this PR if it is no longer required. + Otherwise, please respond with a comment indicating any updates. + This PR will be labeled `inactive-90d` if there is no activity in the next 60 days. + stale-pr-label: "inactive-30d" + exempt-pr-labels: "0 - Blocked,0 - Backlog,good first issue" + days-before-pr-stale: 30 + days-before-pr-close: -1 + operations-per-run: 50 + mark-inactive-90d: + runs-on: ubuntu-latest + steps: + - name: Mark 90 day inactive issues and pull requests + uses: actions/stale@v3 + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} + stale-issue-message: > + This issue has been labeled `inactive-90d` due to no recent activity in the past 90 days. + Please close this issue if no further response or action is needed. + Otherwise, please respond with a comment indicating any updates or changes to the original issue and/or confirm this issue still needs to be addressed. + stale-issue-label: "inactive-90d" + exempt-issue-labels: "0 - Blocked,0 - Backlog,good first issue" + days-before-issue-stale: 90 + days-before-issue-close: -1 + stale-pr-message: > + This PR has been labeled `inactive-90d` due to no recent activity in the past 90 days. + Please close this PR if it is no longer required. + Otherwise, please respond with a comment indicating any updates. + stale-pr-label: "inactive-90d" + exempt-pr-labels: "0 - Blocked,0 - Backlog,good first issue" + days-before-pr-stale: 90 + days-before-pr-close: -1 + operations-per-run: 50 diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.gitignore b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..1328f6b7d6ea9d137f9b77736eb3c499d104b2c2 --- /dev/null +++ b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.gitignore @@ -0,0 +1,2 @@ +# PyCache files +__pycache__/ diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.gitmodules b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/.gitmodules new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CHANGELOG.md b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CHANGELOG.md new file mode 100644 index 0000000000000000000000000000000000000000..7b4174f913b7f20dbaf73e5b1e8f8d5e3d6b7599 --- /dev/null +++ b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CHANGELOG.md @@ -0,0 +1,377 @@ +# NVIDIA CUTLASS Changelog + +## [3.2.2](https://github.com/NVIDIA/cutlass/releases/tag/v3.2.2) (2023-10-25) +* Fixes illegal memory access issue [1138](https://github.com/NVIDIA/cutlass/issues/1138) hit by FlashAttention tests in PyTorch. + +## [3.2.1](https://github.com/NVIDIA/cutlass/releases/tag/v3.2.1) (2023-09-22) +* Python support SM90 Epilogue Visitor Tree (EVT) on top of the C++ support released in 3.2.0. +* SM80 EVT support in C++ and Python. +* Other SM90 epilogue improvements. +* Splitting CUTLASS library into smaller units based on operation, arch and datatypes. See [1105](https://github.com/NVIDIA/cutlass/discussions/1105) for details. +* Making `tools/library/scripts` packageable - `tools/library/scripts` is now moving to `python/cutlass_library`. See the Python [README](/python/README.md) for details. +* SM90 TF32 kernel improvements for all layouts. +* SM90 rasterization direction support in the CUTLASS profiler. +* Improvement for CUTLASS profiler build times. +* Remove Python-C++ bindings. + +## [3.2.0](https://github.com/NVIDIA/cutlass/releases/tag/v3.2.0) (2023-08-03) + +* New warp-specialized persistent FP8 GEMM kernel [kernel schedules](/include/cutlass/gemm/kernel/sm90_gemm_tma_warpspecialized_cooperative.hpp) and [mainloops](/include/cutlass/gemm/collective/sm90_mma_tma_gmma_ss_warpspecialized_fp8.hpp) targeting Hopper architecture that achieve great performance with TMA, WGMMA, and threadblock clusters. An example showcasing [Hopper warp-specialized FP8 GEMMs](/examples/54_hopper_fp8_warp_specialized_gemm). FP8 GEMMs come with a fast accumulation mode. When enabled, problem execution might be faster but at the cost of lower accuracy because intermediate results will not periodically be promoted to a higher precision. +* New [Epilogue Visitor Tree (EVT)](/examples/49_hopper_gemm_with_collective_builder/49_collective_builder.cu) support for Hopper TMA epilogues. EVTs allows for user-defined customized epilogue fusion patterns without having to write a new epilogue. +* [Stream-K](/include/cutlass/gemm/kernel/sm90_tile_scheduler_stream_k.hpp) feature for Hopper. Note that this is only a functional implementation of stream-K, and should not be used for performance comparison. Optimizations are expected in a future release. +* Improved CTA rasterization and support for CTA swizzling for Hopper kernels using the [Tile Scheduler](/include/cutlass/gemm/kernel/sm90_tile_scheduler.hpp). +* Improved performance for [warp-specialized TensorFloat-32 (TF32) GEMM kernels](test/unit/gemm/device/sm90_gemm_tf32_tf32_f32_tensor_op_f32_gmma_rs_cluster_warpspecialized.cu) targeting Hopper TMA. +* [Hopper GEMM+Permute](/examples/53_hopper_gemm_permute/53_hopper_gemm_permute.cu), an example of fusing tensor reordering (permutation) with GEMM mainloop or epilogue. +* New CUTLASS 2D Convolution Python interface. New [example](/examples/python/03_basic_conv2d.ipynb) here. +* Support for Windows (MSVC) builds. Tested with Visual Studio 2019 v16.11.27 on Windows 10.0. +* Optimal performance using [**CUDA 12.2u1**](https://developer.nvidia.com/cuda-downloads) +* Updates and bugfixes from the community (thanks!) + +## [3.1.0](https://github.com/NVIDIA/cutlass/releases/tag/v3.1.0) (2023-04-14) +* New CUTLASS Python interface that aims to provide an ease-of-use interface for instantiating, emitting, compiling, and running CUTLASS kernels via Python. More details [here](/python/README.md) and new [examples](/examples/python). +* New [efficient epilogues](test/unit/gemm/device/sm90_gemm_f16_f16_f16_tensor_op_f32_cluster_warpspecialized_cooperative.cu#L783) using TMA for Hopper. +* Support for [fused epilogues](test/unit/gemm/device/sm90_gemm_f16_f16_f16_tensor_op_f32_cluster_warpspecialized_cooperative_bias_elementwise.cu), such Bias, ReLU and GELU, using the new efficient epilogues. +* New [warp-specialized TensorFloat-32 (TF32) GEMM kernels](test/unit/gemm/device/sm90_gemm_tf32_tf32_f32_tensor_op_f32_gmma_rs_cluster_warpspecialized.cu) targeting Hopper TMA. +* New [*warp-specialized persistent cooperative*](include/cutlass/gemm/kernel/sm90_gemm_tma_warpspecialized_cooperative.hpp) kernel design that allows for larger tile sizes and improves performance on Hopper. +* An [example](examples/51_hopper_gett) showcasing GEMM-Like Tensor-Tensor Contraction (GETT) capability on Hopper. +* Epilogue builders. Similar to mainloop builders (see [example 49](/examples/49_hopper_gemm_with_collective_builder/49_collective_builder.cu)), epilogue builders aim to generate the best-possible epilogue while exposing incremental opt-ins for greater customization. +* Profiler support for overriding kernel and epilogue builder auto schedules for 3.x API kernels, allowing specific policies to be run in the CUTLASS profiler. +* Performance optimizations for the [*warp-specialized persistent ping-pong*](include/cutlass/gemm/kernel/sm90_gemm_tma_warpspecialized_pingpong.hpp) kernel. +* Changes to the [GEMM API 3.x](media/docs/gemm_api_3x.md), involving the host-facing arguments and the underlying `Params` structs. +* [FMHA Backward Pass](examples/41_fused_multi_head_attention/fused_multi_head_attention_backward.cu) from Meta xFormers. +* [Streamk GEMM with Broadcast](examples/47_ampere_gemm_universal_streamk/ampere_gemm_universal_streamk_broadcast.cu) enables epilogue broadcast with StreamK GEMM. +* [Batched B2B GEMM](examples/13_two_tensor_op_fusion) now can run multiple Back-to-Back GEMM with the same problem size in parallel. +* [Batched Strided GEMV](test/unit/gemm/device/gemv.cu) support both row major and column major input matrix. +* [Permute + GEMM fusion](examples/39_gemm_permute) can fuse Permute with following GEMM now. Before, we only support fusing GEMM with Permute in the epilogue. +* [Row Broadcast](include/cutlass/epilogue/threadblock/predicated_tile_iterator_row_broadcast.h) can be fused in the epilogue. +* The GitHub branch is renamed from `master` to `main` in this release. +* Optimal performance using [**CUDA 12.1**](https://developer.nvidia.com/cuda-downloads) +* Updates and bugfixes from the community (thanks!) + +## [3.0.0](https://github.com/NVIDIA/cutlass/releases/tag/v3.0.0) (2023-01-23) +* [CuTe](/media/docs/cute/00_quickstart.md), a [new core library and backend](/include/cute) for CUTLASS 3.0 that defines a single Layout vocabulary type and an associated algebra of layouts for a much more expressive and composable abstraction for tensors, sets of parallel agents, and operations by said agents on tensors. +* [A new conceptual operation hierarchy](media/docs/cutlass_3x_design.md) that replaces the architecture-centric hierarchy of CUTLASS 2.x and [documentation for CUTLASS 3.0's GEMM API changes](/media/docs/gemm_api_3x.md). +* Strict API backwards compatibility that exposes both 2.x and 3.x API kernels through the same [`device::GemmUniversalAdapter`](include/cutlass/gemm/device/gemm_universal_adapter.h) and [`kernel::GemmUniversal`](include/cutlass/gemm/kernel/gemm_universal.hpp) types, allowing users to include both APIs in the same translation units. More information can be found in the [3.x backwards compatibility section](media/docs/cutlass_3x_backwards_compatibility.md). +* Updates to [Functionality](media/docs/functionality.md) which directs users on which kernels are supported via CUTLASS-2 and CUTLASS-3. +* Updates to [Compatibility](/README.md#compatibility) Section regarding supported compilers, operating systems, CUDA Toolkits, Hardware Architectures and [Target Architecture](/README.md#Target-Architecture). +* New warp-specialized GEMM [kernel schedules](include/cutlass/gemm/kernel/sm90_gemm_tma_warpspecialized.hpp) and [mainloops](include/cutlass/gemm/collective/sm90_mma_tma_gmma_ss_warpspecialized.hpp) targeting Hopper architecture that achieve great performance with TMA, WGMMA, and threadblock clusters. +* Extensions to CUTLASS profiler to support threadblock cluster shapes in library and profiler tile configurations. +* [CUTLASS library integration](/tools/library/src/gemm_operation_3x.hpp) for 3.x API kernels built through the new `CollectiveBuilder` API, enabling CUTLASS profiler. +* Support for [Hopper GEMMs](examples/48_hopper_warp_specialized_gemm) through the new 3.0 API with CuTe-based exposure of the Hopper [Tensor Memory Accelerator](https://docs.nvidia.com/cuda/parallel-thread-execution/index.html#data-movement-and-conversion-instructions-cp-async-bulk-tensor) and [WGMMA Tensor Core](https://docs.nvidia.com/cuda/parallel-thread-execution/index.html#asynchronous-warpgroup-level-matrix-instructions) features. +* Set of examples that demonstrate the usage of the new 3.0 API to easily build GEMM kernels targeting Hopper: examples [48](examples/48_hopper_warp_specialized_gemm), [49](examples/49_hopper_gemm_schedules_with_collective_builder), and [50](examples/50_hopper_gemm_with_epilogue_swizzle). + +## [2.11.0](https://github.com/NVIDIA/cutlass/releases/tag/v2.11.0) (2022-11-19) +* [Stream-K](/examples/47_ampere_gemm_universal_streamk), which is a new general way to do split-K. It can not only improve performance, but can also significantly reduce the number of tile sizes that need to be profiled to find the best one. +* [Fused multi-head attention Kernel](/examples/41_fused_multi_head_attention). It has two variants: one uses batched GEMM for the fixed sequence length, and the other one uses group GEMM for the variable sequence length. Both versions just need one kernel. +* [Dual GEMM](/examples/45_dual_gemm), which can fuse A x B and A x C into one kernel. Two GEMMs has no producer-consumer dependency. +* Hopper improves [double precision matrix multiplication](/test/unit/gemm/device/gemm_f64n_f64t_f64t_tensor_op_f64_sm90.cu) by 2x compared to Ampere at iso-clocks. It is supported since CUDA 11.8. +* [BLAS3](/test/unit/gemm/device/hemm_cf64_cf64_cf64_tensor_op_f64_sm90.cu) functions with Hoppers new double precision matrix multiplication instructions. +* [ELL Block Sparse GEMM](/examples/43_ell_block_sparse_gemm), which uses an [ELL matrix](https://developer.nvidia.com/blog/accelerating-matrix-multiplication-with-block-sparse-format-and-nvidia-tensor-cores/) to describe the sparsity of A matrix. B and output matrices are still dense. The block size can be arbitary. +* Optimized [Group Conv](/examples/42_ampere_tensorop_group_conv) for SingleGroup mode, which requires that the output channel per group is a multiple of Threadblock tile N. +* [Optimized DepthWise Conv](/examples/46_depthwise_simt_conv2dfprop/depthwise_simt_conv2dfprop.cu). Two new modes are added + * [kOptimized](/test/unit/conv/device/depthwise_conv2d_fprop_direct_conv_f16nhwc_f16nhwc_f16nhwc_simt_f16_sm60.cu) - use direct conv to compute instead of implicit GEMM. + * The restrictions are: 1) input ,output channel and group number should be multiple of (128 / sizeof(input element)). 2) The input filter size should be the same as the template parameter configuration. + * [kFixedStrideDilation](/test/unit/conv/device/depthwise_conv2d_fprop_direct_conv_fixed_stride_dilation_f16nhwc_f16nhwc_f16nhwc_simt_f16_sm60.cu) - which puts stride and dilation into templates to further improve the performance. In this mode, kernel persistents some inputs into register to squeeze more performance, so large filter/stride/dilation is not recommanded. + * The restrictions are: 1) input, output channel and group number should be multiple of (128 / sizeof(input element)). 2) input filter size, stride, dilation should same as the template parameter configuration. +* [Scripts](/examples/44_multi_gemm_ir_and_codegen) to fuse multiple back-to-back GEMM. Its implementation was discussed in a GTC'22 Spring [talk](https://www.nvidia.com/en-us/on-demand/session/gtcspring22-s41606/). +* [FP8 data type definition](/include/cutlass/float8.h) and [conversion routines](/include/cutlass/numeric_conversion.h#L1274-2115). +* Updates and bugfixes from the community (thanks!). Big shout out to Meta's [xFormers](https://github.com/facebookresearch/xformers). + +* **Deprecation announcement:** CUTLASS plans to deprecate the following: + * Maxwell and Pascal GPU architectures + * Ubuntu 16.04 + * CUDA 10.2 + +## [2.10.0](https://github.com/NVIDIA/cutlass/releases/tag/v2.10.0) (2022-08-23) +* [CUTLASS Python](/examples/40_cutlass_py) now supports GEMM, CONV, Group GEMM for different data types as well as different epilogue flavours. +* Optimizations for CUTLASS's [Grouped GEMM](examples/24_gemm_grouped/gemm_grouped.cu) kernel. Threadblock scheduling part is improved. Some computation can be moved to the host side if applicable. [Grouped Syr2k](examples/38_syr2k_grouped/syr2k_grouped.cu) kernels are added, too. +* Optimizations for [GEMM+Softmax](examples/35_gemm_softmax). All the reduction computation is fused into the previous GEMM. More template arguments are provided to fine tune the performance. +* [Grouped GEMM for Multihead Attention](examples/41_multi_head_attention). This general group gemm based MHA does not require the sequence length of all GEMMs to be the same which makes it most useful for natural language processing. +* [GEMM + Layer norm fusion for Ampere](examples/37_gemm_layernorm_gemm_fusion/) splits the layernorm into two parts and both of them can be fused into the GEMMs before and after separately. In addition to use square sum to compute variance of layernorm, [Shift-K](https://en.wikipedia.org/wiki/Algorithms_for_calculating_variance#Computing_shifted_data) is provided if square sum raise numerical issues. +* [GEMM Epilogue Permutation Fusion](examples/39_gemm_permute) can apply user provided permutation layout mapping in the GEMM epilogue. +* [Grouped convolution targeting implicit GEMM](test/unit/conv/device/group_conv2d_fprop_implicit_gemm_f16nhwc_f16nhwc_f16nhwc_tensor_op_f32_sm80.cu) introduces the first group convolution implementation to CUTLASS. It is an Analytical implementation, not an Optimized. The restrictions are: 1) input and output channel number should be multiple of group number. 2) split-K is not supported. The implementation has 2 modes: + * kSingleGroup: output channel per group is multiple of Threadblock tile N. + * kMultipleGroup: Threadblock tile N is multiple of output channel per group. +* [Depthwise separable convolution](test/unit/conv/device/depthwise_fprop_implicit_gemm_f16nhwc_f16nhwc_f16nhwc_simt_f16_sm60.cu) introduces the first depthwise convolution which is also Analytical for now. The restrictions are: 1) SIMT only 2) No split-K 3) input channel equals to output channel equals to group number. +* Standalone [Layernorm](/tools/util/include/cutlass/util/device_layernorm.h) and [Pooling](/tools/util/include/cutlass/util/device_nhwc_pooling.h) kernels. +* [Back-to-back GEMM/CONV](examples/13_two_tensor_op_fusion) relaxes the requirement that the first GEMM K dimension needs to be the multiple of Threadblock Tile K dimension. +* Optimal performance using [**CUDA 11.6u2**](https://developer.nvidia.com/cuda-downloads) +* Updates and bugfixes from the community (thanks!) + +## [2.9.0](https://github.com/NVIDIA/cutlass/releases/tag/v2.9.0) (2022-04-21) + +* [First layer Convolution kernels](/test/unit/conv/device/conv2d_fprop_fixed_channels_f16nhwc_f16nhwc_f16nhwc_tensor_op_f32_sm80.cu) specialized for small channel counts and reduced alignment + * [Few channels](/include/cutlass/conv/threadblock/conv2d_fprop_activation_tile_access_iterator_few_channels.h) specialization for reduced alignment capabilities + * [Fixed channels](/include/cutlass/conv/threadblock/conv2d_fprop_activation_tile_access_iterator_fixed_channels.h) further specialized when channel count perfectly matches the access vector size + * [Unit tests](/test/unit/conv/device/conv2d_fprop_few_channels_f16nhwc_f16nhwc_f16nhwc_tensor_op_f32_sm80.cu) + * [Python-based instance emitter](/python/cutlass_library/generator.py) in the CUTLASS Library and support in the Profiler +* [BLAS3](https://docs.nvidia.com/cuda/cublas/index.html#cublas-level-3-function-reference) operators accelerated by Tensor Cores + * Supported types: f32, cf32, f64, cf64, tf32x3, complex tf32x3 + * [HERK](/test/unit/gemm/device/her2k_cf32h_cf32n_tensor_op_fast_f32_sm80.cu) with [emitter](/tools/library/scripts/rank_k_operation.py) + * [SYRK](/test/unit/gemm/device/syrk_f32n_f32t_tensor_op_fast_f32_sm80.cu) with [emitter](/tools/library/scripts/rank_k_operation.py) + * [SYMM](/test/unit/gemm/device/symm_f32n_f32n_tensor_op_fast_f32_ls_sm80.cu) with [emitter](/tools/library/scripts/symm_operation.py) + * [TRMM](/test/unit/gemm/device/trmm_f32n_f32t_f32t_tensor_op_fast_f32_ls_sm80.cu) with [emitter](/tools/library/scripts/trmm_operation.py) + * [Unit tests](/test/unit/gemm/device/testbed_rank_k_universal.h) +* [CUTLASS Python](/examples/40_cutlass_py) demonstrating JIT compilation of CUTLASS kernels and a Python-based runtime using [CUDA Python](https://developer.nvidia.com/cuda-python) + * [Python-based runtime](/tools/library/scripts/rt.py) interoperable with existing emitters +* [GEMM + Softmax example](/examples/35_gemm_softmax) +* [Gather and Scatter Fusion with GEMM](/examples/36_gather_scatter_fusion) can gather inputs and scatters outputs based on indices vectors in the same GEMM kernel. + * It can select random rows in a row major matrix. + * It can select random columns in a column major matrix. +* [Back-to-back GEMM/CONV](examples/13_two_tensor_op_fusion) fully supports buffering the first GEMM/CONV results in the shared memory for the latter one to use. It can eliminate register spill when the tile size is big. Additionally, bias vector add is supported in the first GEMM/CONV. + * Supported kernels: GEMM and CONV. + * Supported types: fp16 and int8. + * Supported architectures: Turing and Ampere. +* [Transposed Convolution](/examples/34_transposed_conv2d) (a.k.a Deconvolution) support which reuses Dgrad implementation. +* [Utility functions](/tools/util/include/cutlass/util) that can pad NHWC and convert between NCHW and NHWC. +* [Small alignment implicit gemm](https://github.com/NVIDIA/cutlass/issues/242) support for Fprop/Dgrad/Wgrad so that padding is no longer mandated to use tensor cores in these kernels. +* Epilogue enhancement: + * Eliminate bank conflicts in int8 tensor core kernels. + * Half2 usage if epilogue compute type is fp16. + * More activation functions: Silu, Hardswish, Leaky Relu. + * New elementwise fusion pattern for [residual block](/include/cutlass/epilogue/thread/linear_combination_residual_block.h). +* [Group GEMM](/examples/24_gemm_grouped) thread block number calculation fix which helps to launch the intended number of threadblocks to fully occupy the GPUs. +* [Parallel GEMM splitk](https://github.com/NVIDIA/cutlass/pull/277) support in the CUTLASS profiler. +* Optimal performance using [**CUDA 11.6u2**](https://developer.nvidia.com/cuda-downloads) +* Updates and bugfixes from the community (thanks!) + + +## [2.8.0](https://github.com/NVIDIA/cutlass/releases/tag/v2.8.0) (2021-11-19) + +* **TF32x3:** emulated single-precision using Tensor Cores + * 45+ TFLOPs on NVIDIA A100 + * [GEMM SDK example](/examples/27_ampere_3xtf32_fast_accurate_tensorop_gemm/27_ampere_3xtf32_fast_accurate_tensorop_gemm.cu) (real) + * [COMPLEX GEMM SDK example](/examples/29_ampere_3xtf32_fast_accurate_tensorop_complex_gemm/29_ampere_3xtf32_fast_accurate_tensorop_complex_gemm.cu) (complex) + * [Implicit GEMM Convolution SDK example](/examples/28_ampere_3xtf32_fast_accurate_tensorop_fprop/ampere_3xtf32_fast_accurate_tensorop_fprop.cu) +* **Mainloop fusion for Convolution:** convolution with fused per-channel scale-bias-relu + * [Conv Fprop SDK example](/examples/25_ampere_fprop_mainloop_fusion/ampere_fprop_mainloop_fusion.cu) + * [Conv WGrad SDK example](/examples/26_ampere_wgrad_mainloop_fusion/ampere_wgrad_mainloop_fusion.cu) + * [cutlass::conv::device::ImplicitGemmConvolutionFusion](/include/cutlass/conv/device/implicit_gemm_convolution_fusion.h) +* **Grouped GEMM:** similar to batched GEMM with distinct problem size per group + * [SDK example](/examples/24_gemm_grouped) with performance comparison with Batched Strided GEMM + * [cutlass::gemm::device::GemmGrouped](/include/cutlass/gemm/device/gemm_grouped.h) +* [Implicit GEMM Convolution fusion](/examples/13_two_tensor_op_fusion/) supports staging 1st convolution's output accumulator in the shared memory on Turing. This allows more flexible warp tile sizes and less regsiter pressue. +* Optimal performance using [**CUDA 11.5**](https://developer.nvidia.com/cuda-downloads) +* Updates from the community (thanks!) + +* **Deprecation announcement:** CUTLASS plans to deprecate the following: + * Maxwell and Pascal GPU architectures + * Ubuntu 16.04 + * CUDA 10.2 + +## [2.7.0](https://github.com/NVIDIA/cutlass/releases/tag/v2.7.0) (2021-09-24) + * Mainloop fusion for GEMM: [summation over A or B](/examples/23_ampere_gemm_operand_reduction_fusion/ampere_gemm_operand_reduction_fusion.cu) + * [Strided DGRAD (optimized iterators)](/include/cutlass/conv/kernel/default_conv2d_dgrad.h) + * [Half-precision GELU_taylor activation functions](/include/cutlass/epilogue/thread/activation.h#L196) + * Use these when accumulation and epilogue compute types are all `cutlass::half_t` + * Tuning and bug fixes to [fused GEMM + GEMM example](/examples/13_two_tensor_op_fusion/) + * Support for smaller than 128b aligned Convolutions: [see examples](test/unit/conv/device/conv2d_fprop_implicit_gemm_f16nhwc_f16nhwc_f16nhwc_tensor_op_f16_sm80.cu#L272) + * Caching of results to accelerate Convolution [unit tests](test/unit/conv/device/cache_testbed_output.h) + * Can be enabled or disabled by running `cmake .. -DCUTLASS_TEST_ENABLE_CACHED_RESULTS=OFF` + * Corrections and bug fixes reported by the CUTLASS community + * Thank you for filing these issues! + +## [2.6.1](https://github.com/NVIDIA/cutlass/releases/tag/v2.6.1) (2021-09-03) + * Arbitrary padding and striding for CUTLASS Strided DGRAD Convolution operator (Analytic Iterators) + * Tuning for GEMMs fused with partial reductions + * Corrections and bug fixes reported by the CUTLASS community + * Thank you for filing these issues! + +## [2.6.0](https://github.com/NVIDIA/cutlass/releases/tag/v2.6.0) (2021-07-22) + * Optimal performance when compiled with the [CUDA 11.4 Toolkit](https://developer.nvidia.com/cuda-toolkit) + * Adopt the new L2 prefetch feature in [cp.async](/include/cutlass/arch/memory.h) and [global load](/include/cutlass/arch/memory_sm80.h) + * Fused operators with GEMM and Convolution + * [Fused broadcast in epilogue](test/unit/gemm/device/gemm_with_broadcast_f16n_f16n_f16n_tensorop_f32_sm75.cu) + * [Fused partial reduction in epilogue](/test/unit/gemm/device/gemm_with_reduction_f16n_f16n_f16n_tensorop_f32_sm75.cu) + * 64b tensor strides and leading dimensions support for GEMMs + * Affine rank=2 matrix layouts + * Row stride and column stride for matrices using [cutlass::layout::AffineRank2](/include/cutlass/layout/matrix.h) + * Support [FP64 tensor core](/examples/18_ampere_fp64_tensorop_affine2_gemm/ampere_fp64_tensorop_affine2_gemm.cu) and SIMT GEMM. + * [Batched GEMV](/test/unit/gemm/device/gemv.cu) preview implementation + * [New strided Dgrad](test/unit/conv/device/conv2d_strided_dgrad_implicit_gemm_f16nhwc_f16nhwc_f32nhwc_tensor_op_f32_sm80.cu) implementation + * Accelerates over previous implementation by cutting down redundant math by 4x + * Support using new `Dy` and `w` analytic iterators and existing `cutlass::conv::device::ImplicitGemmConvolution` interface + * Quaternion-valued GEMM and Convolution in single- and double-precision (targeting CUDA Cores) + * Updates to [quaternion.h](/include/cutlass/quaternion.h) and [functional.h](/include/cutlass/functional.h) + * SDK Example for [GEMM](/examples/21_quaternion_gemm/quaternion_gemm.cu) and [Convolution](/examples/22_quaternion_gemm/quaternion_conv.cu) + * [Unit tests for GEMM](/test/unit/gemm/device/simt_qgemm_nn_sm50.cu) and [Convolution](/test/unit/conv/device/conv2d_fprop_implicit_gemm_qf32nhwc_qf32nhwc_qf32nhwc_simt_f32_sm50.cu) + * Many improvements to the epilogue. + * Provide an [option](/include/cutlass/epilogue/threadblock/epilogue.h) to not fully unroll the epilogue to reduce the code size and improve the performance when using complicated elementwise operations + * Performance improvement for FP16 tensor core kernels + * Bug fixes + * Enhanced Clang support and the combination of Clang 13 and CUDA 11.4 can build and run kernels from Pascal and Ampere. + * Updated minimum CUDA Toolkit requirement to 10.2 + * [CUDA 11.4 Toolkit](https://developer.nvidia.com/cuda-toolkit) recommended + * Corrections and bug fixes reported by the CUTLASS community + * Thank you for filing these issues! + +## [2.5.0](https://github.com/NVIDIA/cutlass/releases/tag/v2.5.0) (2021-02-26) + * Tensor reductions + * _m_-to-_n_ reductions of tensors with affine layout + * [Specializations](/test/unit/reduction/device/tensor_reduce_contiguous.cu) for reductions including contiguous dimension + * [Specializations](/test/unit/reduction/device/tensor_reduce_strided.cu) for reductions excluding contiguous dimension + * Custom reduction functors such as `cutlass::logical_and` + * Large tensor support, up to 2^63 elements (however, each dimension is limited to an extent of 2^31) + * Optimizations for 3-D convolution + * [Optimized tile iterators](include/cutlass/conv/threadblock/conv3d_fprop_activation_tile_access_iterator_optimized.h) using precomputed delta table for 3-D convolution + * Full coverage of [forward](test/unit/conv/device/conv3d_fprop_implicit_gemm_f16ndhwc_f16ndhwc_f32ndhwc_tensor_op_f32_sm80.cu) and [backwards](test/unit/conv/device/conv3d_dgrad_implicit_gemm_f16ndhwc_f16ndhwc_f32ndhwc_tensor_op_f32_sm80.cu) passes for 3D convolution + * [Fused Convolution+Convolution example](/examples/13_two_tensor_op_fusion/README.md) + * Corrections and bug fixes reported by the CUTLASS community + * Thank you for filing these issues! + + +## [2.4.0](https://github.com/NVIDIA/cutlass/releases/tag/v2.4.0) (2020-11-19) + * Implicit GEMM convolution kernels supporting CUDA and Tensor Cores on NVIDIA GPUs + * Operators: forward (Fprop), backward data gradient (Dgrad), and backward weight gradient (Wgrad) convolution + * Data type: FP32, complex, Tensor Float 32 (TF32), BFloat16 (BF16), Float16, Int4, Int8, Int32 + * Spatial dimensions: 1-D, 2-D, and 3-D + * Layout: NHWC, NCxHWx + * Implicit GEMM convolution components: + * Global memory iterators supporting Fprop, Dgrad, and Wgrad + * `MmaMultistage` for implicit GEMM convolution for NVIDIA Ampere architecture + * `MmaPipeline` for implicit GEMM convolution for NVIDIA Volta and Turing architectures + * [Documentation](/media/docs/implicit_gemm_convolution.md) describing Implicit GEMM Convolution algorithm and implementation + +## [2.3.0](https://github.com/NVIDIA/cutlass/releases/tag/v2.3.0) (2020-09-23) + * [NVIDIA Ampere Architecture features](https://devblogs.nvidia.com/nvidia-ampere-architecture-in-depth/) + * [Sparse Tensor Core GEMM kernels](test/unit/gemm/device/gemm_f16n_f16n_f32t_tensor_op_f32_sparse_sm80.cu): + * Direct access to Sparse Tensor Cores and maximum performance via [`mma.sp.sync`](https://docs.nvidia.com/cuda/parallel-thread-execution/index.html#warp-level-matrix-instructions-mma-and-friends) + * Fast SGEMM targeting GeForce RTX 30-series CUDA Cores + * Minor Features: + * [Activation functions](/include/cutlass/epilogue/thread/activation.h) such as [GeLU](/include/cutlass/epilogue/thread/linear_combination_gelu.h) and [Sigmoid](/include/cutlass/epilogue/thread/linear_combination_sigmoid.h) + * Small [matrix](/include/cutlass/matrix.h) and [quaternion](/include/cutlass/quaternion.h) template classes in device code + * [Floating-point constants](/include/cutlass/constants.h) + * NVIDIA Ampere GPU Architecture examples and documentation: + * [Tensor Float 32](/examples/14_ampere_tf32_tensorop_gemm/ampere_tf32_tensorop_gemm.cu) and + * [Sparse Tensor Cores](/examples/15_ampere_sparse_tensorop_gemm/ampere_sparse_tensorop_gemm.cu) + * Documentation added on CUTLASS [efficient row-major epilogue](/media/docs/gemm_api.md#efficient-epilogue) + +## [2.2.0](https://github.com/NVIDIA/cutlass/releases/tag/v2.2.0) (2020-06-08) + * [NVIDIA Ampere Architecture features](https://devblogs.nvidia.com/nvidia-ampere-architecture-in-depth/) + * Fast Tensor Core operations: + * Maximum performance via [`mma.sync`](https://docs.nvidia.com/cuda/parallel-thread-execution/index.html#warp-level-matrix-instructions-mma-and-friends) + * Tensor Float 32, BFloat16, and double-precision data types + * Mixed integer data types (int8, int4, bin1) + * Asynchronous copy for deep software pipelines via [`cp.async`](https://docs.nvidia.com/cuda/parallel-thread-execution) + * Described in [GTC 2020 Webinar (SR 21745)](https://developer.nvidia.com/gtc/2020/video/s21745) (free registration required) + * Features: + * SDK examples showing GEMM fused with bias+relu and fused GEMM+GEMM + * Complex-valued GEMMs targeting NVIDIA Ampere Tensor Cores in double-precision and Tensor Float 32 + * Gaussian complex GEMMs using 3m complex multiply algorithm + * Universal GEMM kernel supporting two batch modes and two algorithms for parallel reductions + * Policy updates: + * [CUDA 11 Toolkit](https://developer.nvidia.com/cuda-toolkit) needed to enable NVIDIA Ampere Architecture features + * Disabled F16C by default for compatibility - enable on cmake command line with `-DCUTLASS_ENABLE_F16C=ON` + +## [2.1.0](https://github.com/NVIDIA/cutlass/releases/tag/v2.1.0) (2020-04-06) + * BLAS-style host-side API added to [CUTLASS Library](/media/docs/quickstart.md#cutlass-library) + * API to launch compiled kernel instances for GEMM and planar complex GEMM + * Planar Complex GEMM kernels targeting Volta and Turing Tensor Cores + * Computes complex matrix products on matrices stored as disjoint real and imaginary parts + * [SDK Examples of Planar Complex GEMMs](/examples/10_planar_complex/planar_complex.cu) + * Minor enhancements and bug fixes + +## [2.0.0](https://github.com/NVIDIA/cutlass/releases/tag/v2.0.0) (2019-11-19) + * Substantially refactored for + * Better performance, particularly for native Turing Tensor Cores + * Robust and durable templates spanning the design space + * Encapsulated functionality embodying modern C++11 programming techniques + * Optimized containers and data types for efficient, generic, portable device code + * Updates to: + * [Quick start guide](/media/docs/quickstart.md) + * [Documentation](/README.md#documentation) + * [Utilities](/media/docs/utilities.md) + * [CUTLASS Profiler](/media/docs/profiler.md) + * Native Turing Tensor Cores + * Efficient GEMM kernels targeting Turing Tensor Cores + * Mixed-precision floating point, 8-bit integer, 4-bit integer, and binarized operands + * Coverage of existing CUTLASS functionality + * GEMM kernels targeting CUDA and Tensor Cores in NVIDIA GPUs + * Volta Tensor Cores through native mma.sync and through WMMA API + * Optimizations such as parallel reductions, threadblock rasterization, and intra-threadblock reductions + * Batched GEMM operations + * Complex-valued GEMMs + * **Note: a host compiler supporting C++11 or greater is required.** + +# CUTLASS 1.x + +## [1.3.2](https://github.com/NVIDIA/cutlass/releases/tag/v1.3.2) (2019-07-09) + * Performance improvement for Volta Tensor Cores TN and TT layouts. + +## [1.3.1](https://github.com/NVIDIA/cutlass/releases/tag/v1.3.1) (2019-04-09) + * Corrected NVRTC unit tests. + +## [1.3.0](https://github.com/NVIDIA/cutlass/releases/tag/v1.3.0) (2019-03-20) + * Efficient GEMM kernel targeting Volta Tensor Cores via `mma.sync` instruction added in CUDA 10.1. + +## [1.2.0](https://github.com/NVIDIA/cutlass/releases/tag/v1.2.0) (2018-10-26) + * Parallelized reductions across threadblocks ("Split-K") + * Improved IGEMM performance + * Batched strided WMMA GEMMs + +## [1.1.0](https://github.com/NVIDIA/cutlass/releases/tag/v1.1.0) (2018-09-19) + * Turing Features + * WMMA GEMM targeting TensorCores - INT8, INT4, 1-bit + * Batched Strided GEMM + * Threadblock rasterization strategies + * Improved performance for adverse problem sizes and data layouts + * Extended CUTLASS Core comonents + * Tensor views support arbitrary matrix and tensor layouts + * Zip iterators for structuring multiple data streams + * Enhanced CUTLASS utilities + * Reference code for tensor operations in host and device code + * Added HostMatrix<> for simplified matrix creation + * Examples + * Basic GEMM, tensor views, CUTLASS utilities, batched GEMM, WMMA GEMM + +## [1.0.1](https://github.com/NVIDIA/cutlass/releases/tag/v1.0.1) (2018-06-11) + + * Intra-threadblock reduction added for small threadblock tile sizes + * sgemm_64x128x16, sgemm_128x128x16, sgemm_128x64x16, sgemm_128x32x16, sgemm_64x64x16, sgemm_64x32x16 + * igemm_32x32x128 + * GEMM _K_ residue handled during prologue prior to mainloop + * Replaced Google Test copy with submodule. Use `git submodule init --recursive --update` + +## [1.0.0](https://github.com/NVIDIA/cutlass/commit/2028ebe120aab22bfd0b2baf8902d4c9627eb33f) (2018-05-16) + + * Substantial rewrite to accommodate new architecture + * Kernels: SGEMM, DGEMM, IGEMM, HGEMM, WMMA GEMM + * Unit and performance tests + +## [0.0.1](https://github.com/NVIDIA/cutlass/commit/d08ba8ac46e2fa3f745e070c390182edb56b2e91) (2017-12-04) + + * Initial release + + +## Copyright + +Copyright (c) 2017 - 2023 NVIDIA CORPORATION & AFFILIATES. All rights reserved. +SPDX-License-Identifier: BSD-3-Clause + +``` + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + + 2. Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + + 3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" + AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE + FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +``` + diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CITATION.cff b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CITATION.cff new file mode 100644 index 0000000000000000000000000000000000000000..ea97f1f68ea9f9e24a391561c111192bfed09ee6 --- /dev/null +++ b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CITATION.cff @@ -0,0 +1,112 @@ +cff-version: 1.2.0 +title: CUTLASS +message: >- + If you use this software, please cite using the + following metadata. +type: software +authors: + - given-names: Vijay + family-names: Thakkar + email: vithakkar@nvidia.com + affiliation: NVIDIA + - given-names: Pradeep + family-names: Ramani + email: prramani@nvidia.com + affiliation: NVIDIA + - given-names: Cris + family-names: Cecka + email: ccecka@nvidia.com + affiliation: NVIDIA + - given-names: Aniket + family-names: Shivam + email: ashivam@nvidia.com + affiliation: NVIDIA + - given-names: Honghao + family-names: Lu + email: honghaol@nvidia.com + affiliation: NVIDIA + - given-names: Ethan + family-names: Yan + email: etyan@nvidia.com + affiliation: NVIDIA + - given-names: Jack + family-names: Kosaian + email: jkosaian@nvidia.com + affiliation: NVIDIA + - given-names: Mark + family-names: Hoemmen + email: mhoemmen@nvidia.com + affiliation: NVIDIA + - given-names: Haicheng + family-names: Wu + email: haichengw@nvidia.com + affiliation: NVIDIA + - given-names: Andrew + family-names: Kerr + email: akerr@nvidia.com + affiliation: NVIDIA + - given-names: Matt + family-names: Nicely + email: mnicely@nvidia.com + affiliation: NVIDIA + - given-names: Duane + family-names: Merrill + email: dumerrill@nvidia.com + affiliation: NVIDIA + - given-names: Dustyn + family-names: Blasig + email: dblasig@nvidia.com + affiliation: NVIDIA + - given-names: Fengqi + family-names: Qiao + email: fqiao@nvidia.com + affiliation: NVIDIA + - given-names: Piotr + family-names: Majcher + email: pmajcher@nvidia.com + affiliation: NVIDIA + - given-names: Paul + family-names: Springer + email: pspringer@nvidia.com + affiliation: NVIDIA + - given-names: Markus + family-names: Hohnerbach + affiliation: NVIDIA + email: mhohnerbach@nvidia.com + - given-names: Jin + family-names: Wang + email: jinw@nvidia.com + affiliation: NVIDIA + - given-names: Manish + family-names: Gupta + affiliation: Google + email: manigupta@google.com + + +repository-code: 'https://github.com/NVIDIA/cutlass' +abstract: >- + CUTLASS is a collection of CUDA C++ template + abstractions for implementing high-performance + matrix-multiplication (GEMM) and related + computations at all levels and scales within CUDA. + It incorporates strategies for hierarchical + decomposition and data movement similar to those + used to implement cuBLAS and cuDNN. CUTLASS + decomposes these "moving parts" into reusable, + modular software components abstracted by C++ + template classes. These thread-wide, warp-wide, + block-wide, and device-wide primitives can be + specialized and tuned via custom tiling sizes, data + types, and other algorithmic policy. The resulting + flexibility simplifies their use as building blocks + within custom kernels and applications. +keywords: + - 'cutlass, tensor cores, cuda, cute, nvidia, gpu, linear algebra, matrix computations' +license: BSD-3-Clause +license-url: https://github.com/NVIDIA/cutlass/blob/v3.0.0/LICENSE.txt +version: '3.0.0' +date-released: '2023-01-23' +identifiers: + - type: url + value: "https://github.com/NVIDIA/cutlass/tree/v3.0.0" + description: The GitHub release URL of tag 3.0.0 diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CMakeLists.txt b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CMakeLists.txt new file mode 100644 index 0000000000000000000000000000000000000000..44190d59d14efe15b55f97cb8c4a9ef219c1f594 --- /dev/null +++ b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CMakeLists.txt @@ -0,0 +1,923 @@ +# Copyright (c) 2017 - 2023 NVIDIA CORPORATION & AFFILIATES. All rights reserved. +# SPDX-License-Identifier: BSD-3-Clause +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# 1. Redistributions of source code must retain the above copyright notice, this +# list of conditions and the following disclaimer. +# +# 2. Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# 3. Neither the name of the copyright holder nor the names of its +# contributors may be used to endorse or promote products derived from +# this software without specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +cmake_minimum_required(VERSION 3.19 FATAL_ERROR) +cmake_policy(SET CMP0112 NEW) + +if(cutlass_LOADED) + # If CUTLASS has been previously fetched and loaded, don't do it again. + return() +else() + set(cutlass_LOADED ON) + set(CUTLASS_DIR ${CMAKE_CURRENT_SOURCE_DIR} CACHE PATH "CUTLASS Repository Directory") +endif() + +message(STATUS "CMake Version: ${CMAKE_VERSION}") +set(IMPLICIT_CMAKE_CXX_STANDARD OFF CACHE BOOL "Do not explicitly specify -std=c++11 if set") + +project(CUTLASS VERSION 3.2.2 LANGUAGES CXX) +include(${CMAKE_CURRENT_SOURCE_DIR}/CUDA.cmake) + +if (CUDA_VERSION VERSION_LESS 11.3) + message(WARNING "CUTLASS ${CUTLASS_VERSION} requires CUDA 11.4 or higher, and strongly recommends CUDA 11.8 or higher.") +elseif (CUDA_VERSION VERSION_LESS 11.4) + message(WARNING "CUTLASS ${CUTLASS_VERSION} support for CUDA ${CUDA_VERSION} is deprecated, please use CUDA 11.8 or higher.") +endif() + +if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 7.5) + message(FATAL_ERROR "GCC version must be at least 7.5!") +endif() + +if (CUDA_COMPILER MATCHES "[Cc]lang" AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 7.0) + message(FATAL_ERROR "Clang 7.0+ required for GPU compilation") +endif() + +find_package(Doxygen QUIET) + +################################################################################ + +# +# CUTLASS 3.x requires C++17 +# +set(CMAKE_CXX_STANDARD 17) +set(CMAKE_CXX_STANDARD_REQUIRED ON) +set(CMAKE_CXX_EXTENSIONS OFF) + +if(CUTLASS_NATIVE_CUDA) + set(CMAKE_CUDA_STANDARD 17) + set(CMAKE_CUDA_STANDARD_REQUIRED ON) + list(APPEND CUTLASS_CUDA_NVCC_FLAGS --expt-relaxed-constexpr) +else() + list(APPEND CUTLASS_CUDA_NVCC_FLAGS --std=c++17) +endif() + +if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) + set(CMAKE_INSTALL_PREFIX install CACHE PATH "Default installation location." FORCE) +endif() + +message(STATUS "Default Install Location: ${CMAKE_INSTALL_PREFIX}") + +set(CUTLASS_TEST_LEVEL "0" CACHE STRING "Level of tests to compile.") +# 0 - Sanity, 1 - Release-Quality, 2 - Exhaustive + +find_package(Python3 3.5 COMPONENTS Interpreter REQUIRED) + +# Install cutlass_library Python package +execute_process( + WORKING_DIRECTORY ${CUTLASS_DIR}/python + COMMAND ${Python3_EXECUTABLE} ${CUTLASS_DIR}/python/setup_library.py develop --user + RESULT_VARIABLE cutlass_lib_GENERATOR_INSTALL_RESULT + OUTPUT_FILE ${CMAKE_CURRENT_BINARY_DIR}/cutlass_library_installation.log + ERROR_FILE ${CMAKE_CURRENT_BINARY_DIR}/cutlass_library_installation.log +) + +if(NOT cutlass_lib_GENERATOR_INSTALL_RESULT EQUAL 0) + message(FATAL_ERROR "Error installing cutlass_library package. See ${CMAKE_CURRENT_BINARY_DIR}/cutlass_library_installation.log") +endif() + +################################################################################ +set(CUTLASS_ENABLE_HEADERS_ONLY OFF CACHE BOOL "Enable only the header library") + +if(CUTLASS_ENABLE_HEADERS_ONLY) + set(CUTLASS_ENABLE_EXAMPLES_INIT OFF) + set(CUTLASS_ENABLE_TOOLS_INIT ON) + set(CUTLASS_ENABLE_LIBRARY_INIT OFF) + set(CUTLASS_ENABLE_TESTS_INIT OFF) +else() + set(CUTLASS_ENABLE_EXAMPLES_INIT ON) + set(CUTLASS_ENABLE_TOOLS_INIT ON) + set(CUTLASS_ENABLE_LIBRARY_INIT ON) + if(${CMAKE_PROJECT_NAME} STREQUAL ${PROJECT_NAME}) + set(CUTLASS_ENABLE_TESTS_INIT ON) + else() + set(CUTLASS_ENABLE_TESTS_INIT OFF) + endif() +endif() + +set(CUTLASS_TEST_UNIT_ENABLE_WARNINGS OFF CACHE BOOL "Enable warnings on waived unit tests.") + +set(CUTLASS_ENABLE_EXAMPLES ${CUTLASS_ENABLE_EXAMPLES_INIT} CACHE BOOL "Enable CUTLASS Examples") +set(CUTLASS_ENABLE_TOOLS ${CUTLASS_ENABLE_TOOLS_INIT} CACHE BOOL "Enable CUTLASS Tools") +set(CUTLASS_ENABLE_LIBRARY ${CUTLASS_ENABLE_LIBRARY_INIT} CACHE BOOL "Enable CUTLASS Library") +set(CUTLASS_ENABLE_PROFILER ${CUTLASS_ENABLE_LIBRARY} CACHE BOOL "Enable CUTLASS Profiler") +set(CUTLASS_ENABLE_PERFORMANCE ${CUTLASS_ENABLE_PROFILER} CACHE BOOL "Enable CUTLASS Performance") + +set(CUTLASS_ENABLE_TESTS ${CUTLASS_ENABLE_TESTS_INIT} CACHE BOOL "Enable CUTLASS Tests") +set(CUTLASS_ENABLE_GTEST_UNIT_TESTS ${CUTLASS_ENABLE_TESTS} CACHE BOOL "Enable CUTLASS GTest-based Unit Tests") +################################################################################ + +set(CUTLASS_NVCC_ARCHS_SUPPORTED "") +if (CUDA_VERSION VERSION_GREATER_EQUAL 11.4 AND NOT CUDA_COMPILER MATCHES "[Cc]lang") + list(APPEND CUTLASS_NVCC_ARCHS_SUPPORTED 70 72 75 80 86 87) +endif() +if (CUDA_VERSION VERSION_GREATER_EQUAL 11.8 AND NOT CUDA_COMPILER MATCHES "[Cc]lang") + list(APPEND CUTLASS_NVCC_ARCHS_SUPPORTED 89 90) +endif() +if (CUDA_VERSION VERSION_GREATER_EQUAL 12.0 AND NOT CUDA_COMPILER MATCHES "[Cc]lang") + list(APPEND CUTLASS_NVCC_ARCHS_SUPPORTED 90a) +endif() +set(CUTLASS_NVCC_ARCHS ${CUTLASS_NVCC_ARCHS_SUPPORTED} CACHE STRING "The SM architectures requested.") +set(CUTLASS_NVCC_ARCHS_ENABLED ${CUTLASS_NVCC_ARCHS} CACHE STRING "The SM architectures to build code for.") + +# Find unsupported and deprecated compute capabilities +if (CUTLASS_NVCC_ARCHS_SUPPORTED) + set(CUTLASS_NVCC_ARCHS_UNSUPPORTED ${CUTLASS_NVCC_ARCHS}) + list(REMOVE_ITEM CUTLASS_NVCC_ARCHS_UNSUPPORTED ${CUTLASS_NVCC_ARCHS_SUPPORTED}) + if (CUTLASS_NVCC_ARCHS_UNSUPPORTED) + message(WARNING "Using unsupported or deprecated compute capabilities ${CUTLASS_NVCC_ARCHS_UNSUPPORTED}. Support may be removed in future versions.") + endif() +else() + message(WARNING "No supported compute capabilities for CUDA ${CUDA_VERSION}.") +endif() + +# Special policy introduced in CMake 3.13 +if (POLICY CMP0076) + cmake_policy(SET CMP0076 NEW) +endif() + +include(GNUInstallDirs) + +link_directories(${CUDA_TOOLKIT_ROOT_DIR}/lib64/stubs) + +################################################################################################### +# +# Configure CMake variables +# +################################################################################################### + +message(STATUS "CUDA Compilation Architectures: ${CUTLASS_NVCC_ARCHS_ENABLED}") + +if (NOT (CMAKE_BUILD_TYPE OR CONFIGURATION_TYPES)) + # By default we want to build in Release mode to ensure that we're getting best performance. + set(CMAKE_BUILD_TYPE Release CACHE STRING "Choose build level" FORCE) + set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug" "RelWithDebInfo" "Release") +endif() + +set(CMAKE_POSITION_INDEPENDENT_CODE ON) +if (DEFINED CMAKE_DEBUG_POSTFIX) + set(CUTLASS_LIBRARY_DEBUG_POSTFIX_INIT ${CMAKE_DEBUG_POSTFIX}) +else() + set(CUTLASS_LIBRARY_DEBUG_POSTFIX_INIT .debug) +endif() +set(CUTLASS_LIBRARY_DEBUG_POSTFIX ${CUTLASS_LIBRARY_DEBUG_POSTFIX_INIT} CACHE STRING "Default postfix value for debug libraries") + +if(WIN32) + # On Windows we link against the shared (DLL) runtime. Change gtest settings to match this. + set(gtest_force_shared_crt ON CACHE BOOL "Use shared (DLL) run-time lib even when Google Test is built as static lib" FORCE) +endif() + +if (WIN32) + # Enable more warnings. Add "-Xcompiler=/WX" to enable warnings as errors. + list(APPEND CUTLASS_CUDA_NVCC_FLAGS -Xcompiler=/W3) + + # Disable warning on Unicode characters + list(APPEND CUTLASS_CUDA_NVCC_FLAGS -Xcompiler=/wd4819) + + # Disable excess x86 floating point precision that can lead to results being labeled incorrectly + list(APPEND CUTLASS_CUDA_NVCC_FLAGS -Xcompiler=/fp:strict) +endif(WIN32) + +if (${CUTLASS_NVCC_VERBOSE}) + list(APPEND CUTLASS_CUDA_NVCC_FLAGS -v) +endif() + +# +# CUTLASS NAMESPACE +# +set(CUTLASS_NAMESPACE "cutlass" CACHE STRING "Top level namespace of CUTLASS") + +set(CUTLASS_NVCC_EMBED_CUBIN ON CACHE BOOL "Embed compiled CUDA kernel binaries into executables.") +set(CUTLASS_NVCC_EMBED_PTX ON CACHE BOOL "Embed compiled PTX into executables.") +set(CUTLASS_NVCC_KEEP OFF CACHE BOOL "Keep intermediate files generated by NVCC.") +set(CUTLASS_ENABLE_F16C OFF CACHE BOOL "Enable F16C x86 extensions in host code.") + +################################################################################ +# +# CUTLASS generator cmake configuration +# + +set(CUTLASS_LIBRARY_OPERATIONS "all" CACHE STRING "Comma delimited list of operation name filters. Default '' means all operations are enabled.") +set(CUTLASS_LIBRARY_KERNELS ${CUTLASS_LIBRARY_KERNELS_INIT} CACHE STRING "Comma delimited list of kernel name filters. If unspecified, only the largest tile size is enabled. If 'all' is specified, all kernels are enabled.") +set(CUTLASS_LIBRARY_IGNORE_KERNELS "" CACHE STRING "Comma delimited list of kernel names to exclude from build.") + +################################################################################ + +set(CUTLASS_TEST_ENABLE_CACHED_RESULTS ON CACHE BOOL "Enable caching and reuse of test results in unit tests") + +set_property(CACHE CUTLASS_TEST_LEVEL PROPERTY STRINGS 0 1 2) +list(APPEND CUTLASS_CUDA_NVCC_FLAGS -DCUTLASS_TEST_LEVEL=${CUTLASS_TEST_LEVEL}) +list(APPEND CUTLASS_CUDA_CLANG_FLAGS -DCUTLASS_TEST_LEVEL=${CUTLASS_TEST_LEVEL}) + +if (CUTLASS_TEST_ENABLE_CACHED_RESULTS) + message(STATUS "Enable caching of reference results in conv unit tests") + list(APPEND CUTLASS_CUDA_NVCC_FLAGS -DCUTLASS_TEST_ENABLE_CACHED_RESULTS=1) +endif() + +set(CUTLASS_CONV_UNIT_TEST_RIGOROUS_SIZE_ENABLED ON CACHE BOOL "Enable/Disable rigorous conv problem sizes in conv unit tests") + +if (CUTLASS_CONV_UNIT_TEST_RIGOROUS_SIZE_ENABLED) + message(STATUS "Enable rigorous conv problem sizes in conv unit tests") + list(APPEND CUTLASS_CUDA_NVCC_FLAGS -DCUTLASS_CONV_UNIT_TEST_RIGOROUS_SIZE_ENABLED=1) +endif() + +################################################################################ + +# +# CUDA 10.1 introduces "mma" in PTX performing collective matrix multiply operations. +# + +if (CUDA_VERSION VERSION_LESS 10.1) + set(CUTLASS_ENABLE_TENSOR_CORE_MMA_DEFAULT OFF) +else() + set(CUTLASS_ENABLE_TENSOR_CORE_MMA_DEFAULT ON) +endif() + +# Trace levels for debugging +set(CUTLASS_DEBUG_TRACE_LEVEL "0" CACHE STRING "Level of debug tracing to perform.") +list(APPEND CUTLASS_CUDA_NVCC_FLAGS -DCUTLASS_DEBUG_TRACE_LEVEL=${CUTLASS_DEBUG_TRACE_LEVEL}) + +set(CUTLASS_ENABLE_TENSOR_CORE_MMA ${CUTLASS_ENABLE_TENSOR_CORE_MMA_DEFAULT} CACHE BOOL + "Enable PTX mma instruction for collective matrix multiply operations.") + +# +# NOTE: running with asan and CUDA requires the following environment variable: +# +# ASAN_OPTIONS=protect_shadow_gap=0:replace_intrin=0:detect_leaks=0 +# +# without the above environment setting, an error like the following may be generated: +# +# *** Error: Could not detect active GPU device ID [out of memory] +# ... +# ==9149==ERROR: LeakSanitizer: detected memory leaks +# ... +# +if(ENABLE_ASAN) # https://github.com/google/sanitizers/wiki/AddressSanitizer + list(APPEND CUTLASS_CUDA_NVCC_FLAGS --compiler-options=-fsanitize=address --compiler-options=-fno-omit-frame-pointer) + string(APPEND CMAKE_EXE_LINKER_FLAGS " -fsanitize=address") +endif() + +################################################################################################### +# +# Configure CUDA build options +# +################################################################################################### + +if(CUTLASS_NVCC_EMBED_PTX) + list(APPEND CUTLASS_CUDA_CLANG_FLAGS --cuda-include-ptx=all) +endif() + +if (CUTLASS_ENABLE_TENSOR_CORE_MMA) + list(APPEND CUTLASS_CUDA_FLAGS -DCUTLASS_ENABLE_TENSOR_CORE_MMA=1) +endif() + + + + +if (NOT MSVC AND CUTLASS_NVCC_KEEP) + # MSVC flow handles caching already, but for other generators we handle it here. + set(CUTLASS_NVCC_KEEP_DIR ${CMAKE_CURRENT_BINARY_DIR}/tmp CACHE PATH "Location to store NVCC scratch files") + file(MAKE_DIRECTORY ${CUTLASS_NVCC_KEEP_DIR}) + list(APPEND CUTLASS_CUDA_NVCC_FLAGS --keep -v) # --keep-dir may not work with nvcc for some directories. + list(APPEND CUTLASS_CUDA_CLANG_FLAGS -save-temps=${CUTLASS_NVCC_KEEP_DIR}) +endif() + +if (CUTLASS_ENABLE_F16C AND NOT CMAKE_CROSSCOMPILING) + list(APPEND CUTLASS_CUDA_FLAGS -DCUTLASS_ENABLE_F16C=1) + if ((CMAKE_CXX_COMPILER_ID MATCHES "GNU") OR (CMAKE_CXX_COMPILER_ID MATCHES "Clang")) + list(APPEND CUTLASS_CUDA_NVCC_FLAGS -Xcompiler=-mf16c) + elseif((CMAKE_CXX_COMPILER_ID MATCHES "MSVC")) + list(APPEND CUTLASS_CUDA_NVCC_FLAGS -Xcompiler=/arch:AVX2) + endif() +endif() + +if (CUTLASS_ENABLE_OPENMP_TESTS) + find_package(OpenMP) + if(OpenMP_CXX_FOUND) + list(APPEND CUTLASS_CUDA_NVCC_FLAGS -Xcompiler=${OpenMP_CXX_FLAGS}) + else() + message(WARNING "CUTLASS_ENABLE_OPENMP_TESTS set but OpenMP not found.") + endif() +endif() +if(UNIX) + list(APPEND CUTLASS_CUDA_NVCC_FLAGS -Xcompiler=-Wconversion) + list(APPEND CUTLASS_CUDA_NVCC_FLAGS -Xcompiler=-fno-strict-aliasing) +endif() + +# Don't leak lineinfo in release builds +if (NOT CMAKE_BUILD_TYPE MATCHES "Release") + list(APPEND CUTLASS_CUDA_CLANG_FLAGS -gmlt) + list(APPEND CUTLASS_CUDA_NVCC_FLAGS -lineinfo) +endif() + +#Report CUDA build flags +if (CUDA_COMPILER MATCHES "[Cc]lang") + if(CUTLASS_CUDA_CLANG_FLAGS) + message(STATUS "Using CLANG flags: ${CUTLASS_CUDA_CLANG_FLAGS}") + endif() +else() + if(CUTLASS_CUDA_NVCC_FLAGS) + message(STATUS "Using NVCC flags: ${CUTLASS_CUDA_NVCC_FLAGS}") + endif() +endif() + +if(CUDA_COMPILER MATCHES "[Cc]lang") + if( NOT CMAKE_CXX_COMPILER_ID MATCHES "Clang" ) + message(FATAL_ERROR "Clang CUDA compilation requires Clang CXX compilation. Currently CMAKE_CXX_COMPILER is ${CMAKE_CXX_COMPILER_ID}" ) + endif() + + # There are numerous Clang versions that can work with each CUDA toolkit and the + # the checks are not very useful so we are turning them off and using testing to + # ensure the various combinations work properly. + + list(APPEND CUTLASS_CUDA_CLANG_FLAGS --cuda-path=${CUDA_TOOLKIT_ROOT_DIR}) + list(APPEND CUTLASS_CUDA_CLANG_FLAGS -D__NV_NO_HOST_COMPILER_CHECK=1) + list(APPEND CUTLASS_CUDA_CLANG_FLAGS -Wno-unknown-cuda-version) + + list(APPEND CUTLASS_CUDA_CLANG_FLAGS -mllvm -pragma-unroll-threshold=100000) + list(APPEND CUTLASS_CUDA_CLANG_FLAGS -mllvm -unroll-threshold=5000) + list(APPEND CUTLASS_CUDA_CLANG_FLAGS -Wno-unused-command-line-argument) + + string(REPLACE "." ";" CUDA_VERSION_PARTS ${CMAKE_CUDA_COMPILER_VERSION}) + list(GET CUDA_VERSION_PARTS 0 CUDA_VERSION_MAJOR) + list(GET CUDA_VERSION_PARTS 1 CUDA_VERSION_MINOR) + list(APPEND CUTLASS_CUDA_CLANG_FLAGS -D__CUDACC_VER_MAJOR__=${CUDA_VERSION_MAJOR} -D__CUDACC_VER_MINOR__=${CUDA_VERSION_MINOR}) + + + # needed for libcublasLt.so in case it's installed in the same location as libcudart.so + # dynamic linker can find it if linker sets RPATH (forced by --disable-new-tags) + # Otherwise linker uses RUNPATH and that does not propagate to loaded libs. + list(APPEND CUTLASS_CUDA_CLANG_FLAGS -Wl,--disable-new-dtags) + + link_libraries(nvidia::cudart) + link_libraries(nvidia::cuda_driver) +endif() + +# Support for 128-bit integers if using NVIDIA C++ compiler +if (${CMAKE_CXX_COMPILER_ID} MATCHES "PGI" OR ${CMAKE_CXX_COMPILER_ID} MATCHES "NVHPC") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Mint128 ") +endif() + +if (CMAKE_VERSION VERSION_GREATER_EQUAL 3.18) + # CMake 3.18 added support for CUDA_ARCHITECTURES target property. We will use this + # property for CMake 3.18+, so we request the NEW behavior for correct compatibility. + # https://cmake.org/cmake/help/v3.18/policy/CMP0104.html#policy:CMP0104 + cmake_policy(SET CMP0104 NEW) +endif() + +if (MSVC) + + # MSVC by default does not apply the correct __cplusplus version as specified by the C++ standard + # because MSVC is not a completely compliant implementation. This option forces MSVC to use the + # appropriate value given the requested --std option. This fixes a compilation issue mismatch + # between GCC/Clang and MSVC. + # + # error : a constexpr function cannot have a nonliteral return type "dim3" + # + # See https://developercommunity.visualstudio.com/t/msvc-incorrectly-defines-cplusplus/139261 + + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /Zc:__cplusplus") + set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -Xcompiler /Zc:__cplusplus") + +endif() + +# Some tests require this build option in order to link. +if (MSVC) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /bigobj") + set(CMAKE_CUDA_FLAGS "${CMAKE_CUDA_FLAGS} -Xcompiler /bigobj") +endif() + +function(cutlass_apply_cuda_gencode_flags TARGET) + set(options) + set(oneValueArgs) + set(multiValueArgs SM_ARCHS) + cmake_parse_arguments(_ "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN}) + + if (__SM_ARCHS) + set(ARCHS_ENABLED ${__SM_ARCHS}) + else() + set(ARCHS_ENABLED ${CUTLASS_NVCC_ARCHS_ENABLED}) + endif() + + set(NVCC_FLAGS) + set(CLANG_FLAGS) + set(__CMAKE_CUDA_ARCHS) + foreach(ARCH ${ARCHS_ENABLED}) + list(APPEND CLANG_FLAGS --cuda-gpu-arch=sm_${ARCH}) + set(CODES) + if(CUTLASS_NVCC_EMBED_CUBIN) + list(APPEND CODES sm_${ARCH}) + list(APPEND __CMAKE_CUDA_ARCHS ${ARCH}-real) + endif() + if(CUTLASS_NVCC_EMBED_PTX) + list(APPEND CODES compute_${ARCH}) + list(APPEND __CMAKE_CUDA_ARCHS ${ARCH}-virtual) + endif() + list(JOIN CODES "," CODES_STR) + list(APPEND NVCC_FLAGS -gencode=arch=compute_${ARCH},code=[${CODES_STR}]) + endforeach() + + if (NOT __SM_ARCHS) + if (CUDA_COMPILER MATCHES "[Cc]lang") + target_compile_options( + ${TARGET} + PRIVATE + $<$:${CLANG_FLAGS}> + ) + elseif(CMAKE_VERSION GREATER_EQUAL 3.18) + set_property(TARGET ${TARGET} PROPERTY CUDA_ARCHITECTURES ${__CMAKE_CUDA_ARCHS}) + else() + target_compile_options( + ${TARGET} + PRIVATE + $<$:${NVCC_FLAGS}> + ) + endif() + else() + list(JOIN CLANG_FLAGS " " CLANG_FLAGS_STR) + list(JOIN NVCC_FLAGS " " STR_NVCC_FLAGS) + if (CUDA_COMPILER MATCHES "[Cc]lang") + if(${TARGET} MATCHES ".*\.cpp") + set_source_files_properties(${TARGET} PROPERTIES COMPILE_FLAGS ${CLANG_FLAGS_STR}) + endif() + elseif(CMAKE_VERSION GREATER_EQUAL 3.18) + set_source_files_properties(${TARGET} PROPERTIES CUDA_ARCHITECTURES ${STR_NVCC_FLAGS}) + else() + if(${TARGET} MATCHES ".*\.cu") + set_source_files_properties(${TARGET} PROPERTIES COMPILE_FLAGS ${STR_NVCC_FLAGS}) + endif() + endif() + endif() + +endfunction() + +# Cache the flags so they are available when the function below is called anywhere globally. + +set(__CUTLASS_CUDA_FLAGS ${CUTLASS_CUDA_FLAGS} CACHE INTERNAL "") +set(__CUTLASS_CUDA_FLAGS_RELEASE ${CUTLASS_CUDA_FLAGS_RELEASE} CACHE INTERNAL "") +set(__CUTLASS_CUDA_FLAGS_RELWITHDEBINFO ${CUTLASS_CUDA_FLAGS_RELWITHDEBINFO} CACHE INTERNAL "") +set(__CUTLASS_CUDA_FLAGS_DEBUG ${CUTLASS_CUDA_FLAGS_DEBUG} CACHE INTERNAL "") +set(__CUTLASS_CUDA_CLANG_FLAGS ${CUTLASS_CUDA_CLANG_FLAGS} CACHE INTERNAL "") +set(__CUTLASS_CUDA_CLANG_FLAGS_RELEASE ${CUTLASS_CUDA_CLANG_FLAGS_RELEASE} CACHE INTERNAL "") +set(__CUTLASS_CUDA_CLANG_FLAGS_RELWITHDEBINFO ${CUTLASS_CUDA_CLANG_FLAGS_RELWITHDEBINFO} CACHE INTERNAL "") +set(__CUTLASS_CUDA_CLANG_FLAGS_DEBUG ${CUTLASS_CUDA_CLANG_FLAGS_DEBUG} CACHE INTERNAL "") +set(__CUTLASS_CUDA_NVCC_FLAGS ${CUTLASS_CUDA_NVCC_FLAGS} CACHE INTERNAL "") +set(__CUTLASS_CUDA_NVCC_FLAGS_RELEASE ${CUTLASS_CUDA_NVCC_FLAGS_RELEASE} CACHE INTERNAL "") +set(__CUTLASS_CUDA_NVCC_FLAGS_RELWITHDEBINFO ${CUTLASS_CUDA_NVCC_FLAGS_RELWITHDEBINFO} CACHE INTERNAL "") +set(__CUTLASS_CUDA_NVCC_FLAGS_DEBUG ${CUTLASS_CUDA_NVCC_FLAGS_DEBUG} CACHE INTERNAL "") + +function(cutlass_apply_standard_compile_options TARGET) + + if(CUDA_COMPILER MATCHES "[Cc]lang") + set(CUDA_COMPILE_LANGUAGE CXX) + set(_FLAGS ${__CUTLASS_CUDA_FLAGS} ${__CUTLASS_CUDA_CLANG_FLAGS}) + set(_FLAGS_RELEASE ${__CUTLASS_CUDA_FLAGS_RELEASE} ${__CUTLASS_CUDA_CLANG_FLAGS_RELEASE}) + set(_FLAGS_RELWITHDEBINFO ${__CUTLASS_CUDA_FLAGS_RELWITHDEBINFO} ${__CUTLASS_CUDA_CLANG_FLAGS_RELWITHDEBINFO}) + set(_FLAGS_DEBUG ${__CUTLASS_CUDA_FLAGS_DEBUG} ${__CUTLASS_CUDA_CLANG_FLAGS_DEBUG}) + else() + set(CUDA_COMPILE_LANGUAGE CUDA) + set(_FLAGS ${__CUTLASS_CUDA_FLAGS} ${__CUTLASS_CUDA_NVCC_FLAGS}) + set(_FLAGS_RELEASE ${__CUTLASS_CUDA_FLAGS_RELEASE} ${__CUTLASS_CUDA_NVCC_FLAGS_RELEASE}) + set(_FLAGS_RELWITHDEBINFO ${__CUTLASS_CUDA_FLAGS_RELWITHDEBINFO} ${__CUTLASS_CUDA_NVCC_FLAGS_RELWITHDEBINFO}) + set(_FLAGS_DEBUG ${__CUTLASS_CUDA_FLAGS_DEBUG} ${__CUTLASS_CUDA_NVCC_FLAGS_DEBUG}) + endif() + + target_link_libraries(${TARGET} PRIVATE CUTLASS) + + target_compile_options( + ${TARGET} + PRIVATE + $<$:${_FLAGS}> + $<$:$<$:${_FLAGS_RELEASE}>> + $<$:$<$:${_FLAGS_RELWITHDEBINFO}>> + $<$:$<$:${_FLAGS_DEBUG}>> + ) + +endfunction() + +# +# The following items should eventually be pushed into cutlass/CMakeLists.txt +# + +# GLOB for CUTLASS header files. Should we use a static list instead? +file(GLOB_RECURSE CUTLASS_INCLUDE RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} include/cutlass/*.h) +file(GLOB_RECURSE CUTLASS_CUTLASS RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}/include include/cutlass/*.h include/cutlass/*.hpp include/cutlass/*.inl) +file(GLOB_RECURSE CUTLASS_CUTE RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}/include include/cute/*.h*) +file(GLOB_RECURSE CUTLASS_NVRTC RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}/test test/unit/nvrtc/kernel/*.h) + +################################################################################################### +# +# Define build targets +# +################################################################################################### + +source_group(TREE ${CMAKE_CURRENT_SOURCE_DIR}/include REGULAR_EXPRESSION ".*\.h") + +add_library(CUTLASS INTERFACE) +add_library(nvidia::cutlass::cutlass ALIAS CUTLASS) +set_target_properties(CUTLASS PROPERTIES EXPORT_NAME cutlass) + +set(CUTLASS_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/include CACHE PATH "CUTLASS Header Library") + +set(CUTLASS_GENERATOR_DIR ${CMAKE_CURRENT_SOURCE_DIR}/tools/library CACHE INTERNAL "Location of generator scripts") + +# The following utility directory is needed even if the tools build is disabled, so it exists here. +set(CUTLASS_TOOLS_UTIL_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/tools/util/include CACHE INTERNAL "") + +include_directories(${CUTLASS_INCLUDE_DIR}) + +target_compile_features(CUTLASS INTERFACE cxx_std_11) + +if (NOT CUTLASS_NAMESPACE STREQUAL "cutlass") + target_compile_definitions(CUTLASS INTERFACE CUTLASS_NAMESPACE=${CUTLASS_NAMESPACE}) +endif() + +if (NOT DEFINED CUTLASS_REVISION) + + find_package(Git QUIET) + + execute_process( + COMMAND ${GIT_EXECUTABLE} rev-parse --short HEAD + RESULT_VARIABLE CUTLASS_REVISION_RESULT + OUTPUT_VARIABLE CUTLASS_REVISION + OUTPUT_STRIP_TRAILING_WHITESPACE + ) + + if (CUTLASS_REVISION_RESULT) + message(STATUS "CUTLASS Revision: Unable to detect, Git returned code ${CUTLASS_REVISION_RESULT}.") + else() + message(STATUS "CUTLASS Revision: ${CUTLASS_REVISION}") + endif() + +endif() + +configure_file( + ${CMAKE_CURRENT_SOURCE_DIR}/cmake/version.h.in + ${CMAKE_CURRENT_BINARY_DIR}/include/cutlass/version.h + @ONLY) + +target_include_directories( + CUTLASS + INTERFACE + $ + $ + $ + $ + $ + ) + +# Mark CTK headers as system to supress warnings from them +target_include_directories( + CUTLASS + SYSTEM INTERFACE + $ + ) + +install( + DIRECTORY + ${CUTLASS_INCLUDE_DIR}/ + ${CMAKE_CURRENT_BINARY_DIR}/include/ + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} + ) + +install( + TARGETS CUTLASS + EXPORT NvidiaCutlass + PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} + ) + +################################################################################ + +# Doxygen is available. Generate documentation +if (DOXYGEN_FOUND) + # DOT is available. Enable graph generation in the documentation + if (DOXYGEN_DOT_EXECUTABLE) + set(CUTLASS_ENABLE_DOXYGEN_DOT ON CACHE BOOL "Use dot to generate graphs in the doxygen documentation.") + else() + set(CUTLASS_ENABLE_DOXYGEN_DOT OFF CACHE BOOL "Use dot to generate graphs in the doxygen documentation." FORCE) + endif() + + if (CUTLASS_ENABLE_DOXYGEN_DOT) + set(HAVE_DOT "YES") + else() + set(HAVE_DOT "NO") + endif() + + # Add custom target for Doxygen. + add_custom_target(cutlass_docs ${CMAKE_COMMAND} -E env + "DOT_PATH=${DOXYGEN_DOT_EXECUTABLE}" + "HAVE_DOT=${HAVE_DOT}" + ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile + WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} + VERBATIM + ) +endif() + +if(NOT WIN32) + # Add common library search paths so executables and libraries can load and run + # without LD_LIBRARY_PATH being set. + link_libraries( + "-Wl,-rpath,'$ORIGIN'" + "-Wl,-rpath,'$ORIGIN/../lib64'" + "-Wl,-rpath,'$ORIGIN/../lib'" + "-Wl,-rpath,'${CUDA_TOOLKIT_ROOT_DIR}/lib64'" + "-Wl,-rpath,'${CUDA_TOOLKIT_ROOT_DIR}/lib'" + ) +endif() + +################################################################################ + +include(CTest) +enable_testing() + +if (CUTLASS_ENABLE_GTEST_UNIT_TESTS) + include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/googletest.cmake) +endif() + +if (NOT TARGET test_all) + add_custom_target(test_all) +endif() + +set(CUTLASS_INSTALL_TESTS ON CACHE BOOL "Install test executables") +set(CUTLASS_TEST_EXECUTION_ENVIRONMENT "" CACHE BOOL "Environment in which to invoke unit test executables") + +set(CMAKE_TEST_INSTALL_PREFIX test CACHE STRING "Test root install location, relative to CMAKE_INSTALL_PREFIX.") +set(CUTLASS_TEST_INSTALL_PREFIX ${CMAKE_TEST_INSTALL_PREFIX}/cutlass CACHE STRING "Test root install location, relative to CMAKE_INSTALL_PREFIX.") +set(CUTLASS_TEST_INSTALL_BINDIR ${CUTLASS_TEST_INSTALL_PREFIX}/${CMAKE_INSTALL_BINDIR} CACHE STRING "Test root install location, relative to CMAKE_INSTALL_PREFIX.") +set(CUTLASS_TEST_INSTALL_LIBDIR ${CUTLASS_TEST_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR} CACHE STRING "Test root install location, relative to CMAKE_INSTALL_PREFIX.") + +install(DIRECTORY DESTINATION ${CUTLASS_TEST_INSTALL_PREFIX}) +install(DIRECTORY DESTINATION ${CUTLASS_TEST_INSTALL_BINDIR}) +install(DIRECTORY DESTINATION ${CUTLASS_TEST_INSTALL_LIBDIR}) +install(DIRECTORY DESTINATION ${CUTLASS_TEST_INSTALL_PREFIX}/ctest) + +################################################################################ + +set(CUTLASS_ENABLE_CUBLAS OFF CACHE BOOL "cuBLAS usage for tests") +set(CUTLASS_ENABLE_CUDNN OFF CACHE BOOL "cuDNN usage for tests") + +include(${CMAKE_CURRENT_SOURCE_DIR}/cuBLAS.cmake) + +if (CUTLASS_ENABLE_CUBLAS) + target_compile_definitions(CUTLASS INTERFACE CUTLASS_ENABLE_CUBLAS=1) +endif() + +include(${CMAKE_CURRENT_SOURCE_DIR}/cuDNN.cmake) + +if (CUTLASS_ENABLE_CUDNN) + target_compile_definitions(CUTLASS INTERFACE CUTLASS_ENABLE_CUDNN=1) +endif() + +################################################################################ + +set(CUTLASS_CTEST_TEMPLATE_FILE ${CMAKE_CURRENT_LIST_DIR}/cmake/CTestTestfile.configure.cmake) +set(CUTLASS_CTEST_GENERATED_FILES "" CACHE INTERNAL "") + +function(cutlass_add_executable_tests NAME TARGET) +# +# Generates test rules for `make test`, `make test_all`, and `ctest` invoked from either the +# or the / after installation. +# +# NAME: The base name for the test. Can be run with `make ` or `ctest -R 'c'`. +# TARGET: The target corresponding to the executable under test. +# DISABLE_EXECUTABLE_INSTALL_RULE: An option, if given, that disables creating an install rule for TARGET. +# DEPENDS: A list of targets or files on which this test is dependent. +# DEPENDEES: A list of targets which should depend on this test. +# TEST_COMMAND_OPTIONS: A list of variables (i.e. by reference params) which contain command line arguments +# to pass to the test executable. A unique test is generated for each set of +# options given. If this option is not used, a single test with no arguments is generated. +# TEST_COMMAND_OPTIONS_PREFIX: If provided, is added as a prefix to each TEST_COMMAND_OPTIONS value for +# generating the full variable name to be referenced. +# RESULT_CACHE_FILE: A file to be installed alongside the test executable with pre-computed +# test results to speed up test runtime. +# + + set(options DISABLE_EXECUTABLE_INSTALL_RULE) + set(oneValueArgs DISABLE_TESTS RESULT_CACHE_FILE TEST_COMMAND_OPTIONS_PREFIX) + set(multiValueArgs DEPENDS DEPENDEES TEST_COMMAND_OPTIONS) + cmake_parse_arguments(_ "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN}) + + if (NOT DEFINED __DISABLE_TESTS) + set(__DISABLE_TESTS OFF) + endif() + + set(TEST_EXE $) + set(TEST_EXE_WORKING_DIRECTORY ./${CMAKE_INSTALL_BINDIR}) + + if (__RESULT_CACHE_FILE) + + add_custom_command( + TARGET ${TARGET} + POST_BUILD + COMMAND ${CMAKE_COMMAND} + ARGS -E copy ${__RESULT_CACHE_FILE} "$" + ) + + endif() + + if (NOT __DISABLE_EXECUTABLE_INSTALL_RULE AND CUTLASS_INSTALL_TESTS) + + # file(RELATIVE_PATH CMAKE_CURRENT_BINARY_RELATIVE_DIR ${CMAKE_BINARY_DIR} ${CMAKE_CURRENT_BINARY_DIR}) + + install( + TARGETS ${TARGET} + RUNTIME DESTINATION ${CUTLASS_TEST_INSTALL_BINDIR} + ) + + if (__RESULT_CACHE_FILE) + + install( + FILES ${__RESULT_CACHE_FILE} + DESTINATION ${CUTLASS_TEST_INSTALL_BINDIR}/ + ) + + endif() + + endif() + + if (NOT __TEST_COMMAND_OPTIONS) + set(__TEST_COMMAND_OPTIONS " ") + endif() + + list(LENGTH __TEST_COMMAND_OPTIONS CMD_COUNT) + + if (CMD_COUNT GREATER 1) + add_custom_target(${NAME} DEPENDS ${TARGET} ${__DEPENDS}) + foreach(DEPENDEE ${__DEPENDEES}) + add_dependencies(${DEPENDEE} ${NAME}) + endforeach() + endif() + + if (CUTLASS_INSTALL_TESTS) + + set(_INLINE_PER_TEST_CODE) + + file(READ "${PROJECT_SOURCE_DIR}/cmake/CTestTestfile.test.configure.cmake" _INLINE_PER_TEST_CODE_TEMPLATE) + + endif() + + set(TEST_GROUP_NAME ${NAME}) + + foreach(CMD_OPTIONS_VAR IN LISTS __TEST_COMMAND_OPTIONS) + + if (CMD_COUNT GREATER 1) + string(TOLOWER "${NAME}_${CMD_OPTIONS_VAR}" TEST_NAME) + else() + string(TOLOWER "${NAME}" TEST_NAME) + endif() + + # The following rigmarole is needed to deal with spaces and possible quotes in + # command line arguments. The options are passed "by reference" as the actual + # variable names holding the real options. We then expand these in a way that + # preserves any quotes. Note, they have to be in this order for it to work for + # all the use cases below. + + set(TEST_COMMAND_OPTIONS ${${__TEST_COMMAND_OPTIONS_PREFIX}${CMD_OPTIONS_VAR}}) + list(JOIN TEST_COMMAND_OPTIONS " " TEST_COMMAND_OPTIONS) + separate_arguments(TEST_COMMAND_OPTIONS) + + add_custom_target( + ${TEST_NAME} + COMMAND + ${CUTLASS_TEST_EXECUTION_ENVIRONMENT} $ ${TEST_COMMAND_OPTIONS} + DEPENDS + ${TARGET} + ) + + if (CMD_COUNT GREATER 1) + add_dependencies(${NAME} ${TEST_NAME}) + endif() + + foreach(DEPENDEE ${__DEPENDEES}) + add_dependencies(${DEPENDEE} ${TEST_NAME}) + endforeach() + + set(TEST_NAME c${TEST_NAME}) + string(CONFIGURE "${_INLINE_PER_TEST_CODE_TEMPLATE}" _TEST_CODE @ONLY) + string(APPEND _INLINE_PER_TEST_CODE "${_TEST_CODE}") + + endforeach() + + # To run the tests from an install package with tests enabled, we need to generate test files + # that don't rely on the current directory structure in build. + + set(TEST_NAME c${NAME}) + set(TEST_GEN_DIR ${CMAKE_CURRENT_BINARY_DIR}/ctest/${TEST_NAME}) + file(MAKE_DIRECTORY ${TEST_GEN_DIR}) + + set(TEST_EXE_PATH $) + set(TEST_USE_EXTENDED_FORMAT ON) + configure_file("${CUTLASS_CTEST_TEMPLATE_FILE}" "${TEST_GEN_DIR}/CTestTestfile.${TEST_NAME}.cmake" @ONLY) + + set(TEST_EXE_PATH $) + set(TEST_USE_EXTENDED_FORMAT OFF) # ctest does not support extended add_test format. + configure_file("${CUTLASS_CTEST_TEMPLATE_FILE}" "${TEST_GEN_DIR}/CTestTestfile.${TEST_NAME}.install.cmake.in" @ONLY) + + # The following line imports the tests for immediate run via `make test`. + + include(${TEST_GEN_DIR}/CTestTestfile.${TEST_NAME}.cmake) + + set(CUTLASS_CTEST_GENERATED_FILES ${CUTLASS_CTEST_GENERATED_FILES};ctest/${TEST_NAME}/CTestTestfile.${TEST_NAME}.cmake CACHE INTERNAL "") + + if (CUTLASS_INSTALL_TESTS) + + file(GENERATE + OUTPUT "${TEST_GEN_DIR}/CTestTestfile.${TEST_NAME}.install.cmake" + INPUT "${TEST_GEN_DIR}/CTestTestfile.${TEST_NAME}.install.cmake.in" + ) + + install( + FILES "${TEST_GEN_DIR}/CTestTestfile.${TEST_NAME}.install.cmake" + DESTINATION ${CUTLASS_TEST_INSTALL_PREFIX}/ctest/${TEST_NAME} + RENAME CTestTestfile.${TEST_NAME}.cmake + ) + + endif() + +endfunction() + +if (CUTLASS_ENABLE_TOOLS) + add_subdirectory(tools) + if (CUTLASS_ENABLE_PROFILER) + add_dependencies(test_all test_profiler) + endif() +endif() + +if (CUTLASS_ENABLE_EXAMPLES) + add_subdirectory(examples) + add_dependencies(test_all test_examples) +endif() + +if (CUTLASS_ENABLE_TESTS) + add_subdirectory(test) + if (CUTLASS_ENABLE_GTEST_UNIT_TESTS) + add_dependencies(test_all test_unit) + endif() +endif() + +if (CUTLASS_INSTALL_TESTS) + + file(MAKE_DIRECTORY "${CMAKE_BINARY_DIR}/ctest") + + file(WRITE "${CMAKE_BINARY_DIR}/ctest/CTestTestfile.cmake" "# Generated File\n") + foreach(GENERATED_FILE ${CUTLASS_CTEST_GENERATED_FILES}) + file(APPEND "${CMAKE_BINARY_DIR}/ctest/CTestTestfile.cmake" "include(${GENERATED_FILE})\n") + endforeach() + + install( + FILES "${CMAKE_BINARY_DIR}/ctest/CTestTestfile.cmake" + DESTINATION "${CUTLASS_TEST_INSTALL_PREFIX}/" + ) + +endif() + +################################################################################ + +include(CMakePackageConfigHelpers) + +write_basic_package_version_file( + ${CMAKE_CURRENT_BINARY_DIR}/NvidiaCutlassConfigVersion.cmake + COMPATIBILITY AnyNewerVersion) + +install( + FILES + ${CMAKE_CURRENT_SOURCE_DIR}/cmake/NvidiaCutlassConfig.cmake + ${CMAKE_CURRENT_BINARY_DIR}/NvidiaCutlassConfigVersion.cmake + DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/NvidiaCutlass/ + ) + +install( + EXPORT NvidiaCutlass + NAMESPACE nvidia::cutlass:: + DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/NvidiaCutlass/ + FILE NvidiaCutlassTargets.cmake + ) + +################################################################################ + +include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/NvidiaCutlassPackageConfig.cmake) + diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CONTRIBUTORS.md b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CONTRIBUTORS.md new file mode 100644 index 0000000000000000000000000000000000000000..5a159d8c576cfb0093332d1b59964785fa5e34f8 --- /dev/null +++ b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CONTRIBUTORS.md @@ -0,0 +1,83 @@ +![ALT](/media/images/gemm-hierarchy-with-epilogue-no-labels.png "CUTLASS") + +[README](/README.md#documentation) > **Contributors** + +# CUTLASS Developers and Contributors + +This is the official list of CUTLASS developers and contributors. + +## DEVELOPERS +Vijay Thakkar
+Pradeep Ramani
+Cris Cecka
+Aniket Shivam
+Jack Kosaian
+Mark Hoemmen
+Honghao Lu
+Ethan Yan
+Haicheng Wu
+Andrew Kerr
+Dustyn Blasig
+Fengqi Qiao
+Duane Merrill
+Yujia Zhai
+Shang Zhang
+Piotr Majcher
+Paul Springer
+Markus Hohnerbach
+Jin Wang
+Aditya Atluri
+ +## CuTe +Cris Cecka
+Vijay Thakkar
+ +## CUTLASS Product Manager +Matthew Nicely
+ +## Former CUTLASS Developers +Manish Gupta
+Naila Farooqui
+David Tanner
+Manikandan Ananth
+Zhaodong Chen
+Chinmay Talegaonkar
+ +## CONTRIBUTORS +Timothy Costa
+Julien Demouth
+Brian Fahs
+Michael Garland
+Michael Goldfarb
+Mostafa Hagog
+Fei Hu
+Alan Kaatz
+Tina Li
+Timmy Liu
+Wei Liu
+Duane Merrill
+Kevin Siu
+Markus Tavenrath
+John Tran
+Vicki Wang
+Junkai Wu
+Fung Xie
+Albert Xu
+Yang Xu
+Jack Yang
+Scott Yokim
+Xiuxia Zhang
+Nick Zhao
+ +## ACKNOWLEDGEMENTS + +Girish Bharambe
+Luke Durant
+Carter Edwards
+Olivier Giroux
+Stephen Jones
+Rishkul Kulkarni
+Bryce Lelbach
+Joel McCormack
+Kyrylo Perelygin
+Sean Treichler
diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CUDA.cmake b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CUDA.cmake new file mode 100644 index 0000000000000000000000000000000000000000..b9c60bcd0bec4122b5bf446fbf410a19cd3ff8bc --- /dev/null +++ b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/CUDA.cmake @@ -0,0 +1,371 @@ +# Copyright (c) 2017 - 2023 NVIDIA CORPORATION & AFFILIATES. All rights reserved. +# SPDX-License-Identifier: BSD-3-Clause +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# 1. Redistributions of source code must retain the above copyright notice, this +# list of conditions and the following disclaimer. +# +# 2. Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# 3. Neither the name of the copyright holder nor the names of its +# contributors may be used to endorse or promote products derived from +# this software without specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +if(CUDA_COMPILER MATCHES "[Cc]lang") + set(CUTLASS_NATIVE_CUDA_INIT ON) +elseif(CMAKE_VERSION VERSION_LESS 3.12.4) + set(CUTLASS_NATIVE_CUDA_INIT OFF) +else() + set(CUTLASS_NATIVE_CUDA_INIT ON) +endif() + +set(CUTLASS_NATIVE_CUDA ${CUTLASS_NATIVE_CUDA_INIT} CACHE BOOL "Utilize the CMake native CUDA flow") + +if(NOT DEFINED ENV{CUDACXX} AND NOT DEFINED ENV{CUDA_BIN_PATH} AND DEFINED ENV{CUDA_PATH}) + # For backward compatibility, allow use of CUDA_PATH. + set(ENV{CUDACXX} $ENV{CUDA_PATH}/bin/nvcc) +endif() + +if(CUTLASS_NATIVE_CUDA) + + enable_language(CUDA) + + if(NOT CUDA_VERSION) + set(CUDA_VERSION ${CMAKE_CUDA_COMPILER_VERSION}) + endif() + if(NOT CUDA_TOOLKIT_ROOT_DIR) + get_filename_component(CUDA_TOOLKIT_ROOT_DIR "${CMAKE_CUDA_COMPILER}/../.." ABSOLUTE) + endif() + +else() + + find_package(CUDA REQUIRED) + # We workaround missing variables with the native flow by also finding the CUDA toolkit the old way. + + if(NOT CMAKE_CUDA_COMPILER_VERSION) + set(CMAKE_CUDA_COMPILER_VERSION ${CUDA_VERSION}) + endif() + +endif() + +if (CUDA_VERSION VERSION_LESS 9.2) + message(FATAL_ERROR "CUDA 9.2+ Required, Found ${CUDA_VERSION}.") +endif() +if(NOT CUTLASS_NATIVE_CUDA OR CUDA_COMPILER MATCHES "[Cc]lang") + set(CMAKE_CUDA_COMPILER ${CUDA_TOOLKIT_ROOT_DIR}/bin/nvcc) + message(STATUS "CUDA Compiler: ${CMAKE_CUDA_COMPILER}") +endif() + +find_library( + CUDART_LIBRARY cudart + PATHS + ${CUDA_TOOLKIT_ROOT_DIR} + PATH_SUFFIXES + lib/x86_64-linux-gnu + lib/x64 + lib64 + lib + NO_DEFAULT_PATH + # We aren't going to search any system paths. We want to find the runtime + # in the CUDA toolkit we're building against. + ) + +if(NOT TARGET cudart AND CUDART_LIBRARY) + + message(STATUS "CUDART: ${CUDART_LIBRARY}") + + if(WIN32) + add_library(cudart STATIC IMPORTED GLOBAL) + # Even though we're linking against a .dll, in Windows you statically link against + # the .lib file found under lib/x64. The .dll will be loaded at runtime automatically + # from the PATH search. + else() + add_library(cudart SHARED IMPORTED GLOBAL) + endif() + + add_library(nvidia::cudart ALIAS cudart) + + set_property( + TARGET cudart + PROPERTY IMPORTED_LOCATION + ${CUDART_LIBRARY} + ) + +elseif(TARGET cudart) + + message(STATUS "CUDART: Already Found") + +else() + + message(STATUS "CUDART: Not Found") + +endif() + +find_library( + CUDA_DRIVER_LIBRARY cuda + PATHS + ${CUDA_TOOLKIT_ROOT_DIR} + PATH_SUFFIXES + lib/x86_64-linux-gnu + lib/x64 + lib64 + lib + lib64/stubs + lib/stubs + NO_DEFAULT_PATH + # We aren't going to search any system paths. We want to find the runtime + # in the CUDA toolkit we're building against. + ) + +if(NOT TARGET cuda_driver AND CUDA_DRIVER_LIBRARY) + + message(STATUS "CUDA Driver: ${CUDA_DRIVER_LIBRARY}") + + if(WIN32) + add_library(cuda_driver STATIC IMPORTED GLOBAL) + # Even though we're linking against a .dll, in Windows you statically link against + # the .lib file found under lib/x64. The .dll will be loaded at runtime automatically + # from the PATH search. + else() + add_library(cuda_driver SHARED IMPORTED GLOBAL) + endif() + + add_library(nvidia::cuda_driver ALIAS cuda_driver) + + set_property( + TARGET cuda_driver + PROPERTY IMPORTED_LOCATION + ${CUDA_DRIVER_LIBRARY} + ) + +elseif(TARGET cuda_driver) + + message(STATUS "CUDA Driver: Already Found") + +else() + + message(STATUS "CUDA Driver: Not Found") + +endif() + +find_library( + NVRTC_LIBRARY nvrtc + PATHS + ${CUDA_TOOLKIT_ROOT_DIR} + PATH_SUFFIXES + lib/x64 + lib64 + lib + NO_DEFAULT_PATH + # We aren't going to search any system paths. We want to find the runtime + # in the CUDA toolkit we're building against. + ) + +if(NOT TARGET nvrtc AND NVRTC_LIBRARY) + + message(STATUS "NVRTC: ${NVRTC_LIBRARY}") + + if(WIN32) + add_library(nvrtc STATIC IMPORTED GLOBAL) + # Even though we're linking against a .dll, in Windows you statically link against + # the .lib file found under lib/x64. The .dll will be loaded at runtime automatically + # from the PATH search. + else() + add_library(nvrtc SHARED IMPORTED GLOBAL) + endif() + + add_library(nvidia::nvrtc ALIAS nvrtc) + + set_property( + TARGET nvrtc + PROPERTY IMPORTED_LOCATION + ${NVRTC_LIBRARY} + ) + +elseif(TARGET nvrtc) + + message(STATUS "NVRTC: Already Found") + +else() + + message(STATUS "NVRTC: Not Found") + +endif() + +include_directories(SYSTEM ${CUDA_INCLUDE_DIRS}) +# Some platforms (e.g. Visual Studio) don't add the CUDA include directories to the system include +# paths by default, so we add it explicitly here. + +function(cutlass_correct_source_file_language_property) + if(CUDA_COMPILER MATCHES "[Cc]lang") + foreach(File ${ARGN}) + if(File MATCHES ".*\.cu$") + set_source_files_properties(${File} PROPERTIES LANGUAGE CXX) + endif() + endforeach() + endif() +endfunction() + +if (MSVC OR CUTLASS_LIBRARY_KERNELS MATCHES "all") + set(CUTLASS_UNITY_BUILD_ENABLED_INIT ON) +else() + set(CUTLASS_UNITY_BUILD_ENABLED_INIT OFF) +endif() + +set(CUTLASS_UNITY_BUILD_ENABLED ${CUTLASS_UNITY_BUILD_ENABLED_INIT} CACHE BOOL "Enable combined source compilation") + +if (MSVC) + set(CUTLASS_UNITY_BUILD_BATCH_SIZE_INIT 8) +else() + set(CUTLASS_UNITY_BUILD_BATCH_SIZE_INIT 16) +endif() + +set(CUTLASS_UNITY_BUILD_BATCH_SIZE ${CUTLASS_UNITY_BUILD_BATCH_SIZE_INIT} CACHE STRING "Batch size for unified source files") + +function(cutlass_unify_source_files TARGET_ARGS_VAR) + + set(options) + set(oneValueArgs BATCH_SOURCES BATCH_SIZE) + set(multiValueArgs) + cmake_parse_arguments(_ "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN}) + + if (NOT DEFINED TARGET_ARGS_VAR) + message(FATAL_ERROR "TARGET_ARGS_VAR parameter is required") + endif() + + if (__BATCH_SOURCES AND NOT DEFINED __BATCH_SIZE) + set(__BATCH_SIZE ${CUTLASS_UNITY_BUILD_BATCH_SIZE}) + endif() + + if (CUTLASS_UNITY_BUILD_ENABLED AND DEFINED __BATCH_SIZE AND __BATCH_SIZE GREATER 1) + + set(CUDA_FILE_ARGS) + set(TARGET_SOURCE_ARGS) + + foreach(ARG ${__UNPARSED_ARGUMENTS}) + if(${ARG} MATCHES ".*\.cu$") + list(APPEND CUDA_FILE_ARGS ${ARG}) + else() + list(APPEND TARGET_SOURCE_ARGS ${ARG}) + endif() + endforeach() + + list(LENGTH CUDA_FILE_ARGS NUM_CUDA_FILE_ARGS) + while(NUM_CUDA_FILE_ARGS GREATER 0) + list(SUBLIST CUDA_FILE_ARGS 0 ${__BATCH_SIZE} CUDA_FILE_BATCH) + string(SHA256 CUDA_FILE_BATCH_HASH "${CUDA_FILE_BATCH}") + string(SUBSTRING ${CUDA_FILE_BATCH_HASH} 0 12 CUDA_FILE_BATCH_HASH) + set(BATCH_FILE ${CMAKE_CURRENT_BINARY_DIR}/${NAME}.unity.${CUDA_FILE_BATCH_HASH}.cu) + message(STATUS "Generating ${BATCH_FILE}") + file(WRITE ${BATCH_FILE} "// Unity File - Auto Generated!\n") + foreach(CUDA_FILE ${CUDA_FILE_BATCH}) + get_filename_component(CUDA_FILE_ABS_PATH ${CUDA_FILE} ABSOLUTE) + file(APPEND ${BATCH_FILE} "#include \"${CUDA_FILE_ABS_PATH}\"\n") + endforeach() + list(APPEND TARGET_SOURCE_ARGS ${BATCH_FILE}) + if (NUM_CUDA_FILE_ARGS LESS_EQUAL __BATCH_SIZE) + break() + endif() + list(SUBLIST CUDA_FILE_ARGS ${__BATCH_SIZE} -1 CUDA_FILE_ARGS) + list(LENGTH CUDA_FILE_ARGS NUM_CUDA_FILE_ARGS) + endwhile() + + else() + + set(TARGET_SOURCE_ARGS ${__UNPARSED_ARGUMENTS}) + + endif() + + set(${TARGET_ARGS_VAR} ${TARGET_SOURCE_ARGS} PARENT_SCOPE) + +endfunction() +function(cutlass_add_library NAME) + + set(options SKIP_GENCODE_FLAGS) + set(oneValueArgs EXPORT_NAME) + set(multiValueArgs) + cmake_parse_arguments(_ "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN}) + + cutlass_unify_source_files(TARGET_SOURCE_ARGS ${__UNPARSED_ARGUMENTS}) + + if(CUTLASS_NATIVE_CUDA OR CUDA_COMPILER MATCHES "clang") + cutlass_correct_source_file_language_property(${TARGET_SOURCE_ARGS}) + add_library(${NAME} ${TARGET_SOURCE_ARGS} "") + else() + set(CUDA_LINK_LIBRARIES_KEYWORD PRIVATE) + cuda_add_library(${NAME} ${TARGET_SOURCE_ARGS} "") + endif() + + cutlass_apply_standard_compile_options(${NAME}) + if (NOT __SKIP_GENCODE_FLAGS) + cutlass_apply_cuda_gencode_flags(${NAME}) + endif() + + target_compile_features( + ${NAME} + INTERFACE + cxx_std_11 + ) + + if(__EXPORT_NAME) + add_library(nvidia::cutlass::${__EXPORT_NAME} ALIAS ${NAME}) + set_target_properties(${NAME} PROPERTIES EXPORT_NAME ${__EXPORT_NAME}) + endif() + +endfunction() + +function(cutlass_add_executable NAME) + + set(options) + set(oneValueArgs) + set(multiValueArgs) + cmake_parse_arguments(_ "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN}) + + cutlass_unify_source_files(TARGET_SOURCE_ARGS ${__UNPARSED_ARGUMENTS}) + + if(CUTLASS_NATIVE_CUDA OR CUDA_COMPILER MATCHES "clang") + cutlass_correct_source_file_language_property(${TARGET_SOURCE_ARGS}) + add_executable(${NAME} ${TARGET_SOURCE_ARGS}) + else() + set(CUDA_LINK_LIBRARIES_KEYWORD PRIVATE) + cuda_add_executable(${NAME} ${TARGET_SOURCE_ARGS}) + endif() + + cutlass_apply_standard_compile_options(${NAME}) + cutlass_apply_cuda_gencode_flags(${NAME}) + + target_compile_features( + ${NAME} + INTERFACE + cxx_std_11 + ) + +endfunction() + +function(cutlass_target_sources NAME) + + set(options) + set(oneValueArgs) + set(multiValueArgs) + cmake_parse_arguments(_ "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN}) + + cutlass_unify_source_files(TARGET_SOURCE_ARGS ${__UNPARSED_ARGUMENTS}) + cutlass_correct_source_file_language_property(${TARGET_SOURCE_ARGS}) + target_sources(${NAME} ${TARGET_SOURCE_ARGS}) + +endfunction() diff --git a/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/Doxyfile b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/Doxyfile new file mode 100644 index 0000000000000000000000000000000000000000..9d241c0c5640badb81bb6e8e9bfe3fb11940121f --- /dev/null +++ b/venv/lib/python3.10/site-packages/bitblas/3rdparty/cutlass/Doxyfile @@ -0,0 +1,2283 @@ +# Doxyfile 1.8.5 + +# This file describes the settings to be used by the documentation system +# doxygen (www.doxygen.org) for a project. +# +# All text after a double hash (##) is considered a comment and is placed in +# front of the TAG it is preceding. +# +# All text after a single hash (#) is considered a comment and will be ignored. +# The format is: +# TAG = value [value, ...] +# For lists, items can also be appended using: +# TAG += value [value, ...] +# Values that contain spaces should be placed between quotes (\" \"). + +#--------------------------------------------------------------------------- +# Project related configuration options +#--------------------------------------------------------------------------- + +# This tag specifies the encoding used for all characters in the config file +# that follow. The default is UTF-8 which is also the encoding used for all text +# before the first occurrence of this tag. Doxygen uses libiconv (or the iconv +# built into libc) for the transcoding. See http://www.gnu.org/software/libiconv +# for the list of possible encodings. +# The default value is: UTF-8. + +DOXYFILE_ENCODING = UTF-8 + +# The PROJECT_NAME tag is a single word (or a sequence of words surrounded by +# double-quotes, unless you are using Doxywizard) that should identify the +# project for which the documentation is generated. This name is used in the +# title of most generated pages and in a few other places. +# The default value is: My Project. + +PROJECT_NAME = "CUTLASS" + +# The PROJECT_NUMBER tag can be used to enter a project or revision number. This +# could be handy for archiving the generated documentation or if some version +# control system is used. + +PROJECT_NUMBER = + +# Using the PROJECT_BRIEF tag one can provide an optional one line description +# for a project that appears at the top of each page and should give viewer a +# quick idea about the purpose of the project. Keep the description short. + +PROJECT_BRIEF = "CUDA Templates for Linear Algebra Subroutines and Solvers" + +# With the PROJECT_LOGO tag one can specify an logo or icon that is included in +# the documentation. The maximum height of the logo should not exceed 55 pixels +# and the maximum width should not exceed 200 pixels. Doxygen will copy the logo +# to the output directory. + +PROJECT_LOGO = media/images/cutlass-logo-small.png + +# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) path +# into which the generated documentation will be written. If a relative path is +# entered, it will be relative to the location where doxygen was started. If +# left blank the current directory will be used. + +OUTPUT_DIRECTORY = doxygen + +# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create 4096 sub- +# directories (in 2 levels) under the output directory of each output format and +# will distribute the generated files over these directories. Enabling this +# option can be useful when feeding doxygen a huge amount of source files, where +# putting all generated files in the same directory would otherwise causes +# performance problems for the file system. +# The default value is: NO. + +CREATE_SUBDIRS = NO + +# The OUTPUT_LANGUAGE tag is used to specify the language in which all +# documentation generated by doxygen is written. Doxygen will use this +# information to generate all constant output in the proper language. +# Possible values are: Afrikaans, Arabic, Brazilian, Catalan, Chinese, Chinese- +# Traditional, Croatian, Czech, Danish, Dutch, English, Esperanto, Farsi, +# Finnish, French, German, Greek, Hungarian, Italian, Japanese, Japanese-en, +# Korean, Korean-en, Latvian, Norwegian, Macedonian, Persian, Polish, +# Portuguese, Romanian, Russian, Serbian, Slovak, Slovene, Spanish, Swedish, +# Turkish, Ukrainian and Vietnamese. +# The default value is: English. + +OUTPUT_LANGUAGE = English + +# If the BRIEF_MEMBER_DESC tag is set to YES doxygen will include brief member +# descriptions after the members that are listed in the file and class +# documentation (similar to Javadoc). Set to NO to disable this. +# The default value is: YES. + +BRIEF_MEMBER_DESC = YES + +# If the REPEAT_BRIEF tag is set to YES doxygen will prepend the brief +# description of a member or function before the detailed description +# +# Note: If both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the +# brief descriptions will be completely suppressed. +# The default value is: YES. + +REPEAT_BRIEF = NO + +# This tag implements a quasi-intelligent brief description abbreviator that is +# used to form the text in various listings. Each string in this list, if found +# as the leading text of the brief description, will be stripped from the text +# and the result, after processing the whole list, is used as the annotated +# text. Otherwise, the brief description is used as-is. If left blank, the +# following values are used ($name is automatically replaced with the name of +# the entity):The $name class, The $name widget, The $name file, is, provides, +# specifies, contains, represents, a, an and the. + +ABBREVIATE_BRIEF = + +# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then +# doxygen will generate a detailed section even if there is only a brief +# description. +# The default value is: NO. + +ALWAYS_DETAILED_SEC = NO + +# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all +# inherited members of a class in the documentation of that class as if those +# members were ordinary class members. Constructors, destructors and assignment +# operators of the base classes will not be shown. +# The default value is: NO. + +INLINE_INHERITED_MEMB = NO + +# If the FULL_PATH_NAMES tag is set to YES doxygen will prepend the full path +# before files name in the file list and in the header files. If set to NO the +# shortest path that makes the file name unique will be used +# The default value is: YES. + +FULL_PATH_NAMES = NO + +# The STRIP_FROM_PATH tag can be used to strip a user-defined part of the path. +# Stripping is only done if one of the specified strings matches the left-hand +# part of the path. The tag can be used to show relative paths in the file list. +# If left blank the directory from which doxygen is run is used as the path to +# strip. +# +# Note that you can specify absolute paths here, but also relative paths, which +# will be relative from the directory where doxygen is started. +# This tag requires that the tag FULL_PATH_NAMES is set to YES. + +STRIP_FROM_PATH = + +# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of the +# path mentioned in the documentation of a class, which tells the reader which +# header file to include in order to use a class. If left blank only the name of +# the header file containing the class definition is used. Otherwise one should +# specify the list of include paths that are normally passed to the compiler +# using the -I flag. + +STRIP_FROM_INC_PATH = + +# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter (but +# less readable) file names. This can be useful is your file systems doesn't +# support long names like on DOS, Mac, or CD-ROM. +# The default value is: NO. + +SHORT_NAMES = NO + +# If the JAVADOC_AUTOBRIEF tag is set to YES then doxygen will interpret the +# first line (until the first dot) of a Javadoc-style comment as the brief +# description. If set to NO, the Javadoc-style will behave just like regular Qt- +# style comments (thus requiring an explicit @brief command for a brief +# description.) +# The default value is: NO. + +JAVADOC_AUTOBRIEF = NO + +# If the QT_AUTOBRIEF tag is set to YES then doxygen will interpret the first +# line (until the first dot) of a Qt-style comment as the brief description. If +# set to NO, the Qt-style will behave just like regular Qt-style comments (thus +# requiring an explicit \brief command for a brief description.) +# The default value is: NO. + +QT_AUTOBRIEF = NO + +# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make doxygen treat a +# multi-line C++ special comment block (i.e. a block of //! or /// comments) as +# a brief description. This used to be the default behavior. The new default is +# to treat a multi-line C++ comment block as a detailed description. Set this +# tag to YES if you prefer the old behavior instead. +# +# Note that setting this tag to YES also means that rational rose comments are +# not recognized any more. +# The default value is: NO. + +MULTILINE_CPP_IS_BRIEF = NO + +# If the INHERIT_DOCS tag is set to YES then an undocumented member inherits the +# documentation from any documented member that it re-implements. +# The default value is: YES. + +INHERIT_DOCS = YES + +# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce a +# new page for each member. If set to NO, the documentation of a member will be +# part of the file/class/namespace that contains it. +# The default value is: NO. + +SEPARATE_MEMBER_PAGES = NO + +# The TAB_SIZE tag can be used to set the number of spaces in a tab. Doxygen +# uses this value to replace tabs by spaces in code fragments. +# Minimum value: 1, maximum value: 16, default value: 4. + +TAB_SIZE = 2 + +# This tag can be used to specify a number of aliases that act as commands in +# the documentation. An alias has the form: +# name=value +# For example adding +# "sideeffect=@par Side Effects:\n" +# will allow you to put the command \sideeffect (or @sideeffect) in the +# documentation, which will result in a user-defined paragraph with heading +# "Side Effects:". You can put \n's in the value part of an alias to insert +# newlines. + +#ALIASES += "concept{1}=@ingroup \1\n@par Implemented concepts:\n@ref \1" +ALIASES += "concept{1}=@ingroup \1" + +# This tag can be used to specify a number of word-keyword mappings (TCL only). +# A mapping has the form "name=value". For example adding "class=itcl::class" +# will allow you to use the command class in the itcl::class meaning. + +TCL_SUBST = + +# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources +# only. Doxygen will then generate output that is more tailored for C. For +# instance, some of the names that are used will be different. The list of all +# members will be omitted, etc. +# The default value is: NO. + +OPTIMIZE_OUTPUT_FOR_C = NO + +# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java or +# Python sources only. Doxygen will then generate output that is more tailored +# for that language. For instance, namespaces will be presented as packages, +# qualified scopes will look different, etc. +# The default value is: NO. + +OPTIMIZE_OUTPUT_JAVA = NO + +# Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran +# sources. Doxygen will then generate output that is tailored for Fortran. +# The default value is: NO. + +OPTIMIZE_FOR_FORTRAN = NO + +# Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL +# sources. Doxygen will then generate output that is tailored for VHDL. +# The default value is: NO. + +OPTIMIZE_OUTPUT_VHDL = NO + +# Doxygen selects the parser to use depending on the extension of the files it +# parses. With this tag you can assign which parser to use for a given +# extension. Doxygen has a built-in mapping, but you can override or extend it +# using this tag. The format is ext=language, where ext is a file extension, and +# language is one of the parsers supported by doxygen: IDL, Java, Javascript, +# C#, C, C++, D, PHP, Objective-C, Python, Fortran, VHDL. For instance to make +# doxygen treat .inc files as Fortran files (default is PHP), and .f files as C +# (default is Fortran), use: inc=Fortran f=C. +# +# Note For files without extension you can use no_extension as a placeholder. +# +# Note that for custom extensions you also need to set FILE_PATTERNS otherwise +# the files are not read by doxygen. + +EXTENSION_MAPPING = cu=C++ + +# If the MARKDOWN_SUPPORT tag is enabled then doxygen pre-processes all comments +# according to the Markdown format, which allows for more readable +# documentation. See http://daringfireball.net/projects/markdown/ for details. +# The output of markdown processing is further processed by doxygen, so you can +# mix doxygen, HTML, and XML commands with Markdown formatting. Disable only in +# case of backward compatibilities issues. +# The default value is: YES. + +MARKDOWN_SUPPORT = YES + +# When enabled doxygen tries to link words that correspond to documented +# classes, or namespaces to their corresponding documentation. Such a link can +# be prevented in individual cases by by putting a % sign in front of the word +# or globally by setting AUTOLINK_SUPPORT to NO. +# The default value is: YES. + +AUTOLINK_SUPPORT = YES + +# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want +# to include (a tag file for) the STL sources as input, then you should set this +# tag to YES in order to let doxygen match functions declarations and +# definitions whose arguments contain STL classes (e.g. func(std::string); +# versus func(std::string) {}). This also make the inheritance and collaboration +# diagrams that involve STL classes more complete and accurate. +# The default value is: NO. + +BUILTIN_STL_SUPPORT = YES + +# If you use Microsoft's C++/CLI language, you should set this option to YES to +# enable parsing support. +# The default value is: NO. + +CPP_CLI_SUPPORT = NO + +# Set the SIP_SUPPORT tag to YES if your project consists of sip (see: +# http://www.riverbankcomputing.co.uk/software/sip/intro) sources only. Doxygen +# will parse them like normal C++ but will assume all classes use public instead +# of private inheritance when no explicit protection keyword is present. +# The default value is: NO. + +SIP_SUPPORT = NO + +# For Microsoft's IDL there are propget and propput attributes to indicate +# getter and setter methods for a property. Setting this option to YES will make +# doxygen to replace the get and set methods by a property in the documentation. +# This will only work if the methods are indeed getting or setting a simple +# type. If this is not the case, or you want to show the methods anyway, you +# should set this option to NO. +# The default value is: YES. + +IDL_PROPERTY_SUPPORT = YES + +# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC +# tag is set to YES, then doxygen will reuse the documentation of the first +# member in the group (if any) for the other members of the group. By default +# all members of a group must be documented explicitly. +# The default value is: NO. + +DISTRIBUTE_GROUP_DOC = NO + +# Set the SUBGROUPING tag to YES to allow class member groups of the same type +# (for instance a group of public functions) to be put as a subgroup of that +# type (e.g. under the Public Functions section). Set it to NO to prevent +# subgrouping. Alternatively, this can be done per class using the +# \nosubgrouping command. +# The default value is: YES. + +SUBGROUPING = YES + +# When the INLINE_GROUPED_CLASSES tag is set to YES, classes, structs and unions +# are shown inside the group in which they are included (e.g. using \ingroup) +# instead of on a separate page (for HTML and Man pages) or section (for LaTeX +# and RTF). +# +# Note that this feature does not work in combination with +# SEPARATE_MEMBER_PAGES. +# The default value is: NO. + +INLINE_GROUPED_CLASSES = NO + +# When the INLINE_SIMPLE_STRUCTS tag is set to YES, structs, classes, and unions +# with only public data fields or simple typedef fields will be shown inline in +# the documentation of the scope in which they are defined (i.e. file, +# namespace, or group documentation), provided this scope is documented. If set +# to NO, structs, classes, and unions are shown on a separate page (for HTML and +# Man pages) or section (for LaTeX and RTF). +# The default value is: NO. + +INLINE_SIMPLE_STRUCTS = NO + +# When TYPEDEF_HIDES_STRUCT tag is enabled, a typedef of a struct, union, or +# enum is documented as struct, union, or enum with the name of the typedef. So +# typedef struct TypeS {} TypeT, will appear in the documentation as a struct +# with name TypeT. When disabled the typedef will appear as a member of a file, +# namespace, or class. And the struct will be named TypeS. This can typically be +# useful for C code in case the coding convention dictates that all compound +# types are typedef'ed and only the typedef is referenced, never the tag name. +# The default value is: NO. + +TYPEDEF_HIDES_STRUCT = NO + +# The size of the symbol lookup cache can be set using LOOKUP_CACHE_SIZE. This +# cache is used to resolve symbols given their name and scope. Since this can be +# an expensive process and often the same symbol appears multiple times in the +# code, doxygen keeps a cache of pre-resolved symbols. If the cache is too small +# doxygen will become slower. If the cache is too large, memory is wasted. The +# cache size is given by this formula: 2^(16+LOOKUP_CACHE_SIZE). The valid range +# is 0..9, the default is 0, corresponding to a cache size of 2^16=65536 +# symbols. At the end of a run doxygen will report the cache usage and suggest +# the optimal cache size from a speed point of view. +# Minimum value: 0, maximum value: 9, default value: 0. + +LOOKUP_CACHE_SIZE = 0 + +#--------------------------------------------------------------------------- +# Build related configuration options +#--------------------------------------------------------------------------- + +# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in +# documentation are documented, even if no documentation was available. Private +# class members and static file members will be hidden unless the +# EXTRACT_PRIVATE respectively EXTRACT_STATIC tags are set to YES. +# Note: This will also disable the warnings about undocumented members that are +# normally produced when WARNINGS is set to YES. +# The default value is: NO. + +EXTRACT_ALL = YES + +# If the EXTRACT_PRIVATE tag is set to YES all private members of a class will +# be included in the documentation. +# The default value is: NO. + +EXTRACT_PRIVATE = NO + +# If the EXTRACT_PACKAGE tag is set to YES all members with package or internal +# scope will be included in the documentation. +# The default value is: NO. + +EXTRACT_PACKAGE = NO + +# If the EXTRACT_STATIC tag is set to YES all static members of a file will be +# included in the documentation. +# The default value is: NO. + +EXTRACT_STATIC = NO + +# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) defined +# locally in source files will be included in the documentation. If set to NO +# only classes defined in header files are included. Does not have any effect +# for Java sources. +# The default value is: YES. + +EXTRACT_LOCAL_CLASSES = YES + +# This flag is only useful for Objective-C code. When set to YES local methods, +# which are defined in the implementation section but not in the interface are +# included in the documentation. If set to NO only methods in the interface are +# included. +# The default value is: NO. + +EXTRACT_LOCAL_METHODS = NO + +# If this flag is set to YES, the members of anonymous namespaces will be +# extracted and appear in the documentation as a namespace called +# 'anonymous_namespace{file}', where file will be replaced with the base name of +# the file that contains the anonymous namespace. By default anonymous namespace +# are hidden. +# The default value is: NO. + +EXTRACT_ANON_NSPACES = NO + +# If the HIDE_UNDOC_MEMBERS tag is set to YES, doxygen will hide all +# undocumented members inside documented classes or files. If set to NO these +# members will be included in the various overviews, but no documentation +# section is generated. This option has no effect if EXTRACT_ALL is enabled. +# The default value is: NO. + +HIDE_UNDOC_MEMBERS = NO + +# If the HIDE_UNDOC_CLASSES tag is set to YES, doxygen will hide all +# undocumented classes that are normally visible in the class hierarchy. If set +# to NO these classes will be included in the various overviews. This option has +# no effect if EXTRACT_ALL is enabled. +# The default value is: NO. + +HIDE_UNDOC_CLASSES = NO + +# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, doxygen will hide all friend +# (class|struct|union) declarations. If set to NO these declarations will be +# included in the documentation. +# The default value is: NO. + +HIDE_FRIEND_COMPOUNDS = NO + +# If the HIDE_IN_BODY_DOCS tag is set to YES, doxygen will hide any +# documentation blocks found inside the body of a function. If set to NO these +# blocks will be appended to the function's detailed documentation block. +# The default value is: NO. + +HIDE_IN_BODY_DOCS = NO + +# The INTERNAL_DOCS tag determines if documentation that is typed after a +# \internal command is included. If the tag is set to NO then the documentation +# will be excluded. Set it to YES to include the internal documentation. +# The default value is: NO. + +INTERNAL_DOCS = NO + +# If the CASE_SENSE_NAMES tag is set to NO then doxygen will only generate file +# names in lower-case letters. If set to YES upper-case letters are also +# allowed. This is useful if you have classes or files whose names only differ +# in case and if your file system supports case sensitive file names. Windows +# and Mac users are advised to set this option to NO. +# The default value is: system dependent. + +CASE_SENSE_NAMES = YES + +# If the HIDE_SCOPE_NAMES tag is set to NO then doxygen will show members with +# their full class and namespace scopes in the documentation. If set to YES the +# scope will be hidden. +# The default value is: NO. + +HIDE_SCOPE_NAMES = NO + +# If the SHOW_INCLUDE_FILES tag is set to YES then doxygen will put a list of +# the files that are included by a file in the documentation of that file. +# The default value is: YES. + +SHOW_INCLUDE_FILES = YES + +# If the FORCE_LOCAL_INCLUDES tag is set to YES then doxygen will list include +# files with double quotes in the documentation rather than with sharp brackets. +# The default value is: NO. + +FORCE_LOCAL_INCLUDES = NO + +# If the INLINE_INFO tag is set to YES then a tag [inline] is inserted in the +# documentation for inline members. +# The default value is: YES. + +INLINE_INFO = YES + +# If the SORT_MEMBER_DOCS tag is set to YES then doxygen will sort the +# (detailed) documentation of file and class members alphabetically by member +# name. If set to NO the members will appear in declaration order. +# The default value is: YES. + +SORT_MEMBER_DOCS = YES + +# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the brief +# descriptions of file, namespace and class members alphabetically by member +# name. If set to NO the members will appear in declaration order. +# The default value is: NO. + +SORT_BRIEF_DOCS = NO + +# If the SORT_MEMBERS_CTORS_1ST tag is set to YES then doxygen will sort the +# (brief and detailed) documentation of class members so that constructors and +# destructors are listed first. If set to NO the constructors will appear in the +# respective orders defined by SORT_BRIEF_DOCS and SORT_MEMBER_DOCS. +# Note: If SORT_BRIEF_DOCS is set to NO this option is ignored for sorting brief +# member documentation. +# Note: If SORT_MEMBER_DOCS is set to NO this option is ignored for sorting +# detailed member documentation. +# The default value is: NO. + +SORT_MEMBERS_CTORS_1ST = NO + +# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the hierarchy +# of group names into alphabetical order. If set to NO the group names will +# appear in their defined order. +# The default value is: NO. + +SORT_GROUP_NAMES = NO + +# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be sorted by +# fully-qualified names, including namespaces. If set to NO, the class list will +# be sorted only by class name, not including the namespace part. +# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES. +# Note: This option applies only to the class list, not to the alphabetical +# list. +# The default value is: NO. + +SORT_BY_SCOPE_NAME = NO + +# If the STRICT_PROTO_MATCHING option is enabled and doxygen fails to do proper +# type resolution of all parameters of a function it will reject a match between +# the prototype and the implementation of a member function even if there is +# only one candidate or it is obvious which candidate to choose by doing a +# simple string match. By disabling STRICT_PROTO_MATCHING doxygen will still +# accept a match between prototype and implementation in such cases. +# The default value is: NO. + +STRICT_PROTO_MATCHING = NO + +# The GENERATE_TODOLIST tag can be used to enable ( YES) or disable ( NO) the +# todo list. This list is created by putting \todo commands in the +# documentation. +# The default value is: YES. + +GENERATE_TODOLIST = YES + +# The GENERATE_TESTLIST tag can be used to enable ( YES) or disable ( NO) the +# test list. This list is created by putting \test commands in the +# documentation. +# The default value is: YES. + +GENERATE_TESTLIST = YES + +# The GENERATE_BUGLIST tag can be used to enable ( YES) or disable ( NO) the bug +# list. This list is created by putting \bug commands in the documentation. +# The default value is: YES. + +GENERATE_BUGLIST = YES + +# The GENERATE_DEPRECATEDLIST tag can be used to enable ( YES) or disable ( NO) +# the deprecated list. This list is created by putting \deprecated commands in +# the documentation. +# The default value is: YES. + +GENERATE_DEPRECATEDLIST= YES + +# The ENABLED_SECTIONS tag can be used to enable conditional documentation +# sections, marked by \if ... \endif and \cond +# ... \endcond blocks. + +ENABLED_SECTIONS = + +# The MAX_INITIALIZER_LINES tag determines the maximum number of lines that the +# initial value of a variable or macro / define can have for it to appear in the +# documentation. If the initializer consists of more lines than specified here +# it will be hidden. Use a value of 0 to hide initializers completely. The +# appearance of the value of individual variables and macros / defines can be +# controlled using \showinitializer or \hideinitializer command in the +# documentation regardless of this setting. +# Minimum value: 0, maximum value: 10000, default value: 30. + +MAX_INITIALIZER_LINES = 30 + +# Set the SHOW_USED_FILES tag to NO to disable the list of files generated at +# the bottom of the documentation of classes and structs. If set to YES the list +# will mention the files that were used to generate the documentation. +# The default value is: YES. + +SHOW_USED_FILES = YES + +# Set the SHOW_FILES tag to NO to disable the generation of the Files page. This +# will remove the Files entry from the Quick Index and from the Folder Tree View +# (if specified). +# The default value is: YES. + +SHOW_FILES = YES + +# Set the SHOW_NAMESPACES tag to NO to disable the generation of the Namespaces +# page. This will remove the Namespaces entry from the Quick Index and from the +# Folder Tree View (if specified). +# The default value is: YES. + +SHOW_NAMESPACES = YES + +# The FILE_VERSION_FILTER tag can be used to specify a program or script that +# doxygen should invoke to get the current version for each file (typically from +# the version control system). Doxygen will invoke the program by executing (via +# popen()) the command command input-file, where command is the value of the +# FILE_VERSION_FILTER tag, and input-file is the name of an input file provided +# by doxygen. Whatever the program writes to standard output is used as the file +# version. For an example see the documentation. + +FILE_VERSION_FILTER = + +# The LAYOUT_FILE tag can be used to specify a layout file which will be parsed +# by doxygen. The layout file controls the global structure of the generated +# output files in an output format independent way. To create the layout file +# that represents doxygen's defaults, run doxygen with the -l option. You can +# optionally specify a file name after the option, if omitted DoxygenLayout.xml +# will be used as the name of the layout file. +# +# Note that if you run doxygen from a directory containing a file called +# DoxygenLayout.xml, doxygen will parse it automatically even if the LAYOUT_FILE +# tag is left empty. + +LAYOUT_FILE = + +# The CITE_BIB_FILES tag can be used to specify one or more bib files containing +# the reference definitions. This must be a list of .bib files. The .bib +# extension is automatically appended if omitted. This requires the bibtex tool +# to be installed. See also http://en.wikipedia.org/wiki/BibTeX for more info. +# For LaTeX the style of the bibliography can be controlled using +# LATEX_BIB_STYLE. To use this feature you need bibtex and perl available in the +# search path. Do not use file names with spaces, bibtex cannot handle them. See +# also \cite for info how to create references. + +CITE_BIB_FILES = + +#--------------------------------------------------------------------------- +# Configuration options related to warning and progress messages +#--------------------------------------------------------------------------- + +# The QUIET tag can be used to turn on/off the messages that are generated to +# standard output by doxygen. If QUIET is set to YES this implies that the +# messages are off. +# The default value is: NO. + +QUIET = NO + +# The WARNINGS tag can be used to turn on/off the warning messages that are +# generated to standard error ( stderr) by doxygen. If WARNINGS is set to YES +# this implies that the warnings are on. +# +# Tip: Turn warnings on while writing the documentation. +# The default value is: YES. + +WARNINGS = YES + +# If the WARN_IF_UNDOCUMENTED tag is set to YES, then doxygen will generate +# warnings for undocumented members. If EXTRACT_ALL is set to YES then this flag +# will automatically be disabled. +# The default value is: YES. + +WARN_IF_UNDOCUMENTED = YES + +# If the WARN_IF_DOC_ERROR tag is set to YES, doxygen will generate warnings for +# potential errors in the documentation, such as not documenting some parameters +# in a documented function, or documenting parameters that don't exist or using +# markup commands wrongly. +# The default value is: YES. + +WARN_IF_DOC_ERROR = YES + +# This WARN_NO_PARAMDOC option can be enabled to get warnings for functions that +# are documented, but have no documentation for their parameters or return +# value. If set to NO doxygen will only warn about wrong or incomplete parameter +# documentation, but not about the absence of documentation. +# The default value is: NO. + +WARN_NO_PARAMDOC = NO + +# The WARN_FORMAT tag determines the format of the warning messages that doxygen +# can produce. The string should contain the $file, $line, and $text tags, which +# will be replaced by the file and line number from which the warning originated +# and the warning text. Optionally the format may contain $version, which will +# be replaced by the version of the file (if it could be obtained via +# FILE_VERSION_FILTER) +# The default value is: $file:$line: $text. + +WARN_FORMAT = "$file:$line: $text" + +# The WARN_LOGFILE tag can be used to specify a file to which warning and error +# messages should be written. If left blank the output is written to standard +# error (stderr). + +WARN_LOGFILE = + +#--------------------------------------------------------------------------- +# Configuration options related to the input files +#--------------------------------------------------------------------------- + +# The INPUT tag is used to specify the files and/or directories that contain +# documented source files. You may enter file names like myfile.cpp or +# directories like /usr/src/myproject. Separate the files or directories with +# spaces. +# Note: If this tag is empty the current directory is searched. + +INPUT = include/cutlass tools/util/include/cutlass/ tools/library/include/cutlass/ + +INPUT += media/docs/doxygen_mainpage.md + +# This tag can be used to specify the character encoding of the source files +# that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses +# libiconv (or the iconv built into libc) for the transcoding. See the libiconv +# documentation (see: http://www.gnu.org/software/libiconv) for the list of +# possible encodings. +# The default value is: UTF-8. + +INPUT_ENCODING = UTF-8 + +# If the value of the INPUT tag contains directories, you can use the +# FILE_PATTERNS tag to specify one or more wildcard patterns (like *.cpp and +# *.h) to filter out the source-files in the directories. If left blank the +# following patterns are tested:*.c, *.cc, *.cxx, *.cpp, *.c++, *.java, *.ii, +# *.ixx, *.ipp, *.i++, *.inl, *.idl, *.ddl, *.odl, *.h, *.hh, *.hxx, *.hpp, +# *.h++, *.cs, *.d, *.php, *.php4, *.php5, *.phtml, *.inc, *.m, *.markdown, +# *.md, *.mm, *.dox, *.py, *.f90, *.f, *.for, *.tcl, *.vhd, *.vhdl, *.ucf, +# *.qsf, *.as and *.js. + +FILE_PATTERNS = + +# The RECURSIVE tag can be used to specify whether or not subdirectories should +# be searched for input files as well. +# The default value is: NO. + +RECURSIVE = YES + +# The EXCLUDE tag can be used to specify files and/or directories that should be +# excluded from the INPUT source files. This way you can easily exclude a +# subdirectory from a directory tree whose root is specified with the INPUT tag. +# +# Note that relative paths are relative to the directory from which doxygen is +# run. + +EXCLUDE = + +# The EXCLUDE_SYMLINKS tag can be used to select whether or not files or +# directories that are symbolic links (a Unix file system feature) are excluded +# from the input. +# The default value is: NO. + +EXCLUDE_SYMLINKS = NO + +# If the value of the INPUT tag contains directories, you can use the +# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude +# certain files from those directories. +# +# Note that the wildcards are matched against the file with absolute path, so to +# exclude all test directories for example use the pattern */test/* + +EXCLUDE_PATTERNS = + +# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names +# (namespaces, classes, functions, etc.) that should be excluded from the +# output. The symbol name can be a fully qualified name, a word, or if the +# wildcard * is used, a substring. Examples: ANamespace, AClass, +# AClass::ANamespace, ANamespace::*Test +# +# Note that the wildcards are matched against the file with absolute path, so to +# exclude all test directories use the pattern */test/* + +EXCLUDE_SYMBOLS = + +# The EXAMPLE_PATH tag can be used to specify one or more files or directories +# that contain example code fragments that are included (see the \include +# command). + +EXAMPLE_PATH = + +# If the value of the EXAMPLE_PATH tag contains directories, you can use the +# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp and +# *.h) to filter out the source-files in the directories. If left blank all +# files are included. + +EXAMPLE_PATTERNS = + +# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be +# searched for input files to be used with the \include or \dontinclude commands +# irrespective of the value of the RECURSIVE tag. +# The default value is: NO. + +EXAMPLE_RECURSIVE = NO + +# The IMAGE_PATH tag can be used to specify one or more files or directories +# that contain images that are to be included in the documentation (see the +# \image command). + +IMAGE_PATH = + +# The INPUT_FILTER tag can be used to specify a program that doxygen should +# invoke to filter for each input file. Doxygen will invoke the filter program +# by executing (via popen()) the command: +# +# +# +# where is the value of the INPUT_FILTER tag, and is the +# name of an input file. Doxygen will then use the output that the filter +# program writes to standard output. If FILTER_PATTERNS is specified, this tag +# will be ignored. +# +# Note that the filter must not add or remove lines; it is applied before the +# code is scanned, but not when the output code is generated. If lines are added +# or removed, the anchors will not be placed correctly. + +INPUT_FILTER = + +# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern +# basis. Doxygen will compare the file name with each pattern and apply the +# filter if there is a match. The filters are a list of the form: pattern=filter +# (like *.cpp=my_cpp_filter). See INPUT_FILTER for further information on how +# filters are used. If the FILTER_PATTERNS tag is empty or if none of the +# patterns match the file name, INPUT_FILTER is applied. + +FILTER_PATTERNS = + +# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using +# INPUT_FILTER ) will also be used to filter the input files that are used for +# producing the source files to browse (i.e. when SOURCE_BROWSER is set to YES). +# The default value is: NO. + +FILTER_SOURCE_FILES = NO + +# The FILTER_SOURCE_PATTERNS tag can be used to specify source filters per file +# pattern. A pattern will override the setting for FILTER_PATTERN (if any) and +# it is also possible to disable source filtering for a specific pattern using +# *.ext= (so without naming a filter). +# This tag requires that the tag FILTER_SOURCE_FILES is set to YES. + +FILTER_SOURCE_PATTERNS = + +# If the USE_MDFILE_AS_MAINPAGE tag refers to the name of a markdown file that +# is part of the input, its contents will be placed on the main page +# (index.html). This can be useful if you have a project on for instance GitHub +# and want to reuse the introduction page also for the doxygen output. + +USE_MDFILE_AS_MAINPAGE = media/docs/doxygen_mainpage.md + +#--------------------------------------------------------------------------- +# Configuration options related to source browsing +#--------------------------------------------------------------------------- + +# If the SOURCE_BROWSER tag is set to YES then a list of source files will be +# generated. Documented entities will be cross-referenced with these sources. +# +# Note: To get rid of all source code in the generated output, make sure that +# also VERBATIM_HEADERS is set to NO. +# The default value is: NO. + +SOURCE_BROWSER = NO + +# Setting the INLINE_SOURCES tag to YES will include the body of functions, +# classes and enums directly into the documentation. +# The default value is: NO. + +INLINE_SOURCES = NO + +# Setting the STRIP_CODE_COMMENTS tag to YES will instruct doxygen to hide any +# special comment blocks from generated source code fragments. Normal C, C++ and +# Fortran comments will always remain visible. +# The default value is: YES. + +STRIP_CODE_COMMENTS = YES + +# If the REFERENCED_BY_RELATION tag is set to YES then for each documented +# function all documented functions referencing it will be listed. +# The default value is: NO. + +REFERENCED_BY_RELATION = NO + +# If the REFERENCES_RELATION tag is set to YES then for each documented function +# all documented entities called/used by that function will be listed. +# The default value is: NO. + +REFERENCES_RELATION = NO + +# If the REFERENCES_LINK_SOURCE tag is set to YES and SOURCE_BROWSER tag is set +# to YES, then the hyperlinks from functions in REFERENCES_RELATION and +# REFERENCED_BY_RELATION lists will link to the source code. Otherwise they will +# link to the documentation. +# The default value is: YES. + +REFERENCES_LINK_SOURCE = YES + +# If SOURCE_TOOLTIPS is enabled (the default) then hovering a hyperlink in the +# source code will show a tooltip with additional information such as prototype, +# brief description and links to the definition and documentation. Since this +# will make the HTML file larger and loading of large files a bit slower, you +# can opt to disable this feature. +# The default value is: YES. +# This tag requires that the tag SOURCE_BROWSER is set to YES. + +SOURCE_TOOLTIPS = YES + +# If the USE_HTAGS tag is set to YES then the references to source code will +# point to the HTML generated by the htags(1) tool instead of doxygen built-in +# source browser. The htags tool is part of GNU's global source tagging system +# (see http://www.gnu.org/software/global/global.html). You will need version +# 4.8.6 or higher. +# +# To use it do the following: +# - Install the latest version of global +# - Enable SOURCE_BROWSER and USE_HTAGS in the config file +# - Make sure the INPUT points to the root of the source tree +# - Run doxygen as normal +# +# Doxygen will invoke htags (and that will in turn invoke gtags), so these +# tools must be available from the command line (i.e. in the search path). +# +# The result: instead of the source browser generated by doxygen, the links to +# source code will now point to the output of htags. +# The default value is: NO. +# This tag requires that the tag SOURCE_BROWSER is set to YES. + +USE_HTAGS = NO + +# If the VERBATIM_HEADERS tag is set the YES then doxygen will generate a +# verbatim copy of the header file for each class for which an include is +# specified. Set to NO to disable this. +# See also: Section \class. +# The default value is: YES. + +VERBATIM_HEADERS = YES + +#--------------------------------------------------------------------------- +# Configuration options related to the alphabetical class index +#--------------------------------------------------------------------------- + +# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index of all +# compounds will be generated. Enable this if the project contains a lot of +# classes, structs, unions or interfaces. +# The default value is: YES. + +ALPHABETICAL_INDEX = YES + +# The COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns in +# which the alphabetical index list will be split. +# Minimum value: 1, maximum value: 20, default value: 5. +# This tag requires that the tag ALPHABETICAL_INDEX is set to YES. + +COLS_IN_ALPHA_INDEX = 5 + +# In case all classes in a project start with a common prefix, all classes will +# be put under the same header in the alphabetical index. The IGNORE_PREFIX tag +# can be used to specify a prefix (or a list of prefixes) that should be ignored +# while generating the index headers. +# This tag requires that the tag ALPHABETICAL_INDEX is set to YES. + +IGNORE_PREFIX = + +#--------------------------------------------------------------------------- +# Configuration options related to the HTML output +#--------------------------------------------------------------------------- + +# If the GENERATE_HTML tag is set to YES doxygen will generate HTML output +# The default value is: YES. + +GENERATE_HTML = YES + +# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. If a +# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of +# it. +# The default directory is: html. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_OUTPUT = + +# The HTML_FILE_EXTENSION tag can be used to specify the file extension for each +# generated HTML page (for example: .htm, .php, .asp). +# The default value is: .html. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_FILE_EXTENSION = .html + +# The HTML_HEADER tag can be used to specify a user-defined HTML header file for +# each generated HTML page. If the tag is left blank doxygen will generate a +# standard header. +# +# To get valid HTML the header file that includes any scripts and style sheets +# that doxygen needs, which is dependent on the configuration options used (e.g. +# the setting GENERATE_TREEVIEW). It is highly recommended to start with a +# default header using +# doxygen -w html new_header.html new_footer.html new_stylesheet.css +# YourConfigFile +# and then modify the file new_header.html. See also section "Doxygen usage" +# for information on how to generate the default header that doxygen normally +# uses. +# Note: The header is subject to change so you typically have to regenerate the +# default header when upgrading to a newer version of doxygen. For a description +# of the possible markers and block names see the documentation. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_HEADER = + +# The HTML_FOOTER tag can be used to specify a user-defined HTML footer for each +# generated HTML page. If the tag is left blank doxygen will generate a standard +# footer. See HTML_HEADER for more information on how to generate a default +# footer and what special commands can be used inside the footer. See also +# section "Doxygen usage" for information on how to generate the default footer +# that doxygen normally uses. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_FOOTER = + +# The HTML_STYLESHEET tag can be used to specify a user-defined cascading style +# sheet that is used by each HTML page. It can be used to fine-tune the look of +# the HTML output. If left blank doxygen will generate a default style sheet. +# See also section "Doxygen usage" for information on how to generate the style +# sheet that doxygen normally uses. +# Note: It is recommended to use HTML_EXTRA_STYLESHEET instead of this tag, as +# it is more robust and this tag (HTML_STYLESHEET) will in the future become +# obsolete. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_STYLESHEET = + +# The HTML_EXTRA_STYLESHEET tag can be used to specify an additional user- +# defined cascading style sheet that is included after the standard style sheets +# created by doxygen. Using this option one can overrule certain style aspects. +# This is preferred over using HTML_STYLESHEET since it does not replace the +# standard style sheet and is therefor more robust against future updates. +# Doxygen will copy the style sheet file to the output directory. For an example +# see the documentation. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_EXTRA_STYLESHEET = + +# The HTML_EXTRA_FILES tag can be used to specify one or more extra images or +# other source files which should be copied to the HTML output directory. Note +# that these files will be copied to the base HTML output directory. Use the +# $relpath^ marker in the HTML_HEADER and/or HTML_FOOTER files to load these +# files. In the HTML_STYLESHEET file, use the file name only. Also note that the +# files will be copied as-is; there are no commands or markers available. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_EXTRA_FILES = + +# The HTML_COLORSTYLE_HUE tag controls the color of the HTML output. Doxygen +# will adjust the colors in the stylesheet and background images according to +# this color. Hue is specified as an angle on a colorwheel, see +# http://en.wikipedia.org/wiki/Hue for more information. For instance the value +# 0 represents red, 60 is yellow, 120 is green, 180 is cyan, 240 is blue, 300 +# purple, and 360 is red again. +# Minimum value: 0, maximum value: 359, default value: 220. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_COLORSTYLE_HUE = 100 + +# The HTML_COLORSTYLE_SAT tag controls the purity (or saturation) of the colors +# in the HTML output. For a value of 0 the output will use grayscales only. A +# value of 255 will produce the most vivid colors. +# Minimum value: 0, maximum value: 255, default value: 100. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_COLORSTYLE_SAT = 50 + +# The HTML_COLORSTYLE_GAMMA tag controls the gamma correction applied to the +# luminance component of the colors in the HTML output. Values below 100 +# gradually make the output lighter, whereas values above 100 make the output +# darker. The value divided by 100 is the actual gamma applied, so 80 represents +# a gamma of 0.8, The value 220 represents a gamma of 2.2, and 100 does not +# change the gamma. +# Minimum value: 40, maximum value: 240, default value: 80. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_COLORSTYLE_GAMMA = 80 + +# If the HTML_TIMESTAMP tag is set to YES then the footer of each generated HTML +# page will contain the date and time when the page was generated. Setting this +# to NO can help when comparing the output of multiple runs. +# The default value is: YES. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_TIMESTAMP = NO + +# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML +# documentation will contain sections that can be hidden and shown after the +# page has loaded. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_DYNAMIC_SECTIONS = NO + +# With HTML_INDEX_NUM_ENTRIES one can control the preferred number of entries +# shown in the various tree structured indices initially; the user can expand +# and collapse entries dynamically later on. Doxygen will expand the tree to +# such a level that at most the specified number of entries are visible (unless +# a fully collapsed tree already exceeds this amount). So setting the number of +# entries 1 will produce a full collapsed tree by default. 0 is a special value +# representing an infinite number of entries and will result in a full expanded +# tree by default. +# Minimum value: 0, maximum value: 9999, default value: 100. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_INDEX_NUM_ENTRIES = 100 + +# If the GENERATE_DOCSET tag is set to YES, additional index files will be +# generated that can be used as input for Apple's Xcode 3 integrated development +# environment (see: http://developer.apple.com/tools/xcode/), introduced with +# OSX 10.5 (Leopard). To create a documentation set, doxygen will generate a +# Makefile in the HTML output directory. Running make will produce the docset in +# that directory and running make install will install the docset in +# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find it at +# startup. See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html +# for more information. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_DOCSET = NO + +# This tag determines the name of the docset feed. A documentation feed provides +# an umbrella under which multiple documentation sets from a single provider +# (such as a company or product suite) can be grouped. +# The default value is: Doxygen generated docs. +# This tag requires that the tag GENERATE_DOCSET is set to YES. + +DOCSET_FEEDNAME = "Doxygen generated docs" + +# This tag specifies a string that should uniquely identify the documentation +# set bundle. This should be a reverse domain-name style string, e.g. +# com.mycompany.MyDocSet. Doxygen will append .docset to the name. +# The default value is: org.doxygen.Project. +# This tag requires that the tag GENERATE_DOCSET is set to YES. + +DOCSET_BUNDLE_ID = org.doxygen.Project + +# The DOCSET_PUBLISHER_ID tag specifies a string that should uniquely identify +# the documentation publisher. This should be a reverse domain-name style +# string, e.g. com.mycompany.MyDocSet.documentation. +# The default value is: org.doxygen.Publisher. +# This tag requires that the tag GENERATE_DOCSET is set to YES. + +DOCSET_PUBLISHER_ID = org.doxygen.Publisher + +# The DOCSET_PUBLISHER_NAME tag identifies the documentation publisher. +# The default value is: Publisher. +# This tag requires that the tag GENERATE_DOCSET is set to YES. + +DOCSET_PUBLISHER_NAME = Publisher + +# If the GENERATE_HTMLHELP tag is set to YES then doxygen generates three +# additional HTML index files: index.hhp, index.hhc, and index.hhk. The +# index.hhp is a project file that can be read by Microsoft's HTML Help Workshop +# (see: http://www.microsoft.com/en-us/download/details.aspx?id=21138) on +# Windows. +# +# The HTML Help Workshop contains a compiler that can convert all HTML output +# generated by doxygen into a single compiled HTML file (.chm). Compiled HTML +# files are now used as the Windows 98 help format, and will replace the old +# Windows help format (.hlp) on all Windows platforms in the future. Compressed +# HTML files also contain an index, a table of contents, and you can search for +# words in the documentation. The HTML workshop also contains a viewer for +# compressed HTML files. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_HTMLHELP = NO + +# The CHM_FILE tag can be used to specify the file name of the resulting .chm +# file. You can add a path in front of the file if the result should not be +# written to the html output directory. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +CHM_FILE = + +# The HHC_LOCATION tag can be used to specify the location (absolute path +# including file name) of the HTML help compiler ( hhc.exe). If non-empty +# doxygen will try to run the HTML help compiler on the generated index.hhp. +# The file has to be specified with full path. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +HHC_LOCATION = + +# The GENERATE_CHI flag controls if a separate .chi index file is generated ( +# YES) or that it should be included in the master .chm file ( NO). +# The default value is: NO. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +GENERATE_CHI = NO + +# The CHM_INDEX_ENCODING is used to encode HtmlHelp index ( hhk), content ( hhc) +# and project file content. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +CHM_INDEX_ENCODING = + +# The BINARY_TOC flag controls whether a binary table of contents is generated ( +# YES) or a normal table of contents ( NO) in the .chm file. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +BINARY_TOC = NO + +# The TOC_EXPAND flag can be set to YES to add extra items for group members to +# the table of contents of the HTML help documentation and to the tree view. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTMLHELP is set to YES. + +TOC_EXPAND = NO + +# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and +# QHP_VIRTUAL_FOLDER are set, an additional index file will be generated that +# can be used as input for Qt's qhelpgenerator to generate a Qt Compressed Help +# (.qch) of the generated HTML documentation. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_QHP = NO + +# If the QHG_LOCATION tag is specified, the QCH_FILE tag can be used to specify +# the file name of the resulting .qch file. The path specified is relative to +# the HTML output folder. +# This tag requires that the tag GENERATE_QHP is set to YES. + +QCH_FILE = + +# The QHP_NAMESPACE tag specifies the namespace to use when generating Qt Help +# Project output. For more information please see Qt Help Project / Namespace +# (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#namespace). +# The default value is: org.doxygen.Project. +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_NAMESPACE = org.doxygen.Project + +# The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating Qt +# Help Project output. For more information please see Qt Help Project / Virtual +# Folders (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#virtual- +# folders). +# The default value is: doc. +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_VIRTUAL_FOLDER = doc + +# If the QHP_CUST_FILTER_NAME tag is set, it specifies the name of a custom +# filter to add. For more information please see Qt Help Project / Custom +# Filters (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom- +# filters). +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_CUST_FILTER_NAME = + +# The QHP_CUST_FILTER_ATTRS tag specifies the list of the attributes of the +# custom filter to add. For more information please see Qt Help Project / Custom +# Filters (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom- +# filters). +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_CUST_FILTER_ATTRS = + +# The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this +# project's filter section matches. Qt Help Project / Filter Attributes (see: +# http://qt-project.org/doc/qt-4.8/qthelpproject.html#filter-attributes). +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHP_SECT_FILTER_ATTRS = + +# The QHG_LOCATION tag can be used to specify the location of Qt's +# qhelpgenerator. If non-empty doxygen will try to run qhelpgenerator on the +# generated .qhp file. +# This tag requires that the tag GENERATE_QHP is set to YES. + +QHG_LOCATION = + +# If the GENERATE_ECLIPSEHELP tag is set to YES, additional index files will be +# generated, together with the HTML files, they form an Eclipse help plugin. To +# install this plugin and make it available under the help contents menu in +# Eclipse, the contents of the directory containing the HTML and XML files needs +# to be copied into the plugins directory of eclipse. The name of the directory +# within the plugins directory should be the same as the ECLIPSE_DOC_ID value. +# After copying Eclipse needs to be restarted before the help appears. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_ECLIPSEHELP = NO + +# A unique identifier for the Eclipse help plugin. When installing the plugin +# the directory name containing the HTML and XML files should also have this +# name. Each documentation set should have its own identifier. +# The default value is: org.doxygen.Project. +# This tag requires that the tag GENERATE_ECLIPSEHELP is set to YES. + +ECLIPSE_DOC_ID = org.doxygen.Project + +# If you want full control over the layout of the generated HTML pages it might +# be necessary to disable the index and replace it with your own. The +# DISABLE_INDEX tag can be used to turn on/off the condensed index (tabs) at top +# of each HTML page. A value of NO enables the index and the value YES disables +# it. Since the tabs in the index contain the same information as the navigation +# tree, you can set this option to YES if you also set GENERATE_TREEVIEW to YES. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +DISABLE_INDEX = NO + +# The GENERATE_TREEVIEW tag is used to specify whether a tree-like index +# structure should be generated to display hierarchical information. If the tag +# value is set to YES, a side panel will be generated containing a tree-like +# index structure (just like the one that is generated for HTML Help). For this +# to work a browser that supports JavaScript, DHTML, CSS and frames is required +# (i.e. any modern browser). Windows users are probably better off using the +# HTML help feature. Via custom stylesheets (see HTML_EXTRA_STYLESHEET) one can +# further fine-tune the look of the index. As an example, the default style +# sheet generated by doxygen has an example that shows how to put an image at +# the root of the tree instead of the PROJECT_NAME. Since the tree basically has +# the same information as the tab index, you could consider setting +# DISABLE_INDEX to YES when enabling this option. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +GENERATE_TREEVIEW = NO + +# The ENUM_VALUES_PER_LINE tag can be used to set the number of enum values that +# doxygen will group on one line in the generated HTML documentation. +# +# Note that a value of 0 will completely suppress the enum values from appearing +# in the overview section. +# Minimum value: 0, maximum value: 20, default value: 4. +# This tag requires that the tag GENERATE_HTML is set to YES. + +ENUM_VALUES_PER_LINE = 4 + +# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be used +# to set the initial width (in pixels) of the frame in which the tree is shown. +# Minimum value: 0, maximum value: 1500, default value: 250. +# This tag requires that the tag GENERATE_HTML is set to YES. + +TREEVIEW_WIDTH = 250 + +# When the EXT_LINKS_IN_WINDOW option is set to YES doxygen will open links to +# external symbols imported via tag files in a separate window. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +EXT_LINKS_IN_WINDOW = NO + +# Use this tag to change the font size of LaTeX formulas included as images in +# the HTML documentation. When you change the font size after a successful +# doxygen run you need to manually remove any form_*.png images from the HTML +# output directory to force them to be regenerated. +# Minimum value: 8, maximum value: 50, default value: 10. +# This tag requires that the tag GENERATE_HTML is set to YES. + +FORMULA_FONTSIZE = 10 + +# Use the FORMULA_TRANPARENT tag to determine whether or not the images +# generated for formulas are transparent PNGs. Transparent PNGs are not +# supported properly for IE 6.0, but are supported on all modern browsers. +# +# Note that when changing this option you need to delete any form_*.png files in +# the HTML output directory before the changes have effect. +# The default value is: YES. +# This tag requires that the tag GENERATE_HTML is set to YES. + +FORMULA_TRANSPARENT = YES + +# Enable the USE_MATHJAX option to render LaTeX formulas using MathJax (see +# http://www.mathjax.org) which uses client side Javascript for the rendering +# instead of using prerendered bitmaps. Use this if you do not have LaTeX +# installed or if you want to formulas look prettier in the HTML output. When +# enabled you may also need to install MathJax separately and configure the path +# to it using the MATHJAX_RELPATH option. +# The default value is: NO. +# This tag requires that the tag GENERATE_HTML is set to YES. + +USE_MATHJAX = YES + +# When MathJax is enabled you can set the default output format to be used for +# the MathJax output. See the MathJax site (see: +# http://docs.mathjax.org/en/latest/output.html) for more details. +# Possible values are: HTML-CSS (which is slower, but has the best +# compatibility), NativeMML (i.e. MathML) and SVG. +# The default value is: HTML-CSS. +# This tag requires that the tag USE_MATHJAX is set to YES. + +MATHJAX_FORMAT = HTML-CSS + +# When MathJax is enabled you need to specify the location relative to the HTML +# output directory using the MATHJAX_RELPATH option. The destination directory +# should contain the MathJax.js script. For instance, if the mathjax directory +# is located at the same level as the HTML output directory, then +# MATHJAX_RELPATH should be ../mathjax. The default value points to the MathJax +# Content Delivery Network so you can quickly see the result without installing +# MathJax. However, it is strongly recommended to install a local copy of +# MathJax from http://www.mathjax.org before deployment. +# The default value is: http://cdn.mathjax.org/mathjax/latest. +# This tag requires that the tag USE_MATHJAX is set to YES. + +MATHJAX_RELPATH = http://cdn.mathjax.org/mathjax/latest + +# The MATHJAX_EXTENSIONS tag can be used to specify one or more MathJax +# extension names that should be enabled during MathJax rendering. For example +# MATHJAX_EXTENSIONS = TeX/AMSmath TeX/AMSsymbols +# This tag requires that the tag USE_MATHJAX is set to YES. + +MATHJAX_EXTENSIONS = + +# The MATHJAX_CODEFILE tag can be used to specify a file with javascript pieces +# of code that will be used on startup of the MathJax code. See the MathJax site +# (see: http://docs.mathjax.org/en/latest/output.html) for more details. For an +# example see the documentation. +# This tag requires that the tag USE_MATHJAX is set to YES. + +MATHJAX_CODEFILE = + +# When the SEARCHENGINE tag is enabled doxygen will generate a search box for +# the HTML output. The underlying search engine uses javascript and DHTML and +# should work on any modern browser. Note that when using HTML help +# (GENERATE_HTMLHELP), Qt help (GENERATE_QHP), or docsets (GENERATE_DOCSET) +# there is already a search function so this one should typically be disabled. +# For large projects the javascript based search engine can be slow, then +# enabling SERVER_BASED_SEARCH may provide a better solution. It is possible to +# search using the keyboard; to jump to the search box use + S +# (what the is depends on the OS and browser, but it is typically +# , /