-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Handle horovod errors #24
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left two small comments. Otherwise LGTM
horovod/mxnet/mpi_ops.cc
Outdated
#include "tensor_util.h" | ||
|
||
namespace horovod { | ||
namespace mxnet { | ||
|
||
static StatusManager status_manager; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we want to move op_count
into status_manager
and make it a tuple with the last_error like (op_count, last_error)
. Would it be helpful for debugging?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a good one. Maybe we can save the name (which contains the op_count) to make it more informative.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Does this mean MXNet profiler will have data for communication calls too?
@ctcyang As we discussed offline, MX_API_BEGIN/MX_API_END was used to catch C++ errors and make it possible to throw MXNetError at Python level. It is not profiler related as far as I know. |
TBH, it seems a bit hacky. This doesn't resolve the situation when the last Horovod operation fails. I have another idea. I see that this code can push operation in the engine, which may throw How would that error be handled? What if our Horovod error handling will enqueue another high-priority operation which will just throw |
New API is way nicer! :-) |
This PR populates error originated in Horovod back to MXNet engine through callback. The error will be thrown in MXNet when a sync action is performed, such as wait_to_read(). This approach has no performance impact. This is dependent on a PR in MXNet.
The approaches using synchronize and C++ future library shows 80~85% performance regression.