Closed programmerpyh closed 1 week ago
@programmerpyh The process is similar for Linux. Recently (probably within a week or two), I might upload a Docker image to help users who are not familiar with YACL avoid the hassle of setting up the environment.
Thanks
@programmerpyh You can directly execute the compiled binary to reproduce the experiment, as shown in the image below. If you need other input parameters, you will need to modify the input size in main.cc
.
The YACL can not be installed in Windows
emmmm。 All right. I think you can only use Linux The method is as I mentioned earlier
when I install upsi, there is some errors, could you please help me to solve it?
[root@localhost yacl]# bazel build --linkopt=-ldl --experimental_cc_shared_library --cxxopt=-std=c++17 //... INFO: Analyzed 327 targets (0 packages loaded, 0 targets configured). INFO: Found 327 targets... ERROR: /root/yacl/examples/upsi/rr22/okvs/BUILD.bazel:169:16: Compiling examples/upsi/rr22/okvs/simple_index.cc failed: (Exit 1): gcc failed: error executing command (from target //examples/upsi/rr22/okvs:simple_index) /usr/local/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer '-std=c++0x' -MD -MF ... (remaining 33 arguments skipped)
Use --sandbox_debug to see verbose messages from the sandbox and retain the sandbox build root for debugging
examples/upsi/rr22/okvs/simple_index.cc:22:10: fatal error: boost/math/special_functions/binomial.hpp: No such file or directory
22 | #include "boost/math/special_functions/binomial.hpp"
| ^~~~~~~~~~~
compilation terminated.
INFO: Elapsed time: 6.099s, Critical Path: 5.93s
INFO: 15 processes: 14 internal, 1 linux-sandbox.
FAILED: Build did NOT complete successfully
@programmerpyh This is due to the lack of a boost library. You can try installing Boost locally.
I have Boost locally, but which location should I install to?
The default directory is fine. When you run b2 install without specifying a location, it will be installed to the default location. For example, the default location is /usr/local/boost_1_xx. You can add export LD_LIBRARY_PATH=/usr/local/boost_1_xx/lib:$LD_LIBRARY_PATH
to your ~/.bashrc. Note that the version number should be changed to your current boost version. @programmerpyh
Thank you
Has the compilation been successful? @programmerpyh
I try my best but it still not work,may be I need your docker image later(^_^;)
@programmerpyh Emmmm, all right. You can now use "docker pull shallmate/upsi:latest" to try our UPSI using docker. The compiled executable file is under /yacl/bazel-bin/examples/upsi.
p.s. docker pull may require proxy configuration.
Thank you very much
@programmerpyh You can install the YACL library (https://github.com/secretflow/yacl.git) in Windows. To ensure version consistency, you can choose to install my local version (https://github.com/ShallMate/yacl). Then, create an
examples
folder in the YACL directory and clone the UPSI repository into it. Go back to the YACL directory and runbazel build --linkopt=-ldl //...
. The compiled binary files can be found inbazel-bin/examples/upsi
.P.S. Please install the dependencies for YACL yourself.