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

For preprocessing progress tracking or other tasks that takes lots of time to run #41

Open
fmohebi opened this issue Jul 12, 2024 · 0 comments

Comments

@fmohebi
Copy link

fmohebi commented Jul 12, 2024

If the preprocess function takes too long to run, feel free to add a progress bar so that we are keep updated on the progress:
First install the tqdm package:
%pip install tqdm
And don’t forget to load it to your notebook:
from tqdm import tqdm
Then update the preprocess function, change the apply function to:
df[new_col] = df[text_col].progress_apply(process_text)
Finally add the following line before we run the preprocess function:
tqdm.pandas()
df = preprocess(df, text_col='selftext', new_col='pp_text')

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

1 participant