Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hack to support > 2GB tensors #1558

Merged
merged 1 commit into from Jun 9, 2021
Merged

Conversation

TomWildenhain-Microsoft
Copy link
Contributor

Signed-off-by: Tom Wildenhain tomwi@microsoft.com

Signed-off-by: Tom Wildenhain <tomwi@microsoft.com>
@@ -105,7 +105,7 @@ def get_value_attr(self, external_tensor_storage=None):
if external_tensor_storage is None or a.type != AttributeProto.TENSOR:
return a
if np.product(a.t.dims) > external_tensor_storage.external_tensor_size_threshold:
a = copy.copy(a)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

protobuf copy serializes the tensor end raises an error is > 2GB.

@TomWildenhain-Microsoft TomWildenhain-Microsoft merged commit ab816b3 into master Jun 9, 2021
@TomWildenhain-Microsoft TomWildenhain-Microsoft deleted the tom/2gb_tensors2 branch June 9, 2021 21:44
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.

None yet

2 participants