JQuery dataTable 扩展+Ajax Post,Get一些基本操作(一)

上下文理解的AI增强方案:AI应用架构师的架构洞察 本文将从AI应用架构师的视角,深入探讨“上下文理解”的技术本质、核心挑战,以及一套可落地的上下文增强架构方案。我们会拆解上下文理解的底层需求,分析架构设计中的关键决策,并通过具体案例展示如何构建一个能“记住过去、理解现在、预测未来”的AI系统。三个维度:上下文的内容范围(短期/中期/长期)、数据类型(文本/结构化/多模态)、技术挑战(窗口限制/信息过载/跨会话一致性);三种架构模式:分层上下文存储(热/冷数据分离)、上下文路由(按需筛选)、动态压缩(适配模型窗口);四个关键组件。 阅读详情

首先, Asp.net MVC 系列暂时没有发现封装好的 类似于web form 的datagrid, 只有一款Jquery 的dataTable , 官网地址 http://www.datatables.net, 接下来讲解一下关于自己在项目中对datatable进行扩展的一些实例。(first,Asp.net MVC have not packaging control similar the web form datagrid , and  now   i just konw Jquery dataTable, and The website address: http://www.datatables.net, the next ,i will list  some examples  that i have meet some issues in project),

直接上视图代码

复制代码
<form method="post" οnsubmit="return MaintainDel();">
    <div id="Message">
        <h3 style="color:red">@ViewBag.mes</h3>
    </div>
    <input id="ChooseUserId" name="ChooseUserId" type="hidden" />
    <div class="row">
        <div class="col-lg-12">
            <div class="panel panel-default">
                <!--<div class="panel-heading">
                    Users
                </div>-->

                <div class="panel-body">
                    <div class="table-responsive">
                        <table id="tab" class="table table-striped table-bordered table-hover">
                            <thead>
                                <tr>
                                    <th>Delete</th>
                                    <th>NRIC</th>
                                    <th>USER ID</th>
                                    <th>NAME</th>
                                    <th>Email</th>
                                    <th>ContactNo.</th>
                                    <th>Agency</th>
                                    <th>Designation</th>
                                    <th>SchemeRole</th>
                                    @*<th>IsDeleted</th>*@
                                </tr>
                            </thead>
                        </table>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="text-center">
        <input id="AddUserInfo" type="button" class="btn btn-default" value="Add User" οnclick="AddUser();" name="btnaction" />&nbsp;
        <input id="DelUserInfo" type="submit" class="btn btn-default" value="Delete" name="btnaction" />
    </div>
    </form>
复制代码

对于JQuerydatatable, 我们只需要在视图中写出table的head 就可以, 接下来是controller里面从数据库拿一个list的方法,由于project用的是EF+MVC+Storeprocedure ,对于拿数据方面就不多讲,下面是controller的代码:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
[HttpGet]
        [MyAuthorize(ActionName = ActionCode.MaintainSuperUserAdmin)]
        public  ActionResult MaintainSuperUserAdmin()
        {
            return  View();
        }
 
        /// <summary>
        /// return Json Data for Jquery  Table
        /// </summary>
        /// <param name="parm"></param>
        /// <returns></returns>
        public  JsonResult PageList(DataTablesParam parm)
        {
            int  iDisplayStart = Convert.ToInt32(Request.Params[ "iDisplayStart" ]);
            //data size
            int  iDisplayLength = Convert.ToInt32(Request.Params[ "iDisplayLength" ]);
            //data total           
            int  totalCount;
            IEnumerable<UserUserInfo> user = this .ServiceLocator.GetService<IUserInfoRoleSchemeService>().GetUserInfoRoleSchemeViewInfo(Common.AdminRoleId.SuperAdminId, appid, iDisplayStart, iDisplayLength, out  totalCount).ToList();
            return  Json( new
            {
                sEcho = parm.sEcho,
                iTotalRecords = totalCount,
                iTotalDisplayRecords = totalCount,
                aaData = user
            }, JsonRequestBehavior.AllowGet);
        }

 一个Action对应一个View   改View的数据从Jsonresult中获取。

