-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(rotary,internlm): add DeepLinkApplyRotaryEmb (fallback unimpleme…
…nted)
- Loading branch information
Showing
5 changed files
with
73 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,14 @@ | ||
# Copyright (c) 2024, DeepLink. | ||
|
||
try: | ||
from .deeplink import DeepLinkApplyRotaryEmbQKV_ | ||
from .deeplink import DeepLinkApplyRotaryEmbQKV_, DeepLinkApplyRotaryEmb | ||
except: | ||
print( | ||
"[deeplink_ext] rotary is not implemented in diopi. Falling back to the slower implementation.\n", | ||
end="", | ||
) | ||
from .fallback import ApplyRotaryEmbQKV_ as DeepLinkApplyRotaryEmbQKV_ | ||
from .fallback import ( | ||
ApplyRotaryEmbQKV_ as DeepLinkApplyRotaryEmbQKV_, | ||
ApplyRotaryEmb as DeepLinkApplyRotaryEmb, | ||
) | ||
from . import fallback |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
# Copyright (c) 2024, DeepLink. | ||
|
||
from .fallback import ApplyRotaryEmbQKV_ | ||
from .fallback import ApplyRotaryEmbQKV_, ApplyRotaryEmb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters