随笔分类 - python
摘要:import time from selenium import webdriver browser = webdriver.Chrome() wait_time = 1 USER = 'xl.feng' PWD = 'fengxiaole' seed_url = 'http://xx.com/login.jhtml' browser.get(seed_url) # time.sleep...
阅读全文
摘要:from scipy import integrate
阅读全文
摘要:en.wikipedia.org/wiki/Yum_(.rpm) The Yellowdog Updater, Modified (yum) is an open-source command-line package-management utility for computers running
阅读全文
摘要:w
阅读全文
摘要:python 虚拟机是单线程;当线程执行I/O密集型操作是 单核CPU,不存在“并行”,与语言无关:每个线程运行中,其他线程等待该线程让步 粗粒度的并行 靠 软件,细 硬
阅读全文
摘要:使用文本编辑器 - 廖雪峰的官方网站 https://www.liaoxuefeng.com/wiki/1016959663602400/1017024645952992 直接输入python进入交互模式,相当于启动了Python解释器,但是等待你一行一行地输入源代码,每输入一行就执行一行。 直接运
阅读全文
摘要:[root@hadoop1 nlp]# python sqlserver_t.py Traceback (most recent call last): File "sqlserver_t.py", line 1, in <module> import pymssqlImportError: lib
阅读全文
摘要:https://zhuanlan.zhihu.com/p/31674972 https://rainmanwy.github.io/Python的final-Class/
阅读全文
摘要:js 获取文本 //获取标签机器子标签的所有文本内容 var box = document.getElementById('box'); var box2 = box.innerText; console.log(box2); product.xpath("div//div[@class='a-ro
阅读全文
摘要:w http://www.liaoxuefeng.com/wiki/001374738125095c955c1e6d8bb493182103fac9270762a000/0013747381369301852037f35874be2b85aa318aad57bda000 第一个缺点就是运行速度慢,和
阅读全文
摘要:http://legacy.python.org/dev/peps/pep-0008/ Object type comparisons should always use isinstance() instead of comparing types directly. When checking
阅读全文
摘要:w http://legacy.python.org/dev/peps/pep-0008/ Yes: if foo.startswith('bar'):No: if foo[:3] == 'bar':
阅读全文
摘要:https://docs.python.org/3/library/threading.html Return the ‘thread identifier’ of the current thread. This is a nonzero integer. Its value has no dir
阅读全文
摘要:import os, sys os_sep = os.sep base_dir = os.path.dirname(os_sep.join(os.path.abspath(__file__).split(os_sep)[0: 2])) sys.path.append(base_dir) from c
阅读全文
摘要:向同一个模型的外键反向关联名称产生了冲突 一个模型中有两个外键指向同一张表时,创建迁移模型时报错:“ HINT: Add or change a related_name argument to the definition for 'AnswersModel.author' or 'Answers
阅读全文
摘要:w https://docs.python.org/3/library/functions.html#isinstance
阅读全文
摘要:import inspect def checkpoint(): '''Instrumented `yield checkpoint()` goes here''' f = inspect.stack()[1].frame # stack[1] is the caller of checkpoint
阅读全文
摘要:w 29.4. __main__ — Top-level script environment — Python 3.6.1 documentation https://docs.python.org/3/library/__main__.html D:\pyTOgo\mongoTrans.py
阅读全文

浙公网安备 33010602011771号