1
[MyAuthorize(ActionName = ActionCode.MaintainSuperUserAdmin)]这段是用户权限过滤器 就不细讲,可用可不用。 主要代码为
1
PageList中  拿list数据 以及返回Json格式。Dataparam为个人封装的 可以接收JqueryDatatable 一些属性的数据,(注意JQueryDatatable 自带分页效果)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
public  class  DataTablesParam
     {
         public  int  iDisplayStart { get ; set ; }
         public  int  iDisplayLength { get ; set ; }
         public  int  iColumns { get ; set ; }
         public  string  sSearch { get ; set ; }
         public  bool  bEscapeRegex { get ; set ; }
         public  int  iSortingCols { get ; set ; }
         public  int  sEcho { get ; set ; }
         public  int  total { get ; set ; }
         public  List< bool > bSortable { get ; set ; }
         public  List< bool > bSearchable { get ; set ; }
         public  List< string > sSearchColumns { get ; set ; }
         public  List< int > iSortCol { get ; set ; }
         public  List< string > sSortDir { get ; set ; }
         public  List< bool > bEscapeRegexColumns { get ; set ; }
 
         public  DataTablesParam()
         {
             bSortable = new  List< bool >();
             bSearchable = new  List< bool >();
             sSearchColumns = new  List< string >();
             iSortCol = new  List< int >();
             sSortDir = new  List< string >();
             bEscapeRegexColumns = new  List< bool >();
         }
 
         public  DataTablesParam( int  iColumns)
         {
             this .iColumns = iColumns;
             bSortable = new  List< bool >(iColumns);
             bSearchable = new  List< bool >(iColumns);
             sSearchColumns = new  List< string >(iColumns);
             iSortCol = new  List< int >(iColumns);
             sSortDir = new  List< string >(iColumns);
             bEscapeRegexColumns = new  List< bool >(iColumns);
         }
     }

  Ok   一切就绪了,那么接下来就是如何将后台拿到的数据传递给View的Table,下面是关于这方面的JQuery代码,关于datatable的一些属性,大家就百度吧,,有用到的再说。

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
$(document).ready(function () {
         var  admin = $( '#tab' ).dataTable({
             "sAjaxSource" : "@Url.Content(" ~/UserInfoRoleScheme/SchemePagelist ")" ,
             //"sScrollX": "100%",
             "sScrollXInner" : "100%" ,
             //"bScrollCollapse": true,
             "serverSide" : true ,
             'bPaginate' : true ,
             "bLengthChange" : false ,
             "bSort" : false ,
             "bFilter" : false ,
             "oLanguage" : {
                 "sZeroRecords" : "@Messages.General.EmptyData.Format()" ,
                 "sEmptyTable" : "@Messages.General.EmptyData.Format()" ,
             },
             "aoColumnDefs" : [
                   {
                       "render" : function (data, type, full) {
                           if  (full.IsDeleted == true ) {
                               return  full.UserName;
                           }
                           else  {
                               return  '<a href="'  + "@Url.Content( "~/UserInfoRoleScheme/UpdateSchemeUser" ) " + " ?userid= " + full.UserId + '" >' + full.FullName + '</a>' ;
                           }
                       },
                       "targets" : 3
                   },
           {
               "render" : function (data, type, full) {
 
                   return  '<input type="checkbox" id="CheckUser" name="SelectedRoleId" class="userCheck" value="'  + full.UserId + '"/>' ;
               },
               "targets" : 0
           },
            {
                "render" : function (data, type, full) {
 
                    return  Trim(full.SchemeRole);
                },
                "targets" : 8
            },
           //{
           //    "render": function (data, type, full) {
           //        if (full.IsDeleted == true) {
           //            return "Yes";
           //        }
           //        else {
           //            return "No";
           //        }
           //    },
           //    "targets": 10
           //},
             ],
             'aoColumns' : [
                     { "mData" : "UserInRoleId"  },
                     { "mData" : "Nric"  },
                     { "mData" : "AdId"  },
                     { "mData" : "FullName"  },
                     { "mData" : "EmailAddress"  },
                     { "mData" : "MobileAlias"  },
                     { "mData" : "AgencyId"  },
                     { "mData" : "Designation"  },
                     { "mData" : "SchemeRole"  },
                     //{ "mData": "SchemeName" },
             ]
         });
     })

  该段JQuery代码 ,,,注意

1
"mData" 的时候 输入的字段名字一定要与后台list的columns一致,不然获取不到该列的数据,<br><br>
1
2
3
4
"oLanguage" : {
                 "sZeroRecords" : "@Messages.General.EmptyData.Format()" ,
                 "sEmptyTable" : "@Messages.General.EmptyData.Format()" ,
             },<br>改属性为list为空的时候  JQueryTable显示的errormessage ;<br><br>
