README.md 1006 Bytes
Newer Older
claplace's avatar
claplace committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35
# Colorbar custom xml files 

This script is dedicated to create a custom colorbar based on the colormap used in [matplotolib](https://matplotlib.org/stable/tutorials/colors/colormaps.html). The output is written in a xml file for each variable and each level. In this project there is two .py files that we will describe below 


## xml_conf.py 

This is the configuration files that contains the variable's names,the number of segmentation, the minimum, the maximum. All this information are stocked into a python dictionary object. 

For example 

```python
U_col = {
10:[-40,50,n_sep],
20:[-40,40,n_sep],
30:[-25,32,n_sep],
50:[-20,30,n_sep],
70:[-20,30,n_sep],
100:[-30,50,n_sep],
150:[-30,60,n_sep],
200:[-30,75,n_sep],
500:[-30,50,n_sep],
1000:[-24,24,n_sep]
}
```
This is the minimum,maximum and number of segmentation for each level of the eastward wind (U). 


## color_hexa.py

This is the script used to write the xml files. To run this script you need to do 

```bash 
python color_hexa.py
```