I have completed all the graded cells and the tests pass and show the expected output. However, when I submit the lab for a grade, it comes back with errors. Need guidance to troubleshoot and submit assignment for grade.
Code Cell UNQ_C1: Unexpected error (TypeError(“compute_entropy() got an unexpected keyword argument ‘y’”)) occurred during function check. We expected function compute_entropy to return compute_entropy test 1 failed. Please check that this function is defined properly.
Code Cell UNQ_C2: Unexpected error (TypeError(“split_dataset() got an unexpected keyword argument ‘X’”)) occurred during function check. We expected function split_dataset to return split_dataset test 1 failed. Please check that this function is defined properly.
Code Cell UNQ_C3: Unexpected error (TypeError(“compute_information_gain() got an unexpected keyword argument ‘X’”)) occurred during function check. We expected function compute_information_gain to return compute_information_gain test 1 failed. Please check that this function is defined properly.
Code Cell UNQ_C4: Unexpected error (TypeError(“get_best_split() got an unexpected keyword argument ‘X’”)) occurred during function check. We expected function get_best_split to return get_best_split test 1 failed. Please check that this function is defined properly.
If you see many functions being marked as incorrect, try to trace back your steps & identify if there is an incorrect function that is being used in other steps. This dependency may be the cause of the errors.
I seem to have the same issue. I might have accidentally changed the code and ended up having the same situation. Can you please let me know how I can solve it?
go to the week 4 course material and open the practice lab from there. this should give you a fresh start.
declare all your variables inside the ‘start code here’ and ‘end code here’ tabs. DO NOT type anything of your own outside this bracket, just to be safe. whatever you need to type, do it inside this bracket.
thanks for the help TMosh!
i was scratching my head for days figuring out the problem, lol