分类
摘要:
目录
Python基础__线程、进程、协程
1、什么是线程(thread)?
2、什么是进程(process)?
3、进程和线程的区别
4、GIL全局解释器锁
5、多线程(threading模块)
... 阅读原文
2019-04-07 00:49:05 阅读(2284) 评论(0)
摘要:
我是在安装scrapy时遇到这个问题的,安装其他组件也可能会遇到。但问题解决办法都是大致相同的。
以安装scrapy为例:
在pycharm中安装twisted或者scrapy时出现:
error: Microsoft Visual C++ 14.0 is required. Get it with “... 阅读原文
2019-04-07 00:00:03 阅读(2467) 评论(0)
摘要:
第四节 数据类型(列表、元祖)
今日内容
列表
元祖
1、列表
1.格式
users = ["ji",1,3,"gyhj"]
2.公共方法
1.len #计算长度
users = ["ji",1,3,"gyhj"]
val = len(users)
print(val) # 3
2.索引 #输出某一... 阅读原文
2019-04-06 21:39:02 阅读(3511) 评论(0)
摘要:
基本绘图:
(1) plot是标准的绘图库,调用函数plot(x,y)就可以创建一个带有绘图的图形窗口(其中y是x的函数)。输入的参数为具有相同长度的数组(或列表);或者plot(y)是plot(range(len(y)),y)的简写。
例1:python实现使用200个采样点来绘制sin(x),并且每隔四个点... 阅读原文
2019-04-06 20:55:04 阅读(2330) 评论(0)
摘要:
一、元组tuple
1、作用
存多个值,对比列表来说,元组不可变,主要是用来读。
2、定义
与列表类型比,只不过[ ]换成()
t = () #本质:t = tuple(())print(t,type(t)) #() <class 'tuple>#强制类型转换中,参数为for可以循环的对象... 阅读原文
2019-04-06 20:21:01 阅读(2395) 评论(0)
摘要:
一,本机配置
Win10 64bit
NVIDIA GeForce GTX 960M
Python3.7(Anaconda)
二,安装CUDA
亲测,TensorFlow-gpu1.13.1支持cuda10.0的版本,所以我们可直接选择cuda10.0的版本
Window10下载CUDA10
安装步骤为... 阅读原文
2019-04-06 19:20:02 阅读(2725) 评论(0)
摘要:
Instructions
John and Mary want to travel between a few towns A, B, C ... Mary has on a sheet of paper a list of distances between these towns. ls = [50, 55, ... 阅读原文
2019-04-06 19:09:02 阅读(2070) 评论(0)
摘要:
一、Linux 命令的基本使用
01. 常用 Linux 命令的基本使用
序号
命令
对应英文
作用
01
ls
list
查看当前文件夹下的内容
02
pwd
print wrok directory
查看当前所在文件夹
03
cd [目录名]
change directory
切换文件夹
0... 阅读原文
2019-04-06 19:05:01 阅读(2291) 评论(0)
摘要:
格式:\033[显示方式;前景色;背景色m + 结尾部分:\033[0m
字体色 | 背景色 | 颜色描述
-------------------------------------------
30 | 40 | 黑色
... 阅读原文
2019-04-06 17:50:01 阅读(2440) 评论(0)
摘要:
Instructions
In this kata, you must create a digital root function.
A digital root is the recursive sum of all the digits in a number. Given n, take the sum ... 阅读原文
2019-04-06 16:08:01 阅读(2404) 评论(0)