Created
December 8, 2019 18:52
-
-
Save dmesquita/38fc7037b906bb1c348e0ece064d0fbb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pandas as pd | |
import modin.pandas as pd_modin | |
import cudf as pd_cudf | |
results_loading = [] | |
### Read in the data with Pandas | |
for run in range(0,30): | |
s = time.time() | |
df = pd.read_csv("../inep/dados/microdados_educacao_superior_2018//microdados_ed_superior_2018/dados/DM_ALUNO.CSV") | |
e = time.time() | |
results_loading.append({"lib":"Pandas","time":float("{}".format(e-s))}) | |
print("Pandas Loading Time = {}".format(e-s)) | |
### Read in the data with Modin | |
for run in range(0,30): | |
s = time.time() | |
df = pd_modin.read_csv("../inep/dados/microdados_educacao_superior_2018//microdados_ed_superior_2018/dados/DM_ALUNO.CSV") | |
e = time.time() | |
results_loading.append({"lib":"Modin","time":float("{}".format(e-s))}) | |
print("Modin Loading Time = {}".format(e-s)) | |
### Read in the data with cudf | |
for run in range(0,30): | |
s = time.time() | |
df = pd_cudf.read_csv("../inep/dados/microdados_educacao_superior_2018//microdados_ed_superior_2018/dados/DM_ALUNO.CSV") | |
e = time.time() | |
results_loading.append({"lib":"Cudf","time":float("{}".format(e-s))}) | |
print("Cudf Loading Time = {}".format(e-s)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment