# 斯坦福大学自然语言处理经典入门课程-Dan Jurafsky 和 Chris Manning 教授授课

https://www.bilibili.com/video/av95374756/

https://www.bilibili.com/video/av95620839/

https://www.bilibili.com/video/av95688853/

https://www.bilibili.com/video/av95689471/

https://www.bilibili.com/video/av95944973/

https://www.bilibili.com/video/av95951080/

https://www.bilibili.com/video/av95953429/

https://www.bilibili.com/video/av96298777/

https://www.bilibili.com/video/av96299315/

https://www.bilibili.com/video/av96314351/

https://www.bilibili.com/video/av96316377/

https://www.bilibili.com/video/av96675221/

https://www.bilibili.com/video/av96675891/

https://www.bilibili.com/video/av96676532/

https://www.bilibili.com/video/av96676976/

https://www.bilibili.com/video/av96736911/

https://www.bilibili.com/video/av96738129/

https://www.bilibili.com/video/av96738928/

https://www.bilibili.com/video/av96739766/

https://www.bilibili.com/video/av96740680/

# Coursera上博弈论相关课程（公开课）汇总推荐

1. 斯坦福大学的 博弈论（Game Theory）

This course is aimed at students, researchers, and practitioners who wish to understand more about strategic interactions. You must be comfortable with mathematical thinking and rigorous arguments. Relatively little specific math is required; but you should be familiar with basic probability theory (for example, you should know what a conditional probability is), and some very light calculus would be helpful.

Popularized by movies such as "A Beautiful Mind", game theory is the mathematical modeling of strategic interaction among rational (and irrational) agents. Over four weeks of lectures, this advanced course considers how to design interactions between agents in order to achieve good social outcomes. Three main topics are covered: social choice theory (i.e., collective decision making and voting systems), mechanism design, and auctions. In the first week we consider the problem of aggregating different agents' preferences, discussing voting rules and the challenges faced in collective decision making. We present some of the most important theoretical results in the area: notably, Arrow's Theorem, which proves that there is no "perfect" voting system, and also the Gibbard-Satterthwaite and Muller-Satterthwaite Theorems. We move on to consider the problem of making collective decisions when agents are self interested and can strategically misreport their preferences. We explain "mechanism design" -- a broad framework for designing interactions between self-interested agents -- and give some key theoretical results. Our third week focuses on the problem of designing mechanisms to maximize aggregate happiness across agents, and presents the powerful family of Vickrey-Clarke-Groves mechanisms. The course wraps up with a fourth week that considers the problem of allocating scarce resources among self-interested agents, and that provides an introduction to auction theory.

3. 东京大学的 博弈论入门课程（Welcome to Game Theory）

This course provides a brief introduction to game theory. Our main goal is to understand the basic ideas behind the key concepts in game theory, such as equilibrium, rationality, and cooperation. The course uses very little mathematics, and it is ideal for those who are looking for a conceptual introduction to game theory. Business competition, political campaigns, the struggle for existence by animals and plants, and so on, can all be regarded as a kind of “game,” in which individuals try to do their best against others. Game theory provides a general framework to describe and analyze how individuals behave in such “strategic” situations. This course focuses on the key concepts in game theory, and attempts to outline the informal basic ideas that are often hidden behind mathematical definitions. Game theory has been applied to a number of disciplines, including economics, political science, psychology, sociology, biology, and computer science. Therefore, a warm welcome is extended to audiences from all fields who are interested in what game theory is all about.

# Coursera上数据结构 & 算法课程（公开课）汇总推荐

1. 普林斯顿大学 Sedgewick 教授的 算法1: Algorithms, Part I

This course covers the essential information that every serious programmer needs to know about algorithms and data structures, with emphasis on applications and scientific performance analysis of Java implementations. Part I covers elementary data structures, sorting, and searching algorithms. Part II focuses on graph- and string-processing algorithms.

2. 普林斯顿大学 Sedgewick 教授的 算法2: Algorithms, Part II

“Part II较Part I在部分Programming Assignments上增加了timing和memory的难度，API100%不再意味着全部100%，这正是这门课程的精华之处：不是灌输算法知识，而是通过实际操作的过程让学员深入理解数据结构和算法调优在经济上的意义。个人很喜欢论坛上大家在Performance Thread里贴出自己的report然后交流优化心得的过程，很有圆桌会议的架势。这门课的教授Robert Sedgewick师出名门，是Knuth在斯坦福的博士。老爷子年岁已近70，一直活跃在论坛上解答和讨论问题，敬业程度让人赞叹。”

