MILVLG / bottom-up-attention.pytorch

A PyTorch reimplementation of bottom-up-attention models
Apache License 2.0
294 stars 76 forks source link

socket.gaierror: [Errno -5] No address associated with hostname #97

Open WangLanxiao opened 2 years ago

WangLanxiao commented 2 years ago

Thanks for your help. I meet some strange errors as below. The log file is: 2022-10-08 19:57:58,183 WARNING worker.py:1189 -- The agent on node amax failed with the following error: Traceback (most recent call last): File "/data1/wlx/anaconda3/envs/bottomup/lib/python3.7/site-packages/ray/new_dashboard/agent.py", line 354, in loop.run_until_complete(agent.run()) File "/data1/wlx/anaconda3/envs/bottomup/lib/python3.7/asyncio/base_events.py", line 568, in run_until_complete return future.result() File "/data1/wlx/anaconda3/envs/bottomup/lib/python3.7/site-packages/ray/new_dashboard/agent.py", line 144, in run modules = self._load_modules() File "/data1/wlx/anaconda3/envs/bottomup/lib/python3.7/site-packages/ray/new_dashboard/agent.py", line 98, in _load_modules c = cls(self) File "/data1/wlx/anaconda3/envs/bottomup/lib/python3.7/site-packages/ray/new_dashboard/modules/reporter/reporter_agent.py", line 148, in init self._metrics_agent = MetricsAgent(dashboard_agent.metrics_export_port) File "/data1/wlx/anaconda3/envs/bottomup/lib/python3.7/site-packages/ray/_private/metrics_agent.py", line 77, in init namespace="ray", port=metrics_export_port))) File "/data1/wlx/anaconda3/envs/bottomup/lib/python3.7/site-packages/ray/_private/prometheus_exporter.py", line 334, in new_stats_exporter options=option, gatherer=option.registry, collector=collector) File "/data1/wlx/anaconda3/envs/bottomup/lib/python3.7/site-packages/ray/_private/prometheus_exporter.py", line 266, in init self.serve_http() File "/data1/wlx/anaconda3/envs/bottomup/lib/python3.7/site-packages/ray/_private/prometheus_exporter.py", line 321, in serve_http port=self.options.port, addr=str(self.options.address)) File "/data1/wlx/anaconda3/envs/bottomup/lib/python3.7/site-packages/prometheus_client/exposition.py", line 168, in start_wsgi_server TmpServer.address_family, addr = _get_best_family(addr, port) File "/data1/wlx/anaconda3/envs/bottomup/lib/python3.7/site-packages/prometheus_client/exposition.py", line 157, in _get_best_family infos = socket.getaddrinfo(address, port) File "/data1/wlx/anaconda3/envs/bottomup/lib/python3.7/socket.py", line 748, in getaddrinfo for res in _socket.getaddrinfo(host, port, family, type, proto, flags): socket.gaierror: [Errno -5] No address associated with hostname

1219521375 commented 1 year ago

It seems that there is a problem with ray. You can remove the --fastmode to use the non accelerated version. I have never encountered this problem in local development. If the code reports an error at ray.init(), you can try this solution