1
"aoColumnDefs" : 是自己对datatable每一列的一些扩展定义,比如 当 我点击每一行的名字的时候  链接到Update页面更新该用户的所有信息。<br>checkbox  每一行自动加上checkbox便于 进行一些操作,批量删除,单个删除等操作。
1
"targets"   从0 开始  可以定位到每一列 如 0  就是第一列 checkbox。<br><br>
1
"render" : function (data, type, full)   full为该行的所有数据,data 为该行该列的数据。<br><br>下面 为Jquery Datatable 的展示效果,很多属性没设置,,都是根据客户需求来的,,各位可以参考官网自行设置。<br><br>

1
加入了checkbox之后由于是根据后台的数据动态的显示的,,所以checkbox的取值 给我了很大的困扰,下面的Jquery方法 是我感觉比较好的一种吧,一般的都是用id取值,但是在相同的id下 我们不得不考虑用id取值的准确性,因此,我们通过 class  遍历 对checkbox进行取值。
1
2
3
4
5
6
7
var  UserId= "" ;
$( '.userCheck' ).each(function () {
     if  ( this . checked  == true ) {
         UserId += $( this ).attr( 'value' ) + ','
     }           
})   

  得到一个string类型的数据,就可以传回后台通过一系列操作,达到自己想要操作的目的了。

自己整理的一些东西

1
<br><br>
cut&tag学习笔记 上图是我得到的结果,下图是教程的结果,比对结果有一些差异,我也不知道具体原因是啥。谷歌了一下,发现原因可能是因为环境变量的问题,系统不知道picard的具体位置,需要设置全局环境变量,遂查了一下picard的位置。我发现我做出来的结果测序深度一致,但是比对的结果有一点差异,不知道是我的操作问题,还是参考基因组更新了导致比对结果出现了些许不同。上图是我得到的结果,下图是教程的结果,除了IgG_rep1外比对结果一致。上图是我的结果,下图是教程的结果,结果不太一致,不知道是具体的原因是什么。 阅读详情

相关推荐

CANoe/CANalyzer新手必看:从零配置到报文分析的完整流程(附B站官方教程实操)

本文为CANoe/CANalyzer新手提供从零配置到报文分析的完整流程指南,涵盖硬件连接、工程配置、报文捕获及信号级分析等关键步骤。通过详细的实操案例和B站官方教程,帮助工程师快速掌握汽车电子总线分析工具的核心应用,提升诊断效率与通信系统理解。

y7z8a的博客 773

datatable ajax datasrc,datatables插件ajax发送post数据的问题

