国产人妻人伦精品_欧美一区二区三区图_亚洲欧洲久久_日韩美女av在线免费观看

合肥生活安徽新聞合肥交通合肥房產(chǎn)生活服務(wù)合肥教育合肥招聘合肥旅游文化藝術(shù)合肥美食合肥地圖合肥社保合肥醫(yī)院企業(yè)服務(wù)合肥法律

DDA3020代做、代寫Python語言編程
DDA3020代做、代寫Python語言編程

時(shí)間:2024-10-12  來源:合肥網(wǎng)hfw.cc  作者:hfw.cc 我要糾錯(cuò)



DDA3020 Homework 1
Due date: Oct 14, 2024
Instructions
• The deadline is 23:59, Oct 14, 2024.
• The weight of this assignment in the ffnal grade is 20%.
• Electronic submission: Turn in solutions electronically via Blackboard. Be sure to submit
 your homework as one pdf ffle plus two python scripts. Please name your solution ffles as
”DDA3020HW1 studentID name.pdf”, ”HW1 yourID Q1.ipynb” and ”HW1 yourID Q2.ipynb”.
(.py ffles also acceptable)
• Note that late submissions will result in discounted scores: 0-24 hours → 80%, 24-120 hours
→ 50%, 120 or more hours → 0%.
• Answer the questions in English. Otherwise, you’ll lose half of the points.
• Collaboration policy: You need to solve all questions independently and collaboration between
students is NOT allowed.
1 Written Problems (50 points)
1.1. (Learning of Linear Regression, 25 points) Suppose we have training data:
{(x1, y1),(x2, y2), . . . ,(xN , yN )},
where xi ∈ R
d and yi ∈ R
k
, i = 1, 2, . . . , N.
i) (9 pts) Find the closed-form solution of the following problem.
min
W,b
X
N
i=1
∥yi − Wxi − b∥
2
2
,
ii) (8 pts) Show how to use gradient descent to solve the problem. (Please state at least one
possible Stopping Criterion)
1DDA3020 Machine Learning Autumn 2024, CUHKSZ
iii) (8 pts) We further suppose that x1, x2, . . . , xN are drawn from N (µ, σ
2
). Show that the
maximum likelihood estimation (MLE) of σ
2
is σˆ
2
MLE =
1
N
PN
n=1
(xn − µMLE)
2
.
1.2. (Support Vector Machine, 25 points) Given two positive samples x1 = (3, 3)
T
, x2 =
(4, 3)
T
, and one negative sample x3 = (1, 1)
T
, ffnd the maximum-margin separating hyperplane and
support vectors.
Solution steps:
i) Formulating the Optimization Problem (5 pts)
ii) Constructing the Lagrangian (5 pts)
iii) Using KKT Conditions (5 pts)
iv) Solving the Equations (5 pts)
v) Determining the Hyperplane Equation and Support Vectors (5 pts)
2 Programming (50 points)
2.1. (Linear regression, 25 points) We have a labeled dataset D = {(x1, y1),(x2, y2),
· · · ,(xn, yn)}, with xi ∈ R
d being the d-dimensional feature vector of the i-th sample, and yi ∈ R
being real valued target (label).
A linear regression model is give by
fw0,...,wd
(x) = w0 + w1x1 + w2x2 + · · · + wdxd, (1)
where w0 is often called bias and w1, w2, . . . , wd are often called coefffcients.
Now, we want to utilize the dataset D to build a linear model based on linear regression.
We provide a training set Dtrain that includes 2024 labeled samples with 11 features (See linear
 regression train.txt) to fft model, and a test set Dtest that includes 10 unlabeled samples with
