I. Contents of the study1. Command Sys.path ()Show Current environment variables2. Command Os.system ("dir")Show files in current directory, show only, do not save results3. Command Text = Os.popen ("dir"). Read ()Displays the files in the current
1. dialog box, drop-down box(1) There are two kinds of dialog box, one is the IFRAME format, need to Switch_to_iframe () to locate, now most of the dialog is div format, this format can be positioned to locate the element, the dialog first position
Because the Webdriver API method is very long, plus most of the positioning method is positioned in the XPath way, more so that the code looks super long, in order to make the overall code look neat, the Webdriver encapsulation, learning data from
Installing the two plugins is simple and there are two ways to do it:1, online Installation:The method already has the PIP command installed by default, using Pip install XLRD and XLWT directly2. Offline installationDownload the two plugins from the
1 sys.argv command line argument list, the first element is the program itself path 2sys.exit (n) exit the program, exit normally exits (0)3 Sys.version Gets the version information of the Python interpreter 4sys.maxint
Not to study for the purpose of learning, it is bullying ~ So the rogue has become rich ...Well, it's not poverty. From one day onwards, the blog only talk about learning and feelings, do not talk about work, do not pull useless ~What's the whole
The two commonly used statements are 1. Conditional statements
If singly格式:if 条件表达式例如:if 5 > 3: print(‘True‘) >>> ‘True‘#当条件满足时才会执行上述操作。
if...else format: If conditional expression: Pass Else:pass for example: if 5 > 3:print (' OK ')
1. Capture camera and real-time displayImport Cv2import numpy as Npimport pickleimport matplotlib.pyplot as Pltcap = Cv2. Videocapture (0) while True: ret,frame = Cap.read () # We operations on the frame come here Gray = Cv2.cvtcolor (
Import Os,errno
#基本工具类
#① recursively generates a folder or file under the path of the input
#② recursively delete the folders and files below the input path
‘‘‘
Param:dirpath
return:
authorcreated by Wu Yongcong 2017-8-17
Places to be aware of1. Before using the variable, you need to assign a value first2. Variable names can include letters, numbers, underscores, but variable names cannot start with a number3. The letters can be uppercase or lowercase, but case
Import CopyDIC = {#定义一个字典, each element in the dictionary is an array."CPU": [80,],"Mem": [80],"Disk": [80,]}New_dic = Copy.copy (DIC) #浅拷贝, the first-level dictionary is copied and the memory space is reassigned. But the second-level array element
Weekend again, good fun, and can rest for two days! Recently are busy to buy computer things, here to tell you, try not to buy HP's computer, I bought less than a year, now basically is a scrap of iron. Heartache My Money money!Recently, several
This article mainly describes the python implementation of crawling need to log on the site, combined with a complete example of the Python landing site and data capture related operations skills, the need for friends can refer to the next
The
Virtualenv is a tool for creating an isolated python environment. VIRTUALENV Create a folder that contains all the necessary executables to use the packages required by the Python project.
After installing tools such as Python and pip,setuptools,
File read and write operations in a variety of programming languages are the more important part, is also a very common part, today to detail the Python file read and write operations, as well as the points to note.
One. Python Open file
The code
Here is a small series to bring you a python comparison of two elements of the array of similarities and differences method. Small series feel very good, now share to everyone, also for everyone to make a reference. Let's take a look at it with a
The enumerate function iterates through the elements in the sequence and their subscripts.
Enumerate function Description:
Function prototypes: Enumerate (sequence, [start=0])
Function: Sequence data and data subscript are listed separately for the
Instructions for use: in order to prevent malicious attacks, while not the original user login verification method code changes, in the test account password method and then set a layer of calibration method (verification code), filtering Non-human
Use Anaconda (reprinted) and use anaconda for reprintingAnaconda
Anaconda is a release that contains frequently used data science packages. It is derived from conda-a package and Environment Manager.
Anaconda is actually a software releaseconda,
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service