| 36 | gs::ArrowProjectedFragment<std::string, uint64_t, double, int64_t>; |
| 37 | |
| 38 | void RunCTXSSSP(std::shared_ptr<ProjectedFragmentType> fragment, |
| 39 | const grape::CommSpec& comm_spec, |
| 40 | const std::string& out_prefix) { |
| 41 | using AppType = grape::SSSP<ProjectedFragmentType>; |
| 42 | auto app = std::make_shared<AppType>(); |
| 43 | auto worker = AppType::CreateWorker(app, fragment); |
| 44 | auto spec = grape::DefaultParallelEngineSpec(); |
| 45 | worker->Init(comm_spec, spec); |
| 46 | MPI_Barrier(comm_spec.comm()); |
| 47 | worker->Query("v4"); |
| 48 | |
| 49 | auto ctx = worker->GetContext(); |
| 50 | |
| 51 | worker->Finalize(); |
| 52 | |
| 53 | std::ofstream ostream; |
| 54 | std::string output_path = |
| 55 | grape::GetResultFilename(out_prefix, fragment->fid()); |
| 56 | LOG(INFO) << "to write to: " << output_path; |
| 57 | ostream.open(output_path); |
| 58 | ctx->Output(ostream); |
| 59 | ostream.close(); |
| 60 | } |
| 61 | |
| 62 | void Run(vineyard::Client& client, const grape::CommSpec& comm_spec, |
| 63 | vineyard::ObjectID id) { |
no test coverage detected