11 features (see linear regression test.txt) to estimate model.
1. Using the LinearRegression class from Sklearn package to get the bias w0 and the coefffcients
w1, w2, . . . , w11, then computing the yˆ = f(x) of test set Dtest by the model trained well. (Put
the estimation of w0, w1, . . . , w11 and these yˆ in your answers.)
2. Implementing the linear regression by yourself to obtain the bias w0 and the coefffcients
w1, w2, . . . , w11, then computing the yˆ = f(x) of test set Dtest. (Put the estimation of
w0, w1, . . . , w11 and these yˆ in your answers. It is allowed to compute the inverse of a matrix
using the existing python package.)
2DDA3020 Machine Learning Autumn 2024, CUHKSZ
(Hint: Note that for linear regression train.txt, there are 2024 rows with 12 columns where the
ffrst 11 columns are features x and the last column is target y and linear regression test.txt
only contains 10 rows with 11 columns (features). Both of two tasks require the submission of
code and results. Put all the code in a “HW1 yourID Q1.ipynb” Jupyter notebook. ffle.(”.py”
ffle is also acceptable))
2.2. (SVM, 25 points)
Task Description You are asked to write a program that constructs support vector machine
models with different kernel functions and slack variables.
Datasets You are provided with the iris dataset. The data set contains 3 classes of 50 instances
each, where each class refers to a type of iris plant. There are four features: 1. sepal length in cm;
2. sepal width in cm; 3. petal length in cm; 4. petal width in cm. You need to use these features
to classify each iris plant as one of the three possible types.
What you should do You should use the SVM function from python sklearn package, which
provides various forms of SVM functions. For multiclass SVM you should use the one vs rest
strategy. You are recommended to use sklearn.svm.svc() function. You can use numpy for vector
manipulation. For technical report, you should report the results required as mentioned below (e.g.
training error, testing error, and so on).
1. (2 points) Split training set and test set. Split the data into a training set and a test set.
The training set should contain 70% of the samples, while the test set should include 30%.
The number of samples from each category in both the training and test sets should reffect
this 70-30 split; for each category, the ffrst 70% of the samples will form the training set, and
the remaining 30% will form the test set. Ensure that the split maintains the original order
of the data. You should report instance ids in the split training set and test set. The output
format is as follows:
Q2.2.1 Split training set and test set:
Training set: xx
Test set: xx
You should ffll up xx in the template. You should write ids for each set in the same line with
comma separated, e.g. Training set:[1, 4, 19].
2. (10 points) Calculation using Standard SVM Model (Linear Kernel). Employ the
standard SVM model with a linear kernel. Train your SVM on the split training dataset and
3DDA3020 Machine Learning Autumn 2024, CUHKSZ
validate it on the testing dataset. Calculate the classiffcation error for both the training and
testing datasets, output the weight vector w, the bias b, and the indices of support vectors
(start with 0). Note that the scikit-learn package does not offer a function with hard margin,
so we will simulate this using C = 1e5. You should ffrst print out the total training error
and testing error, where the error is
wrong prediction
number of data
. Then, print out the results for each class
separately (note that you should calculate errors for each class separately in this part). You
should also mention in your report which classes are linear separable with SVM without slack.
The output format is as follows:
Q2.2.2 Calculation using Standard SVM Model:
total training error: xx, total testing error: xx,
class setosa:
training error: xx, testing error: xx,
w: xx, b: xx,
support vector indices: xx,
class versicolor:
training error: xx, testing error: xx,
w: xx, b: xx,
support vector indices: xx,
class virginica:
training error: xx, testing error: xx,
w: xx, b: xx,
support vector indices: xx,
Linear separable classes: xx
If we view the one vs all strategy as combining the multiple different SVM, each one being
a separating hyperplane for one class and the rest of the points, then the w, b and support
vector indices for that class is the corresponding parameters for the SVM separating this class
and the rest of the points. If a variable is of vector form, say a =


