Spaces:
Runtime error
Runtime error
Corey Morris
commited on
Commit
·
dd61816
1
Parent(s):
a89ad93
changed to save and load in a directory
Browse files- save_for_regression.py +1 -1
- test_regression.py +1 -1
save_for_regression.py
CHANGED
|
@@ -45,7 +45,7 @@ if __name__ == '__main__':
|
|
| 45 |
last_commit = os.popen('git rev-parse HEAD').read().strip()
|
| 46 |
print(last_commit)
|
| 47 |
# save the current output to a file
|
| 48 |
-
df_current.to_parquet(f'output_{last_commit}.parquet', index=True)
|
| 49 |
print("Saved output to file")
|
| 50 |
if untracked_changes:
|
| 51 |
print("There are untracked changes")
|
|
|
|
| 45 |
last_commit = os.popen('git rev-parse HEAD').read().strip()
|
| 46 |
print(last_commit)
|
| 47 |
# save the current output to a file
|
| 48 |
+
df_current.to_parquet(f'dataframe_history/output_{last_commit}.parquet', index=True)
|
| 49 |
print("Saved output to file")
|
| 50 |
if untracked_changes:
|
| 51 |
print("There are untracked changes")
|
test_regression.py
CHANGED
|
@@ -12,7 +12,7 @@ class TestRegression(unittest.TestCase):
|
|
| 12 |
# load the reference dataframe
|
| 13 |
last_commit = os.popen('git rev-parse HEAD').read().strip()
|
| 14 |
print(last_commit)
|
| 15 |
-
reference_file = f'output_{last_commit}.parquet'
|
| 16 |
df_reference = pd.read_parquet(reference_file)
|
| 17 |
|
| 18 |
|
|
|
|
| 12 |
# load the reference dataframe
|
| 13 |
last_commit = os.popen('git rev-parse HEAD').read().strip()
|
| 14 |
print(last_commit)
|
| 15 |
+
reference_file = f'dataframe_history/output_{last_commit}.parquet'
|
| 16 |
df_reference = pd.read_parquet(reference_file)
|
| 17 |
|
| 18 |
|