bhadresh-savani
commited on
Commit
·
7ec8067
1
Parent(s):
b058840
added tf and flax support
Browse files- config.json +2 -2
- convert_pytorch_to_flax.py +3 -0
- flax_model.msgpack +3 -0
- tf_model.h5 +3 -0
config.json
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
{
|
2 |
-
"_name_or_path": "
|
3 |
"architectures": [
|
4 |
"ElectraForTokenClassification"
|
5 |
],
|
@@ -46,7 +46,7 @@
|
|
46 |
"summary_type": "first",
|
47 |
"summary_use_proj": true,
|
48 |
"torch_dtype": "float32",
|
49 |
-
"transformers_version": "4.
|
50 |
"type_vocab_size": 2,
|
51 |
"use_cache": true,
|
52 |
"vocab_size": 30522
|
|
|
1 |
{
|
2 |
+
"_name_or_path": "ElectraForTokenClassificationNER",
|
3 |
"architectures": [
|
4 |
"ElectraForTokenClassification"
|
5 |
],
|
|
|
46 |
"summary_type": "first",
|
47 |
"summary_use_proj": true,
|
48 |
"torch_dtype": "float32",
|
49 |
+
"transformers_version": "4.19.0.dev0",
|
50 |
"type_vocab_size": 2,
|
51 |
"use_cache": true,
|
52 |
"vocab_size": 30522
|
convert_pytorch_to_flax.py
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
from transformers import FlaxAutoModelForTokenClassification
|
2 |
+
model = FlaxAutoModelForTokenClassification.from_pretrained("./", from_pt=True)
|
3 |
+
model.save_pretrained("./")
|
flax_model.msgpack
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:582ff1ae9063765443c6f6fed56d2cd82b913025abdd6d37ac66f0b9d4539cb9
|
3 |
+
size 435601421
|
tf_model.h5
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:004becf31e3f33494b1b76ea91193c7b4a40448b0e4a86f358644241a9f41cf8
|
3 |
+
size 435882528
|