@@ -6,20 +6,71 @@ To avoid problems with installation, use of the virtualenv Python virtual enviro
6
6
7
7
Then use pip to install all dependencies (numpy, scipy, matplotlib, netCDF4, cython, pyproj, Shapely, ...), e.g.:
8
8
9
- * ** pip install cython numpy matplotlib scipy netCDF4 shapely pyproj**
9
+ ``` bash
10
+ pip install cython numpy matplotlib scipy netCDF4 shapely pyproj
11
+ ```
10
12
11
13
Then run the following to install the eddy tracker:
12
14
13
- * ** python setup.py install**
15
+ ``` bash
16
+ python setup.py install
17
+ ```
14
18
15
19
Two executables are now available in your PATH: EddyIdentification and EddyTracking
16
20
17
21
Edit the corresponding yaml files and then run the code, e.g.:
18
22
19
- * ** EddyIdentification eddy_identification.yaml**
23
+ ``` bash
24
+ EddyIdentification eddy_identification.yaml
25
+ ```
20
26
21
27
for identification, followed by:
22
28
23
- * ** EddyTracking tracking.yaml**
29
+ ``` bash
30
+ EddyTracking tracking.yaml
31
+ ```
32
+
33
+ for tracking.
34
+
35
+
36
+ # Py Eddy Tracker module #
37
+
38
+ ### Grid manipulation ###
39
+
40
+ Loading grid
41
+ ``` python
42
+ from py_eddy_tracker.dataset.grid import RegularGridDataset
43
+ h = RegularGridDataset(' share/nrt_global_allsat_phy_l4_20190223_20190226.nc' , ' longitude' , ' latitude' )
44
+ ```
45
+
46
+ Plotting grid
47
+ ``` python
48
+ fig = plt.figure(figsize = (14 , 12 ))
49
+ ax = fig.add_axes([.02 , .51 , .9 , .45 ])
50
+ ax.set_title(' ADT (m)' )
51
+ ax.set_ylim(- 75 , 75 )
52
+ ax.set_aspect(' equal' )
53
+ m= ax.pcolormesh(h.x_bounds, h.y_bounds, h.grid(' adt' ).T.copy(), vmin = - 1 , vmax = 1 , cmap = ' coolwarm' )
54
+ ax.grid(True )
55
+ plt.colorbar(m, cax = fig.add_axes([.94 , .51 , .01 , .45 ]))
56
+ ```
57
+
58
+ Filtering
59
+ ``` python
60
+ h.bessel_high_filter(' adt' , 500 , order = 3 )
61
+ ```
62
+
63
+ Add second plot
64
+ ``` python
65
+ ax = fig.add_axes([.03 , .02 , .9 , .45 ])
66
+ ax.set_title(' ADT Filtered (m)' )
67
+ ax.set_aspect(' equal' )
68
+ ax.set_ylim(- 75 , 75 )
69
+ m= ax.pcolormesh(h.x_bounds, h.y_bounds, h.grid(' adt' ).T, vmin = - .1 , vmax = .1 , cmap = ' coolwarm' )
70
+ ax.grid(True )
71
+ plt.colorbar(m, cax = fig.add_axes([.94 , .02 , .01 , .45 ]))
72
+ fig.savefig(' share/png/filter.png' )
73
+ ```
74
+
75
+ ![ signal filtering] ( share/png/filter.png )
24
76
25
- for tracking.
0 commit comments