Browse Source

Revert "delete online Data Getter and Iter"

This reverts commit 9b21071c8d.
tags/v0.4.10
Yige Xu 5 years ago
parent
commit
30180b91e1
1 changed files with 13 additions and 0 deletions
  1. +13
    -0
      fastNLP/core/batch.py

+ 13
- 0
fastNLP/core/batch.py View File

@@ -201,6 +201,19 @@ class TorchLoaderIter(BatchIter):
self.batch_size = dataset.batch_size


class OnlineDataGettter:
# TODO
pass


class OnlineDataIter(BatchIter):
# TODO
def __init__(self, dataset, batch_size=1, buffer_size=10000, sampler=None, as_numpy=False,
num_workers=0, pin_memory=False, drop_last=False,
timeout=0, worker_init_fn=None, **kwargs):
super().__init__()


def _to_tensor(batch, field_dtype):
"""



Loading…
Cancel
Save