Skip to content

Instantly share code, notes, and snippets.

We can make this file beautiful and searchable if this error is corrected: It looks like row 4 should actually have 8 columns, instead of 5 in line 3.
query_no,query,cardinality_predict,cardinality_true,q_error,latency_ms,generated_spn_calls,latency_generated_code
0,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 2 AND title.series_years >= 1340 AND title.production_year <= 2004.0;",10333,11637,1.1261976192780412,39.27454399945418,0,0.0
1,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.phonetic_code = 16773 AND title.kind_id = 1 AND movie_companies.company_type_id = 1 AND movie_info_idx.info_type_id = 101;",117,383,3.2735042735042734,38.96145999988221,0,0.0
2,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 4 AND title.phonetic_code <= 16924 AND title.production_year >= 1987.0 AND movie_companies.company_type_id = 1;",37736,79017,2.093942124231
We can make this file beautiful and searchable if this error is corrected: It looks like row 4 should actually have 8 columns, instead of 5 in line 3.
query_no,query,cardinality_predict,cardinality_true,q_error,latency_ms,generated_spn_calls,latency_generated_code
0,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 2 AND title.series_years >= 1340 AND title.production_year <= 2004.0;",11538,11637,1.0085803432137286,42.26786499202717,0,0.0
1,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.phonetic_code = 16773 AND title.kind_id = 1 AND movie_companies.company_type_id = 1 AND movie_info_idx.info_type_id = 101;",183,383,2.092896174863388,40.731608009082265,0,0.0
2,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 4 AND title.phonetic_code <= 16924 AND title.production_year >= 1987.0 AND movie_companies.company_type_id = 1;",31559,79017,2.503786558509
We can make this file beautiful and searchable if this error is corrected: It looks like row 4 should actually have 8 columns, instead of 5 in line 3.
query_no,query,cardinality_predict,cardinality_true,q_error,latency_ms,generated_spn_calls,latency_generated_code
0,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 2 AND title.series_years >= 1340 AND title.production_year <= 2004.0;",10685,11637,1.0890968647636874,20.333573993411846,0,0.0
1,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.phonetic_code = 16773 AND title.kind_id = 1 AND movie_companies.company_type_id = 1 AND movie_info_idx.info_type_id = 101;",245,383,1.563265306122449,25.415468000574037,0,0.0
2,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 4 AND title.phonetic_code <= 16924 AND title.production_year >= 1987.0 AND movie_companies.company_type_id = 1;",27984,79017,2.82364922813
We can make this file beautiful and searchable if this error is corrected: It looks like row 4 should actually have 8 columns, instead of 6 in line 3.
query_no,query,cardinality_predict,cardinality_true,q_error,latency_ms,generated_spn_calls,latency_generated_code
0,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 2 AND title.series_years >= 1340 AND title.production_year <= 2004.0;",8656,11637,1.3443853974121995,43.02999000356067,0,0.0
1,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.phonetic_code = 16773 AND title.kind_id = 1 AND movie_companies.company_type_id = 1 AND movie_info_idx.info_type_id = 101;",200,383,1.915,39.682850998360664,0,0.0
2,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 4 AND title.phonetic_code <= 16924 AND title.production_year >= 1987.0 AND movie_companies.company_type_id = 1;",30747,79017,2.5699092594399455,43.71991
We can make this file beautiful and searchable if this error is corrected: It looks like row 4 should actually have 8 columns, instead of 5 in line 3.
query_no,query,cardinality_predict,cardinality_true,q_error,latency_ms,generated_spn_calls,latency_generated_code
0,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 2 AND title.series_years >= 1340 AND title.production_year <= 2004.0;",11781,11637,1.0123743232791957,45.468691998394206,0,0.0
1,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.phonetic_code = 16773 AND title.kind_id = 1 AND movie_companies.company_type_id = 1 AND movie_info_idx.info_type_id = 101;",239,383,1.602510460251046,44.66612699616235,0,0.0
2,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 4 AND title.phonetic_code <= 16924 AND title.production_year >= 1987.0 AND movie_companies.company_type_id = 1;",30906,79017,2.556688021743
We can make this file beautiful and searchable if this error is corrected: It looks like row 4 should actually have 8 columns, instead of 5 in line 3.
query_no,query,cardinality_predict,cardinality_true,q_error,latency_ms,generated_spn_calls,latency_generated_code
0,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 2 AND title.series_years >= 1340 AND title.production_year <= 2004.0;",10837,11637,1.0738211682199872,20.455916004721075,0,0.0
1,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.phonetic_code = 16773 AND title.kind_id = 1 AND movie_companies.company_type_id = 1 AND movie_info_idx.info_type_id = 101;",246,383,1.556910569105691,26.634241003193893,0,0.0
2,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 4 AND title.phonetic_code <= 16924 AND title.production_year >= 1987.0 AND movie_companies.company_type_id = 1;",27979,79017,2.82415382965
We can make this file beautiful and searchable if this error is corrected: It looks like row 4 should actually have 8 columns, instead of 5 in line 3.
query_no,query,cardinality_predict,cardinality_true,q_error,latency_ms,generated_spn_calls,latency_generated_code
0,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 2 AND title.series_years >= 1340 AND title.production_year <= 2004.0;",9892,11637,1.176405175899717,38.586937997024506,0,0.0
1,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.phonetic_code = 16773 AND title.kind_id = 1 AND movie_companies.company_type_id = 1 AND movie_info_idx.info_type_id = 101;",119,383,3.2184873949579833,32.95858099590987,0,0.0
2,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 4 AND title.phonetic_code <= 16924 AND title.production_year >= 1987.0 AND movie_companies.company_type_id = 1;",44853,79017,1.7616881813925
query_no query cardinality_predict cardinality_true q_error latency_ms generated_spn_calls latency_generated_code
0 SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 2 AND title.series_years >= 1340 AND title.production_year <= 2004.0; 6750 11637 1.724 48.24709799140692 0 0.0
1 SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.phonetic_code = 16773 AND title.kind_id = 1 AND movie_companies.company_type_id = 1 AND movie_info_idx.info_type_id = 101; 20 383 19.15 39.38393101270776 0 0.0
2 SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 4 AND title.phonetic_code <= 16924 AND title.production_year >= 1987.0 AND movie_companies.company_type_id = 1; 43965 79017 1.7972705561241897 45.22453300887719 0 0.0
We can make this file beautiful and searchable if this error is corrected: It looks like row 4 should actually have 8 columns, instead of 5 in line 3.
query_no,query,cardinality_predict,cardinality_true,q_error,latency_ms,generated_spn_calls,latency_generated_code
0,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 2 AND title.series_years >= 1340 AND title.production_year <= 2004.0;",24827,11637,2.1334536392541033,44.170667009893805,0,0.0
1,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.phonetic_code = 16773 AND title.kind_id = 1 AND movie_companies.company_type_id = 1 AND movie_info_idx.info_type_id = 101;",22,383,17.40909090909091,38.34984201239422,0,0.0
2,"SELECT COUNT(*) FROM movie_companies, movie_info_idx, title WHERE title.id=movie_companies.movie_id AND title.id=movie_info_idx.movie_id AND title.kind_id = 4 AND title.phonetic_code <= 16924 AND title.production_year >= 1987.0 AND movie_companies.company_type_id = 1;",44389,79017,1.7801031787154
@amogkam
amogkam / grid_search.py
Last active August 26, 2020 01:35
Huggingface Transformers Blog Post
{
"per_gpu_batch_size": [16, 32],
"learning_rate": [2e-5, 3e-5, 5e-5],
"num_epochs": [2, 3, 4]
}