Repository navigation
Expand file tree
/
Copy pathindex.html
More file actions
122 lines (110 loc) · 7.6 KB
/
Copy pathindex.html
File metadata and controls
122 lines (110 loc) · 7.6 KB
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Veloserver</title>
<style>
body {
font-family: Arial, sans-serif;
margin: 0;
padding: 0;
background-color: #f2f2f2;
}
section {
width: 80%;
margin-left: auto;
margin-right: auto;
text-align: center;
background-color: #fff;
border: 1px solid #ddd;
padding: 20px;
box-shadow: 0 0 10px rgba(0,0,0,0.2);
}
h1 {
font-size: 36px;
margin-bottom: 10px;
}
p {
margin-bottom: 20px;
}
button {
background-color: #4CAF50;
border: none;
color: white;
padding: 10px 20px;
text-decoration: none;
display: inline-block;
font-size: 16px;
}
table {
margin: 0 auto 20px auto;
border-collapse: collapse;
}
th, td {
border: 1px solid #ddd;
padding: 6px 10px;
text-align: left;
}
th {
background-color: #f7f7f7;
}
code {
background-color: #f4f4f4;
padding: 1px 4px;
}
</style>
</head>
<body>
<main>
<section id="title">
<h1>Veloserver: Velocity Data Visualization Services</h1>
</section>
<section id="description">
<h2>Description</h2>
<p>Veloserver is a geospatial data visualization server designed to dynamically return velocity data such as winds and ocean currents from weather models and other datasets. It returns the data in formats optimized for visualizing in a web client including animated vector streamlines via gribjson. It includes built-in caching to reduce requests to external data sources and deliver quick results.</p>
</section>
<section id="usage">
<h2>Usage</h2>
<p>Default server port is 8104. Data is fetched on demand from the upstream model, converted to the requested format, cached, and returned. A trailing <code>/</code> is optional on every route.</p>
<p>Most requests are structured in the form:</p>
<p><code>/<model>/<product>/<format>/<datetime>/<projwin></code></p>
<p><code>product</code> and <code>projwin</code> are optional, which gives the following routes:</p>
<table>
<tr><th>Route</th><th>Returns</th></tr>
<tr><td><code>/<model>/<format>/<datetime></code></td><td>Global data for the default product (winds)</td></tr>
<tr><td><code>/<model>/<format>/<datetime>/<projwin></code></td><td>Data subset to a bounding box</td></tr>
<tr><td><code>/<model>/<product>/<format>/<datetime></code></td><td>Global data for a specific product</td></tr>
<tr><td><code>/<model>/<product>/<format>/<datetime>/<projwin></code></td><td>A specific product, subset to a bounding box</td></tr>
</table>
<p>There is also one dedicated route for Cloud-Optimized GeoTIFFs, which is HRRR only and takes no model or format: <code>/cog/<product>/<datetime></code> returns an EPSG:3857 Cloud-Optimized GeoTIFF.</p>
<h3>Parameters</h3>
<p><strong>model</strong> - <code>hrrr</code> (CONUS), <code>gfs</code> (global), or <code>ecmwf</code> (global; requires a licence and <code>~/.ecmwfapirc</code>).</p>
<p><strong>product</strong> - HRRR only; defaults to <code>winds</code>. Options: <code>winds</code> (10 m U/V vectors, the velocity layer), <code>temp_2m</code>, <code>dewpoint_2m</code>, <code>rh_2m</code>, <code>wind_gust</code>, <code>pbl_height</code>, <code>precip_rate</code>, <code>smoke_massden</code>.</p>
<p><strong>format</strong> - <code>gribjson</code> (U/V vectors for animated streamlines, winds only), <code>geotiff</code>, or <code>png</code>. Only winds supports gribjson; for any other product use geotiff, png, or the /cog route (gribjson otherwise returns 400). gfs and ecmwf return gribjson only.</p>
<p><strong>datetime</strong> - ISO 8601, e.g. <code>2025-01-01T06:00:00Z</code>. A bare date means midnight. Each model rounds to its own run cadence: HRRR hourly, GFS every 6 hours, ECMWF 00z.</p>
<p><strong>projwin</strong> - Bounding box <code>ulx,uly,lrx,lry</code> (west, north, east, south). Leave it out of the route for the full grid.</p>
<p><strong>fxx</strong> is an optional query parameter for HRRR requests. It sets the forecast hour, which is how far ahead of the model run you want to look, so adding <code>?fxx=6</code> gives you the six-hour forecast. If you leave it off you get F00, which is called the analysis hour. The analysis hour is the model's best picture of the atmosphere at the moment the run started, rather than a forecast of some later time. Every run reaches F18, and the runs at 00, 06, 12, and 18z reach all the way out to F48.</p>
</section>
<section id="samples">
<h2>Sample Requests</h2>
<h3>Winds (velocity / streamline layer)</h3>
<p>Global HRRR winds: <a href="http://localhost:8104/hrrr/gribjson/2025-01-01T00:00:00Z" rel="nofollow">http://localhost:8104/hrrr/gribjson/2025-01-01T00:00:00Z</a></p>
<p>HRRR winds over Southern California: <a href="http://localhost:8104/hrrr/winds/gribjson/2025-01-01T00:00:00Z/-118,34,-117,33" rel="nofollow">http://localhost:8104/hrrr/winds/gribjson/2025-01-01T00:00:00Z/-118,34,-117,33</a></p>
<p>Global GFS winds: <a href="http://localhost:8104/gfs/gribjson/2025-01-01T00:00:00Z" rel="nofollow">http://localhost:8104/gfs/gribjson/2025-01-01T00:00:00Z</a></p>
<p>ECMWF winds over a box (06:00 UTC): <a href="http://localhost:8104/ecmwf/gribjson/2025-01-01T06:00:00Z/-118,34,-117,33" rel="nofollow">http://localhost:8104/ecmwf/gribjson/2025-01-01T06:00:00Z/-118,34,-117,33</a></p>
<h3>HRRR forecast hours (fxx)</h3>
<p>Analysis (F00), the default: <a href="http://localhost:8104/hrrr/gribjson/2025-01-01T12:00:00Z" rel="nofollow">http://localhost:8104/hrrr/gribjson/2025-01-01T12:00:00Z</a></p>
<p>6 hours ahead of the 09z run: <a href="http://localhost:8104/hrrr/gribjson/2025-01-01T09:00:00Z?fxx=6" rel="nofollow">http://localhost:8104/hrrr/gribjson/2025-01-01T09:00:00Z?fxx=6</a></p>
<p>48 hours ahead of the 00z extended run: <a href="http://localhost:8104/hrrr/gribjson/2025-01-01T00:00:00Z?fxx=48" rel="nofollow">http://localhost:8104/hrrr/gribjson/2025-01-01T00:00:00Z?fxx=48</a></p>
<h3>HRRR rasters (png, geotiff)</h3>
<p>2 m temperature PNG: <a href="http://localhost:8104/hrrr/temp_2m/png/2025-01-01T00:00:00Z" rel="nofollow">http://localhost:8104/hrrr/temp_2m/png/2025-01-01T00:00:00Z</a></p>
<p>PBL height GeoTIFF: <a href="http://localhost:8104/hrrr/pbl_height/geotiff/2025-01-01T00:00:00Z" rel="nofollow">http://localhost:8104/hrrr/pbl_height/geotiff/2025-01-01T00:00:00Z</a></p>
<p>Smoke during the Jan 2025 LA fires: <a href="http://localhost:8104/hrrr/smoke_massden/png/2025-01-08T21:00:00Z" rel="nofollow">http://localhost:8104/hrrr/smoke_massden/png/2025-01-08T21:00:00Z</a></p>
<h3>Cloud-Optimized GeoTIFFs (/cog)</h3>
<p>Winds COG: <a href="http://localhost:8104/cog/winds/2025-01-01T00:00:00Z" rel="nofollow">http://localhost:8104/cog/winds/2025-01-01T00:00:00Z</a></p>
<p>Temperature COG, 12-hour forecast: <a href="http://localhost:8104/cog/temp_2m/2025-01-01T00:00:00Z?fxx=12" rel="nofollow">http://localhost:8104/cog/temp_2m/2025-01-01T00:00:00Z?fxx=12</a></p>
</section>
</main>
</body>
</html>