This course covers the essential information that every serious programmer needs to know about algorithms and data structures, with emphasis on applications and scientific performance analysis of Java implementations. Part I covers elementary data structures, sorting, and searching algorithms. Part II focuses on graph- and string-processing algorithms.

3. 斯坦福大学的 算法专项课程（Algorithms Specialization）

Algorithms are the heart of computer science, and the subject has countless practical applications as well as intellectual depth. This specialization is an introduction to algorithms for learners with at least a little programming experience. The specialization is rigorous but emphasizes the big picture and conceptual understanding over low-level implementation and mathematical details. After completing this specialization, you will be well-positioned to ace your technical interviews and speak fluently about algorithms with other programmers and computer scientists. About the instructor: Tim Roughgarden has been a professor in the Computer Science Department at Stanford University since 2004. He has taught and published extensively on the subject of algorithms and their applications.

The primary topics in this part of the specialization are: asymptotic ("Big-oh") notation, sorting and searching, divide and conquer (master method, integer and matrix multiplication, closest pair), and randomized algorithms (QuickSort, contraction algorithm for min cuts).

The primary topics in this part of the specialization are: data structures (heaps, balanced search trees, hash tables, bloom filters), graph primitives (applications of breadth-first and depth-first search, connectivity, shortest paths), and their applications (ranging from deduplication to social network analysis).

The primary topics in this part of the specialization are: greedy algorithms (scheduling, minimum spanning trees, clustering, Huffman codes) and dynamic programming (knapsack, sequence alignment, optimal search trees).

The primary topics in this part of the specialization are: shortest paths (Bellman-Ford, Floyd-Warshall, Johnson), NP-completeness and what it means for the algorithm designer, and strategies for coping with computationally intractable problems (analysis of heuristics, local search).

4. 北京大学的 程序设计与算法专项课程系列

This specialization is a mix of theory and practice: you will learn algorithmic techniques for solving various computational problems and will implement about 100 algorithmic coding problems in a programming language of your choice. No other online course in Algorithms even comes close to offering you a wealth of programming challenges that you may face at your next job interview. To prepare you, we invested over 3000 hours into designing our challenges as an alternative to multiple choice questions that you usually find in MOOCs. Sorry, we do not believe in multiple choice questions when it comes to learning algorithms...or anything else in computer science! For each algorithm you develop and implement, we designed multiple tests to check its correctness and running time — you will have to debug your programs without even knowing what these tests are! It may sound difficult, but we believe it is the only way to truly understand how the algorithms work and to master the art of programming. The specialization contains two real-world projects: Big Networks and Genome Assembly. You will analyze both road networks and social networks and will learn how to compute the shortest route between New York and San Francisco (1000 times faster than the standard shortest path algorithms!) Afterwards, you will learn how to assemble genomes from millions of short fragments of DNA and how assembly algorithms fuel recent developments in personalized medicine.

# 斯坦福大学机器学习第十一课“机器学习系统设计(Machine learning system design)”

1) Prioritizing what to work on: Spam classification example(工作的优先级：垃圾邮件分类例子)

2) Error analysis(错误分析)

3) Error metrics for skewed classes(不对称性分类的错误评估)

4) Trading off precision and recall(精确度和召回率的权衡)

5) Data for machine learning(数据对于机器学习的重要性)

1) Prioritizing what to work on: Spam classification example(工作的优先级：垃圾邮件分类例子)

x = 邮件的特征；
y = 垃圾邮件(1) 或 非垃圾邮件(0)

- 首先很自然的考虑到收集较多的数据，例如"honeypot" project,一个专门收集垃圾邮件服务器ip和垃圾邮件内容的项目；

- 但是上一章已经告诉我们，数据并不是越多越好，所以可以考虑设计其他复杂的特征，例如利用邮件的发送信息，这通常隐藏在垃圾邮件的顶部；

- 还可以考虑设计基于邮件主体的特征，例如是否将"discount"和"discounts"看作是同一个词？同理如何处理"deal"和"Dealer"? 还有是否将标点作为特征？

- 最后可以考虑使用复杂的算法来侦测错误的拼写（垃圾邮件会故意将单词拼写错误以逃避垃圾邮件过滤器，例如m0rtgage, med1cine, w4tches)

