Skip to content

Commit

Permalink
🔀 merge with latest grailed db changes
Browse files Browse the repository at this point in the history
  • Loading branch information
jadewang26 committed Dec 7, 2024
1 parent 65037d3 commit 4dd32c7
Show file tree
Hide file tree
Showing 2 changed files with 60 additions and 0 deletions.
11 changes: 11 additions & 0 deletions color_analysis/download_dataset.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import os
import pandas as pd

# df = pd.read_csv(f'grailed-dataset/styles_grailed.csv')
# print(df.head())
# print(len(df.loc[df["Department"]=="womenswear"]))
num_hits = 40
page_range = 500
for department in ["menswear", "womenswear"]:
for page_num in range(page_range):
os.system(f"python3 get_grailed_items.py -g {department} -n {num_hits} -p {page_num}")
49 changes: 49 additions & 0 deletions tests/database_contents.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
SELECT COUNT(*) FROM items WHERE ColorSeason="spring" AND MasterCategory="tops"; --217
SELECT COUNT(*) FROM items WHERE ColorSeason="summer" AND MasterCategory="tops"; --132
SELECT COUNT(*) FROM items WHERE ColorSeason="autumn" AND MasterCategory="tops"; --220
SELECT COUNT(*) FROM items WHERE ColorSeason="winter" AND MasterCategory="tops"; --160

SELECT COUNT(*) FROM items WHERE ColorSeason="spring" AND MasterCategory="bottoms"; --84
SELECT COUNT(*) FROM items WHERE ColorSeason="summer" AND MasterCategory="bottoms"; --54
SELECT COUNT(*) FROM items WHERE ColorSeason="autumn" AND MasterCategory="bottoms"; --72
SELECT COUNT(*) FROM items WHERE ColorSeason="winter" AND MasterCategory="bottoms"; --54

SELECT COUNT(*) FROM items WHERE ColorSeason="spring" AND MasterCategory="footwear"; --13
SELECT COUNT(*) FROM items WHERE ColorSeason="summer" AND MasterCategory="footwear"; --7
SELECT COUNT(*) FROM items WHERE ColorSeason="autumn" AND MasterCategory="footwear"; --22
SELECT COUNT(*) FROM items WHERE ColorSeason="winter" AND MasterCategory="footwear"; --11

SELECT COUNT(*) FROM items WHERE ColorSeason="spring" AND MasterCategory="outerwear"; --37
SELECT COUNT(*) FROM items WHERE ColorSeason="summer" AND MasterCategory="outerwear"; --30
SELECT COUNT(*) FROM items WHERE ColorSeason="autumn" AND MasterCategory="outerwear"; --51
SELECT COUNT(*) FROM items WHERE ColorSeason="winter" AND MasterCategory="outerwear"; --35

SELECT COUNT(*) FROM items WHERE ColorSeason="spring" AND MasterCategory="accessories"; --160
SELECT COUNT(*) FROM items WHERE ColorSeason="summer" AND MasterCategory="accessories"; --87
SELECT COUNT(*) FROM items WHERE ColorSeason="autumn" AND MasterCategory="accessories"; --137
SELECT COUNT(*) FROM items WHERE ColorSeason="winter" AND MasterCategory="accessories"; --99

SELECT COUNT(*) FROM items WHERE ColorSeason="spring" AND MasterCategory="womens_tops"; --231
SELECT COUNT(*) FROM items WHERE ColorSeason="summer" AND MasterCategory="womens_tops"; --125
SELECT COUNT(*) FROM items WHERE ColorSeason="autumn" AND MasterCategory="womens_tops"; --163
SELECT COUNT(*) FROM items WHERE ColorSeason="winter" AND MasterCategory="womens_tops"; --133

SELECT COUNT(*) FROM items WHERE ColorSeason="spring" AND MasterCategory="womens_bottoms"; --116
SELECT COUNT(*) FROM items WHERE ColorSeason="summer" AND MasterCategory="womens_bottoms"; --69
SELECT COUNT(*) FROM items WHERE ColorSeason="autumn" AND MasterCategory="womens_bottoms"; --85
SELECT COUNT(*) FROM items WHERE ColorSeason="winter" AND MasterCategory="womens_bottoms"; --57

SELECT COUNT(*) FROM items WHERE ColorSeason="spring" AND MasterCategory="womens_footwear"; --56
SELECT COUNT(*) FROM items WHERE ColorSeason="summer" AND MasterCategory="womens_footwear"; --66
SELECT COUNT(*) FROM items WHERE ColorSeason="autumn" AND MasterCategory="womens_footwear"; --43
SELECT COUNT(*) FROM items WHERE ColorSeason="winter" AND MasterCategory="womens_footwear"; --39

SELECT COUNT(*) FROM items WHERE ColorSeason="spring" AND MasterCategory="womens_outerwear"; --81
SELECT COUNT(*) FROM items WHERE ColorSeason="summer" AND MasterCategory="womens_outerwear"; --63
SELECT COUNT(*) FROM items WHERE ColorSeason="autumn" AND MasterCategory="womens_outerwear"; --56
SELECT COUNT(*) FROM items WHERE ColorSeason="winter" AND MasterCategory="womens_outerwear"; --41

SELECT COUNT(*) FROM items WHERE ColorSeason="spring" AND MasterCategory="womens_accessories"; --81
SELECT COUNT(*) FROM items WHERE ColorSeason="summer" AND MasterCategory="womens_accessories"; --66
SELECT COUNT(*) FROM items WHERE ColorSeason="autumn" AND MasterCategory="womens_accessories"; --67
SELECT COUNT(*) FROM items WHERE ColorSeason="winter" AND MasterCategory="womens_accessories"; --38

0 comments on commit 4dd32c7

Please sign in to comment.