Merge commit '4c060df2f17405dc26dc65a77e412d5c2a23525a'
Conflicts: subtree/rabit/tracker/rabit_yarn.py
This commit is contained in:
@@ -63,6 +63,10 @@ class AllreduceBase : public IEngine {
|
||||
if (world_size == -1) return 1;
|
||||
return world_size;
|
||||
}
|
||||
/*! \brief whether is distributed or not */
|
||||
virtual bool IsDistributed(void) const {
|
||||
return tracker_uri == "NULL";
|
||||
}
|
||||
/*! \brief get rank */
|
||||
virtual std::string GetHost(void) const {
|
||||
return host_uri;
|
||||
|
||||
@@ -56,6 +56,10 @@ class EmptyEngine : public IEngine {
|
||||
virtual int GetWorldSize(void) const {
|
||||
return 1;
|
||||
}
|
||||
/*! \brief whether it is distributed */
|
||||
virtual bool IsDistributed(void) const {
|
||||
return false;
|
||||
}
|
||||
/*! \brief get the host name of current node */
|
||||
virtual std::string GetHost(void) const {
|
||||
return std::string("");
|
||||
|
||||
@@ -59,6 +59,10 @@ class MPIEngine : public IEngine {
|
||||
virtual int GetWorldSize(void) const {
|
||||
return MPI::COMM_WORLD.Get_size();
|
||||
}
|
||||
/*! \brief whether it is distributed */
|
||||
virtual bool IsDistributed(void) const {
|
||||
return true;
|
||||
}
|
||||
/*! \brief get the host name of current node */
|
||||
virtual std::string GetHost(void) const {
|
||||
int len;
|
||||
|
||||
Reference in New Issue
Block a user