1
2
3
?**4;
?**5;?**5;?**6;, then you should write
each entry in the same line with comma separated e.g. [1,2,3].
3. (6 points) Calculation using SVM with Slack Variables (Linear Kernel). For each
C = 0.25 × t, where t = 1, 2, . . . , 4, train your SVM on the training dataset, and subsequently
validate it on the testing dataset. Calculate the classiffcation error for both the training and
testing datasets, the weight vector w, the bias b, and the indices of support vectors, and the
slack variable ζ of support vectors (you may compute it as max(0, 1 − y · f(X)). The output
format is as follows:
Q2.2.3 Calculation using SVM with Slack Variables (C = 0.25 × t, where t = 1, . . . , 4):
4DDA3020 Machine Learning Autumn 2024, CUHKSZ
-------------------------------------------
C=0.25,
total training error: xx, total testing error: xx,
class setosa:
training error: xx, testing error: xx,
w: xx, b: xx,
support vector indices: xx,
slack variable: xx,
class versicolor:
training error: xx, testing error: xx,
w: xx, b: xx,
support vector indices: xx,
slack variable: xx,
class virginica:
training error: xx, testing error: xx,
w: xx, b: xx,
support vector indices: xx,
slack variable: xx,
-------------------------------------------
C=0.5,
<... results for (C=0.5) ...>
-------------------------------------------
C=0.75,
<... results for (C=0.75) ...>
-------------------------------------------
C=1,
<... results for (C=1) ...>
4. (7 points) Calculation using SVM with Kernel Functions. Conduct experiments with
different kernel functions for SVM without slack variable. Calculate the classiffcation error
for both the training and testing datasets, and the indices of support vectors for each kernel
type:
(a) 2nd-order Polynomial Kernel
(b) 3nd-order Polynomial Kernel
(c) Radial Basis Function Kernel with σ = 1
(d) Sigmoidal Kernel with σ = 1
The output format is as follows:
5DDA3020 Machine Learning Autumn 2024, CUHKSZ
Q2.2.4 Calculation using SVM with Kernel Functions:
-------------------------------------------
(a) 2nd-order Polynomial Kernel,
total training error: xx, total testing error: xx,
class setosa:
training error: xx, testing error: xx,
w: xx, b: xx,
support vector indices: xx,
class versicolor:
training error: xx, testing error: xx,
w: xx, b: xx,
support vector indices: xx,
class virginica:
training error: xx, testing error: xx,
w: xx, b: xx,
support vector indices: xx,
-------------------------------------------
(b) 3nd-order Polynomial Kernel,
<... results for (b) ...>
-------------------------------------------
(c) Radial Basis Function Kernel with σ = 1,
<... results for (c) ...>
-------------------------------------------
(d) Sigmoidal Kernel with σ = 1,
<... results for (d) ...>
Submission Submit your executable code in a “HW1 yourID Q2.ipynb” Jupyter notebook(”.py”
file is also acceptable). Indicate the corresponding question number in the comment for each cell,
and ensure that your code can logically produce the required results for each question in the required
format. Please note that you need to write clear comments and use appropriate function/variable
names. Excessively unreadable code may result in point deductions.

6

請加QQ:99515681  郵箱:99515681@qq.com   WX:codinghelp




 

掃一掃在手機(jī)打開當(dāng)前頁
  • 上一篇:代做CS 259、Java/c++設(shè)計(jì)程序代寫
  • 下一篇:代做MSE 280、代寫Matlab程序語言
  • 無相關(guān)信息
    合肥生活資訊

    合肥圖文信息
    流體仿真外包多少錢_專業(yè)CFD分析代做_友商科技CAE仿真
    流體仿真外包多少錢_專業(yè)CFD分析代做_友商科
    CAE仿真分析代做公司 CFD流體仿真服務(wù) 管路流場仿真外包
    CAE仿真分析代做公司 CFD流體仿真服務(wù) 管路
    流體CFD仿真分析_代做咨詢服務(wù)_Fluent 仿真技術(shù)服務(wù)
    流體CFD仿真分析_代做咨詢服務(wù)_Fluent 仿真
    結(jié)構(gòu)仿真分析服務(wù)_CAE代做咨詢外包_剛強(qiáng)度疲勞振動(dòng)
    結(jié)構(gòu)仿真分析服務(wù)_CAE代做咨詢外包_剛強(qiáng)度疲
    流體cfd仿真分析服務(wù) 7類仿真分析代做服務(wù)40個(gè)行業(yè)
    流體cfd仿真分析服務(wù) 7類仿真分析代做服務(wù)4
    超全面的拼多多電商運(yùn)營技巧,多多開團(tuán)助手,多多出評軟件徽y1698861
    超全面的拼多多電商運(yùn)營技巧,多多開團(tuán)助手
    CAE有限元仿真分析團(tuán)隊(duì),2026仿真代做咨詢服務(wù)平臺(tái)
    CAE有限元仿真分析團(tuán)隊(duì),2026仿真代做咨詢服
    釘釘簽到打卡位置修改神器,2026怎么修改定位在范圍內(nèi)
    釘釘簽到打卡位置修改神器,2026怎么修改定
  • 短信驗(yàn)證碼 豆包網(wǎng)頁版入口 破天一劍 目錄網(wǎng) 排行網(wǎng)

    關(guān)于我們 | 打賞支持 | 廣告服務(wù) | 聯(lián)系我們 | 網(wǎng)站地圖 | 免責(zé)聲明 | 幫助中心 | 友情鏈接 |

    Copyright © 2025 hfw.cc Inc. All Rights Reserved. 合肥網(wǎng) 版權(quán)所有
    ICP備06013414號-3 公安備 42010502001045

    国产人妻人伦精品_欧美一区二区三区图_亚洲欧洲久久_日韩美女av在线免费观看
    热久久精品免费视频| 国产极品粉嫩福利姬萌白酱| 国产综合免费视频| 99久久综合狠狠综合久久止 | 国产日本欧美一区二区三区在线| 日韩一区在线视频| 欧美一区二区三区在线免费观看 | 人人妻人人澡人人爽欧美一区双| 97色在线播放视频| 欧美激情精品在线| 国产在线欧美日韩| 国产精品国产亚洲精品看不卡 | 操91在线视频| 精品一区二区不卡| 国产精品久久久久久久久久新婚| 欧美日韩精品免费观看视一区二区| 久久天堂国产精品| 午夜啪啪福利视频| 91精品国产91久久久久久最新 | 亚洲精品乱码视频| 99视频在线免费观看| 在线观看一区二区三区三州| 国产欧美综合一区| 欧美日韩成人黄色| 国产在线播放91| 麻豆国产精品va在线观看不卡| 精品无码久久久久久久动漫| 欧美成aaa人片在线观看蜜臀| 国产一区亚洲二区三区| 欧美精品一区三区| 成人av在线亚洲| 午夜欧美性电影| 国产成人综合精品在线| 全黄性性激高免费视频| 久久天天躁狠狠躁夜夜躁| 国模精品一区二区三区色天香| 精品国产免费久久久久久尖叫| 国产乱子夫妻xx黑人xyx真爽| 亚洲综合中文字幕在线观看| 国产精品小说在线| 亚洲精品日韩精品| 久久国产午夜精品理论片最新版本| 日韩免费毛片| 国产精品成人一区二区| 成人免费网站在线| 无码人妻精品一区二区三区99v| 久久影院理伦片| 欧美亚洲一二三区| 精品久久久久久亚洲| 91久久精品美女| 欧美在线视频导航| 色综合久久悠悠| 国产黑人绿帽在线第一区| 欧美日本韩国一区二区三区| 国产精品成人久久电影| 北条麻妃在线视频观看| 日本电影一区二区三区| 国产精品第100页| 91精品国产电影| 精品www久久久久奶水| 在线视频福利一区| 日韩专区在线播放| 国产美女主播一区| 日韩精品久久久| 国产精品久久久久久久av电影| 99国产精品久久久久老师| 欧洲成人在线视频| 国产a∨精品一区二区三区不卡 | 国产精品色午夜在线观看| 福利在线一区二区| 欧美有码在线观看视频| 欧美激情一区二区三区高清视频| 国产福利精品视频| 国产亚洲综合视频| 日韩福利视频| 欧美激情中文网| 国产精品手机播放| 国产精品91久久| 国产亚洲欧美一区二区| 欧美一级片中文字幕| 国产精品入口尤物| 国产成人在线一区| 成人羞羞国产免费| 欧美在线视频观看免费网站| 亚洲bt天天射| 精品国产乱码久久久久久108| 久久久久久久久久久免费精品| 成人a在线观看| 国产视频不卡| 欧美极品日韩| 日本精品久久久久中文字幕| 欧美精品激情在线观看| 国产精品视频久久久久| 久久精品国产sm调教网站演员 | 91高潮在线观看| 国产日本欧美一区二区三区在线| 欧美日韩午夜爽爽| 日韩一区免费观看| 成人久久18免费网站漫画| 蜜桃成人免费视频| 亚洲精品免费一区二区三区| 国产精品久久二区| 久久人人爽人人爽人人片av高清 | 91观看网站| 丰满少妇久久久| 精品一区久久| 欧美日本韩国在线| 日韩精品欧美专区| 少妇人妻互换不带套| 亚洲色欲久久久综合网东京热 | 久久婷婷开心| 国产精品99久久久久久白浆小说| 啊啊啊一区二区| 国产欧美日韩综合精品二区| 精品日产一区2区三区黄免费 | 99精品99久久久久久宅男| 黄色一级二级三级| 欧美日韩视频免费| 亚洲最大福利视频网| 在线观看国产一区| 一区二区不卡视频| 在线日韩av永久免费观看| 麻豆成人在线看| 久久亚洲精品小早川怜子66| 国产精品三级久久久久久电影 | 久久青青草原一区二区| 久久久亚洲国产精品| 777精品视频| 国产成人精品久久亚洲高清不卡| 8090成年在线看片午夜| 久久久综合亚洲91久久98| 久久久水蜜桃| 久久久久久亚洲精品不卡| 日韩中文字幕视频在线| 色妞欧美日韩在线| 精品国产一区久久久| 国产精品免费一区二区三区四区| www.色综合| 国产精品网站入口| 久久这里只有精品99| 伊人久久大香线蕉午夜av| 亚洲欧洲日本国产| 日本三级中文字幕在线观看| 欧美综合第一页| 蜜桃成人免费视频| 国产精品一 二 三| 久青草视频在线播放 | 亚洲砖区区免费| 日韩中文不卡| 欧洲久久久久久| 极品校花啪啪激情久久| 精品一区二区三区毛片| 国产精自产拍久久久久久| 操人视频欧美| 国产精品12345| 久久久久久久久一区二区| 久久人人爽亚洲精品天堂| 欧美成aaa人片在线观看蜜臀| 欧美精品福利在线| 都市激情久久久久久久久久久| 秋霞在线观看一区二区三区| 国产在线一区二区三区播放| 超碰97网站| 久久久久久久久久av| 欧美另类第一页| 亚洲精品一区二区三区樱花| 日本a视频在线观看| 国产亚洲欧美一区二区| 久久免费视频1| 精品久久免费观看| 日本一区精品| 国产午夜福利在线播放| 国产成人激情视频| 精品久久久久av| 日韩av在线综合| 国产无套粉嫩白浆内谢的出处| 久久男人的天堂| 国产精品果冻传媒潘| 日韩成人av电影在线| 免费久久99精品国产自| 91精品国产高清久久久久久91| 北条麻妃一区二区三区中文字幕| 欧美精品国产精品日韩精品| 欧美专区中文字幕| 成人免费视频97| 久久视频精品在线| 亚洲精品久久久久久一区二区 | 国产精品国产亚洲伊人久久| 日本一区二区三区视频免费看| 国产又粗又猛又爽又黄的网站| 97免费视频在线播放| 国产精品视频久久久久| 熟女少妇精品一区二区| 国产在线拍揄自揄视频不卡99| 久久久久欧美| 亚洲色成人www永久在线观看| 欧美国产视频一区| 久久精品一区二| 久久99久久久久久久噜噜| 欧美日韩国产精品一卡|