当前位置:网站首页>Torch. Distributions. Normal
Torch. Distributions. Normal
2022-06-13 01:39:00 【lainegates】
Pytorch Normal distribution provided , Official documents
How it was created
>>> m = Normal(torch.tensor([0.0]), torch.tensor([1.0]))
>>> m.sample() # Generate the data , Biography shape Parameters
tensor([ 0.1046])
Interface log_prob(self, value)
return value Probabilistic log value , The normal distribution formula is
f ( x ) = 1 2 π σ e x p ( − ( x − μ ) 2 2 σ 2 ) f(x)=\frac{1}{\sqrt{2\pi}\sigma}exp(-\frac{(x-\mu)^2}{2\sigma^2}) f(x)=2πσ1exp(−2σ2(x−μ)2)
The calculation formula of the function is :
l o g ( f ( x ) ) = − l o g ( 2 π ) − l o g ( σ ) − ( x − μ ) 2 2 σ 2 log(f(x)) = -log(\sqrt{2\pi})-log(\sigma)-\frac{(x-\mu)^2}{2\sigma^2} log(f(x))=−log(2π)−log(σ)−2σ2(x−μ)2
Interface def entropy(self)
Return value formula
1 2 + 2 π 2 + l o g ( σ ) \frac{1}{2}+\frac{2\pi}{2}+log(\sigma) 21+22π+log(σ)
It looks like the normal distribution formula log value , But I don't know why 1 2 \frac{1}{2} 21
边栏推荐
- [Andoid][踩坑]CTS 11_r3开始出现的testBootClassPathAndSystemServerClasspath_nonDuplicateClasses FAIL问题分析
- [WSL2]WSL2迁移虚拟磁盘文件ext4.vhdx
- [WSL2]限制WSL2可访问的硬件资源(CPU/内存)
- 4K sea bottom and water surface fabrication method and ocean bump displacement texture Download
- 使用Pygame创建一个简单游戏界面
- Project training (XVII) -- personal work summary
- Redis usage optimization summary learning
- Alexnet implements image classification of caltech101 dataset (pytorch Implementation)
- This of phaser3 add. sprite
- Facial expression recognition dataset
猜你喜欢

Rasa dialogue robot helpdesk (III)

Simple operation of MySQL database
![[Andoid][踩坑]CTS 11_r3开始出现的testBootClassPathAndSystemServerClasspath_nonDuplicateClasses FAIL问题分析](/img/b5/7ea603775dc0448368d209de037a43.png)
[Andoid][踩坑]CTS 11_r3开始出现的testBootClassPathAndSystemServerClasspath_nonDuplicateClasses FAIL问题分析

MySQL related summary

三、上传织物图片至SQL Server并提供name进行展示织物照片

服务器安装jupyterlab以及远程登录配置

Work and life

Camera model_
![[wsl2]wsl2 migrate virtual disk file ext4 vhdx](/img/e9/4e08e07c2de2f99c2938e79f7f1c44.png)
[wsl2]wsl2 migrate virtual disk file ext4 vhdx

Leetcode question brushing 06 bit operation
随机推荐
4K sea bottom and water surface fabrication method and ocean bump displacement texture Download
[andoid][step pit]cts 11_ Testbootclasspathandsystemserverclasspath at the beginning of R3_ Analysis of nonduplicateclasses fail
[WSL2]WSL2迁移虚拟磁盘文件ext4.vhdx
The second round of mesa
Explanation and application of prefix sum (one-dimensional, two-dimensional)
Alexnet implements image classification of caltech101 dataset (pytorch Implementation)
Sliding window summary of TCP connections
TensorFlow2的Conv1D, Conv2D,Conv3D机器对应的MaxPooling详解
np. Understanding of axis in concatenate
Sonarqube local installation
关于tkinter.Canvas 不显示图片的问题
[wsl2]wsl2 migrate virtual disk file ext4 vhdx
Idea installation tutorial
Realization of flip animation
MySQL related summary
[WSL2]限制WSL2可访问的硬件资源(CPU/内存)
leetcode743. Network latency (medium, Dijkstra)
C language implementation of the classic eight queens problem
The interviewer only asked me five questions and the interview was over
Page optimization - Notes