Spaces:
Sleeping
Sleeping
Upload prep.py with huggingface_hub
Browse files
prep.py
CHANGED
|
@@ -23,7 +23,7 @@ api = HfApi(token=os.getenv("HF_TOKEN"))
|
|
| 23 |
# read data for Huggingface dataset space
|
| 24 |
DATASET_PATH = "hf://datasets/sudhirpgcmma02/Engine_PM/data/engine_data.csv"
|
| 25 |
df = pd.read_csv(DATASET_PATH)
|
| 26 |
-
|
| 27 |
#Features naming standardisation for easy handling
|
| 28 |
df.columns = (df.columns
|
| 29 |
.str.strip()
|
|
@@ -31,6 +31,8 @@ df.columns = (df.columns
|
|
| 31 |
.str.replace(r"[^\w]","_",regex=True)
|
| 32 |
)
|
| 33 |
|
|
|
|
|
|
|
| 34 |
# Targe varaible intialisation
|
| 35 |
target_col = 'Engine_Condition'
|
| 36 |
|
|
|
|
| 23 |
# read data for Huggingface dataset space
|
| 24 |
DATASET_PATH = "hf://datasets/sudhirpgcmma02/Engine_PM/data/engine_data.csv"
|
| 25 |
df = pd.read_csv(DATASET_PATH)
|
| 26 |
+
data_df=df.copy()
|
| 27 |
#Features naming standardisation for easy handling
|
| 28 |
df.columns = (df.columns
|
| 29 |
.str.strip()
|
|
|
|
| 31 |
.str.replace(r"[^\w]","_",regex=True)
|
| 32 |
)
|
| 33 |
|
| 34 |
+
|
| 35 |
+
|
| 36 |
# Targe varaible intialisation
|
| 37 |
target_col = 'Engine_Condition'
|
| 38 |
|