Skip to content

Fix kernel registration doc #815

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

Closed
wants to merge 1 commit into from

Conversation

larryliu0820
Copy link
Contributor

Summary: As titled

Reviewed By: dbort

Differential Revision: D50145731

Summary: As titled

Reviewed By: dbort

Differential Revision: D50145731
@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Oct 10, 2023
@netlify
Copy link

netlify bot commented Oct 10, 2023

Deploy Preview for resplendent-gnome-14e531 ready!

Name Link
🔨 Latest commit 6b2935e
🔍 Latest deploy log https://app.netlify.com/sites/resplendent-gnome-14e531/deploys/6525df8138e0be000878fd29
😎 Deploy Preview https://deploy-preview-815--resplendent-gnome-14e531.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D50145731

@facebook-github-bot
Copy link
Contributor

This pull request has been merged in d845671.

Gasoonjia pushed a commit that referenced this pull request Jul 30, 2024
…815)

By wrapping attempt to load a model with `try {} catch (std::runtime_error) {}` and attempting to create model on GPU first, as attempt to load CPU model on CUDA destroys CUDA context (bugs/fixes againt PyTorch are coming, tracked in pytorch/pytorch#126547 )

Also, fix two bugs in the repo:
 - Initialize `Tokenizer::initialized_` to false
 - Change name of the tokenizer file in a workflow from `tokenizer.bin` to `tokenizer.model`


Fixes pytorch/torchchat#709

Test plan:
```
python3 torchchat.py export --checkpoint-path checkpoints/stories15M/model.pth --output-dso-path model_cpu.so --device cpu
python3 torchchat.py export --checkpoint-path checkpoints/stories15M/model.pth --output-dso-path model.so
./cmake-out/aoti_run ./model.so -z checkpoints/stories15M/tokenizer.model
./cmake-out/aoti_run ./model_cpu.so -z checkpoints/stories15M/tokenizer.model
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported Merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants