-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Replace the use of stamen tiles in the repo #451
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -277,7 +277,9 @@ | |
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"metadata": {}, | ||
"metadata": { | ||
"scrolled": false | ||
}, | ||
"outputs": [], | ||
"source": [ | ||
"hv.output(backend='matplotlib')\n", | ||
|
@@ -341,7 +343,7 @@ | |
"points = hd.dynspread(hd.datashade(pts, aggregator=ds.count_cat('category'), color_key=color_key))\n", | ||
"\n", | ||
"tiles = hv.element.tiles.ESRI().opts(alpha=0.4, bgcolor=\"black\").opts(responsive=True, min_height=600)\n", | ||
"labels = hv.element.tiles.StamenLabels().opts(alpha=0.7, level='glyph')\n", | ||
"labels = hv.element.tiles.EsriUSATopo().opts(alpha=0.4, level='glyph')\n", | ||
Comment on lines
345
to
+346
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @Azaya89 the code used to overlay an ESRI base map with the Stamen Labels layer that just contains labels (https://maps.stamen.com/toner-labels/#12/37.7922/-122.2301). With these changes, it is now overlaying two ESRI base maps, which doesn't make much sense. We've also lost the labels. Let's go through these examples next week together. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. OK, I was thinking about it in a different way. See you next week then! There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It would be great if we could find a labels-only tile set that still works, but I'm not aware of any. Failing that, I think the task is to choose an underlying tile set with labels embedded in it already in a way that is not too distracting. I do think people need labels, because otherwise it's hard to orient yourself. But with many tile sets, the labels are rendered in a way that becomes extremely busy when dense data is overlaid on them. So there's definitely some trial and error involved and tradeoffs to make. |
||
"\n", | ||
"tiles * labels * points.opts(show_legend=False) * legend.opts(xaxis='bare',yaxis='bare', title='')" | ||
] | ||
|
@@ -509,7 +511,7 @@ | |
"sopts = dict(start=0, end=1, sizing_mode='stretch_width')\n", | ||
"map_opacity = pn.widgets.FloatSlider(value=0.7, name=\"Map opacity\", **sopts)\n", | ||
"data_opacity = pn.widgets.FloatSlider(value=1.0, name=\"Data opacity\", **sopts)\n", | ||
"label_opacity = pn.widgets.FloatSlider(value=0.9, name=\"Label opacity\", **sopts)\n", | ||
"label_opacity = pn.widgets.FloatSlider(value=0.3, name=\"Label opacity\", **sopts)\n", | ||
"overlay = (tiles.apply.opts(alpha=map_opacity) *\n", | ||
" pointsp.apply.opts(alpha=data_opacity, show_legend=False) * vessel_name_raster *\n", | ||
" labels.apply.opts(alpha=label_opacity) * highlight * legend)\n", | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not
EsriStreet
like the others?