当前位置:网站首页>程序员写PPT的小技巧
程序员写PPT的小技巧
2022-08-02 05:09:00 【大淘宝技术】

▐ 将reveal.js运行起来
git clone https://github.com/hakimel/reveal.js
<!doctype html><html> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"> <title>reveal.js</title> <link rel="stylesheet" href="dist/reset.css"> <link rel="stylesheet" href="dist/reveal.css"> <link rel="stylesheet" href="dist/theme/black.css"> <!-- Theme used for syntax highlighted code --> <link rel="stylesheet" href="plugin/highlight/monokai.css"> </head> <body> <div class="reveal"> <div class="slides"> <section>Slide 1</section> <section>Slide 2</section> </div> </div> <script src="dist/reveal.js"></script> <script src="plugin/notes/notes.js"></script> <script src="plugin/markdown/markdown.js"></script> <script src="plugin/highlight/highlight.js"></script> <script> // More info about initialization & config: // - https://revealjs.com/initialization/ // - https://revealjs.com/config/ Reveal.initialize({ hash: true, // Learn about plugins: https://revealjs.com/plugins/ plugins: [ RevealMarkdown, RevealHighlight, RevealNotes ] });</script> </body></html>
npm start -- --port=30800

▐ reveal.js step by step
<div class="reveal">
<div class="slides">
<section>Slide 1</section>
<section>Slide 2</section>
</div>
</div>
▐ 支持markdown
<section data-markdown>
<textarea data-markdown>
</textarea>
</section>
<section data-markdown>
<textarea data-markdown>
推荐系统的主要算法包括:
- 矩阵分解
- 线性模型
- 树模型
- 深度学习模型
</textarea>
</section>

▐ 换个主题
<link rel="stylesheet" href="dist/theme/black.css">
<link rel="stylesheet" href="dist/theme/beige.css">

▐ 支持数学公式
<script src="plugin/math/math.js"></script>
Reveal.initialize({
hash: true,
math: {
mathjax:
"https://cdn.jsdelivr.net/gh/mathjax/[email protected]/MathJax.js",
config: "TeX-AMS_HTML-full",
// pass other options into `MathJax.Hub.Config()`
TeX: { Macros: { RR: "{\\bf R}" } },
},
plugins: [RevealMarkdown, RevealHighlight, RevealNotes, RevealMath], });
<script src="plugin/math/math.js"></script>
<script>
Reveal.initialize({
hash: true,
math: {
mathjax:
"https://cdn.jsdelivr.net/gh/mathjax/[email protected]/MathJax.js",
config: "TeX-AMS_HTML-full",
// pass other options into `MathJax.Hub.Config()`
TeX: { Macros: { RR: "{\\bf R}" } },
},
plugins: [RevealMarkdown, RevealHighlight, RevealNotes, RevealMath],
});
</script>
<section>
\[\begin{aligned}
\ MAE(X,h)=\frac{1}{m} \sum_{i=1}^m|h(x^i)-y^{(i)}| \
\end{aligned} \]
</section>
<section data-markdown>
<textarea data-markdown>
$MAE(X,h)=\frac{1}{m} \sum_{i=1}^m|h(x^i)-y^{(i)}|$
</textarea>
</section>

▐ 代码高亮


<section>
<pre>
<code class="language-javascript">
model.compile({
optimizer: tf.train.sgd(0.000001),
loss: 'meanSquaredError'
});
return model.fitDataset(flattenedDataset, {
epochs: 10,
callbacks: {
onEpochEnd: async (epoch, logs) => {
console.log(epoch + ':' + logs.loss);
}
}
});
</code>
</pre>
</section>

