.. _objects_nsa: NSA Object Service ================== Service for accessing the NSA object (noise receptor). Noise receptors can be accessed and the data manipulated. Noise receptors in windPRO have predefined settings for different countries as noise regulations need to be reflected. It is important to keep that in mind when making scripts that should work for multiple countries. WindPRO gives different options for these settings that are convenient for use in the GUI. These settings are mostly represented by integers in the background for windPRO and also in windPRO scripting. Below is an example for the values that are set in the noise receptor object. .. code-block:: 'PreDefinedCountry': 7 'PreDefinedType': 8 'PreDefined': 18 'NoiseDemandNew': 50.0 Note that "PreDefinedCountry" is the country setting in windPRO, "PreDefinedType" is an additional setting available for some countries, and "PreDefined" is the selection of a specific type of dwelling. To determine the correct setting it is advised to set it in the windPRO GUI and get the correct object via scripting. Note, that it is possible to change the "NoiseDemandNew", which is the acceptable noise level, in scripting even for predefined values. "PreDefined" takes precedent over the set noise value. Noise sensitive areas can be defined by using the corner points within the object. A good way to determine which values need to be changed to get to the noise receptor settings required is to set it in the windPRO GUI. You can use the function ``compare_objects`` from the windproapi python package. It compares what values are not the same between two objects which can be very useful for noise receptors. .. warning:: Areas can be set for noise receptors but they are not correctly shown in the windPRO GUI but are represented correctly in the calculation. Loading the noise receptor in the windPRO GUI will redraw the shape correctly. The script shows how to manipulate noise receptors and and add new points and areas to windPRO. .. literalinclude:: ../../../python/examples/fromDocs/objects/nsa_object.py