Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
pytensor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
testgroup
pytensor
Commits
a0ae9812
提交
a0ae9812
authored
8月 07, 2015
作者:
Iban Harlouchet
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
numpydoc for theano/scalar/basic_scipy.py
上级
69d69910
隐藏空白字符变更
内嵌
并排
正在显示
1 个修改的文件
包含
17 行增加
和
9 行删除
+17
-9
basic_scipy.py
theano/scalar/basic_scipy.py
+17
-9
没有找到文件。
theano/scalar/basic_scipy.py
浏览文件 @
a0ae9812
...
...
@@ -87,14 +87,18 @@ erfc = Erfc(upgrade_to_float_no_complex, name='erfc')
class
Erfcx
(
UnaryScalarOp
):
"""
Implements the scaled complementary error function exp(x**2)*erfc(x) in a numerically stable way for large x. This
is useful for calculating things like log(erfc(x)) = log(erfcx(x)) - x ** 2 without causing underflow. Should only
be used if x is known to be large and positive, as using erfcx(x) for large negative x may instead introduce
overflow problems.
Note: This op can still be executed on GPU, despite not having c_code. When
Implements the scaled complementary error function exp(x**2)*erfc(x) in a
numerically stable way for large x. This is useful for calculating things
like log(erfc(x)) = log(erfcx(x)) - x ** 2 without causing underflow.
Should only be used if x is known to be large and positive, as using
erfcx(x) for large negative x may instead introduce overflow problems.
Notes
-----
This op can still be executed on GPU, despite not having c_code. When
running on GPU, sandbox.cuda.opt.local_gpu_elemwise_[0,1] replaces this op
with sandbox.cuda.elemwise.ErfcxGPU.
"""
def
impl
(
self
,
x
):
if
imported_scipy_special
:
...
...
@@ -124,7 +128,9 @@ class Erfinv(UnaryScalarOp):
"""
Implements the inverse error function.
Note: This op can still be executed on GPU, despite not having c_code. When
Notes
-----
This op can still be executed on GPU, despite not having c_code. When
running on GPU, sandbox.cuda.opt.local_gpu_elemwise_[0,1] replaces this op
with sandbox.cuda.elemwise.ErfinvGPU.
...
...
@@ -237,6 +243,7 @@ gamma = Gamma(upgrade_to_float, name='gamma')
class
GammaLn
(
UnaryScalarOp
):
"""
Log gamma function.
"""
@staticmethod
def
st_impl
(
x
):
...
...
@@ -280,6 +287,7 @@ gammaln = GammaLn(upgrade_to_float, name='gammaln')
class
Psi
(
UnaryScalarOp
):
"""
Derivative of log gamma function.
"""
@staticmethod
def
st_impl
(
x
):
...
...
@@ -360,13 +368,13 @@ psi = Psi(upgrade_to_float, name='psi')
class
Chi2SF
(
BinaryScalarOp
):
"""
Compute (1 - chi2_cdf(x))
ie. chi2 pvalue (chi2 'survival function')
Compute (1 - chi2_cdf(x)) ie. chi2 pvalue (chi2 'survival function').
C code is provided in the Theano_lgpl repository.
This make it faster.
https://github.com/Theano/Theano_lgpl.git
"""
@staticmethod
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论