Logistic Regression
联邦学习分类 | 训练模式 | 隐私计算技术 |
---|---|---|
横向联邦 | 明文 | |
DPSGD | 差分隐私 | |
Paillier | 同态加密 | |
纵向联邦 | 明文 | |
CKKS | 同态加密 |
如果是通过docker方式部署,先执行 docker exec -it primihub-node0 bash
进入到 primihub-node0
容器中,再执行CLI命令启动。
横向联邦
明文模式训练
- CLI
- Python SDK
二分类
./primihub-cli --task_config_file="example/FL/logistic_regression/hfl_binclass_plaintext.json"
多分类
./primihub-cli --task_config_file="example/FL/logistic_regression/hfl_multiclass_plaintext.json"
二分类
submit example/FL/logistic_regression/hfl_binclass_plaintext.json
多分类
submit example/FL/logistic_regression/hfl_multiclass_plaintext.json
DPSGD模式训练
- CLI
- Python SDK
二分类
./primihub-cli --task_config_file="example/FL/logistic_regression/hfl_binclass_dpsgd.json"
多分类
./primihub-cli --task_config_file="example/FL/logistic_regression/hfl_multiclass_dpsgd.json"
二分类
submit example/FL/logistic_regression/hfl_binclass_dpsgd.json
多分类
submit example/FL/logistic_regression/hfl_multiclass_dpsgd.json
Paillier同态模式训练
- CLI
- Python SDK
二分类
./primihub-cli --task_config_file="example/FL/logistic_regression/hfl_binclass_paillier.json"
二分类
submit example/FL/logistic_regression/hfl_binclass_paillier.json
预测
- CLI
- Python SDK
二分类
./primihub-cli --task_config_file="example/FL/logistic_regression/hfl_binclass_predict.json"
多分类
./primihub-cli --task_config_file="example/FL/logistic_regression/hfl_multiclass_predict.json"
二分类
submit example/FL/logistic_regression/hfl_binclass_predict.json
多分类
submit example/FL/logistic_regression/hfl_multiclass_predict.json
纵向联邦
明文模式训练
- CLI
- Python SDK
二分类
./primihub-cli --task_config_file="example/FL/logistic_regression/vfl_binclass_plaintext.json"
多分类
./primihub-cli --task_config_file="example/FL/logistic_regression/vfl_multiclass_plaintext.json"
二分类
submit example/FL/logistic_regression/vfl_binclass_plaintext.json
多分类
submit example/FL/logistic_regression/vfl_multiclass_plaintext.json
CKKS同态模式训练
- CLI
- Python SDK
二分类
./primihub-cli --task_config_file="example/FL/logistic_regression/vfl_binclass_ckks.json"
多分类
./primihub-cli --task_config_file="example/FL/logistic_regression/vfl_multiclass_ckks.json"
二分类
submit example/FL/logistic_regression/vfl_binclass_ckks.json
多分类
submit example/FL/logistic_regression/vfl_multiclass_ckks.json
预测
- CLI
- Python SDK
二分类
./primihub-cli --task_config_file="example/FL/logistic_regression/vfl_binclass_predict.json"
多分类
./primihub-cli --task_config_file="example/FL/logistic_regression/vfl_multiclass_predict.json"
二分类
submit example/FL/logistic_regression/vfl_binclass_predict.json
多分类
submit example/FL/logistic_regression/vfl_multiclass_predict.json