1,找到tensorflow_privacy包的路径
2,打包压缩成.zip
3,采用kaggle中添加dataset的形式添加该包
4,添加:
import os
for dirname, _, filenames in os.walk(’/kaggle/input’):
for filename in filenames:
print(os.path.join(dirname, filename))
5,添加:
import sys
sys.path.insert(0, ‘/kaggle/input/tensorflow-privacy’)
然后就可以import tensorflow_privacy了