https://prefect.io logo
Title
y

yair friedman

06/22/2022, 11:27 AM
hi , i am executing my flow not from main flow. when i run it on the default executor everything is running file, when i use DaskExecutor it crashs with the following message 2022-06-22 14:06:40,649 prefect.TaskRunner INFO Task ‘train_model[0]’: Starting task run... 2022-06-22 14:06:40,650 prefect.TaskRunner INFO Task ‘train_model[1]’: Starting task run... The frame.append method is deprecated and will be removed from pandas in a future version. Use pandas.concat instead. The frame.append method is deprecated and will be removed from pandas in a future version. Use pandas.concat instead. 2022-06-22 14:06:55.255 python[95140:4859256] * Terminating app due to uncaught exception ‘NSInternalInconsistencyException’, reason: ‘NSWindow drag regions should only be invalidated on the Main Thread!’ please advise.
k

Kevin Kho

06/22/2022, 1:43 PM
Hey yair, so need to double post next time. We’ll see the message. This seems like a log from a task? This is not a Prefect log. What is the task doing?
y

yair friedman

06/22/2022, 2:09 PM
i am running a ML task (internally it does all kind of scikit-learn transformes + run mljar-suprevised estimator) the task is mapped so multiple runs happens with the same unmapped data. the same flow runs without an issue with default executor , but fails with daskexecutor or LocalDaskExecutor.
k

Kevin Kho

06/22/2022, 2:16 PM
Is this Prefect 1 or 2?
y

yair friedman

06/22/2022, 2:17 PM
perfect 1
k

Kevin Kho

06/22/2022, 2:19 PM
What does the mapped task return? A fitted model?
Are you plotting with matplotlib?
y

yair friedman

06/22/2022, 2:22 PM
return a dictionary of values
return {"pipeline": pipeline_which_is_list_of_dict, "some_object":internal_object , "f1" :internal_object.metrics_dict['f1'] }
i am not plotting directly. maybe matplotlib is used internally in the used packages
k

Kevin Kho

06/22/2022, 2:24 PM
I really don’t know. There is a problem with parallelizing something inside your task. Might be some plotting like this. Maybe you can try processes for the LocalDaskExecutor to provide more isolation? But this will copy your DataFrame multiple times so it might bloat memory too
y

yair friedman

06/22/2022, 2:26 PM
ok, will try to isolate the problem
thanks
ok, found the issue, it was with the mljar’s . when i switched to my own algorithm it all worked perfectly
k

Kevin Kho

06/22/2022, 2:46 PM
Ah I see