自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

Quasimodo

先战胜自己!

  • 博客(28)
  • 收藏
  • 关注

原创 不是有效的 Win32 应用程序

[WinError 193] %1 不是有效的 Win32 应用程序Could not find 'msvcp140.dll'. TensorFlow requires that this DLL be installed in a directory that is named in your %PATH% environment variable. You may install this DLL by downloading Visual C++ 2015 Redistributable Upd.

2022-05-06 14:25:57 582

原创 【pywin32】Windows窗口功能及部分消息参数意义

SW_HIDE:隐藏窗口并激活其他窗口。nCmdShow=0。SW_MAXIMIZE:最大化指定的窗口。nCmdShow=3。SW_MINIMIZE:最小化指定的窗口并且激活在Z序中的下一个顶层窗口。nCmdShow=6。SW_RESTORE:激活并显示窗口。如果窗口最小化或最大化,则系统将窗口恢复到原来的尺寸和位置。在恢复最小化窗口时,应用程序应该指定这个标志。nCmdShow=9。S...

2020-05-07 14:33:16 1264

原创 python Windows自动化bug

_ctypes.ComError: 别慌,可能是代码运行顺序问题,也可能是该内容没有正确与线程配合,或者是不能在线程内运行。

2020-04-01 14:39:50 239

原创 Python+Tkinter window窗口绘图

Tkinter相关教程:realpython,tutorialspoint给一段框出桌面上任意图标的代码练习——实际上是结合win32的python开源库uiautomation获取桌面上任意图标/窗口的坐标后,利用tkinter在图标上建立一个半透明带边框的窗口。from tkinter import Tk, Canvasimport uiautomation as uiade...

2020-03-28 14:26:35 2391

原创 adb 及Android系统相关 命令记录

Android终端(串口): 在设备环境中 stop adbd/start adbd 停止/启动adbd模拟器 ip addr 查看ip ip route 查看当前设备ip和网关 getprop |grep adb 查看adb运行状态 ip addr add 172.16.194.12/21 dev eth0 更改设备ip地址 i...

2019-05-08 16:32:54 273

原创 Django模板语言小记

2018-03-15 12:59:14 148

原创 python 注意点小记

编码类:1.中文转成正常字符串:aa.encode('latin').decode('gbk')

2018-01-19 14:14:40 176

原创 Django简单步骤(二)——数据(Models&Mysql)

