相关推荐
从NHANES到发表:如何用survey包完成符合CDC要求的统计分析(含完整R代码)
本文详细介绍了如何利用R语言的survey包,对美国国家健康与营养调查数据进行符合CDC要求的统计分析。文章重点解析了NHANES数据的复杂抽样设计、权重变量的正确选择与调整,并提供了从数据获取、清洗、构建调查设计对象到执行加权回归及生成发表级表格的完整R代码实战指南,帮助研究者避免常见错误,确保分析结果的准确性与可发表性。
Microsoft Windows Command-Line Administrator's Pocket Consultant
Microsoft Windows Command-Line Administrators Pocket ConsultantMicrosoft Press | 28 April, 2004 | ISBN: 0735620385 | CHM | 1,32 MbPocket-sized guide delivers information on managing Microsoft
电路保护设计实战:保险丝选型、I²t计算与多级协同方案
电路保护是电子系统可靠性的基石,其核心原理是在发生过流或过压等异常情况时,及时切断故障回路,防止能量持续灌入导致元器件损坏甚至安全事故。从技术价值看,优秀的保护设计能显著提升产品寿命、安全性和市场口碑,尤其在快充、电动汽车等高功率密度应用中,保护器件已成为不可或缺的安全屏障。在众多保护器件中,保险丝作为最基础的过流保护元件,其正确选型与应用直接关系到保护效果。本文聚焦于保险丝选型的实战细节,深入解析了I²t(电流平方时间积)这一关键参数,它定义了熔断所需的能量阈值,是匹配被保护半导体器件耐受能力、实现有效保
图书推荐:SQL Server 2008 Administrator's Pocket Consultant
Microsoft SQL Server 2008 Administrators Pocket Consultant涵盖了SQL Server 2008系统管理员所需要的所有核心管理任务,并且非常简洁、实用。相比其他图书而言,你不必为查找一个小内容而费尽千辛万苦地翻越数百页的不相干信息,真正体现了该书的袖珍性。该书是被作为SQL Server管理的问题资源设计的,因此,像日常管理、常用任务、
SIMPLIS实战:从零构建理想BUCK电路,精准计算与POP稳态分析
本文详细介绍了如何使用SIMPLIS软件从零开始构建并仿真一个理想的BUCK降压电路。通过设定关键参数、计算理想器件值,并搭建仿真模型,文章重点演示了暂态仿真以观察电路上电过程,并深入讲解了高效的POP(周期性工作点)稳态分析技术,帮助工程师快速验证设计、评估稳态性能,从而加速电源设计迭代。
【AI智能体】Codex 插件从使用到项目开发实战操作详解
Codex 插件从使用到项目开发实战操作详解
AI 答案漂移检测:嵌入相似度、阈值标定与告警实现
做 GEO 监测的人迟早会遇到一个尴尬:上周还在报告里写「这个问句已经稳定被引用」,这周客户自己一问,答案换了个品牌。问题不在监测方法,而在多数监测系统只存「有没有提到」,不存「答案长什么样」。这篇写我们这套漂移检测模块的实现,目标是回答一个问题:同一个问句,今天的答案和两周前相比,变了多少,这个变化是正常抖动还是异常。
AUTOSAR NvM 实车故障深度剖析:车载存储问题快速定位与工程解决方案
软件配置与代码逻辑无问题时,排查底层驱动与ECU硬件,步骤如下:底层驱动排查:排查Fls/Eep驱动配置,是否适配目标MCU(如TC397、S32K),编程/擦除/读取时序是否合理;检查Fls/Eep驱动错误处理逻辑,是否未处理Flash编程失败、读取错误等异常;验证Flash高速编程模式是否启用,是否能提升写入/读取速度;排查MemIf层配置,是否正确对接NvM与Fls/Eep驱动,是否存在调度延迟。
Vue开发篇之组件通信与表单:点了任务行,谁来更新列表
用四个Vue组件完成任务录入与状态切换,跟踪props、事件转发和表单草稿的归属。
反光柱定位算法实战03:VEnus代码解析和纯反光柱定位中的可改进方向
本文深入解析了开源框架VEnus的反光柱定位与建图实现流程,包括强度提取、聚类、数据关联、位姿优化等核心模块。同时指出其三大局限:匹配质量脆弱性、单一传感器依赖和地图扩展逻辑缺失,并提出改进方向:融合里程计/IMU数据、引入图优化后端、建立动态地图维护机制。该分析为基于反光柱的定位系统优化提供了实用参考,有助于提升工业场景下的定位鲁棒性和精确性。
基于Simulink的占空比调制DTC降低转矩脉动
修改传统SVPWM模块,输入占空比d和有效矢量索引,计算Ton=d∗Tc、Toff=(1−d)∗Tc,生成对称PWM波形(替代开关表直接输出)。:低速时(n<500rpm)减小dmax=0.6(避免磁链畸变),高速时(n>2000rpm)增大dmax=0.8(提升动态响应);kT/kψ:转矩/磁链误差增益(需整定,如kT=0.02/(N⋅m),kψ=0.1/Wb);(θ为电压矢量与磁链夹角)。② SVM-DTC(占空比计算模块启用,d0=0.5,kT=0.02,kψ=0.1)。
九、list
类模板,我们可以根据所需要的数据类型实例化出类,如list<int>。list文档介绍函数名称功能说明list()无参构造构造并初始化n个val拷贝构造函数使用迭代器进行初始化构造使用列表进行初始化。
深度学习驱动的虚拟试衣间:从CP-VTON到HR-VITON的完整实现指南
虚拟试衣(Virtual Try-On,VTON)是一项利用计算机视觉和深度学习技术,将目标服装自然地“穿”到人物图像上的智能技术。这项技术正在彻底改变在线购物体验,让消费者无需实际试穿就能预览服装的上身效果。VITON-HD是目前最常用的高分辨率虚拟试衣数据集。图像分辨率:1024×768训练集:11,647对(人物+服装)测试集:2,032对每对包含:人物全身照(front)服装平铺图(cloth)人体解析图(segmentation)姿态关键点(pose)
import cn.hutool.core.collection.CollUtil常用库介绍一下
在平时的 Java 开发中,只要涉及到集合的判空、去重、求交集/差集、List 转 Map 等操作,都可以优先看看。
深度学习工具包 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")
汉书HE8,好用的汇编代码编写工具
汉书HE8,好用的汇编代码编写工具早期编写汇编代码所用功能强大
Argument list too long:参数撞上的那堵墙
通配符是个很好用的语法糖,但它不是免费的:展开发生在命令执行之前,所有文件名都要在内核那里过一次安检。文件名里可能包含空格、换行甚至引号,用默认的换行分隔会把一个文件拆成好几个参数,反而制造新的麻烦。分隔的,管道出来变成了换行,统计口径不完全一致,但它足够帮你发现“环境是不是异常膨胀了”。里 128 KB 的缓冲区,就是它给自己留的安全余量——它宁可多跑几趟,也不愿意踩到。)的四分之一来算这个上限,同时设了一个下限,算出来的结果通常就是 2 MB 左右。目录里的日志文件不算大,几百兆而已,磁盘也还有空间。
全球国家地区城市数据
MySQL全球国家地区城市数据报。。。。。。。。。。。。
Java 面试题:数组和 List 如何快速互转?最佳方案是什么?(其他高频面试API)
业务需求推荐 APIList 判断元素是否存在contains()List 根据条件查询单个对象List 根据条件查询多个对象List 判断是否存在符合条件的数据anyMatch()List 排序后快速查找Map 根据 Key 查询 Valueget()Map 判断 Key 是否存在大量数据判断元素是否存在List 根据 ID 高频查询List 转 HashMap两个 List 根据 ID 关联一个 List 转 Map。
STM32F407中文手册
STM32f407中文手册 本参考手册面向应用开发人员,提供有关使用 STM32F405xx/07xx、STM32F415xx/17xx、 STM32F42xxx 和 STM32F43xxx 微控制器存储器与外设的完整信息。STM32F405xx/07xx、STM32F415xx/17xx、STM32F42xxx 和 STM32F43xxx 构成一个微 控制器系列,各产品具有不同的存储器大小、封装和外设。有关订购信息以及器件的机械与电气特性,请参见数据手册。有关 ARM Cortex™-M4F 内核的信息,请参见《Cortex™-M4F 技术参考手册》。
集合按大小切片分批,这个Java工具类5个方法含基本类型数组
本文分享一款JDK17环境下的Java集合分片工具类,内置5个开箱即用的方法,覆盖Collection、对象数组、int数组、long数组四种入参形态,支持分片与分片数量计算两大核心功能。工具类切出的是可增删的独立新列表,元素按引用共享,支持Set、Deque等无下标集合按迭代顺序分片;分片数量计算采用防溢出公式,超大总量也不会溢出。边界处理严格,异常信息明确,适合批量写库、分批调用外部接口、分片提交任务等场景,源码可直接复制使用。
【RHCA+】numactl命令(管理numa)
root@wuzuniao ~]# numactl -H #查看服务器上的numa数量及每个node内的cpu和内存数。[root@wuzuniao ~]# yum -y install numactl #安装工具。[root@wuzuniao ~]# numactl #输入错误就会弹出命令帮助。限制程序只使用node本地内存,不能使用其他node内存;[root@wuzuniao ~]# numactl -s #查看策略。查看、管理numa;语法格式:numactl [参数]使用哪个node的cpu。
函数式编程
本文介绍Java 8函数式编程核心内容,涵盖Lambda表达式、Stream流、Optional及方法引用。通过对比传统匿名内部类,展示Lambda简化代码的便捷性;以Stream流实现集合链式操作,高效完成过滤、去重、遍历等任务;结合实际案例,说明函数式编程提升开发效率、增强可读性与并发处理能力的优势,助力开发者快速掌握现代Java编程范式。
LKDS8.Linux内核的双向链表代码解析(8) 拼接链表、获取链表首/尾元素的宏、list_for_each系列的安全版本的宏
本文系统解析了Linux内核双向链表的核心操作:list_splice()系列函数实现链表拼接,list_splice_init()与list_splice_tail_init()在拼接后重置源链表;通过宏如list_first_entry_or_null、list_last_entry_or_null安全获取首尾节点;list_for_each_safe等安全遍历宏利用临时指针避免删除时断链,保障遍历安全。结合栈与队列语义,揭示其在内核内存管理中的高效应用。
NCCL-AllReduce-用户缓冲区注册及设备Work构造 (六)
在传统 Collective 路径中,主机根据任务选定的算法、协议和连接能力,为符合条件的用户缓冲区准备注册资源。每个任务各有一份设备 Work,其中保存缓冲区地址、归约参数和注册状态。下图以同一 communicator 中的 Ring 任务 A 和 NVLS 任务 B 为例,说明相关对象由谁持有、注册结果保存在哪里,以及任务和 Work 如何交给后续的 Plan 编排。保留任务及注册记录。保存已完成分类和调优的任务,保存按地址范围组织的注册记录。
C++ initializer_list 详解
本文详解C++11引入的std::initializer_list,涵盖其底层机制、基本用法及常见陷阱。它作为统一初始化的核心,提供轻量级只读视图,支持函数参数、构造函数初始化,但需注意底层数组生命周期与对象绑定,避免返回或保存临时initializer_list。重载决议中initializer_list优先级高,易引发意外行为,应谨慎使用。
Java集合框架核心笔记|List、Set、Map底层原理+选型+面试高频
本文系统梳理Java集合框架核心知识:Collection(List、Set、Queue)与Map双列集合体系,重点解析ArrayList、LinkedList、HashSet、HashMap等常用类的底层原理、特性及选型建议。涵盖泛型、遍历方式、线程安全问题及高频面试题,附集合选型速查表与常见异常避坑指南,适合快速掌握集合核心要点。
VB6端口侦听HTTP协议读卡器提交的GET、POST请求,解析Json获取卡号、设备编号等参数
本文介绍了一款基于VB的TCP服务器程序,用于接收和响应设备连接请求。通过监听指定端口,动态管理多客户端连接,支持心跳、刷卡、扫码等数据解析与应答。程序可自定义返回内容,包括中文显示、语音提示、延时设置等,并具备异常处理与连接状态监控功能,适用于智能门禁、考勤设备等物联网场景。
Vue2项目中数据字典的使用封装
封装components/DictSelect.vue组件。在main.js中注册成全局方法。页面初始化时查询字典数据。
536



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



