Comments (4)
Dear HHansi
Thanks for looking into this. I've tried this and also got stuck at the same place. I think I found that the script only works for models trained with the original bert implementation (found here) and not with the TF2.x implementation. Converting our model to PyTorch is very high on my todo-list though. The script can still be used, one just has to adapt to the new variable names in BERT TF2.x. Let me know if you find a suitable script - PRs are always welcome ofc 😄
from covid-twitter-bert.
Dear mar-muel,
Thank you for your response.
I'll let you know if I could find a solution.
from covid-twitter-bert.
Hi Hansi
Just to let you know that I have now converted the model into a native PyTorch model (I wrote my own script, see here, if you're interested).
You can now use our model like any other model, e.g.:
from transformers import BertForPreTraining
model = BertForPreTraining.from_pretrained('digitalepidemiologylab/covid-twitter-bert')
Hope this helps!
from covid-twitter-bert.
Hi Martin,
Thank you very much.
This really helps a lot.
from covid-twitter-bert.
Related Issues (17)
- Add link to preprint in readme HOT 1
- Masked worked prediction returning "unused" tokens HOT 3
- CUDA out of memory Error from loading CT-Bert directly from Huggingface HOT 2
- License? HOT 2
- Failed to download dataset HOT 1
- Strategies for downstream NER tasks with more label
- Make one over CORD-19 HOT 1
- the model architecture of COVID-Twitter-BERT v2 MNLI
- No proper encodings for covid-related terms HOT 1
- Failed to find data adapter HOT 2
- A few observations. HOT 2
- Logic behind [UNK] token for pronouns HOT 2
- COVID Category (CC) dataset has 4 invalid formats for Tweet ID HOT 1
- Loss HOT 2
- What are the tokens for Usernames and Hastags in the BERT vocabulary? HOT 1
- Download Twitter-Sentiment SemEval HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from covid-twitter-bert.