Create model/configuration_maskrcnn.py
Browse files
model/configuration_maskrcnn.py
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
from transformers import PretrainedConfig
|
| 2 |
+
|
| 3 |
+
class MaskRCNNConfig(PretrainedConfig):
|
| 4 |
+
model_type = "maskrcnn"
|
| 5 |
+
|
| 6 |
+
def __init__(
|
| 7 |
+
self,
|
| 8 |
+
num_classes=91,
|
| 9 |
+
hidden_layer=256,
|
| 10 |
+
**kwargs
|
| 11 |
+
):
|
| 12 |
+
super().__init__(**kwargs)
|
| 13 |
+
self.num_classes = num_classes
|
| 14 |
+
self.hidden_layer = hidden_layer
|