Hello,
Finally iโve got my desired output.
There is one more thing i would like to know. My corner coordinates are
28.18 - 28.88 (longitude)
37.50 - 37.88 (latitude)
For example i will add some scatter points (earthquake aftershocks) and their coordinates are
28.50,37.60
28.52,37.56
.
.
.
Is it possible to set my x and y axis values as long lat values ?
import plotly.graph_objects as go
import numpy as np
from matplotlib.colors import LightSource
import matplotlib.pyplot as plt
dem = np.load('topo.npz')
z = dem['elevation']
dx, dy = dem['dx'], dem['dy']
dy = 111200 * dy
dx = 111200 * dx * np.cos(np.radians(dem['ymin']))
ls = LightSource(azdeg=315, altdeg=45)
cmap = plt.cm.gist_earth
rgb = ls.shade(z, cmap=cmap,vmin=0,vmax=2500, blend_mode='overlay',vert_exag=5, dx=dx, dy=dy)
img = np.array((255*rgb[:, :, :3]+0.5), int)
fig= go.Figure(go.Image(z=img ))
fig.show()