I’m trying to follow the “Deploying on Google App Engine” guide, but when I do “gcloud app deploy”, I’m getting this error. Any idea what could be going on? Thanks in advance!
Step 7/9 : RUN python app/server.py
---> Running in e07fcc55fbdb
Traceback (most recent call last):
File "app/server.py", line 37, in <module>
learn = loop.run_until_complete(asyncio.gather(*tasks))[0]
File "/usr/local/lib/python3.6/asyncio/base_events.py", line 484, in run_until_complete
return future.result()
File "app/server.py", line 30, in setup_learner
tfms=get_transforms(), size=224).normalize(imagenet_stats)
File "/usr/local/lib/python3.6/site-packages/fastai/vision/data.py", line 165, in single_from_classes
return sd.label_const(0, label_cls=CategoryList, classes=classes).transform(ds_tfms, **kwargs).databunch()
TypeError: transform() got multiple values for argument 'tfms'
The command '/bin/sh -c python app/server.py' returned a non-zero code: 1
ERROR
ERROR: build step 0 "gcr.io/cloud-builders/docker" failed: exit status 1
-----------------------------------------------------------------------------------------------------------------------------------------------------------------
ERROR: (gcloud.app.deploy) Cloud build failed. Check logs at https://console.cloud.google.com/gcr/builds/2b9f958b-4ea9-414a-8294-621fbed31e8f?project=959127849283 Failure status: UNKNOWN: Error Resp
onse: [2] Build failed; check build logs for details
So, I managed to solve the above problem by following the instructions here. Now I’m able to deploy the app, but it doesn’t seem to be doing anything… it just says “analyzing” forever. Any idea how I can debug what’s going on?
So, I solved the above problem as well by following instructions here. Everything seems to be working fine now, but it might be worthwhile to update the guide to avoid others running into these same issues.
Hi, I had the same issue after successfully deploy the app on GAE here https://bear-vision.appspot.com/, but when I test it out, it seems Analyzing… forever, do you have any clue please?
In server.py, changing the return value of def analyze to JSONResponse({'result': learn.predict(img)[0].obj}) fixed this issue for me. I had to deploy it locally first to figure out that this was the issue though.