Skip to content

Commit 57dbf41

Browse files
Conchylicultorcopybara-github
authored andcommitted
Minor formatting change for features.Text
PiperOrigin-RevId: 258590715
1 parent 163b494 commit 57dbf41

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

tensorflow_datasets/core/features/text_feature.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,4 +157,6 @@ def _encoder_cls(self):
157157
return self._encoder_config and self._encoder_config.encoder_cls
158158

159159
def _additional_repr_info(self):
160+
if self.encoder is None:
161+
return {}
160162
return {"encoder": repr(self.encoder)}

0 commit comments

Comments
 (0)