python - 模块“matplotlib”在 Django 中没有属性“switch_backend”
问题描述
我一直在网上搜索没有成功。我将 matplotlib 导入到我的 django 3.2 项目中,我得到错误模块 'matplotlib' has no attribute 'switch_backend'
import matplotlib as plt
plt.switch_backend('AGG')
fig = plt.figure(figsize=(10, 4))
有没有办法解决这个问题?
解决方案
推荐阅读
- javascript - JS。从字符串中获取部分日期
- python - 为什么索引对象不会在用它重新索引的不同熊猫对象之间共享?
- node.js - 您好,我一直在尝试为正在使用护照本地猫鼬构建的应用程序设置用户身份验证并面临此错误
- elasticsearch - 断路异常
弹性搜索 - python - 在 Windows 上获取子进程的错误消息
- tsql - 如何在 PATINDEX 中执行 OR
- jquery - Jquery在追加一个函数后调用一个函数
- pandas - get_dummies 之后的一种更快的聚合方式
- c# - 是否可以将自定义自动完成关键字添加到 IntelliSense?
- excel - 在 Excel 中搜索隐藏的未锁定单元格