当前位置: 首页 > news >正文

一个网站上面有名优cpa项目推广联盟

一个网站上面有名优,cpa项目推广联盟,上海网站seo,微信开发者平台入口学过高斯软件的人都知道#xff0c;我们在撰写输入文件 gjf 时需要准备输入【泛函】和【基组】这两个关键词。 【泛函】敲定计算方法#xff0c;【基组】则类似格点积分中的密度#xff0c;与计算精度密切相关。 部分研究人员借用高斯中的一系列基组去包装输入几何信息我们在撰写输入文件 gjf 时需要准备输入【泛函】和【基组】这两个关键词。 【泛函】敲定计算方法【基组】则类似格点积分中的密度与计算精度密切相关。 部分研究人员借用高斯中的一系列基组去包装输入几何信息距离、角度和二面角这样做一方面提高了GNN的可解释性另一方面也实实在在的提高了模型精度。从 AI 角度看embedding则可以看作是几何信息的升维。 具体来说 如果模型输入仅有距离信息则采用径向基函数去embedding。常用的有 Gaussian 也有Bessel如果模型输入含有距离和角度信息。在直角坐标系下可以用 Gaussian 和 sin 函数组embedding。在球坐标系下可以考虑 spherical Bessel functions and spherical harmonics 组合。其中 spherical harmonics 采用m0的形式。如果模型输入含有距离角度和二面角信息一般采用 spherical Bessel functions and spherical harmonics 组合。可能有其他的但目前涉及二面角的模型较少据我了解Spherenet和ComENet均采用的是这种组合。 下面进行简要介绍 Gaussian 系列基组 SchNet网络架构中使用的基组是目前用途最广的基组之一。 我们借助 DIG 框架中 schnet 的实现对其进行可视化 from dig.threedgraph.method.schnet.schnet import *import numpy as np import math import matplotlib.pyplot as pltimport torchdist_test torch.arange(0.01, 5.01, 0.01) dist_emb emb(num_gaussians5) y dist_emb(dist_test) y y.Tfor idx, y_plot in enumerate(y):x [a_dist.detach().numpy() for a_dist in dist_test]y [an_emb.detach().numpy() for an_emb in y_plot]plt.plot(x, y, labelfGaussian embedding {idx})plt.xlabel(x) plt.ylabel(y) plt.legend() plt.show()结果如下图所示 所谓“对几何信息进行嵌入”指同一个距离信息对应x轴一个点。如果高斯基组有5则嵌入后该距离信息就映射到了5个口袋里获得一组长度为5的特征向量。 此处为了清晰的可视化仅设置 num_gaussians5 在实际应用中这一数值往往设的很高。例如原版的 schnet 将这一数值设为 300在 DIG 版本中这一数值是默认的 50而在最新的 schnetpack 中这一数值 降为了 20. Bessel 系列基组 与高斯基组类似Bessel 系列基组用于 embedding 距离信息文献里用 spherical Bessel functions 表示。 其源头可以追溯到微分方程的求解spherical Bessel functions 是作为一系列解中的径向部分存在也常被称为 radical Bessel functions。 最早使用 Bessel functions 的可能不严谨GNN大概是 DimeNet。据 DimeNet 原文报道使用 Bessel functions 会带来一定程度的精度提升。 我们借助 DIG 框架中 DimeNet 的实现对其进行可视化 from dig.threedgraph.method.spherenet.features import *import numpy as np import math import matplotlib.pyplot as pltimport torchdist_test torch.arange(0.01, 5.01, 0.01) dist_emb dist_emb(num_radial5) y dist_emb(dist_test) y y.Tfor idx, y_plot in enumerate(y):x [a_dist.detach().numpy() for a_dist in dist_test]y [an_emb.detach().numpy() for an_emb in y_plot]plt.plot(x, y, labelfradical_basis_{idx})plt.xlabel(x) plt.ylabel(y) plt.legend() plt.show()结果如下图所示 spherical harmonics 基组 spherical Bessel functions 和 spherical harmonics 不是一个基组。他俩分别对应方程特解中的径向和角度部分。 下图为 ComENet 中的概述 spherical harmonics 基组常常在球极坐标系下和 spherical Bessel functions 配套使用。 如果输入的几何信息仅有角度没有二面角我们将 spherical harmonics 中的 m 置零。 此时得到的是一系列二维的 embedding 矩阵。 我们借助 DIG 框架中 SphereNet 的实现对其进行可视化源码稍微改了改此处仅是一些思路 from dig.threedgraph.method.spherenet.features import *import numpy as np import math import matplotlib.pyplot as pltimport torchangle_emb angle_emb(num_spherical4, num_radial4, cutoff4) rlist np.arange(0, 4.01, 0.005) # Angstroms thetalist np.radians(np.arange(0, 361, 0.5)) # Radians rmesh, thetamesh np.meshgrid(rlist, thetalist) # Generate a meshn 1 l 1 fig plt.figure() info angle_emb(torch.tensor(rlist), torch.tensor(thetalist)) info_0 info[n, l] info_0 info_0.detach().numpy()info_0 info_0.reshape(len(rlist), len(thetalist)) info_0 info_0.T fig, ax plt.subplots(subplot_kwdict(projectionpolar)) ax.contourf(thetamesh, rmesh, info_0, 100, cmapRdBu) ax.set_rticks([]) ax.set_xticks([]) plt.savefig(f./basis/n_{n}_l_{l}.png, dpi400)结果如下图所示 我们可以得到一系列能够embedding角度和距离信息的函数。 下图是DimeNet原文中的图 需要注意的是DimeNet源码中对 l0 的径向函数进行了修改所以无法复现 Figure 2 第一行。 我们还可以借助 scipy 进行实现例如下面我们对角度部分 spherical harmonics 进行可视化不涉及径向部分径向部分在 scipy.special._spherical_bessel 里 借用plotly实现可交互的可视化 import plotly.graph_objects as go import numpy as np from mpl_toolkits.mplot3d import Axes3D from scipy.special import sph_harm# from scipy.special._spherical_bessel import# l, m 3, 0for l in range(0, 4):for m in range(-l, l1):theta np.linspace(0, np.pi, 100)phi np.linspace(0, 2 * np.pi, 100)theta, phi np.meshgrid(theta, phi)xyz np.array([np.sin(theta) * np.sin(phi),np.sin(theta) * np.cos(phi),np.cos(theta)])Y sph_harm(abs(m), l, phi, theta)if m 0:Y np.sqrt(2) * (-1) ** m * Y.imagelif m 0:Y np.sqrt(2) * (-1) ** m * Y.realYx, Yy, Yz np.abs(Y) * xyzfig go.Figure(data[go.Surface(xYx, yYy, zYz, surfacecolorY.real), ])fig.update_layout(titlefY_l_{l}_m_{m}, )fig.write_html(rf./pics_html/Y_l_{l}_m_{m}.html) 借用matplotlib实现静态的可视化 import numpy as np import matplotlib.pyplot as plt import matplotlib.gridspec as gridspec # The following import configures Matplotlib for 3D plotting. from mpl_toolkits.mplot3d import Axes3D from scipy.special import sph_harm# plt.rc(text, usetexTrue)# Grids of polar and azimuthal angles theta np.linspace(0, np.pi, 100) phi np.linspace(0, 2*np.pi, 100) # Create a 2-D meshgrid of (theta, phi) angles. theta, phi np.meshgrid(theta, phi) # Calculate the Cartesian coordinates of each point in the mesh. xyz np.array([np.sin(theta) * np.sin(phi),np.sin(theta) * np.cos(phi),np.cos(theta)])def plot_Y(ax, el, m):Plot the spherical harmonic of degree el and order m on Axes ax.# NB In SciPys sph_harm function the azimuthal coordinate, theta,# comes before the polar coordinate, phi.Y sph_harm(abs(m), el, phi, theta)# Linear combination of Y_l,m and Y_l,-m to create the real form.if m 0:Y np.sqrt(2) * (-1)**m * Y.imagelif m 0:Y np.sqrt(2) * (-1)**m * Y.realYx, Yy, Yz np.abs(Y) * xyz# Colour the plotted surface according to the sign of Y.cmap plt.cm.ScalarMappable(cmapRdBu)cmap.set_clim(-0.5, 0.5)ax.plot_surface(Yx, Yy, Yz,facecolorscmap.to_rgba(Y.real),rstride2, cstride2)# Draw a set of x, y, z axes for reference.ax_lim 0.5ax.plot([-ax_lim, ax_lim], [0,0], [0,0], c0.5, lw1, zorder10)ax.plot([0,0], [-ax_lim, ax_lim], [0,0], c0.5, lw1, zorder10)ax.plot([0,0], [0,0], [-ax_lim, ax_lim], c0.5, lw1, zorder10)# Set the Axes limits and title, turn off the Axes frame.# ax.set_title(r$Y_{{{},{}}}$.format(el, m))ax.set_title(Y_l_{}_m_{}.format(el, m))ax_lim 0.5ax.set_xlim(-ax_lim, ax_lim)ax.set_ylim(-ax_lim, ax_lim)ax.set_zlim(-ax_lim, ax_lim)ax.axis(off)# fig plt.figure(figsizeplt.figaspect(1.))for l in range(0, 4):for m in range(-l, l1):fig plt.figure()ax fig.add_subplot(projection3d)plot_Y(ax, l, m)plt.savefig(./pics_png/Y_l_{}_m_{}.png.format(l, m))静态效果如下 OK至此GNN中常用的基组至少我所了解到的介绍完了。 一般来说仅涉及距离信息的架构常常采用 gaussian 基组。 如果要用 spherical harmonics 这种涉及角度的基组一般需要将几何坐标转到球极坐标下而这将导致网络适应等变架构时遇到困难。 当然还有使用 tensor field 做基组的这块我还了解的少但看起来好像也是套的 spherical harmonics 。
文章转载自:
http://www.morning.hfrbt.cn.gov.cn.hfrbt.cn
http://www.morning.ybshj.cn.gov.cn.ybshj.cn
http://www.morning.spxsm.cn.gov.cn.spxsm.cn
http://www.morning.rszt.cn.gov.cn.rszt.cn
http://www.morning.btns.cn.gov.cn.btns.cn
http://www.morning.kjfqf.cn.gov.cn.kjfqf.cn
http://www.morning.mwbqk.cn.gov.cn.mwbqk.cn
http://www.morning.nqypf.cn.gov.cn.nqypf.cn
http://www.morning.bzqnp.cn.gov.cn.bzqnp.cn
http://www.morning.gtmdq.cn.gov.cn.gtmdq.cn
http://www.morning.dpwcl.cn.gov.cn.dpwcl.cn
http://www.morning.qfbzj.cn.gov.cn.qfbzj.cn
http://www.morning.lftpl.cn.gov.cn.lftpl.cn
http://www.morning.rwlns.cn.gov.cn.rwlns.cn
http://www.morning.cfynn.cn.gov.cn.cfynn.cn
http://www.morning.btnmj.cn.gov.cn.btnmj.cn
http://www.morning.bhrbr.cn.gov.cn.bhrbr.cn
http://www.morning.bqyb.cn.gov.cn.bqyb.cn
http://www.morning.kscwt.cn.gov.cn.kscwt.cn
http://www.morning.nwtmy.cn.gov.cn.nwtmy.cn
http://www.morning.bfgpn.cn.gov.cn.bfgpn.cn
http://www.morning.rnyhx.cn.gov.cn.rnyhx.cn
http://www.morning.pmjhm.cn.gov.cn.pmjhm.cn
http://www.morning.yckrm.cn.gov.cn.yckrm.cn
http://www.morning.dnjwm.cn.gov.cn.dnjwm.cn
http://www.morning.sryyt.cn.gov.cn.sryyt.cn
http://www.morning.jngdh.cn.gov.cn.jngdh.cn
http://www.morning.fmkjx.cn.gov.cn.fmkjx.cn
http://www.morning.shuanga.com.cn.gov.cn.shuanga.com.cn
http://www.morning.hous-e.com.gov.cn.hous-e.com
http://www.morning.lydtr.cn.gov.cn.lydtr.cn
http://www.morning.zkdmk.cn.gov.cn.zkdmk.cn
http://www.morning.pqhgn.cn.gov.cn.pqhgn.cn
http://www.morning.bqmsm.cn.gov.cn.bqmsm.cn
http://www.morning.rqsr.cn.gov.cn.rqsr.cn
http://www.morning.fcqlt.cn.gov.cn.fcqlt.cn
http://www.morning.mnccq.cn.gov.cn.mnccq.cn
http://www.morning.mbrbk.cn.gov.cn.mbrbk.cn
http://www.morning.xkbdx.cn.gov.cn.xkbdx.cn
http://www.morning.gbxxh.cn.gov.cn.gbxxh.cn
http://www.morning.rkfwr.cn.gov.cn.rkfwr.cn
http://www.morning.fnmgr.cn.gov.cn.fnmgr.cn
http://www.morning.btrfm.cn.gov.cn.btrfm.cn
http://www.morning.hqxyt.cn.gov.cn.hqxyt.cn
http://www.morning.kgxrq.cn.gov.cn.kgxrq.cn
http://www.morning.c7496.cn.gov.cn.c7496.cn
http://www.morning.rynrn.cn.gov.cn.rynrn.cn
http://www.morning.tnktt.cn.gov.cn.tnktt.cn
http://www.morning.xqndf.cn.gov.cn.xqndf.cn
http://www.morning.pdynk.cn.gov.cn.pdynk.cn
http://www.morning.kyfrl.cn.gov.cn.kyfrl.cn
http://www.morning.jtfsd.cn.gov.cn.jtfsd.cn
http://www.morning.nlqgb.cn.gov.cn.nlqgb.cn
http://www.morning.jbfzx.cn.gov.cn.jbfzx.cn
http://www.morning.czgfn.cn.gov.cn.czgfn.cn
http://www.morning.swyr.cn.gov.cn.swyr.cn
http://www.morning.fbpdp.cn.gov.cn.fbpdp.cn
http://www.morning.jntcr.cn.gov.cn.jntcr.cn
http://www.morning.rkbly.cn.gov.cn.rkbly.cn
http://www.morning.bzpwh.cn.gov.cn.bzpwh.cn
http://www.morning.lfqtp.cn.gov.cn.lfqtp.cn
http://www.morning.phnbd.cn.gov.cn.phnbd.cn
http://www.morning.tqhpt.cn.gov.cn.tqhpt.cn
http://www.morning.gnmhy.cn.gov.cn.gnmhy.cn
http://www.morning.bmsqq.cn.gov.cn.bmsqq.cn
http://www.morning.rddlz.cn.gov.cn.rddlz.cn
http://www.morning.ykshx.cn.gov.cn.ykshx.cn
http://www.morning.bfysg.cn.gov.cn.bfysg.cn
http://www.morning.bpkqd.cn.gov.cn.bpkqd.cn
http://www.morning.wbxrl.cn.gov.cn.wbxrl.cn
http://www.morning.sfwcx.cn.gov.cn.sfwcx.cn
http://www.morning.nspbj.cn.gov.cn.nspbj.cn
http://www.morning.ptslx.cn.gov.cn.ptslx.cn
http://www.morning.ljngm.cn.gov.cn.ljngm.cn
http://www.morning.ymjgx.cn.gov.cn.ymjgx.cn
http://www.morning.bpcf.cn.gov.cn.bpcf.cn
http://www.morning.fjfjm.cn.gov.cn.fjfjm.cn
http://www.morning.hrkth.cn.gov.cn.hrkth.cn
http://www.morning.krkwh.cn.gov.cn.krkwh.cn
http://www.morning.tstwx.cn.gov.cn.tstwx.cn
http://www.tj-hxxt.cn/news/258693.html

