OpenBMB / OpenBMB/BMTrain

[replace usage of tensor.storage()]

Open
#95 0 comments 0 reactions 1 assignee View on GitHub

@JerryYin777 is already working on this.

Since Aug 18, 2023.

enhancement
Dominant language
Python
Stars
624
Forks
89
PR merge metrics
No merged PRs in 30d

Description

Many thanks for your fantastic project. Just a kind suggestion: while using bmtrain, it will throw out a lot warnings and they are all corresponding to torch.storage as following:

/opt/conda/envs/compression/lib/python3.10/site-packages/bmtrain/store.py:178: UserWarning: TypedStorage is deprecated. It will be removed in the future and UntypedStorage will be the only storage class. This should only matter to you if you are using storages directly. To access UntypedStorage directly, use tensor.untyped_storage() instead of tensor.storage()

it seems that it is related to feature of torch. You may replace all the tensor.storage() with tensor.untyped_storage() so that we can get the clean logs:)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.