Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed May 13, 2024
1 parent 3e65a81 commit cfad40e
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 8 deletions.
13 changes: 8 additions & 5 deletions source/api_cc/src/common.cc
Original file line number Diff line number Diff line change
Expand Up @@ -329,8 +329,8 @@ void deepmd::check_status(const tensorflow::Status& status) {

void throw_env_not_set_warning(std::string env_name) {
std::cerr << "DeePMD-kit WARNING: Environmental variable " << env_name
<< " is not set. " << "Tune " << env_name
<< " for the best performance. "
<< " is not set. "
<< "Tune " << env_name << " for the best performance. "
<< "See https://deepmd.rtfd.io/parallelism/ for more information."
<< std::endl;
}
Expand Down Expand Up @@ -1347,11 +1347,14 @@ void deepmd::print_summary(const std::string& pre) {
std::cout << pre << "source commit at: " + global_git_date << "\n";
std::cout << pre << "support model ver.: " + global_model_version << "\n";
#if defined(GOOGLE_CUDA)
std::cout << pre << "build variant: cuda" << "\n";
std::cout << pre << "build variant: cuda"
<< "\n";
#elif defined(TENSORFLOW_USE_ROCM)
std::cout << pre << "build variant: rocm" << "\n";
std::cout << pre << "build variant: rocm"
<< "\n";
#else
std::cout << pre << "build variant: cpu" << "\n";
std::cout << pre << "build variant: cpu"
<< "\n";
#endif
#ifdef BUILD_TENSORFLOW
std::cout << pre << "build with tf inc: " + global_tf_include_dir << "\n";
Expand Down
9 changes: 6 additions & 3 deletions source/ipi/driver.cc
Original file line number Diff line number Diff line change
Expand Up @@ -126,17 +126,20 @@ int main(int argc, char *argv[]) {
if (!isinit) {
writebuffer_(&socket, msg_needinit, MSGLEN);
if (b_verb) {
std::cout << "# send back " << "NEEDINIT" << std::endl;
std::cout << "# send back "
<< "NEEDINIT" << std::endl;

Check warning on line 130 in source/ipi/driver.cc

View check run for this annotation

Codecov / codecov/patch

source/ipi/driver.cc#L130

Added line #L130 was not covered by tests
}
} else if (hasdata) {
writebuffer_(&socket, msg_havedata, MSGLEN);
if (b_verb) {
std::cout << "# send back " << "HAVEDATA" << std::endl;
std::cout << "# send back "
<< "HAVEDATA" << std::endl;

Check warning on line 136 in source/ipi/driver.cc

View check run for this annotation

Codecov / codecov/patch

source/ipi/driver.cc#L136

Added line #L136 was not covered by tests
}
} else {
writebuffer_(&socket, msg_ready, MSGLEN);
if (b_verb) {
std::cout << "# send back " << "READY" << std::endl;
std::cout << "# send back "
<< "READY" << std::endl;

Check warning on line 142 in source/ipi/driver.cc

View check run for this annotation

Codecov / codecov/patch

source/ipi/driver.cc#L142

Added line #L142 was not covered by tests
}
}
} else if (header_str == "INIT") {
Expand Down

0 comments on commit cfad40e

Please sign in to comment.