-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinit.py
More file actions
36 lines (30 loc) · 1008 Bytes
/
init.py
File metadata and controls
36 lines (30 loc) · 1008 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
import MergeSorts as ms
import QuickSorts as qs
import TimSorts as ts
import Threeway as tw
import numpy as np
import time
from ucimlrepo import fetch_ucirepo
import json
import pandas as pd
if __name__ == "__main__":
data_file = open("yelp\\yelp_academic_dataset_business.json", encoding="utf8")
data = []
for line in data_file:
data.append(json.loads(line))
checkin_df = pd.DataFrame(data)
data_file.close()
yelpStars = list(checkin_df['stars'])
print(yelpStars)
# wineQual = fetch_ucirepo(id=186)
# wineSortData = list(wineQual.data.features['citric_acid'].values)
# smaller_list = list(np.random.randint(1, 100, 20))
# small_list = list(np.random.randint(1, 1000, 1000))
# median_list = list(np.random.randint(1, 1000, 10000))
# big_list = list(np.random.randint(1, 10000, 100000))
start = time.time()
# sort here
# qs.quickSortStable(wineSortData)
end = time.time()
print('elapsed tiem: '+ str(end - start))
#