Skip to content

Conversation

@abhishek-singh591
Copy link
Contributor

No description provided.

- update the hidden_states, and fix for onnx model
"""

def get_repeated_layer_class(self) -> Type[nn.Module]:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rename to get_submodules_for_export

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

okay will do.

Comment on lines +80 to +81
cos = torch.cat([cos[0, ..., 0:32], cos[0, ..., 32:80], cos[0, ..., 80:128]], dim=-1).unsqueeze(0)
sin = torch.cat([sin[0, ..., 0:32], sin[0, ..., 32:80], sin[0, ..., 80:128]], dim=-1).unsqueeze(0)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why hardcoding?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To get around (Split: Non-constant split tensor not supported) issue, although some tests are still pending. will let you know here.

try:
_C._jit_pass_onnx_track_scope_attributes(graph, onnx_attrs)
except Exception as e:
logger.warning(f"Failed to track ONNX scope attributes: {e}. Skipping this step.")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why warning?
We should fail here if _C._jit_pass_onnx_track_scope_attributes(graph, onnx_attrs) fails

Copy link
Contributor Author

@abhishek-singh591 abhishek-singh591 Jan 7, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a hacky workaround for the issue. if you remember previously, we use to pass empty onnx_attrs. for VLMs there are additional issue now. We are skipping the failing step though it does not impact model execution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants