Upload processors.py with huggingface_hub
Browse files- processors.py +9 -0
processors.py
ADDED
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
from .operator import FieldOperator
|
2 |
+
|
3 |
+
|
4 |
+
class ToString(FieldOperator):
|
5 |
+
def process(self, instance):
|
6 |
+
return str(instance)
|
7 |
+
|
8 |
+
|
9 |
+
# add_to_catalog(ToString('prediction'), 'processors', 'to_string')
|