From a3da05829c2756c42f45a41572a9a0f2217d9d6a Mon Sep 17 00:00:00 2001 From: hanhxiao Date: Fri, 11 Oct 2019 10:34:26 +0800 Subject: [PATCH] fix(flow): fix flow unit test --- tests/test_gnes_flow.py | 2 +- tests/yaml/flow-transformer.yml | 9 +-------- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/tests/test_gnes_flow.py b/tests/test_gnes_flow.py index a5ec5f3f..b4c68711 100644 --- a/tests/test_gnes_flow.py +++ b/tests/test_gnes_flow.py @@ -144,7 +144,7 @@ def _test_query_flow(self): with flow.build(backend='process') as f, open(self.test_file, encoding='utf8') as fp: f.query(bytes_gen=[v.encode() for v in fp][:10]) - @unittest.SkipTest + # @unittest.SkipTest def test_index_query_flow(self): self._test_index_flow() print('indexing finished') diff --git a/tests/yaml/flow-transformer.yml b/tests/yaml/flow-transformer.yml index f32b1d56..ba5b17f9 100644 --- a/tests/yaml/flow-transformer.yml +++ b/tests/yaml/flow-transformer.yml @@ -1,13 +1,6 @@ !PipelineEncoder components: - - !PyTorchTransformers - parameters: - model_dir: $TORCH_TRANSFORMERS_MODEL - model_name: bert-base-uncased - - !PoolingEncoder - parameters: - pooling_strategy: REDUCE_MEAN - backend: torch + - !CharEmbeddingEncoder {} gnes_config: name: my_transformer # a customized name is_trained: true # indicate the model has been trained