Args: Compares the current bitsandbytes version to a given reference with an operation. operation (`str`): A string representation of an operator, such as `">"` or `"<="` version (`str`): A version string
(operation: str, version: str)
| 795 | |
| 796 | @cache |
| 797 | def is_bitsandbytes_version(operation: str, version: str): |
| 798 | """ |
| 799 | Args: |
| 800 | Compares the current bitsandbytes version to a given reference with an operation. |
| 801 | operation (`str`): |
| 802 | A string representation of an operator, such as `">"` or `"<="` |
| 803 | version (`str`): |
| 804 | A version string |
| 805 | """ |
| 806 | if not _bitsandbytes_available: |
| 807 | return False |
| 808 | return compare_versions(parse(_bitsandbytes_version), operation, version) |
| 809 | |
| 810 | |
| 811 | @cache |
no test coverage detected
searching dependent graphs…