Task timed out while running geopandas with a 5.0 GB file

0

On my desktop the geopandas kan clip the file within 8-9 seconds while on lambda it is doing taske timed out after 300 seconds. I have even used shp = gpd.read_file(input_path, bbox=(x-modelsize/2, y-modelsize/2, x+modelsize/2, y+modelsize/2), engine="pyogrio", max_features=20000) The maximum memory which can be used is set as maximum on lambda. On my desktop it never reaches more than 3 GB.

  • The task is timing out at 300 seconds which is 5 minutes. Try increasing the Lambda function timeout to 900 seconds / 15 minutes, the longest a Lambda function is allowed to run. I have had similiar issues with Lambda functions using geopandas and ended up having to use libraries such as GDAL directly instead of relying on geopandas due to the constraints of the underlying EC2 instance. Local testing was well under the 15 minute mark however when using the same code via a Docker container deployed to Lambda, it was timing out at 15 minutes.

已提問 8 個月前檢視次數 41 次
沒有答案

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南