wandb_api_pb2.py 608 B

123456789101112131415161718
  1. import google.protobuf
  2. protobuf_version = google.protobuf.__version__[0]
  3. if protobuf_version == "4":
  4. from wandb.proto.v4.wandb_api_pb2 import *
  5. elif protobuf_version == "5":
  6. from wandb.proto.v5.wandb_api_pb2 import *
  7. elif protobuf_version == "6":
  8. from wandb.proto.v6.wandb_api_pb2 import *
  9. elif protobuf_version == "7":
  10. from wandb.proto.v7.wandb_api_pb2 import *
  11. else:
  12. raise ImportError(
  13. "Failed to import protobufs for protobuf version"
  14. f" {google.protobuf.__version__}. `wandb` only works with major"
  15. " versions 4, 5, 6, and 7 of the protobuf package.",
  16. )