举个栗子:import datetime as dtfrom django.db import modelsclass ProjectModel(models.Model): id = models.IntegerField('id', primary_key=True) proj_name = models.CharField(max_length=50, verbo

2018-01-15 17:34:35 158

原创 Django简单步骤(一)——安装及文件介绍

安装版本区分:(在下pycharm党,具体安装方式Google/Baidu)pip3 install django==2.0 # python 3.x版本 使用pip3django-admin startproject dj_tur(整项目名) python manage.py startapp app(应用名字)文件简要:

2018-01-15 16:28:55 251

原创 Linux+django 连接SqlServer的问题

error django.db.utils.Error: (‘IM002’, ‘[IM002] [Microsoft][ODBC xxxxxxx不知道是啥xxxxx]… 或 Exception Value: (‘08001’, ‘[08001] [unixODBC][FreeTDS][SQL Server]Unable to connect to data source (0) (S

2017-09-18 16:19:25 2239

原创 git 提交

CREATE -新建远程仓库,本地创建项目与连接:仓库创建一个新项目,项目名与本地项目名同名 - 复制仓库新项目的代码地址(HTTPS/ssh) 在项目一级目录下: git init # 当前项目目录生产本地Git管理和.git 目录 git add . # 添加所有文件 git commit -m “备注” git remote add origin http://yourpr...

2017-09-15 17:32:45 295

原创 nginx+uwsgi+django(restframework)服务器部署

django项目假设已完成安装问题nginx pip install nginxerror:uwsgi pip install uwsgi error no request plugin is loaded you will not be able to manage requests 解决:sudo apt-get install uwsgi-plugin-python

2017-09-14 17:32:13 727

原创 python 字符串错误+部分转码问题

'ascii' codec can't encode characters in position 3-6: ordinal not in range(128)解决:import sysreload(sys)sys.setdefaultencoding('utf-8')GBK 转 UTF8:(text).decode('gbk').encode('utf-8')UTF8

2017-08-16 13:59:27 475

原创 [失效py2.7]windows+Apache部署django项目部分流程及遇到的问题

花了我一天的时间到处百度谷歌问大神,终于部署成功了我的Django项目……在此抱怨windows作为生存环境的恶劣条件……此处只显示我所经过的流程,由于没有实时记录所以安装下载还是结合虫师点这里跳转以及LogMe的步骤点这里跳转一起看。简单的所需下载内容:Apache2.22下载,一步步next,遇到server Domain/serverName可以随便填写,注意格式,之后可在...

2017-05-23 08:26:00 6105 1

原创 Python面试相关

去参加了几个面试,记录一下问到的题目和答案。应试的是Python开发和运维相关。1:MySQL的内存引擎有几种(相对的作用和优势)?参考博客:MySQL中的各种引擎InnoDB、MyISAM、HEAP(MEMORY)、BLACKHOLE、ARCHIVE、CSV、PERFORMANCE_SCHEMA、Merge、Federated和Cluster/NDB等。 MyISAM:基于ISA

2017-03-08 00:39:46 525

原创 SSH 相关

远程映射至本地内网ssh -p8412 [email protected] -xfnNT -L 0.0.0.0:8058:localhost:8038

2017-02-28 23:27:46 243

原创 mysql操作遇到的问题

断连_mysql_exceptions.InterfaceError: (0, '')

2017-02-27 22:45:08 522

原创 PHP初学注意小记

格式:‘;’分号必须每行都带上。变量属性:global,local,staticglobal--全局变量,只用于函数之外,若函数内使用需标记: global $x; GLOBALS['$x']; #GLOBALS带'S'local  --局部变量,只能在当前函数使用。static --静态变量,连续调用函数变量值不被清除。数据类型:

2016-09-06 16:23:33 325

转载 Ubuntu配置Nginx,PHP环境

点击查看---- Nginx,Php环境配置

2016-09-06 08:32:23 261

原创 celery 简单应用及 redis的安装和启动

1.安装redis①wget http://download.redis.io/releases/redis-3.0.3.tar.gz②tar xzf redis-3.0.3.tar.gz③在redis-3.0.3目录下make,后会生成src目录,执行src下面的redis-server即可运行redis(./redis-server即时性运行)2.flask+celery简单应

2016-08-23 15:02:30 1326

原创 Django-restful-framwork(serializer相关)

serializer核心参数:(默认值)read_only (False)write_only (False)required (True) #若字段在反序列中不需要,设置成falseallow_null (False) #置空default #默认值source (source = 'user.email')#整个对象需要被传递来确定输出表示的字段,可用于创建嵌套关系

2016-07-07 10:47:40 820

原创 开发django过程中遇到的问题

ImportError:1.cannot define “template_pack”django——crispy_forms问题:注释掉local/lib/python2.7/site-packages/crispy_forms/utils.py中73行“form, form_style, context, template_pack=template_pack,”的“templat

2016-06-20 14:04:24 520

原创 安装WingIDE 及两条软件包删除命令 -ubuntu

官网下载personal5http://wingware.com/downloads/wingide-personalwingIDE 依赖两个包:libqt4-webkit        libjpeg62sudo dpkg -i wingide-personal5_5.1.9-1_amd64.deb-------失败的分割线--------目前wingIDE安装失败,因为依赖

2016-01-27 15:47:09 1989

原创 【过期技能】Django1.5+xadmin 显示问题,无法添加inline

添加了inline,inline如下所示,应该只有一条却多余显示无用的条框,且加号按钮无用,无法创建和保存解决方案:django-crispy-forms版本问题pip list查看安装的django-crispy-forms版本是多少,当时环境为django-crispy-forms == 1.5.2删除原版本pip uninstall django-crispy-f

2016-01-20 09:18:53 3221 2

转载 has a relation with model <class '***'>, which has either not been installed or is abstract.

projects.blacklist: 'pro_cont' has a relation with model , which has either not been installed or is abstract.关系:一个多对多关系中间表:class Project_pro_contract(models.Model): id = models.A

2015-12-30 10:45:44 671

翻译 ValueError:Cannot assign:A must be a 'B' instance.

原问题网址:http://stackoverflow.com/questions/10535604/cannot-assign-must-be-a-instance-django描述:Not sure where the confusion here is. Scripter.title is a foreign key toBook, so you must give

2015-12-17 09:34:03 8072

原创 python - django 部分安装命令

安装指定版本django(等号不留空)pip install django==1.6.1pip安装crispy-forms:pip install --upgrade django-crispy-formsdjango.core.exceptions.ImproperlyConfigured: Error loading MySQLdb module: No module named

2015-10-28 14:12:29 1850

转载 django自定义上传文件路径

根据http://blog.csdn.net/cendywang/article/details/17587849后得到自己的例子(想创建路径为‘excel/2015/001/filename’)例子:models.pydef get_path(self,filename): time = 'excel/%Y/' return datetime.now().selfti

2015-10-19 15:54:12 910

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除