johnsmith0031 / alpaca_lora_4bit

MIT License
533 stars 84 forks source link

Remove import of custom_autotune (it's triton-dependent, triton depen… #123

Closed alex4321 closed 1 year ago

alex4321 commented 1 year ago

Since triton package dependency is optional:

https://github.com/johnsmith0031/alpaca_lora_4bit/blob/winglian-setup_pip/setup.py#L25

    extras_require={
        'triton': 'triton',
    },

I think we should't have the following import:

https://github.com/alex4321/alpaca_lora_4bit/blob/winglian-setup_pip/src/alpaca_lora_4bit/__init__.py#L5

from . import custom_autotune

Because it's a triton-depending module: https://github.com/johnsmith0031/alpaca_lora_4bit/blob/winglian-setup_pip/src/alpaca_lora_4bit/custom_autotune.py#L12


import triton

class Autotuner(triton.KernelInterface):

So I moved import to implementation-depending comments section

alex4321 commented 1 year ago

@winglian @johnsmith0031

johnsmith0031 commented 1 year ago

Thanks for the fix!