人工智能第二課(雅禮2020級(jí)高二下選修課)
2022-03-07 22:49 作者:Lit_費(fèi)米子の選擇_on | 我要投稿
UOS系統(tǒng)介紹:Linux內(nèi)核&Deepin基礎(chǔ)&國(guó)產(chǎn)系統(tǒng)


2.終端使用
Matplotlib嘗試? :Hexbin 演示
轉(zhuǎn)自Matplotlib:
import numpy as np
import matplotlib.pyplot as plt
# Fixing random state for reproducibility
np.random.seed(19680801)
n = 100000
x = np.random.standard_normal(n)
y = 2.0 + 3.0 * x + 4.0 * np.random.standard_normal(n)
xmin = x.min()
xmax = x.max()
ymin = y.min()
ymax = y.max()
fig, axs = plt.subplots(ncols=2, sharey=True, figsize=(7, 4))
fig.subplots_adjust(hspace=0.5, left=0.07, right=0.93)
ax = axs[0]
hb = ax.hexbin(x, y, gridsize=50, cmap='inferno')
ax.axis([xmin, xmax, ymin, ymax])
ax.set_title("Hexagon binning")
cb = fig.colorbar(hb, ax=ax)
cb.set_label('counts')
ax = axs[1]
hb = ax.hexbin(x, y, gridsize=50, bins='log', cmap='inferno')
ax.axis([xmin, xmax, ymin, ymax])
ax.set_title("With a log color scale")
cb = fig.colorbar(hb, ax=ax)
cb.set_label('log10(N)')
plt.show()
嘗試:OHHHHHHHHH

3.建立虛擬環(huán)境
(1).清華:計(jì)圖 jittor? ?華為:昇思?
(2)Anaconda:base環(huán)境等
NOTE:代碼包與環(huán)境必須適配
(3)部分簡(jiǎn)單代碼及操作
*按前兩個(gè)代碼,再用Tab補(bǔ)全
*mkdir? ?新建文件夾
*rm -rf? ?刪除
*cd? ?進(jìn)入
*jupyter-notebook? ?網(wǎng)頁(yè)python?
*netstat-nultp? ?查看正在運(yùn)行的程序
*top? ?看活躍程序
*ls? ?目錄中所有文件
*pwd? ?查看目錄路徑
* .? ?自己
* ..? ?上一級(jí)
*開(kāi)啟:conda active jittor
*殺死:conda deactive
Note:安裝時(shí)注意版本,如 python 3.7.5
標(biāo)簽: