Skip to content

feature/stat-script#5

Open
cheakimsemao wants to merge 2 commits intomasterfrom
feature/stat-script
Open

feature/stat-script#5
cheakimsemao wants to merge 2 commits intomasterfrom
feature/stat-script

Conversation

@cheakimsemao
Copy link
Copy Markdown

@cheakimsemao cheakimsemao commented Aug 9, 2022

added stat script

@cheakimsemao cheakimsemao added the enhancement New feature or request label Aug 9, 2022
@cheakimsemao cheakimsemao requested a review from Socret360 August 9, 2022 03:35
@cheakimsemao cheakimsemao self-assigned this Aug 9, 2022
@cheakimsemao cheakimsemao changed the title added stat script feature/stat-script Aug 9, 2022
Copy link
Copy Markdown
Collaborator

@Socret360 Socret360 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Don't need to have is_directory function. os.path.isdir already returns a boolean.
  2. Update the description in parser.add_argument and AssertError description too.
  3. Don't + "/" use os.path.join instead. + "/" will cause an error on windows.
  4. The code goes through the entire dataset twice. Once for reading the text boxes and onces for counting the characters. You can make adjust to only goes through the dataset once.
  5. The function and variable names that has "word" in them is not accurate. Each textboxes contains a line (not a word). Should rename strip_words and split_words to strip_line and split_line respectively.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants