中转传输是指使用中转buffer进行传输,在如下场景中需要使用。
本示例使用中转传输功能进行Host To Host传输。
1 2 3 4 5 6 7 8 9 | Hixl engine; std::map<AscendString, AscendString> options; options["BufferPool"] = "4:8"; AscendString local_engine = "ip:port"; // 替换成真实IP端口;是Hixl的唯一标识,端口为有效值 auto ret = engine.Initialize(local_engine, options); if (ret != SUCCESS) { printf("[ERROR] Initialize failed, ret = %u\n", ret); return -1; } |