Skip to content

Commit

Permalink
dataloader getting near done
Browse files Browse the repository at this point in the history
  • Loading branch information
robfatland committed Jul 8, 2024
1 parent 3f76754 commit cf65f6a
Show file tree
Hide file tree
Showing 26 changed files with 13,096 additions and 424 deletions.
5 changes: 3 additions & 2 deletions book/chapters/data.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -223,6 +223,7 @@
"***Tasks***\n",
"\n",
"\n",
"- Does the S3 Zarr source go down on Sunday evenings? Is there a way to test if it is down?\n",
"- This section does not demonstrate profile use; but it should\n",
"- This section effectively does the profile-from-data chart twice; once is enough\n",
"- Mothball the ReformatDataFile() function in `data.py` which is part of the old Data Explorer procedure.\n",
Expand Down Expand Up @@ -811,9 +812,9 @@
],
"source": [
"# temperature and salinity\n",
"fig,axs = ChartTwoSensors(profiles, [ranges['temperature'], ranges['salinity']], [0], \n",
"fig,axs = ChartTwoSensors(profiles, [ranges['temperature'], ranges['conductivity']], [0], \n",
" d['temperature'][0], d['temperature'][1], 'Temperature', colors['temperature'], 'ascent',\n",
" d['salinity'][0], d['salinity'][1], 'Salinity', colors['salinity'], 'ascent', 6, 4)"
" d['conductivity'][0], d['conductivity'][1], 'Conductivity', colors['conductivity'], 'ascent', 6, 4)"
]
},
{
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
13,153 changes: 12,924 additions & 229 deletions book/chapters/dataloader.ipynb

Large diffs are not rendered by default.

351 changes: 163 additions & 188 deletions book/chapters/epipelargosy.ipynb

Large diffs are not rendered by default.

10 changes: 5 additions & 5 deletions book/chapters/shallowprofiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ def GenerateTimeWindowIndices(profiles, date0, date1, time0, time1):


sensors = [
['conductivity', 'ctd'], ['density', 'ctd'], ['pressure', 'ctd'], ['salinity', 'ctd'], ['temperature', 'ctd'],
['conductivity', 'ctd'], ['density', 'ctd'], ['pressure', 'ctd'], ['salinity', 'ctd'], ['temp', 'ctd'],
['chlora', 'fluor'], ['backscatter', 'fluor'], ['fdom', 'fluor'],
['spkir412nm', 'spkir'], ['spkir443nm', 'spkir'], ['spkir490nm', 'spkir'], ['spkir510nm', 'spkir'], ['spkir555nm', 'spkir'], ['spkir620nm', 'spkir'], ['spkir683nm', 'spkir'],
['nitrate', 'nitrate'],
Expand All @@ -75,7 +75,7 @@ def GenerateTimeWindowIndices(profiles, date0, date1, time0, time1):
['up', 'vel'], ['east', 'vel'], ['north', 'vel']]

ranges = {
'conductivity':(32.0,34.5),'density':(1024, 1028),'pressure':(0.,200.),'salinity':(32, 34),'temperature':(7, 11),
'conductivity':(3.2,3.7),'density':(1024, 1028),'pressure':(0.,200.),'salinity':(32, 34),'temp':(7, 11),
'chlora':(0.,1.5),'backscatter':(0.00,0.006),'fdom':(0.5,4.5),
'spkir412nm':(0.0, 15.0), 'spkir443nm':(0.0, 15.0), 'spkir490nm':(0.0, 15.0), 'spkir510nm':(0.0, 15.0), 'spkir555nm':(0.0, 15.0), 'spkir620nm':(0.0, 15.0), 'spkir683nm':(0.0, 15.0),
'nitrate':(0., 35.),
Expand All @@ -87,7 +87,7 @@ def GenerateTimeWindowIndices(profiles, date0, date1, time0, time1):
}

standard_deviations = {
'conductivity':(0.1, 0.6),'density':(0., .3),'pressure':(0.,10.),'salinity':(.0, .4),'temperature':(.0, .7),
'conductivity':(0.1, 0.6),'density':(0., .3),'pressure':(0.,10.),'salinity':(.0, .4),'temp':(.0, .7),
'chlora':(0.0, 0.5),'backscatter':(0.0,0.003),'fdom':(0.0,0.7),
'spkir412nm':(0.0, .5), 'spkir443nm':(0.0, .5), 'spkir490nm':(0.0, .5), 'spkir510nm':(0.0, .5), 'spkir555nm':(0.0, .5), 'spkir620nm':(0.0, .5), 'spkir683nm':(0.0, .5),
'nitrate':(0., 4.),
Expand All @@ -99,7 +99,7 @@ def GenerateTimeWindowIndices(profiles, date0, date1, time0, time1):
}

colors = {
'conductivity':'xkcd:maroon','density':'xkcd:brick red','pressure':'xkcd:eggplant','salinity':'cyan','temperature':'red',
'conductivity':'xkcd:maroon','density':'xkcd:brick red','pressure':'xkcd:eggplant','salinity':'cyan','temp':'red',
'chlora':'green','backscatter':'xkcd:blood orange','fdom':'xkcd:olive drab',
'spkir412nm':'black', 'spkir443nm':'black', 'spkir490nm':'black', 'spkir510nm':'black',
'spkir555nm':'black', 'spkir620nm':'black', 'spkir683nm':'black',
Expand All @@ -113,7 +113,7 @@ def GenerateTimeWindowIndices(profiles, date0, date1, time0, time1):

sensor_names = {
'conductivity':'Conductivity','density':'Density (kg m-3)','pressure':'Pressure',
'salinity':'Salinity','temperature':'Temperature (deg C)', 'temp':'Temperature (deg C)',
'salinity':'Salinity','temp':'Temperature (deg C)',
'chlora':'Chlorophyll-A','backscatter':'Particulate Backscatter','fdom':'Fluorescent DOM',
'spkir412nm':'Spectral Irradiance 412nm',
'spkir443nm':'Spectral Irradiance 443nm',
Expand Down
1 change: 1 addition & 0 deletions environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ dependencies:
- xarray
- ipywidgets
- netcdf4
- s3fs



0 comments on commit cf65f6a

Please sign in to comment.