6.5. copro.data.fill_X_conflict

copro.data.fill_X_conflict(X, config, conflict_data, polygon_gdf)[source]

Fills the X-dictionary with the conflict data for each polygon and each year. Used during the projection runs as the sample and conflict data need to be treated separately there.

Parameters
  • X (dict) – dictionary containing keys to be sampled.

  • config (ConfigParser-object) – object containing the parsed configuration-settings of the model.

  • conflict_data (dataframe) – dataframe containing all polygons with conflict.

  • polygon_gdf (geo-dataframe) – geo-dataframe containing the selected polygons.

Returns

dictionary containing sample and conflict values.

Return type

dict