The Front-End Checklist

做个记录,摘自Front-End Performance Checklist 

HTML

  1. Minified HTML:medium The HTML code is minified, comments, white spaces and new lines are removed from production files. 
  2. Remove unnecessary comments: low Ensure that comments are removed from your pages.
  3. Remove unnecessary attributes: low Type attributes like type="text/javascript" or type="text/css" are not required anymore and should be removed.
  4.  Place CSS tags always before JavaScript tags: high  Ensure that your CSS is always loaded before having JavaScript code.
  5. Minimize the number of iframes: high  Use iframes only if you don't have any other technical possibility. Try to avoid as much as you can iframes.

CSS

  1. Minification: high All CSS files are minified, comments, white spaces and new lines are removed from production files.
  2. Concatenation: medium CSS files are concatenated in a single file (Not always valid for HTTP/2).(合并css,减少http请求,http2不必)
  3. Non-blocking: high CSS files need to be non-blocking to prevent the DOM from taking time to load.(css必须是非阻塞的)
    How:You need to add the rel attribute with the preload value and add as="style" on the <link> element
    <link rel="preload" href="a.css" as="style" onload="this.rel='stylesheet'">
    <noscript><link rel="stylesheet" href="a.css"></noscript>
  4. Length of CSS classes: low The length of your classes can have an (slight) impact on your HTML and CSS files (eventually).
  5. Unused CSS: medium Remove unused CSS selectors.
  6. CSS Critical: high The CSS critical (or "above the fold") collects all the CSS used to render the visible portion of the page. It is embedded before your principal CSS call and between <style></style> in a single line (minified if possible).
    取出首屏渲染所必须的 critical CSS,以内联的方式写在 <style></style> 之中,然后异步加载剩余的 CSS 样式,这相当于离线加载剩余部分的 CSS 样式,然后在后台将其注入到页面中。
  7. Embedded or inline CSS: high Avoid using embed or inline CSS inside your <body> (Not valid for HTTP/2)
  8. Analyse stylesheets complexityhigh Analyzing your stylesheets can help you to flag issues, redundancies and duplicate CSS selectors.
    分析样式表,去除冗余重复的代码

Fonts

  1. Webfont formats: medium You are using WOFF2 on your web project or application.
  2.  Use preconnect to load your fonts faster: medium
    <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
  3. Webfont size: medium Webfont sizes don't exceed 300kb (all variants included)
  4. Prevent Flash or Invisible Text: medium Avoid transparent text until the Webfont is loaded

