- 稀疏图适合用邻接表,效率和边数量有关;密集图适合用邻接矩阵
- dijkstra求单源最短路,但是不能用于负边,堆优化(优先队列实现)
相关推荐
python blp模型 估计_随机系数Logit模型及Stata实现
欢迎投稿(荐稿)计量经济圈,计量相关都行邮箱:econometrics666@sina.cn作者:北京交通大学经济管理学院博士生,王琦珀。欢迎你加入计量经济圈社群,一起探讨前沿计量理论和实证方法。一、随机系数Logit模型1.背景实证产业组织(Empirical Industrial Organization,EIO)是目前产业组织理论的前沿,其中又以Ariel Pakes为带头人,其近期工作论文...
JAVA杂记1
文档:java杂记1.note 链接:javase杂记1
TikTok网页版X-bougs和_signature参数逆向实战:从断点到RPC调用的完整流程
本文详细解析了TikTok网页版X-bougs和_signature参数的逆向工程实战,从基础断点调试到高级RPC调用,完整还原加密参数的生成过程。通过工具链搭建、加密定位、核心突破及实战演练,帮助开发者深入理解TikTok的加密体系,并构建自动化签名系统。
java杂记2
文档:Java杂记2.note 链接:javase杂记2
SpringBoot Actuator未授权访问漏洞实战:从发现到利用
本文深入剖析了SpringBoot Actuator未授权访问漏洞的成因、危害与利用手法。文章详细演示了如何发现暴露的端点,并通过实战案例复现了从敏感信息泄露到利用反序列化漏洞实现远程代码执行(RCE)的全过程,为开发与运维人员提供了从漏洞发现到修复加固的完整安全指南。
Windows MCP 安装教程:让 AI 代理与 Windows 系统无缝交互
通过以上步骤,你已经成功安装和配置了 Windows MCP 服务。现在你的 Cursor 编辑器可以通过 MCP 协议与 Windows 系统进行深度交互,AI 代理能够:启动和控制应用程序执行系统命令自动化 UI 操作获取系统状态信息这为 AI 辅助开发和工作流程自动化提供了强大的基础。如果你在使用过程中遇到任何问题,欢迎在评论区讨论或查看项目的官方文档。
java杂记3
文档:JAVA杂记3.note 链接:javase杂记3
串级PID 位置环+速度环
串级PID 位置环+速度环
SQL杂记
文档:SQL杂记.note 链接:添加链接描述
本地部署 Bolt.new - 小学生都能轻松搭建AI编程环境
本地部署 Bolt.new - 小学生都能轻松搭建AI编程环境
RTKLIB PPP与RTK_POST精密定位实战:从实时到事后处理的完整流程解析
本文详细解析了如何使用RTKLIB进行精密单点定位(PPP)的完整流程,涵盖从实时处理到事后处理(RTK_POST)的关键步骤。文章深入探讨了数据准备、软件配置、核心参数设置(如电离层、对流层、潮汐改正)以及常见问题排查,旨在帮助用户掌握高精度GNSS定位技术,实现从入门到精通的实战应用。
java杂记4
文档:Java杂记4(随记).note 链接:javase杂记4
【数据集】基于ubESTARFM法的100m 地温LST数据集(澳大利亚)
【数据集】基于ubESTARFM法的100m 地温LST数据集(澳大利亚)
读朱自清先生《欧游杂记》随感
序中他对两个来月间游览五国十二个地方仅一语带过,更多的笔墨对游览的感受做了说明,着重介绍游览的名胜古迹,因何而记录,说明游记为什么只记录风景而不谈自己感受。如为了描写景物间的关系,作者特别举例说明“楼上正中一间大会议厅”,给人一种从观察者的角度看,而没有采用“是”字句、“有”字句、“在”字句安排,即“楼上正中是一间大会议厅”、“楼上有一间大会议厅”、“大会议厅在楼上正中”,期望给读者以整个的具体的印象。由此,结合作者的序,再读他的游记,既有一种身临其境,同时也能感受作者当时的心境。
精雕软件(JDpaint) 5.5 绿色版
精雕软件(JDpaint) 5.5 绿色版精雕软件(JDpaint) 5.5 绿色版精雕软件(JDpaint) 5.5 绿色版
霍尼韦尔SoftMaster使用说明
霍尼韦尔SoftMaster使用说明
linux学习杂记
linux学习杂记
IMSL CNL 7.0.0 (x86-64)Crack
IMSL CNL 7.0.0 (x86-64)Crack intel的算法库破解文件,这是C++版本的破解文件
数据结构杂记(补)
此篇为数据结构杂记的补充声明:
深度学习工具包 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');```[](https://bitdeli.com/free "Bitdeli Badge")
杂记 Infinity infinite
Infinity infinite
EF学习杂记:索引帖
下面将开设一个Entity Framework的学习杂记,着重记录自己在学习Entity Framework的过程中收集一些有关EF的内容,其中前面的一些杂记主要是翻译自博客Mata-Me中的相关内容,我认为他的博客关于EF的讲述非常值得参考,其他的有部分是我自己的摸索,都以系列的方式记录在下面,本文章将作为该系列文章的一个索引帖进行发布: EF学习杂记1:如何在继承类中返回指定的类 EF学习...
学习及生活杂记
<一,>近期生活杂记; 铭记每一刻旅程,感恩,无语,走着并深耕不辍; 1,2014-07-19,在合肥保利交定金认购一套房,作为我和女朋友在合肥的一席属于个人的休憩之地,此处应该感谢老婆支援的认购定金,前面我说错了,应该是我老婆,2014-08-04在老婆家乡阜阳市登记领证结婚; 2,2014-07-28,交完购房一定首付,此处感谢爸妈哥嫂....驰援的购房首付金; 3,201...
前端学习杂记(JS)
这篇博文是自己在工作中学到的关于JS的之前不知道的新知识。 将其记录下来并分享一下 处理一个对象内的数据的方法 Object.entries(data).forEach([key, value]) => { // dosomething } // Object.entries(data) data为我们要处理的对象 返回一个数组每项为对象键值对组成的数组的二维数组 如: const d...
课程学习 CV 北京邮电大学 鲁鹏(笔记一:杂记)
杂记
数学杂记(3)支持向量机SVM相关
关于支持向量机SVM的一些证明练习。
程序员杂记系列
有感而发,糊撇乱侃的文章。宣泄一些郁闷,分享一些快乐。 程序员杂记:以显摆的名义! http://jianle.blog.51cto.com/429692/642710 程序员杂记:奋战在青青网吧! http://jianle.blog.51cto.com/429692/646494 程序员杂记:兴趣井”与“机遇缝” http://jianle.blog.51cto.com/42...
白沙雜記 勒馬臨門
白沙雜記에 曰余居家接客에 常以任眞(天)爲貴하고 不主末禮라 故로 親朋이 亦知此風習하니라 一日에 李長城玉汝(李貴의 字)官罷歸鄕할새 道過京城하야 訪余於家러라니 適余不在라 玉汝勒馬臨門하야 呼女奴分付曰爲我語吳嫂하라 我俟令公歸家하야 卽當再訪하리라 我管下奴子幾名이오 馬幾匹이니可照此數하야 具夕飯하되 萬無遲誤하라 未幾에 余自外至則吳娘
诗词小集 · 杂记碎念
该博客主要包含诗词、歌赋、文摘、文言文和杂记等内容。诗词涵盖了白居易、李白、杜甫等众多诗人的作品;歌赋涉及《长恨歌》等;文摘包含名言警句;文言文有经典语句;杂记包含人生感悟等。还提及了信息技术领域Carmack的名言。
2641



被折叠的 条评论
为什么被折叠?



