From e8efd984a81c198cad697434a1041e4cee6979df Mon Sep 17 00:00:00 2001 From: DucAnh Date: Wed, 8 Jul 2020 16:40:13 +0900 Subject: [PATCH] update code --- line_recognition.sh | 9 --------- requirements.txt | 3 ++- utils.py | 6 ------ 3 files changed, 2 insertions(+), 16 deletions(-) delete mode 100755 line_recognition.sh diff --git a/line_recognition.sh b/line_recognition.sh deleted file mode 100755 index 6707bca..0000000 --- a/line_recognition.sh +++ /dev/null @@ -1,9 +0,0 @@ -#!/bin/bash - -export CUDA_VISIBLE_DEVICES=0 -python -u ./translate_line.py -k 10 ./pretrain/WAP_params.pkl \ - ./pretrain/kindai_voc.txt \ - ./data_kindai/val.pkl \ - ./data_kindai/caption_val.txt \ - ./result/test_decode_result.txt \ - ./result/test.wer diff --git a/requirements.txt b/requirements.txt index e665661..54f6e2a 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,6 +1,7 @@ -torch==0.4.1.post2 +torch==1.4.0 torchvision==0.2.1 opencv-python==3.4.2.17 scikit-image==0.14.2 scipy==1.1.0 Polygon3 + diff --git a/utils.py b/utils.py index 7e58750..4962aa0 100644 --- a/utils.py +++ b/utils.py @@ -5,12 +5,6 @@ import sys import pickle as pkl import torch from torch import nn -from Augmentor.Operations import Distort, Skew, RandomBrightness -from PIL import Image - -d = Distort(probability=0.2, grid_height=15, grid_width=15, magnitude=10) -sk = Skew(probability=1.0, skew_type='TILT_LEFT_RIGHT', magnitude=0.15) -br = RandomBrightness(probability = 1.0, min_factor = 0.9, max_factor = 1.1) # load data def dataIterator(feature_file, label_file, dictionary, batch_size, batch_Imagesize, maxlen, maxImagesize):