我正在尝试使用 python 3.8 和 youtube_dl 2020.3.24 从 youtube 下载歌曲。但奇怪的是,我尝试下载的大多数歌曲都没有下载。我说的是 99% 的人。下载的那些从 youtube_dl 得到以下错误:
ERROR: unable to download video data: HTTP Error 403: Forbidden
值得一提的是,这发生在一夜之间,我没有更改任何代码。在此之前一切正常。我有朋友运行相同的代码,但他们没有收到此错误
我需要在 python 中以 plotly 更改子图标题,即将其旋转 90 度。我很努力,但没有成功。
这是我的代码
import plotly.offline as pyo
import plotly.graph_objs as go
from plotly import tools
trace1 = go.Bar(
x=[1, 2, 3],
y=[10, 11, 12]
)
trace2 = go.Bar(
x=[1, 2, 3],
y=[100, 110, 120],
)
trace3 = go.Bar(
x=[1, 2, 3],
y=[1000, 1100, 1200],
)
fig = tools.make_subplots(rows=1, cols=3,
shared_xaxes=True, shared_yaxes=True,
vertical_spacing=0.001,
subplot_titles = ('first_title', 'second_title', 'third_title'))
fig.append_trace(trace1, 1, 1)
fig.append_trace(trace2, 1, 2)
fig.append_trace(trace3, 1, 3)
fig['layout'].update(height=600, width=600, title='main_title')
pyo.plot(fig, filename='file.html')
Run Code Online (Sandbox Code Playgroud)
所以,我想旋转'first_title'
,'second_title' …
df=pd.read_excel(filename)
我应该添加哪些属性来排除页眉和页脚?