<link rel="stylesheet" href="plugin/highlight/zenburn.css" />
<link rel="stylesheet" href="dist/theme/moon.css" />

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta
name="viewport"
content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"
/>
<title>reveal.js学习</title>
<link rel="stylesheet" href="dist/reset.css" />
<link rel="stylesheet" href="dist/reveal.css" />
<link rel="stylesheet" href="dist/theme/moon.css" />
<!-- Theme used for syntax highlighted code -->
<link rel="stylesheet" href="plugin/highlight/monokai.css" />
</head>
<body>
<div class="reveal">
<div class="slides">
<section>Slide 1</section>
<section>
\[\begin{aligned}
\ MAE(X,h)=\frac{1}{m} \sum_{i=1}^m|h(x^i)-y^{(i)}| \
\end{aligned} \]
</section>
<section data-markdown>
<textarea data-markdown>
推荐系统的主要算法包括:
- 矩阵分解
- 线性模型
- 树模型
- 深度学习模型
</textarea
>
</section>
<section data-markdown>
<textarea data-markdown>
$MAE(X,h)=\frac{1}{m} \sum_{i=1}^m|h(x^i)-y^{(i)}|$
</textarea>
</section>
<section>
<pre>
<code class="language-javascript">
model.compile({
optimizer: tf.train.sgd(0.000001),
loss: 'meanSquaredError'
});
return model.fitDataset(flattenedDataset, {
epochs: 10,
callbacks: {
onEpochEnd: async (epoch, logs) => {
console.log(epoch + ':' + logs.loss);
}
}
});
</code>
</pre>
</section>
</div>
</div>
<script src="dist/reveal.js"></script>
<script src="plugin/notes/notes.js"></script>
<script src="plugin/markdown/markdown.js"></script>
<script src="plugin/highlight/highlight.js"></script>
<script src="plugin/math/math.js"></script>
<script>
// More info about initialization & config:
// - https://revealjs.com/initialization/
// - https://revealjs.com/config/
Reveal.initialize({
hash: true,
math: {
mathjax:
"https://cdn.jsdelivr.net/gh/mathjax/[email protected]/MathJax.js",
config: "TeX-AMS_HTML-full",
// pass other options into `MathJax.Hub.Config()`
TeX: { Macros: { RR: "{\\bf R}" } },
},
// Learn about plugins: https://revealjs.com/plugins/
plugins: [RevealMarkdown, RevealHighlight, RevealNotes, RevealMath],
});
</script>
</body>
</html>
▐ 背景图片
<section data-background-image="https://cdn.jsdelivr.net/www.jsdelivr.com/000a3f2b6a7baa6ae0f786a251fd105e4b230d8e/img/landing/[email protected]"> </section>
▐ HTML and CSS
<section>
<h3 style="{color: #ffec3d;}">推荐系统的冷启动</h3>
<ul>
<li>利用热门数据</li>
<li>利用用户注册信息</li>
<li>利用第三方数据</li>
<li>利用物品内容属性</li>
</ul>
</section>
<style>
ul {
font-size: 18px;
}
</style>
▐ 淡入淡出
<section>
<h3>推荐系统的冷启动</h3>
<ul>
<li class="fragment">利用热门数据</li>
<li class="fragment">利用用户注册信息</li>
<li class="fragment">利用第三方数据</li>
<li class="fragment">利用物品内容属性</li>
</ul>
</section>

<section>
<h3>推荐系统的冷启动</h3>
<ul>
<li class="fragment highlight-red">利用热门数据</li>
<li>利用用户注册信息</li>
<li>利用第三方数据</li>
<li>利用物品内容属性</li>
</ul>
</section>

▐ 导出为PDF

▐ 更进一步


本文分享自微信公众号 - 淘系技术(AlibabaMTT)。
如有侵权,请联系 [email protected] 删除。
本文参与“OSC源创计划”,欢迎正在阅读的你也加入,一起分享。
边栏推荐
- LeetCode刷题系列 -- 10. 正则表达式匹配
- Introduction to Grid Layout
- Mysql数据库 | 基于Docker搭建Mysql-8.0以上版本主从实例实战
- Automated operation and maintenance tools - ansible, overview, installation, module introduction
- 【解决】RESP.app 连接不上redis
- Android studio connects to MySQL and completes simple login and registration functions
- coredns介绍
- 软件测试在职2年跳槽4次,你还在怪老板不给你涨薪?
- C语言中i++和++i在循环中的差异性
- ERROR 1045 (28000) Access denied for user 'root'@'localhost'Solution
猜你喜欢
Detailed explanation of the software testing process (mind map) of the first-tier manufacturers
leetcode一步解决链表反转问题
Use the browser's local storage to realize the function of remembering the user name
ERROR 1045 (28000) Access denied for user ‘root‘@‘localhost‘解决方法
复盘:图像饱和度计算公式和图像信噪(PSNR)比计算公式
ELK log analysis system
软件测试在职2年跳槽4次,你还在怪老板不给你涨薪?
Matlab论文插图绘制模板第41期—气泡图(bubblechart)
Meta公司内部项目-RaptorX:将Presto性能提升10倍
OAuth 授权协议 | 都云原生时代了,我们应该多懂一点OAuth ?
随机推荐
navicat连接MySQL报错:1045 - Access denied for user ‘root‘@‘localhost‘ (using password YES)
构造方法、成员变量、局部变量
说好的女程序员做测试有优势?面试十几家,被面试官虐哭~~
PIL与numpy格式之间的转换
5年在职经验之谈:2年功能测试、3年自动化测试,从入门到不可自拔...
MYSQL unique constraint
C语言小游戏——扫雷小游戏
ERROR 1045 (28000) Access denied for user 'root'@'localhost'Solution
Brush LeetCode topic series - 10. Regular expression match
复盘:图像饱和度计算公式和图像信噪(PSNR)比计算公式
网安学习-内网渗透4
提高软件测试能力的方法有哪些?看完这篇文章让你提升一个档次
Introduction to Grid Layout
一线大厂软件测试流程(思维导图)详解
对node工程进行压力测试与性能分析
Navicat如何连接MySQL
How much does a test environment cost? Start with cost and efficiency
[PSQL] 窗口函数、GROUPING运算符
What do interview test engineers usually ask?The test supervisor tells you
CPU使用率和负载区别及分析