在用datatables插件的时候碰到的问题,想用button onclick时间触发table的reload,从而将一个input元素中用户输入的内容post到后台,以下是我写的简单的例子$(document).ready( function () {$('#table_id').DataTable({"processing": true,"serverSide": true,"ajax": {...

weixin_35793308的博客 413

Nvidia Tesla A100 驱动安装方法

Nvidia Tesla A100 驱动安装方法 遇到的问题:以前安装tesla系列、geforce系列等gpu 驱动的时候,只需执行nvidiaxxxx.run驱动包或者安装nvidiaxxxx.rpm包即可,但遇到新的GPU Nvidia Tesla A100的时候,安装完驱动似乎不起作用,找了半天资料,原来需要以下步骤才可以使用;

qq_24343177的博客 2万+

Jquery DataTable ajax get

使用DataTable,并通过ajax来实现数据的展示 第一步:引入 <link href="https://cdn.datatables.net/1.10.24/css/jquery.dataTables.min.css" rel="stylesheet"> <script src="https://cdn.datatables.net/1.10.24/js/jquery.dataTables.min.js"></script> 第二步:HTML页面编写 <ta

Minecr001的博客 459

[QMT和ptrade量化交易小白入门]-125、菜场大妈加上四大现金行业指数风控,最大回撤从22%减少了一半

群里面有人建议,在菜场大妈策略的基础上,加入申万的行业指数(银行,钢铁,有色,煤炭)测算其宽度,当这四大行业其中有一个高就会清仓(用来控制回撤)。这背后的逻辑是,在存量资金博弈的市场环境中,资金总量相对固定,当银行、钢铁、有色、煤炭等大市值周期行业因基本面改善(如涨价、政策催化)或避险需求而走强时,会吸引大量资金涌入,导致其他板块(尤其是小市值股票)面临流动性虹吸。经过回测,对比上一个版本发现确实是可以降低一半的回撤,最大回撤从22.3%降到了11.4%,而且有很多时间是空仓等待。

木头大左的博客 241

内网渗透(二)之基础知识-工作组介绍

在一个大型单位里,可能有成百上千台计算机互相连接组成局域网,它们都会列在"网络"(网上邻居)内。如果不对这些计算机进行分组,网络的混乱程度是可想而知的 为了解决这一问题,产生了工作组( Work Group)这个概念。将不同的计算机按功能(或部 门)分别列入不同的工作组,例如技术部的计算机都列入"技术部"工作组、行政部的计算机都 列入"行政部"工作组。要想访问某个部门的资源,只要在"网络"里双击该部门的工作组名 就可以看到该部门的所有计算机了。相比不分组的情况,这样的情况有序得多(尤其对大型局域网来说)。

把自己活成一道光,因为你不知道,谁会借着你的光,走出了黑暗。请保持心中的善良,因为你不知道,谁会借着你的善良,走出了绝望。请保持你心中的信仰,因为你不知道,谁会借着你的信仰,走出了迷茫。请相信自己的力量,因为你不知道,谁会因为相信你,开始相信了自己.... 1219

jquery table ajax,JQuery Ajax动态加载Table数据的实例讲解

我们在jsp定义一个select和一个table,要求实现根据select的选值,动态加载table数据。table第一次加载数据的function定义如下:function loadData() {var c = '';$('#import-table').DataTable({ajax: {url: '' + "../../../hot/getByCode.action?code=APP",t...

weixin_31514917的博客 596

05 - GRACE数据处理-球谐展开与球谐综合

GRACE数据处理-球谐展开和综合前面在介绍GRACE相关理论的时候提到过下面的公式,从公式形式上可以看出,面密度变化和球谐系数(CS)之间是能够相互转换的,那这个转化的过程可以称为球谐展开,简单理解就是将全球网格数据转化为球谐系数的过程。而球谐综合可以看作是球谐展开的逆过程,利用球谐系数计算到全球格网分布。

weixin_43339605的博客 1050

datatables 封装 post传参

封装 var Hf_DataTable = function () {     /* 全选以及选中效果功能  */     function checkAll(table) {         //全选功能         table.find('.checkall').change(function () {             var allCheck = table.find('tbo...

qq_39753664的博客 1780

【无人机基站】基于K-mean算法实现无人机基站部署附matlab代码

【无人机基站】基于K-mean算法实现无人机基站部署附matlab代码

天天酷科研的博客 243

告别 DEFINE VIEW:CDS View Entity 迁移全景实战(报表迁移 + ADT 向导 + 避坑清单)

CDS迁移的关键要点与策略 CDS DDIC-based View已被标记为废弃,迁移到CDS View Entity成为必要。迁移面临的主要挑战包括激活成本、命名约束和依赖风险。ABAP 7.57及以上版本必须优先处理,否则将积累技术债务。 迁移方式主要有两种: 报表路线:适合渐进式迁移的On-Premise项目 ADT向导:适合云环境批量迁移 关键注意事项: 必须提前检查SQL View依赖关系 金额/数量字段需要显式引用单位/货币字段 建议按使用场景分批迁移 最佳实践是结合报表进行系统盘点,再通过AD

2007 年 ~ 2025 年,深耕 SAP 技术 18 年 208

JQuery dataTable 扩展+Ajax Post,Get一些基本操作(二)

简单的小demo ,, 主要是讲如何在dataTable 中 进行 行 的编辑, 如做delete,edit ,等操作的时候 如何获取 改行的一些主要数据。 1 <div class="col-md-12"> 2 <div class="panel-body"> 3 ...

weixin_30825199的博客 262

android 蓝牙通讯demo

android 下蓝牙通讯demo,实现了发现蓝牙,使能蓝牙,通过蓝牙发送消息。

关于前端接口 jquery的ajax请求

关于jquery中ajax请求一.ajax语法二. 四种请求方式1.get请求2.post请求2.1 默认格式2.2 json格式请求2.3 序列化表单值2.3 FormData3.put请求4.delete 请求三、常用的状态码四、重新加载数据table.ajax.reload();4.1 每30秒重新加载表数据(分页重置)4.2 每30秒重新加载表数据(分页留存)4.3 使用回调函数来更新外部元素 一.ajax语法 $.ajax({键值对}); $.ajax({ //四种请求方式大写 GET

太阳宝宝的博客 924

深度学习工具包 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")

jre9下载 jdk9

(Java SE Runtime Environment 9.0) 9.0u175 官方最新版 【x86|x64】

jquery datatable插件使用分享

这个插件很好用,筛选,分页等功能都是内置的了。重要的是根据自己的喜爱,变换它的css。 本文主要写个和ajax交互的小例子。

任性积累 2628

温度PID控制PLC程序

温度PID稳定控制程序,适用于欧姆龙PLC,对其他PLC也具有很大参考价值

html ajax put请求,关于前端接口 jquery的ajax请求

关于jquery中ajax请求一.ajax语法$.ajax({键值对});$.ajax({//四种请求方式大写 GET POST PUT DELETEtype: "POST",//接口地址或发送请求的地址url: "http://localhost:9015/u9 api/",//如果接口指定有发送请求头,那么需要写headersheaders: { "键 ":"值" },//默认...

weixin_35997999的博客 796

dataTable配置方式以及参数详解

<"类名称"> 表示一个class="类名称"的闭合的div 例如: <"rad"> = <div class="rad"></div>"aLengthMenu" : [ [ 50, 100, -1 ], [ "50", "100", "所有" ] ],"sInfo" : "第 _START_ - _END_ 条 / 共 _TOTAL_ 条数据",* 注意:_MENU_、_START_、_END_、_TOTAL_、_MAX_等通配。"sLengthMenu" : "每页显示 _MENU_ 条记录",

weixin_46293740的博客 862

jquery datatable服务端分页

OK,上次完成了客户端的分页,这次我们就在上一次的Demo上进行修改,来实现服务端的分页~ js代码:<script type="text/javascript"> $(document).ready(function() { $('#table_id_example').DataTable({ "bProcessing" : false, //是否显示加载

Firmye 3609

jquery.dataTable.js 使用详解 一、基础配置

    dataTable用了很久,今天在此总结一下使用方法以及常用属性的解释。     要试用dataTable,首先你得有个table,html代码如下:   &lt;html&gt; &lt;head&gt; &lt;head lang="zh-CN"&gt; &lt;meta charset="UTF-8"&gt; &lt;link href="s

wol555c的博客 720

jquery 数据转为json_JQuery将DataTable、list<>数据转换成JSON数据

jquery ajax 调用webservice以及跨域问题2012-12-04 13:46 by omgee, 279 阅读, 0 评论, 收藏, 编辑先在服务器端配置webconfig,因为默认情况下是不支持post,get访问在system.web 中间本地调用客户端$(document).ready(function () {$("#button1").click(function () ...

weixin_39859819的博客 472

JQuery .ajax .post .get 应用

.ajax 前台代码: &lt;script type="text/javascript"&gt; $(function () { $("a").click(function () { switch (this.id) { case "login": ...

weixin_33883178的博客 89

DataTable合并行

table= $('#table').DataTable( { destroy: true, serverSide: true, responsive: true, deferRender: false,//设置延迟渲染,提高效率用 draw:false, searching : false, bLengthChange: false, order: [[ 0, 'asc' ],[ 1, 'asc' ]],...

半城繁華半城傷的博客 703

mvc中如何用ajax生成table,Asp.net MVC 中利用jquery datatables 实现数据分页显示功能

1、Controller中的方法代码如下:由于方法中的存储过程没有带分页参数,所以还可以有继续优化的空间。/// /// 获取测点列表/// /// [HttpPost]public JsonResult GetMeasurePointList(string TreeID, string TreeType, int sEcho, int iDisplayStart, int iDisplayLen...

weixin_34279705的博客 481

DataTable 带滚动刷新全选全不选

引入 ../../../../media/css/jquery.dataTables.css ../../css/scroller.dataTables.css https://code.jquery.com/jquery-3.3.1.js ../../../../media/js/jquery.dataTables.js ../../js/dataTables.scroller.j...

weixin_30908707的博客 288

用springmvc模式和ajax完成分页,DataTables+SpringMVC实现服务器端分页处理

View层jsp或者html代码:First nameLast nameFirst nameLast nameJS代码:$("#example").DataTable({"bLengthChange": false,"bFilter": false,"bSort": false,"bInfo": true,"bProcessing": true, // 加载条"iDisplayLength": 1...

weixin_30482027的博客 317

通过jquery ID筛选器绑定dataTable插件

/* * 通过jquery ID筛选器绑定dataTable插件 */ $("#mainTable").dataTable({ /* * sErrMode * 错误信息显示方式 * 分别为alert和throw,默认为alert */ "sErrMode" : "throw", /* *

Jc0803kevin的专栏 515
上一篇: 细细品味Web——Json-Lib类库使用手册
下一篇: JAVA 图片加水印 支持水印换行 水印背景
lb8607
博客等级 码龄18年 17粉丝 18原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

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

抵扣说明:

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

余额充值