Images

  1. Images optimization: high Your images are optimized, compressed without direct impact to the end user.
  2. Images format: high Choose your image format appropriately.
  3. Use vector image vs raster/bitmap: medium Prefer using vector image rather than bitmap images (when possible).
    矢量图像(SVG)往往比图像小,SVG的响应速度和比例都很好
  4. Images dimensions: medium Set width and height attributes on <img> if the final rendered image size is known.
  5. Avoid using Base64 images: medium You could eventually convert tiny images to base64 but it's actually not the best practice.
  6. Lazy loading: medium Images are lazyloaded (A noscript fallback is always provided).
  7. Responsive images: medium Ensure to serve images that are close to your display size.(srcset和picture了解一下

JavaScript

  1. JS Minification: high All JavaScript files are minified, comments, white spaces and new lines are removed from production files (still valid if using HTTP/2).
  2. No JavaScript inside: medium (Only valid for website) Avoid having multiple JavaScript codes embedded in the middle of your body. Regroup your JavaScript code inside external files or eventually in the <head> or at the end of your page (before </body>).
  3. Non-blocking JavaScript: high JavaScript files are loaded asynchronously using async or deferred using defer attribute.
  4. Optimized and updated JS libraries: medium All JavaScript libraries used in your project are necessary (prefer Vanilla JavaScript for simple functionalities), updated to their latest version and don't overwhelm your JavaScript with unnecessary methods.
  5. Check dependencies size limit: low Ensure to use wisely external libraries, most of the time, you can use a lighter library for a same functionality.(比如dayjs替代了momentjs)
  6. JavaScript Profiling: medium Check for performance problems in your JavaScript files (and CSS too).

Server

  1. Page weight < 1500 KB (ideally < 500 KB): high Reduce the size of your page + resources as much as you can.
  2. Page load times < 3 seconds: high Reduce as much as possible your page load times to quickly deliver your content to your users.
  3. Time To First Byte < 1.3 seconds: high Reduce as much as you can the time your browser waits before receiving data.
  4. Cookie size: medium If you are using cookies be sure each cookie doesn't exceed 4096 bytes(4kb) and your domain name doesn't have more than 20 cookies.
  5. Minimizing HTTP requests: high Always ensure that every file requested are essential for your website or application.
  6. Use a CDN to deliver your assets: medium Use a CDN to deliver faster your content over the world.
  7. Serve files from the same protocol: high Avoid having your website using HTTPS and serve files coming from source using HTTP.
  8. Serve reachable files: high Avoid requesting unreachable files (404).
  9. Set HTTP cache headers properly: high Set HTTP headers to avoid expensive number of roundtrips between your browser and the server.
  10. GZIP / Brotli compression is enabled: high

转载于:https://www.cnblogs.com/colima/p/9389086.html

深度学习是机器学习的一个子领域,它基于人工神经网络的研究,特别是利用多层次的神经网络来进行学习和模式识别。深度学习模型能够学习数据的高层次特征,这些特征对于图像和语音识别、自然语言处理、医学图像分析等应用至关重要。以下是深度学习的一些关键概念和组成部分: 1. **神经网络(Neural Networks)**:深度学习的基础是人工神经网络,它是由多个层组成的网络结构,包括输入层、隐藏层和输出层。每个层由多个神经元组成,神经元之间通过权重连接。 2. **前馈神经网络(Feedforward Neural Networks)**:这是最常见的神经网络类型,信息从输入层流向隐藏层,最终到达输出层。 3. **卷积神经网络(Convolutional Neural Networks, CNNs)**:这种网络特别适合处理具有网格结构的数据,如图像。它们使用卷积层来提取图像的特征。 4. **循环神经网络(Recurrent Neural Networks, RNNs)**:这种网络能够处理序列数据,如时间序列或自然语言,因为它们具有记忆功能,能够捕捉数据中的时间依赖性。 5. **长短期记忆网络(Long Short-Term Memory, LSTM)**:LSTM 是一种特殊的 RNN,它能够学习长期依赖关系,非常适合复杂的序列预测任务。 6. **生成对抗网络(Generative Adversarial Networks, GANs)**:由两个网络组成,一个生成器和一个判别器,它们相互竞争,生成器生成数据,判别器评估数据的真实性。 7. **深度学习框架**:如 TensorFlow、Keras、PyTorch 等,这些框架提供了构建、训练和部署深度学习模型的工具和库。 8. **激活函数(Activation Functions)**:如 ReLU、Sigmoid、Tanh 等,它们在神经网络中用于添加非线性,使得网络能够学习复杂的函数。 9. **损失函数(Loss Functions)**:用于评估模型的预测与真实值之间的差异,常见的损失函数包括均方误差(MSE)、交叉熵(Cross-Entropy)等。 10. **优化算法(Optimization Algorithms)**:如梯度下降(Gradient Descent)、随机梯度下降(SGD)、Adam 等,用于更新网络权重,以最小化损失函数。 11. **正则化(Regularization)**:技术如 Dropout、L1/L2 正则化等,用于防止模型过拟合。 12. **迁移学习(Transfer Learning)**:利用在一个任务上训练好的模型来提高另一个相关任务的性能。 深度学习在许多领域都取得了显著的成就,但它也面临着一些挑战,如对大量数据的依赖、模型的解释性差、计算资源消耗大等。研究人员正在不断探索新的方法来解决这些问题。
【4层】3100平米综合办公楼毕业设计(含计算书、建筑结构图) 、1资源项目源码均已通过严格测试验证,保证能够正常运行; 2、项目问题、技术讨论,可以给博主私信或留言,博主看到后会第一时间与您进行沟通; 3、本项目比较适合计算机领域相关的毕业设计课题、课程作业等使用,尤其对于人工智能、计算机科学与技术等相关专业,更为适合; 4、下载使用后,可先查看README.md或论文文件(如有),本项目仅用作交流学习参考,请切勿用于商业用途。 5、资源来自互联网采集,如有侵权,私聊博主删除。 6、可私信博主看论文后选择购买源代码。 1、资源项目源码均已通过严格测试验证,保证能够正常运行; 2、项目问题、技术讨论,可以给博主私信或留言,博主看到后会第一时间与您进行沟通; 3、本项目比较适合计算机领域相关的毕业设计课题、课程作业等使用,尤其对于人工智能、计算机科学与技术等相关专业,更为适合; 4、下载使用后,可先查看README.md或论文文件(如有),本项目仅用作交流学习参考,请切勿用于商业用途。 5、资源来自互联网采集,如有侵权,私聊博主删除。 6、可私信博主看论文后选择购买源代码。 、1资源项目源码均已通过严格测试验证,保证能够正常运行; 2、项目问题、技术讨论,可以给博主私信或留言,博主看到后会第一时间与您进行沟通; 3、本项目比较适合计算机领域相关的毕业设计课题、课程作业等使用,尤其对于人工智能、计算机科学与技术等相关专业,更为适合; 4、下载使用后,可先查看README.md或论文文件(如有),本项目仅用作交流学习参考,请切勿用于商业用途。 5、资源来自互联网采集,如有侵权,私聊博主删除。 6、可私信博主看论文后选择购买源代码。
1、资源项目源码均已通过严格测试验证,保证能够正常运行; 、2项目问题、技术讨论,可以给博主私信或留言,博主看到后会第一时间与您进行沟通; 3、本项目比较适合计算机领域相关的毕业设计课题、课程作业等使用,尤其对于人工智能、计算机科学与技术等相关专业,更为适合; 4、下载使用后,可先查看README.md或论文文件(如有),本项目仅用作交流学习参考,请切勿用于商业用途。 5、资源来自互联网采集,如有侵权,私聊博主删除。 6、可私信博主看论文后选择购买源代码。 1、资源项目源码均已通过严格测试验证,保证能够正常运行; 2、项目问题、技术讨论,可以给博主私信或留言,博主看到后会第一时间与您进行沟通; 3、本项目比较适合计算机领域相关的毕业设计课题、课程作业等使用,尤其对于人工智能、计算机科学与技术等相关专业,更为适合; 4、下载使用后,可先查看README.md或论文文件(如有),本项目仅用作交流学习参考,请切勿用于商业用途。、资 5源来自互联网采集,如有侵权,私聊博主删除。 6、可私信博主看论文后选择购买源代码。 1、资源项目源码均已通过严格测试验证,保证能够正常运行; 2、项目问题、技术讨论,可以给博主私信或留言,博主看到后会第一时间与您进行沟通; 3、本项目比较适合计算机领域相关的毕业设计课题、课程作业等使用,尤其对于人工智能、计算机科学与技术等相关专业,更为适合; 4、下载使用后,可先查看README.md或论文文件(如有),本项目仅用作交流学习参考,请切勿用于商业用途。、 5资源来自互联网采集,如有侵权,私聊博主删除。 6、可私信博主看论文后选择购买源代码。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值