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

Memory usage too much #15

Closed
us opened this issue Feb 24, 2020 · 1 comment
Closed

Memory usage too much #15

us opened this issue Feb 24, 2020 · 1 comment

Comments

@us
Copy link

us commented Feb 24, 2020

I tried the Find-Look-Alike-Celebrities.ipynb on colab but on
df['pixels'] = df['full_path'].apply(getImagePixels)
this line give a memory error. Colab has 25gb memory.
How can I avoid that?

@serengil
Copy link
Owner

serengil commented Feb 27, 2020

You might apply filter on df based on gender. I mean that if you would like to find the one look-alike you and your gender is male, then discard female instances in the data frame. In this way, you can decrease the number of instances to the half.

df = df[df['gender'] >= 1] #0: man, 1: woman

Also, increasing the face score will decrease the number of instances as well.

df = df[df['face_score'] >= 3]

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

2 participants