= PALM Create Static Driver (palm_csd) = In order to create comprehensive drivers for PALM runs in urban environments, PALM comes shipped with the tool palm_csd. This python3-based script was developed in the course of [http://uc2-mosaik.org the MOSAIK project] and thus is, in principal, only working for the democities Berlin, Hamburg, and Stuttgart. However, with some effort it is possible to adapt the script for other cities as well. Note that in the mid-term, palm_csd will be replaced by a more generic and universal tool based with a graphical user interface as front end. == Execution == In order to create a static driver, go to the working directory (usually {{{~/palm/current_version}}}), prepare a palm_csd configuration file (see below, an exemplary file can be found [source:palm/trunk/SCRIPTS/.csd.config.default here]). After set-up of the configuration file, execute palm_csd as follows: {{{ palm_csd .csd.config.default }}} The static driver will be written to the directory specified in the configuration file. During compilation of the driver, palm_csd will print some more or less useful information to screen. == Configuration file == This section describes how to set-up a configuration file for creating a static driver for PALM based on pre-processed NetCDF data. In the following we will use data for Berlin, which is available via Open Access. The configuration file uses the well-known format of INI files, which are processed by the ConfigParser package in python. It consists of the following sections: === [global] === A set of global attributes can be defined that will be passed to the static driver file. In details, the following attributes can be set (see also [wiki:doc/app/iofiles/pids/static static driver description]: ||='''Attribute''' =||='''Data type''' =||='''Description''' =|| || {{{author}}} || string || Author of the static driver. Use the format: name, email || || {{{contact}}} || string || Contact person, format as for {{{author}}} || || {{{acronym}}} || string || Institional acronym (formating rules applies to static drivers used in the [http://uc2-mosaik.org MOSAIK] project) || || {{{comment}}} || string || Arbitrary text || || {{{data_content}}} || string || Arbitrary text || || {{{dependencies}}} || string || Arbitrary text || || {{{keywords}}} || string || Arbitrary keywords || || {{{source}}} || string || List of data sources used to generate the driver || || {{{campaign}}} || string || Information on measurement capaign (if applicable) || || {{{location}}} || string || Geo-location of the static driver content (if applicable) || || {{{site}}} || string || Site description od the static driver content (if applicable) || || {{{institution}}} || string || Institution of the driver creator || || {{{palm_version}}} || float || PALM version for which the driver was generated (for comptatibility checks) || || {{{rotation_angle}}} || float || Clockwise angle of rotation in degrees between North positive y axis and the y axis in the data, e.g. ''0.0''. This value overwrites the namelist parameter [wiki:doc/app/initialization_parameters#rotation_angle rotation_angle]. || || {{{references}}} || string || Arbitrary text || Example: {{{ author = Bjoern Maronga, maronga@muk.uni-hannover.de contact_person = Bjoern Maronga, maronga@muk.uni-hannover.de acronym = LUHimuk comment = created with palm_csd data_content dependencies keywords source campaign location = Berlin site = Berlin Mitte institution = Institute of Meteorology and Climatology, Leibniz University Hannover palm_version = 6.0 rotation_angle = 0.0 references }}} === [settings] === filename_out = /ldata2/MOSAIK/showcase_python lai_roof_intensive = 1.5 lai_roof_extensive = 3.0 lai_high_vegetation_default = 5.0 lai_low_vegetation_default = 1.0 lai_alpha = 5.0 lai_beta = 3.0 patch_height_default = 10.0 bridge_width = 3.0 debug_mode = False season = "summer" === [output] === path = /ldata2/MOSAIK/ file_out = winter_iop1_test version = 1 === [input_01] - [input_XX] === path = /ldata2/MOSAIK/Berlin_static_driver_data pixel_size = 15.0 file_x = Berlin_CoordinatesUTM_x_15m_DLR.nc file_y = Berlin_CoordinatesUTM_y_15m_DLR.nc file_x_UTM = Berlin_CoordinatesUTM_y_15m_DLR.nc file_y_UTM = Berlin_CoordinatesUTM_x_15m_DLR.nc file_lat = Berlin_CoordinatesLatLon_y_15m_DLR.nc file_lon = Berlin_CoordinatesLatLon_x_15m_DLR.nc file_zt = Berlin_terrain_height_15m_DLR.nc file_buildings_2d = Berlin_building_height_15m_DLR.nc file_building_id = Berlin_building_id_15m_DLR.nc file_building_type = Berlin_building_type_15m_DLR.nc file_bridges_2d = Berlin_bridges_height_15m_DLR.nc file_bridges_id = Berlin_bridges_id_15m_DLR.nc file_lai = Berlin_leaf_area_index_15m_DLR_WANG_summer.nc file_vegetation_type = Berlin_vegetation_type_15m_DLR.nc file_vegetation_height = Berlin_vegetation_patch_height_15m_DLR.nc file_pavement_type = Berlin_pavement_type_15m_DLR.nc file_water_type = Berlin_water_type_15m_DLR.nc file_soil_type = Berlin_soil_type_15m_DLR.nc file_street_type = Berlin_street_type_15m_DLR.nc file_street_crossings = Berlin_street_crossings_15m_DLR.nc file_tree_height = Berlin_trees_height_clean_15m.nc file_tree_crown_diameter = Berlin_tree_crown_15m_DLR.nc file_tree_trunk_diameter = Berlin_trees_trunk_clean_15m.nc file_tree_type = Berlin_trees_type_15m_DLR.nc file_patch_height = Berlin_vegetation_patch_height_15m_DLR.nc file_vegetation_on_roofs = Berlin_vegetation_on_roofs_15m_DLR.nc === [domain_root] === pixel_size = 15.0 origin_x = 19605 origin_y = 20895 nx = 200 ny = 200 buildings_3d = False dz = 15.0 allow_high_vegetation = True generate_vegetation_patches = True use_palm_z_axis= False interpolate_terrain = False domain_parent vegetation_on_roofs = True street_trees = True canopy_patches = True === [domain_01] - [domain_NXX] === pixel_size = 1.0 origin_x = 19605 origin_y = 20895 nx = 1023 ny = 1023 buildings_3d = True dz = 1.0 allow_high_vegetation = False generate_vegetation_patches = True use_palm_z_axis= True interpolate_terrain = True domain_parent = root vegetation_on_roofs = True street_trees = True canopy_patches = True == Required input data == == Best practices == == Literature == * Heldens et al. * Mikhailovic & Lalic * Markkanen et al.