Commit 7cc1e78
committed
fix: add is_compileable attribute to HFInferenceParams for transformers 5.4+
transformers >= 5.4 checks cache.is_compileable in generate(). The custom
HFInferenceParams class (TE-based cache) did not implement this attribute,
causing AttributeError during test_generate_with_cache tests.
Set is_compileable = False since this cache type is not compatible with
torch.compile generate().
Tested locally:
- models/mixtral: 52 passed, 3 skipped, 26 xfailed (3 local-only OOM on 32GB GPU, pass on CI L4)
- recipes/mixtral_native_te: 7 passed
- recipes/opengenome2_mixtral_native_te: 20 passed
Signed-off-by: svc-bionemo <267129667+svc-bionemo@users.noreply.github.com>1 parent 376a00f commit 7cc1e78
4 files changed
Lines changed: 6 additions & 5 deletions
File tree
- bionemo-recipes
- models/mixtral
- recipes
- mixtral_native_te
- opengenome2_mixtral_native_te
- ci/scripts
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
880 | 880 | | |
881 | 881 | | |
882 | 882 | | |
| 883 | + | |
| 884 | + | |
883 | 885 | | |
884 | 886 | | |
885 | 887 | | |
| |||
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
886 | 886 | | |
887 | 887 | | |
888 | 888 | | |
| 889 | + | |
| 890 | + | |
889 | 891 | | |
890 | 892 | | |
891 | 893 | | |
| |||
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
880 | 880 | | |
881 | 881 | | |
882 | 882 | | |
| 883 | + | |
| 884 | + | |
883 | 885 | | |
884 | 886 | | |
885 | 887 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
205 | 205 | | |
206 | 206 | | |
207 | 207 | | |
208 | | - | |
209 | | - | |
210 | | - | |
211 | | - | |
212 | | - | |
213 | 208 | | |
214 | 209 | | |
215 | 210 | | |
| |||
0 commit comments