2) Error analysis(错误分析)

• - 从一个简单的算法入手这样可以很快的实现这个算法，并且可以在交叉验证集上进行测试；
• - 画学习曲线以决定是否更多的数据，更多的特征或者其他方式会有所帮助；
• - 错误分析：人工检查那些算法预测错误的例子（在交叉验证集上），看看能否找到一些产生错误的原因。

• (i) 邮件是什么类型的？
• (ii) 什么样的线索或特征你认为有可能对算法的正确分类有帮助？

• 对于discount/discounts/discounted/discounting 能否将它们看作是同一个词？
• 能不能使用“词干化”的工具包来取单词的词干，例如“Porter stemmer"？

• 不对单词提前词干：5%错误率   vs 对单词提取词干：3% 错误率
• 对大小写进行区分（Mom / mom): 3.2% 错误率

3) Error metrics for skewed classes(不对称性分类的错误评估)

True Positive （真正例, TP）被模型预测为正的正样本；可以称作判断为真的正确率

True Negative（真负例 , TN）被模型预测为负的负样本 ；可以称作判断为假的正确率

False Positive （假正例, FP）被模型预测为正的负样本；可以称作误报率

False Negative（假负例 , FN）被模型预测为负的正样本；可以称作漏报率

Precision-预测中实际得癌症的病人数量(真正例)除以我们预测的得癌症的病人数量：

Recall-预测中实际得癌症的病人数量(真正例)除以实际得癌症的病人数量：

4) Trading off precision and recall(精确度和召回率的权衡)

• 如果 $h_\theta(x) \ge 0.5$，则预测为1， 正例；
• 如果 $h_\theta(x) < 0.5$, 则预测为0， 负例；

F值是对精确度和召回率的一个很好的权衡，两种极端的情况也能很好的平衡：

5) Data for machine learning(数据对于机器学习的重要性)

For breakfast I ate ___ eggs

• -Perceptron(Logistic regression)
• -Winnow
• -Memory-based
• -Naïve Bayes

“It's not who has the best algorithm that wins. It's who has the most data."

http://en.wikipedia.org/wiki/Precision_and_recall

http://en.wikipedia.org/wiki/Accuracy_and_precision

True(False) Positives (Negatives)

http://en.wikipedia.org/wiki/F1_score

# 斯坦福大学机器学习第十课“应用机器学习的建议(Advice for applying machine learning)”

1) Deciding what to try next(决定下一步该如何做)

2) Evaluating a hypothesis(评估假设)

3) Model selection and training/validation/test sets(模型选择和训练/验证/测试集)

4) Diagnosing bias vs. variance(诊断偏差和方差)

5) Regularization and bias/variance(正则化和偏差/方差)

6) Learning curves(学习曲线)

7) Deciding what to try next (revisited)(再次决定下一步该做什么)

1) Deciding what to try next(决定下一步该如何做)

- 获取更多的训练样本

- 尝试使用更少的特征的集合

- 尝试获得其他特征

- 尝试添加多项组合特征

- 尝试减小 $\lambda$

- 尝试增加 $\lambda$

2) Evaluating a hypothesis(评估假设)

- 通过最小化训练集的error $J(\theta)$来学习参数$\theta$;
- 再计算测试集的error:

-首先从训练集中学习参数$\theta$;
-计算测试集的error:

-额外再加一个错误分类的error(或者称为0/1错误分类error);

3) Model selection and training/validation/test sets(模型选择和训练/验证/测试集)

4) Diagnosing bias vs. variance(诊断偏差和方差)

a) 高偏差(欠拟合):

b) 高方差(过拟合):

c) 合适的拟合：

5) Regularization and bias/variance(正则化和偏差/方差)

6) Learning curves(学习曲线)

7) Deciding what to try next (revisited)(再次决定下一步该做什么)

- 获取更多的训练样本

- 尝试使用更少的特征的集合

- 尝试获得其他特征

- 尝试添加多项组合特征

- 尝试减小 $\lambda$

- 尝试增加 $\lambda$

- 获取更多的训练样本 - 解决高方差

- 尝试使用更少的特征的集合 - 解决高方差

- 尝试获得其他特征 - 解决高偏差

- 尝试添加多项组合特征 - 解决高偏差

- 尝试减小 $\lambda$ - 解决高偏差

- 尝试增加 $\lambda$ -解决高方差

Mitchell教授的经典书籍《机器学习