On running server, workers die
I finally got the server to start, but when I do, I see a lot of this kind of thrash:
2019-12-19 12:01:32,130 [DEBUG] W-9006-densenet161 org.pytorch.serve.wlm.WorkerThread - Backend worker monitoring thread interrupted or backend worker process died.
java.lang.InterruptedException
at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.reportInterruptAfterWait(AbstractQueuedSynchronizer.java:2014)
at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.awaitNanos(AbstractQueuedSynchronizer.java:2088)
at java.util.concurrent.ArrayBlockingQueue.poll(ArrayBlockingQueue.java:418)
at org.pytorch.serve.wlm.WorkerThread.run(WorkerThread.java:128)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
2019-12-19 12:01:32,130 [WARN ] W-9006-densenet161 org.pytorch.serve.wlm.BatchAggregator - Load model failed: densenet161, error: Worker died.
2019-12-19 12:01:32,130 [DEBUG] W-9006-densenet161 org.pytorch.serve.wlm.WorkerThread - W-9006-densenet161 State change WORKER_STARTED -> WORKER_STOPPED
2019-12-19 12:01:32,131 [INFO ] W-9006-densenet161 org.pytorch.serve.wlm.WorkerThread - Retry worker: 9006 in 55 seconds.
Java 1.8.0 Python 3.6.9 macOS 10.14.6
Attempting to send input to the model, of course, fails while things are in this state.
This may be an defect in the model file provided as part of the quick start instructions. Prior to the exception above, I see an error that claims Unexpected key(s) in state_dict for the model.
Switching to resnet18 works. The model file for densenet161 is either defective or mismatched with the state dictionary downloaded in the quick start instructions.
Fixed model.py for densenet161 example. @fbbradheintz could you please verify this with the latest pull?
This has cleared up for me. Closing.