相关文章:

  • 营销网站特点采集文章留在网站
  • 学做网站培训班要多少钱网络营销专业的就业方向
  • 常州市建设局网站6陕西网站建站
  • 深圳市国外网站建设服务机构电子商务未来发展趋势前景
  • 聚美优品网站模版免费门户网站制作
  • 牟平网站建设自助服务器网站建设
  • 金融中介做网站需要麦包包在网站建设方面
  • 怎么设计网站关注建设银行网站
  • 土特产直营网站建设代码灯具网站建设
  • 外贸购物网站开发网站建设流程咨询
  • 辽宁建设集团招聘信息网站建设部职称网站
  • 网站域名地址查询行牛建站
  • 定制鞋子哪个网站好网站建设专业英文
  • 景安备案网站网站开发框架文档
  • 天蓝色网站桂林手机网站制作
  • 如何申请网站备案号有哪些可以免费推广的平台
  • 技术社区网站开发例子网站开发硬件设计
  • 网站seo诊断湖南岚鸿诊断江苏机械加工网
  • 挂机宝 可以做网站2022年近期重大新闻事件
  • 南昌正规网站公司写网站的教程
  • 网站视频链接怎么做wordpress 商品 模板下载
  • 上海平台网站建设价格前端跟后端哪个就业难
  • 网站建设那家好兰州企业建设网站
  • 网站里面网友点评怎么做wordpress win调试
  • 山东济南网站建设公司什么网站推广比较好
  • 企业网站建设的步骤过程乐陵人力资源网站
  • 网站建设实战案例最新的跨境电商平台有哪些
  • 网站建设合同报价上海市中小企业服务中心
  • 青岛中小企业建设网站有扶持资金吗一个网站如何做cdn加速器
  • 免费的建网站软件建站公司 phpwind