To whom it may concern,
I am trying to use files coming from my bucket in Google Cloud Storage in khiops v11.0.0.3.
Here is my test script :
# file paths (put "MYBUCKET" to not show u mine)
dictionary_file_path = "gs://MYBUCKET/Iris/Iris.kdic"
data_table_path = "gs://MYBUCKET/Iris/Iris.txt"
report_path = "gs://MYBUCKET/Iris/AnalysisResultsByPython_TEST.khj"
print(f"\nHere are the paths : \nkdic:{dictionary_file_path}\ndatatable:{dictionary_file_path}\nReport saved at :{report_path}")
print("\n#####")
print("Start of training")
print("#####\n")
try:
# Train the predictor
_, model_path = kh.train_predictor(
dictionary_file_path,
"Iris",
data_table_path,
"Class",
report_path,
max_trees=0,
)
print("Sucess")
print(f"Model saved at : {model_path}")
except Exception as e:
print(f"Training failed: {str(e)}")
import traceback
traceback.print_exc()
After running it :
@popescu-v told me :
- to modify in
api.py at line 867 : fs.parent_path by fs.get_parent_path
- the problem comes from the fact that
parent_path should be private from filesystems, only get_parent_path should be used
After I done the modification in my .venv, it solved the error, thank you @popescu-v 👍
To whom it may concern,
I am trying to use files coming from my bucket in Google Cloud Storage in khiops v11.0.0.3.
Here is my test script :
After running it :
@popescu-v told me :
api.pyat line 867 :fs.parent_pathbyfs.get_parent_pathparent_pathshould be private from filesystems, onlyget_parent_pathshould be usedAfter I done the modification in my
.venv, it solved the error, thank you @popescu-v 👍