Py
Wyhn.Wang
Have a nice day!
展开
-
pytorch分布式报错 “tensor must be non-overlapping and dense“
tensor拆分后出现的错误,将tensor连续化即可:t1=t1.contiguous()原创 2021-02-04 09:27:59 · 1694 阅读 · 0 评论 -
[Python]爬拉钩(Python职位)
import requestsfrom bs4 import BeautifulSoupimport timeimport random#header里面加上cookie防止被bandef getHTMLText(url,encoding='utf-8'): header_list=["Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKi...原创 2018-07-15 15:44:10 · 419 阅读 · 0 评论 -
Pycharm自带database连接数据库报错
java.lang.RuntimeException: com.mysql.cj.exceptions.InvalidConnectionAttributeException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone. You must conf...原创 2019-04-26 15:38:13 · 1979 阅读 · 3 评论 -
Python获取随机字母
import stringimport randoms = string.ascii_letters# 大写string.ascii_uppercase# 小写string.ascii_lowercaser = random.choice(s)print(r)原创 2019-04-25 10:32:16 · 10923 阅读 · 2 评论