代码之家  ›  专栏  ›  技术社区  ›  Harry Moreno

部署到ML引擎时发生ClipbyValue错误

  •  0
  • Harry Moreno  · 技术社区  · 6 年前

    当我试图将keras模型部署到ml引擎时

    $ gcloud ml-engine versions create v2 --model=plantDisease01 --origin=gs://${BUCKET_NAME}/
    plantDisease01 --runtime-version=1.4                                                       
    Creating version (this might take a few minutes)......failed.                              ERROR: (gcloud.ml-engine.versions.create) Bad model detected with error:  "Failed to load model: Loading servable: {name: default version: 1} failed: Not found: Op type not registere
    d 'ClipByValue' in binary running on localhost. Make sure the Op and Kernel are registered
    in the binary running in this process.\n\n (Error code: 0)"
    FAIL
    

    我的储藏室看起来像

    $ gsutil ls gs://keras-class-191806/plantDisease01/export                      [23:29:38]
    gs://keras-class-191806/plantDisease01/export/
    gs://keras-class-191806/plantDisease01/export/saved_model.pb
    

    我用这种方法构建了协议缓冲区版本 https://stackoverflow.com/a/44232441/630752

    1 回复  |  直到 6 年前
        1
  •  1
  •   Lefteris S Mikhail Berlyant    6 年前

    ClipByValue introduced in TensorFlow 1.8 . 你也可以 register 你自己去手术还是换个 --runtime-version 标志值为1.8。