[modular] fixes! (#33820)

* fix converter for function definitions

* small changes

* no prints

* style
This commit is contained in:
Arthur
2024-09-30 16:43:55 +02:00
committed by GitHub
parent 1d29a75a6a
commit 1dba608df9
9 changed files with 322 additions and 247 deletions

View File

@@ -1,8 +1,8 @@
# 🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨
# This file was automatically generated from <path_to_diff_file.py>.
# This file was automatically generated from <path_to_modular_file.py>.
# Do NOT edit this file manually as any edits will be overwritten by the generation of
# the file from the diff. If any change should be done, please apply the change to the
# diff.py file directly. One of our CI enforces this
# the file from the modular. If any change should be done, please apply the change to the
# modular_xxx.py file directly. One of our CI enforces this
# 🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨
import math
import os
@@ -1027,6 +1027,7 @@ class DummyBertModel(DummyBertPreTrainedModel):
if not return_dict:
return (sequence_output, pooled_output) + encoder_outputs[1:]
return super().forward(input_ids)
return BaseModelOutputWithPoolingAndCrossAttentions(
last_hidden_state=sequence_output,