Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Data format? #19

Open
sajedamurra opened this issue May 5, 2021 · 2 comments
Open

Data format? #19

sajedamurra opened this issue May 5, 2021 · 2 comments

Comments

@sajedamurra
Copy link

sajedamurra commented May 5, 2021

any information about training data structure?

@lyc728
Copy link

lyc728 commented Dec 7, 2021

any information about training data structure?
Did you fix it ?

@masc-it
Copy link

masc-it commented Dec 15, 2021

You can infer it from here.

def __getitem__(self, index):
        '''
        line: image path\tlabel
        '''
        line = self.lines[index]
        img_path, label_y_str = line.strip('\n').split('\t')
        img = cv2.imread(img_path) / 255.

In your dataset.txt each line should have this structure:
path-to-img1.jpg\ttext-inside-your-img1
path-to-img2.jpg\ttext-inside-your-img2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants