iBatis小结

Alphafold2/multimer本地安装避坑指南:从Conda环境配置到GPU加速实战 本文详细介绍了Alphafold2/multimer本地安装的全流程,从Conda环境配置到GPU加速实战,特别针对常见的报错处理提供了解决方案。通过硬件环境检查、依赖安装技巧、OpenMM补丁应用等步骤,帮助研究人员高效部署蛋白质结构预测工具,提升计算效率。 阅读详情
 
Xml代码 复制代码
  1. <?xml version="1.0" encoding="UTF-8" ?>      
  2. <!DOCTYPE sqlMap            
  3.     PUBLIC "-//ibatis.apache.org//DTD SQL Map 2.0//EN"            
  4.     "http://ibatis.apache.org/dtd/sql-map-2.dtd">      
  5. <sqlMap namespace="Account">      
  6.   <typeAlias alias="Account" type="test.Account"/>      
  7.   <!--列表查询,返回Account Object的List-->         
  8.   <resultMap id="AccountResult" class="Account">      
  9.     <result property="id" column="ID"/>      
  10.     <result property="firstName" column="FIRST_NAME"/>      
  11.     <result property="lastName" column="LAST_NAME"/>      
  12.     <result property="emailAddress" column="EMAIL"/>      
  13.   </resultMap>        
  14.   <select id="selectAllAccounts" resultMap="AccountResult">      
  15.     select * from ACCOUNT      
  16.   </select>      
  17.         
  18.   <!--列表查询,返回HashMap的List -->       
  19.   <!--resultMap无需再通过JDBC ResultSetMetaData 来动态获取字段信息,性能有提高-->      
  20.      
  21.   <resultMap id="mapResult" class="java.util.HashMap">      
  22.     <result property="roleid" column="ROLEID"/>      
  23.     <result property="rolename" column="ROLENAME"/>      
  24.     <result property="id" column="ID"/>      
  25.     <result property="firstName" column="FIRST_NAME"/>      
  26.     <result property="lastName" column="LAST_NAME"/>      
  27.     <result property="emailAddress" column="EMAIL"/>      
  28.     <result property="dt" column="DT"/>      
  29.   </resultMap>      
  30.   <select id="selectAllAccountsWithMap" resultMap="mapResult">      
  31.         select B.ROLEID, B.ROLENAME, A.ID, A.FIRST_NAME,A.LAST_NAME,A.EMAIL,A.DT      
  32.         from ACCOUNT A left outer join ROLE B   on A.ROLEID = B.ROLEID      
  33.         ORDER BY A.ID DESC      
  34.   </select>      
  35.         
  36. <!--动态构造查询条件-->      
  37. <select id="getUsers" parameterClass="user" resultMap="get-user-result">      
  38.     Select id,name,sex from t_user      
  39.     <dynamic prepend="WHERE">      
  40.         <isNotEmpty prepend="AND" property="name">      
  41.             (name like #name#)      
  42.         </isNotEmpty>      
  43.         <isNotEmpty prepend="AND" property="address">      
  44.             (address like #address#)      
  45.         </isNotEmpty>      
  46.     </dynamic>      
  47. </select>      
  48. <isNotEmpty prepend="AND" property="name">      
  49.     ( name=#name#      
  50.         <isNotEmpty prepend="AND" property="address">      
  51.             address=#address#      
  52.         </isNotEmpty>      
  53.     )      
  54. </isNotEmpty>      
  55. <select id="dynamicGetAccountList" resultMap="account-result" >      
  56.     select * from ACCOUNT      
  57.     <dynamic prepend="WHERE">      
  58.         <isNotNull prepend="AND" property="firstName" open=”(“ close=”)”>      
  59.             ACC_FIRST_NAME = #firstName#      
  60.             <isNotNull prepend="OR" property="lastName">      
  61.                 ACC_LAST_NAME = #lastName#      
  62.             </isNotNull>      
  63.         </isNotNull>      
  64.         <isNotNull prepend="AND" property="emailAddress">      
  65.             ACC_EMAIL like #emailAddress#      
  66.         </isNotNull>      
  67.         <isGreaterThan prepend="AND" property="id" compareValue="0">      
  68.             ACC_ID = #id#      
  69.         </isGreaterThan>      
  70.     </dynamic>      
  71.     order by ACC_LAST_NAME      
  72. </select>      
  73.      
  74. <isParameterPresent> <isNotParameterPresent> <isNull> <isNotNull> <isEmpty> <isNotEmpty>      
  75. <isEqual> <isNotEqual> <isGreaterThan> <isGreaterEqual> <isLessThan> <isLessEqual>      
  76.      
  77. <!-- Sql片段的是用-->      
  78. <sql id="selectItem_fragment">      
  79.     FROM items WHERE parentid = 6     
  80. </sql>      
  81. <select id="selectItemCount" resultClass="int">      
  82.     SELECT COUNT(*) AS total      
  83.     <include refid="selectItem_fragment"/>      
  84. </select>      
  85. <select id="selectItems" resultClass="Item">      
  86.     SELECT id, name      
  87.     <include refid="selectItem_fragment"/>      
  88. </select>      
  89.      
  90. <!--缓存-->      
  91. <cacheModel id="product-cache" type="LRU">      
  92.     <flushInterval hours="24"/>      
  93.     <flushOnExecute statement="insertProduct"/>      
  94.     <flushOnExecute statement="updateProduct"/>      
  95.     <flushOnExecute statement="deleteProduct"/>      
  96.     <property name=”size” value=”1000” />      
  97. </cacheModel>      
  98. <select id=”getProductList” parameterClass=”int” cacheModel=”product-cache”>      
  99.     select * from PRODUCT where PRD_CAT_ID = #value#      
  100. </select>      
  101.      
  102. <!—对XML支持 -->      
  103. <select id="getPerson" parameterClass=”int” resultClass="xml" xmlResultName=”person”>      
  104.     SELECT      
  105.     PER_ID as id,      
  106.     PER_FIRST_NAME as firstName,      
  107.     PER_LAST_NAME as lastName,      
  108.     PER_BIRTH_DATE as birthDate,      
  109.     PER_WEIGHT_KG as weightInKilograms,      
  110.     PER_HEIGHT_M as heightInMeters      
  111.     FROM PERSON      
  112.     WHERE PER_ID = #value#      
  113. </select>      
  114. <person>      
  115.     <id>1</id>      
  116.     <firstName>Clinton</firstName>      
  117.     <lastName>Begin</lastName>      
  118.     <birthDate>1900-01-01</birthDate>      
  119.     <weightInKilograms>89</weightInKilograms>      
  120.     <heightInMeters>1.77</heightInMeters>      
  121. </person>      
  122.      
  123. <!—字符串替换      
  124. select * from $tableName$      
  125. Important Note 1: This support will only substitute Strings, so it is not appropriate for complex data types like Date or Timestamp.      
  126. Important Note 2: If you use this support to alter a table name, or a column list, in an SQL select statement,then you should always specify remapResults=“true”      
  127. -->.      
  128.      
  129. <!—关联查询方式,有1/N问题-->      
  130. <sqlMap namespace="User">      
  131.     <typeAlias alias="user" type="com.ibatis.sample.User"/>      
  132.     <typeAlias alias="address" type="com.ibatis.sample.Address"/>      
  133.     <resultMap id="get-user-result" class="user">      
  134.         <result property="id" column="id"/>      
  135.         <result property="name" column="name"/>      
  136.         <result property="sex" column="sex"/>      
  137.         <result property="addresses" column="id" select="User.getAddressByUserId"/>      
  138.     </resultMap>      
  139.     <select id="getUsers"    parameterClass="java.lang.String" resultMap="get-user-result">      
  140.         <![CDATA[Select id,name,sex from t_user where id = #id#]]>      
  141.     </select>      
  142.     <select id="getAddressByUserId"  parameterClass="int" resultClass="address">      
  143.         <![CDATA[select address,zipcode from t_address where user_id = #userid# ]]>      
  144.     </select>      
  145. </sqlMap>      
  146. <resultMap id="get-user-result" class="user">      
  147.     <result property="id" column="id"/>      
  148.     <result property="name" column="name"/>      
  149.     <result property="sex" column="sex"/>      
  150.     <result property="address" column="t_address.address"/>      
  151.     <result property="zipCode" column="t_address.zipcode"/>      
  152. </resultMap>      
  153. <select id="getUsers" parameterClass="java.lang.String" resultMap="get-user-result">      
  154.     <![CDATA[select* from t_user,t_address where t_user.id=t_address.user_id]]>      
  155. </select>      
  156. 保证User 类中包含address和zipCode两个String型属性。      
  157.      
  158. <!—关联查询,无1/N问题-->      
  159.   <resultMap id="AccountResultWithRole" class="Account" groupBy="id">      
  160.     <result property="id" column="ID"/>      
  161.     <result property="firstName" column="FIRST_NAME"/>      
  162.     <result property="lastName" column="LAST_NAME"/>      
  163.     <result property="emailAddress" column="EMAIL"/>          
  164.     <result property="role" resultMap="Account.roleResult"/>      
  165.   </resultMap>      
  166.   <resultMap id="roleResult" class="test.Role">      
  167.     <result property="roleid" column="ROLEID"/>      
  168.     <result property="rolename" column="ROLENAME"/>      
  169.   </resultMap>      
  170.   <select id="selectAccountByIdWithRole" parameterClass="int" resultMap="AccountResultWithRole">      
  171.         select B.ROLEID, B.ROLENAME, A.ID, A.FIRST_NAME,A.LAST_NAME,A.EMAIL from ACCOUNT A left outer join ROLE B on A.ROLEID = B.ROLEID where A.ID = #id#      
  172.   </select>      
  173.         
  174.   <!--查询-->         
  175.   <select id="selectAccountById" parameterClass="int" resultClass="Account">      
  176.     select ID as id,FIRST_NAME as firstName,LAST_NAME as lastName,       EMAIL as emailAddress from ACCOUNT where ID = #id#      
  177.   </select>      
  178.         
  179.   <!--新增-->           
  180.   <insert id="insertAccount" parameterClass="Account">      
  181.     insert into ACCOUNT (FIRST_NAME,LAST_NAME,EMAIL,PID,DT)        
  182.     values (#firstName:VARCHAR#, #lastName:VARCHAR#, #emailAddress:VARCHAR#,#pid:INTEGER:0#,#dt:TIME#)      
  183.     <selectKey resultClass="int" type="post" keyProperty="id">      
  184.         SELECT @@IDENTITY AS ID      
  185.     </selectKey>          
  186.   </insert>      
  187.         
  188.   <!--更新-->         
  189.   <update id="updateAccount" parameterClass="Account">      
  190.     update ACCOUNT set      
  191.       FIRST_NAME = #firstName:VARCHAR#,      
  192.       LAST_NAME = #lastName:VARCHAR#,      
  193.       EMAIL = #emailAddress:VARCHAR#      
  194.     where      
  195.       ID = #id#      
  196.   </update>      
  197.      
  198.   <!--删除-->      
  199.   <delete id="deleteAccountById" parameterClass="int">      
  200.     delete from ACCOUNT where ID = #id#      
  201.   </delete>      
  202.         
  203.   <!--存储过程,如果没有返回列表,procTest的resultMap可以省略-->       
  204.   <parameterMap id="procParamMap" class="java.util.HashMap" >      
  205.     <parameter property="id" jdbcType="INTEGER" javaType="java.lang.Integer" mode="IN"/>      
  206.     <parameter property="outid" jdbcType="INTEGER" javaType="java.lang.Integer" mode="OUT"/>      
  207.     <parameter property="errMsg" jdbcType="VARCHAR" javaType="java.lang.String" mode="OUT"/>      
  208.   </parameterMap>      
  209.   <resultMap id="procResultMap" class="java.util.HashMap" >      
  210.     <result property="a" column="AAA"/>      
  211.     <result property="b" column="BBB"/>      
  212.     <result property="c" column="CCC"/>          
  213.   </resultMap>        
  214.   <procedure id="procTest" parameterMap="procParamMap" resultMap="procResultMap">      
  215.     {call test_sp_1 (?,?,?)}      
  216.   </procedure>      
  217. </sqlMap>    
解决Windows 10安装语言包时遇到的0x800F0954错误 在安装Windows 10操作系统的语言包时,如果遇到错误代码0x800F0954的提示,这无疑会让许多用户感到困惑和无助。这个错误通常意味着在安装过程中遇到了一些阻碍,导致无法正常完成语言包的安装。本文将为大家详细解析这个错误代码0x800F0954,并提供一系列有效的解决方法,帮助大家顺利安装所需的语言包。 阅读详情

相关推荐

VMware Workstation Pro 17 最新破解版安装教程(附永久激活密钥)

本文详细介绍了VMware Workstation Pro 17专业版的安装与配置指南,包括系统要求检查、官方版本安装流程、高级配置优化及常见问题排查。通过合规使用官方版本,开发者可以充分利用其强大的虚拟化能力,提升多平台开发与测试效率。

weixin_29327977的博客 3539

解决 MyBatis-TypeException: The alias ‘XXX‘ is already mapped to the value ‘com.XXX.XXX‘

解决 MyBatis-TypeException: The alias 'XXX' is already mapped to the value 'com.XXX.XXX'

一起coding,一起嗨。 3296

基于Simulink的防空导弹六自由度弹道建模与仿真实战

本文详细介绍了基于Simulink的防空导弹六自由度弹道建模与仿真方法。通过分析导弹动力学原理、Simulink环境配置、气动力建模、推进与控制系统设计等关键环节,提供了一套完整的实战指南。文章特别强调了六自由度模型在防空导弹仿真中的重要性,并分享了常见问题排查与优化建议,为相关领域工程师提供实用参考。

apple5的专栏 867

The alias ‘ ‘ is already mapped to the value mybatis因为实体类名重复,出现重复映射

在开发过程中,定义了一个实体类名称为Collection,但是与jar包里的C ollection冲突,所以编译不通过。修改办法为: 在实体类上面,通过注解的形式,起一个别名: @Alias("collections") public class Collection implements Serializable ———————————————— 版权声明:本文为优快云博主「zhuifengnian」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。 原文链接:http.

monody666的博客 1万+

NBIS单细胞教程:差异基因(五)

此文章是通过学习瑞典国家生物信息学基础设施(NBIS) 所开放的单细胞分析教程加上网上所查找的资料,自身的理解所形成的,可能会有不足之处。该部分是对不同集群之间的差异基因进行分析。参考来源:https://github.com/NBISweden/workshop-scRNAseq/blob/master/labs/seurat/seurat_05_dge.Rmd感兴趣的话可以阅读原文。

songyi10的博客 1万+

安卓刷Windows太难?这款手机平板双系统刷机工具,小白也能轻松拿捏!(小白福音!手机平板专用,一键搞定安卓刷 Windows 双系统!)

安卓刷Windows太难?这款手机平板双系统刷机工具,小白也能轻松拿捏!(小白福音!手机平板专用,一键搞定安卓刷 Windows 双系统!)

XiaoqiangClub的博客 4669

电商平台学习笔记(三)——Mybatis启动异常org.apache.ibatis.type.TypeException

今天一大早刚过来写代码,接着昨天使用MapperScannerConfigurer来扫包!以帮助从DAO层解脱出来(只需要定义接口)!结果就遇到了Bug。&lt;wbr style="line-height:28px; font-family:'Hiragino Sans GB W3','Hiragino Sans GB',Arial,Helvetica,simsun,宋体; font-size:...

xiangshou100的博客 2176

AI自动化流程在金融风控中的3个典型案例

AI自动化风控流程全流程自动化:最小化人工干预,实现从数据输入到决策输出的闭环自适应学习:通过持续数据反馈实现模型自动迭代优化实时决策能力:满足毫秒级(支付风控)至分钟级(信贷审批)的响应需求多模态数据融合:整合结构化、非结构化和实时流数据智能决策解释:自动生成符合监管要求的决策解释人机协同机制:在高风险场景下实现AI与人类专家的协同决策实施后关键绩效指标(KPI)变化指标实施前实施后改进幅度平均审批时间3.2天4.7分钟-99.7%自动审批率15%85%+467%

架构师的AI之路,分享AI应用开发架构的学习与实践。 1535

报错:TypeException: The alias xxx is already mapped to the value

项目启动就报错: [ERROR][2020-09-02 11:33:38][org.springframework.boot.SpringApplication.reportFailure(SpringApplication.java:826)] Application run failed org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘YYZXControll

YIBOFan 4812

OpenHarmony Stage模型深度解剖:从Ability Kit到沙箱隔离的全链路底层原理

基于微内核架构,提供进程管理、内存管理、IPC通信等基础能力:包含V8引擎、ArkTS运行时、渲染引擎等核心组件:Ability Kit框架,提供应用生命周期管理、组件调度等能力:基于Stage模型的应用程序。

m0_67505153的博客 191

【文献笔记】CVPR 2023|Attention-Based Point Cloud Edge Sampling

优点能够有效采出点云数据的边缘点分类任务性能优越不足没有设计出一个更好的上采样方法,导致分割任务的性能略低只考虑了边缘特征,没有利用其他几何特征。

m0_55908255的博客 319

mybatis报错:The alias 'xxx' is already mapped to the value 'com.demo.xxx'

项目编译时,报错如下: Caused by: org.apache.ibatis.type.TypeException: The alias 'xxx' is already mapped to the value 'com.demo.xxx'. at org.apache.ibatis.type.TypeAliasRegistry.registerAlias(TypeAliasRegistr

学无止境 4万+

Test软件:Keysight二次开发_(3).安装与配置开发环境

在开始进行Keysight软件的二次开发之前,首先需要确保您的开发环境已经正确安装和配置。本节将详细介绍如何安装和配置必要的开发工具和依赖项,以便您能够顺利进行开发工作。

2401_87715305的博客 1413

ibatis小结

sqlMap配置文件 <?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE sqlMapConfig PUBLIC "-//ibatis.apache.org//DTD SQL Map Config 2.0/...

chuifuhuo6864的博客 130

ssm框架搭建

这个是一个在idea上成功跑起来的ssm框架项目,保存在这里方便以后使用直接下载

深度学习工具包 DeepLearningToolbox

深度学习工具包Deprecation notice.-----This toolbox is outdated and no longer maintained.There are much better tools available for deep learning than this toolbox, e.g. [Theano](http://deeplearning.net/software/theano/), [torch](http://torch.ch/) or [tensorflow](http://www.tensorflow.org/)I would suggest you use one of the tools mentioned above rather than use this toolbox.Best, Rasmus.DeepLearnToolbox================A Matlab toolbox for Deep Learning.Deep Learning is a new subfield of machine learning that focuses on learning deep hierarchical models of data.It is inspired by the human brain's apparent deep (layered, hierarchical) architecture.A good overview of the theory of Deep Learning theory is[Learning Deep Architectures for AI](http://www.iro.umontreal.ca/~bengioy/papers/ftml_book.pdf)For a more informal introduction, see the following videos by Geoffrey Hinton and Andrew Ng.* [The Next Generation of Neural Networks](http://www.youtube.com/watch?v=AyzOUbkUf3M) (Hinton, 2007)* [Recent Developments in Deep Learning](http://www.youtube.com/watch?v=VdIURAu1-aU) (Hinton, 2010)* [Unsupervised Feature Learning and Deep Learning](http://www.youtube.com/watch?v=ZmNOAtZIgIk) (Ng, 2011)If you use this toolbox in your research please cite [Prediction as a candidate for learning deep hierarchical models of data](http://www2.imm.dtu.dk/pubdb/views/publication_details.php?id=6284)```@MASTERSTHESIS\{IMM2012-06284, author = "R. B. Palm", title = "Prediction as a candidate for learning deep hierarchical models of data", year = "2012",}```Contact: rasmusbergpalm at gmail dot comDirectories included in the toolbox-----------------------------------`NN/` - A library for Feedforward Backpropagation Neural Networks`CNN/` - A library for Convolutional Neural Networks`DBN/` - A library for Deep Belief Networks`SAE/` - A library for Stacked Auto-Encoders`CAE/` - A library for Convolutional Auto-Encoders`util/` - Utility functions used by the libraries`data/` - Data used by the examples`tests/` - unit tests to verify toolbox is workingFor references on each library check REFS.mdSetup-----1. Download.2. addpath(genpath('DeepLearnToolbox'));Example: Deep Belief Network---------------------```matlabfunction test_example_DBNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit RBM and visualize its weightsrand('state',0)dbn.sizes = [100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);figure; visualize(dbn.rbm{1}.W'); % Visualize the RBM weights%% ex2 train a 100-100 hidden unit DBN and use its weights to initialize a NNrand('state',0)%train dbndbn.sizes = [100 100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);%unfold dbn to nnnn = dbnunfoldtonn(dbn, 10);nn.activation_function = 'sigm';%train nnopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.10, 'Too big error');```Example: Stacked Auto-Encoders---------------------```matlabfunction test_example_SAEload mnist_uint8;train_x = double(train_x)/255;test_x = double(test_x)/255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit SDAE and use it to initialize a FFNN% Setup and train a stacked denoising autoencoder (SDAE)rand('state',0)sae = saesetup([784 100]);sae.ae{1}.activation_function = 'sigm';sae.ae{1}.learningRate = 1;sae.ae{1}.inputZeroMaskedFraction = 0.5;opts.numepochs = 1;opts.batchsize = 100;sae = saetrain(sae, train_x, opts);visualize(sae.ae{1}.W{1}(:,2:end)')% Use the SDAE to initialize a FFNNnn = nnsetup([784 100 10]);nn.activation_function = 'sigm';nn.learningRate = 1;nn.W{1} = sae.ae{1}.W{1};% Train the FFNNopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.16, 'Too big error');```Example: Convolutional Neural Nets---------------------```matlabfunction test_example_CNNload mnist_uint8;train_x = double(reshape(train_x',28,28,60000))/255;test_x = double(reshape(test_x',28,28,10000))/255;train_y = double(train_y');test_y = double(test_y');%% ex1 Train a 6c-2s-12c-2s Convolutional neural network %will run 1 epoch in about 200 second and get around 11% error. %With 100 epochs you'll get around 1.2% errorrand('state',0)cnn.layers = { struct('type', 'i') %input layer struct('type', 'c', 'outputmaps', 6, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %sub sampling layer struct('type', 'c', 'outputmaps', 12, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %subsampling layer};cnn = cnnsetup(cnn, train_x, train_y);opts.alpha = 1;opts.batchsize = 50;opts.numepochs = 1;cnn = cnntrain(cnn, train_x, train_y, opts);[er, bad] = cnntest(cnn, test_x, test_y);%plot mean squared errorfigure; plot(cnn.rL);assert(er<0.12, 'Too big error');```Example: Neural Networks---------------------```matlabfunction test_example_NNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);% normalize[train_x, mu, sigma] = zscore(train_x);test_x = normalize(test_x, mu, sigma);%% ex1 vanilla neural netrand('state',0)nn = nnsetup([784 100 10]);opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samples[nn, L] = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.08, 'Too big error');%% ex2 neural net with L2 weight decayrand('state',0)nn = nnsetup([784 100 10]);nn.weightPenaltyL2 = 1e-4; % L2 weight decayopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex3 neural net with dropoutrand('state',0)nn = nnsetup([784 100 10]);nn.dropoutFraction = 0.5; % Dropout fraction opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex4 neural net with sigmoid activation functionrand('state',0)nn = nnsetup([784 100 10]);nn.activation_function = 'sigm'; % Sigmoid activation functionnn.learningRate = 1; % Sigm require a lower learning rateopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex5 plotting functionalityrand('state',0)nn = nnsetup([784 20 10]);opts.numepochs = 5; % Number of full sweeps through datann.output = 'softmax'; % use softmax outputopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex6 neural net with sigmoid activation and plotting of validation and training error% split training data into training and validation datavx = train_x(1:10000,:);tx = train_x(10001:end,:);vy = train_y(1:10000,:);ty = train_y(10001:end,:);rand('state',0)nn = nnsetup([784 20 10]); nn.output = 'softmax'; % use softmax outputopts.numepochs = 5; % Number of full sweeps through dataopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, tx, ty, opts, vx, vy); % nntrain takes validation set as last two arguments (optionally)[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');```[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/rasmusbergpalm/deeplearntoolbox/trend.png)](https://bitdeli.com/free "Bitdeli Badge")

iBATIS学习小结

一、iBATIS介绍 1.iBATIS的思想: iBATIS是查询映射工具,而不是O/RM工具,适用于持久层。 方案 相同的优点 解决的问题 存储过程 iBATIS对SQL进行了封装和外部化,使SQL从应用程序中分离出来,iBATIS支持对存储过程的调用 业务逻辑从数据库中分离出来,应用程序更容易部署与测试,也具有更好的可移植性。...

iteye_9308的博客 199

WINCC7.3破解文件

WINCC7.3硬件够破解文件,有需要的下载!WINCC7.3硬件够破解文件,有需要的下载!

ibatis 小结

IBATIS的操作核心对象是SqlSession,它提供了强大的增、删、改、查功能,我们对对象(数据库)的所有操作都是基于SqlSession来完成的。SqlSession执行哪些具体操作需要我们来为它指定mapper,这个mapper类似于我们在SQLDeveloper中执行SQL,只不过现在是把SQL配置在Mapper.xml文件中,并且这个SQL具体自动校验、封装的功能。每一个操...

s306587279的专栏 169

visio安装包

Microsoft Office Visio 是一款专业的制图软件。利用经过更新的形状、协作工具和数据链接图表,创建专业级图表以简化复杂的信息。

ibatis 初学小结

ibatis学习 ibatis与hibernate都是持久层的额技术框架,这里看看ibatis的配置:作为自己以后的参考: ibstis的配置主要由两种文件, (一)有关项目的总体配置,如连接的数据源,连接池,缓存等的配置,也即sqlmapconfig.xml文件的配置。 (二)sqlmap.xml文件的配置,也即对象与表的操作映射的配置。 下面分两个部分进行记录 第一

花落尽相随 663

ibatis转成Mybatis问题小结

在数据层ibatis转换成mybatis的时候,遇到了点问题。 区别1: ibatis的结构是Service-&gt;ServiceImpl-&gt;Dao-&gt;DaoImpl-&gt;Domain(实体类)-&gt;xml(里面是对应的SQL) mybatis的结构是Service-&gt;Mapper-&gt;Mapper.xml文件,其中Mapper文件需要在application...

yuyuyumeimeimei的博客 1619

Ibatis Iterator用法小结

1、要在ibatis里面使用命名空间需要在sqlMapConfig.xml中增加如下设置          &lt;settings useStatementNamespaces="true" /&gt; 2、写JavaBean类时  建议把属性全部写成引用类型  对于基本类型写成它对应的包装类型       这样可以避免数据库中对应的字段可以为空时   查询结果在映射时报错 3、 &lt...

f04062115的专栏 718

刚学ibatis,小结一下

1. ibatis 框架通过对象和SQL 之间映射来完成持久化工作的。 2. ibatis框架的搭建 (1)所需的架包:ibatis.jar  mysql-connector-java-bin.jar (2)配置数据源:SqlMapConfig.xml             PUBLIC "-//ibatis.apache.org//DTD SQL Map Config 2.0/

kimi_lov_ing的专栏 975

iBATIS学习小结1——初步了解iBATIS

    刚开始实习,还未具体参与某个项目,所以抽出点时间来学习下这个即将用到的工具——Eclipse,当然主要还是iBATIS,因为具体设计还不到火候,只能做点数据导入数据库并完成到具体类的映射这种稍微点拨下就能学会的事儿。但是我不满足于借由已经配置好的Eclipse写些无趣的代码,我希望能更深入的了解iBATIS。    学习心得是在平时学习中一点一滴积累的,因为还是小白,可能有相当多的错误,希...

红枫林 184

ibatis学习小结

 sqlMap配置文件 PUBLIC "-//ibatis.apache.org//DTD SQL Map Config 2.0//EN" "http://ibatis.apache.org/dtd/sql-map-config-2.dtd"> useStatementNamespaces="true" cacheModelsEnabled="true" enhancem

tiancityycf的专栏 679

ibatis 使用小结

一、在ibatis的配置文件中,#,$等表示的意义是不同的。 举例来说明他们的应用: DAO层代码赋值为:username=”abc” sortField=”ord1” ascending=”ASC” &lt;select id="getDestroyIdListLimit" parameterClass="java.util.Map" resultClass="String"&gt;  ...

marco1983的专栏 252
上一篇: IbatisNet动态SQL
下一篇: sql命令备份/恢复数据库
jackfor001
博客等级 码龄22年 41粉丝 61原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

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

抵扣说明:

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

余额充值