- 博客(1255)
- 资源 (35)
- 收藏
- 关注
原创 配置中心Spring cloud config、Apollo、Nacos对比
目前在国内开发者社区比较热,在Github上有超过5k颗星,在国内众多互联网公司有落地案例,可以说Apollo是目前配置中心产品领域Number1的产品,其成熟度和企业级特性要远远强于Spring Cloud体系中的Spring Cloud Config产品。也许经过的迭代更久,功能上比Nacos更加完善,权限管理做的全面,配置上可能会做的更细节一些,不过操作比较繁琐,比较适合多业务 多团队的业务场景。Nacos内置监听心跳检测机制,每5秒、15秒、30秒对服务进行心跳探测,标注为健康、不健康、剔除;
2024-09-29 18:27:19 692
原创 什么是 Elasticsearch?一篇搞懂
显然,Elasticsearch是老外写的,内置的分词器都是英文类的,而我们用户搜索的时候往往搜的是中文,现在中文分词器用得最多的就是。,它主要负责维护索引元数据、负责切换主分片和副本分片身份等工作(后面会讲到分片的概念),如果主节点挂了,会选举出一个新的主节点。从上面所讲的写入流程,我们就可以知道:Get(通过ID去查Doc是实时的),Query(通过query去匹配Doc是近实时的)上面我们已经知道当我们向Elasticsearch写入数据的时候,是写到主分片上的,我们可以了解更多的细节。
2024-09-28 17:24:38 1292
原创 Web3Auth 如何工作?
重要的是,完整的私钥不存储在钱包基础设施系统内的任何地方,包括我们的数据库或任何参与节点。集成到您的应用程序中后,SDK 有助于嵌入登录功能。使用 Web3Auth 基础架构,您的密钥会被分成多个部分,并存储在您的设备和我们的 Auth 网络中。而在传统的 Web3Auth SDK 中,您的密钥是使用阈值签名在前端动态重建的。相反,这些部分密钥存储在不同的位置,并且您的设备用于为您的消息/交易制作部分签名。正如您在上图中看到的,右侧 TSS 架构的最终输出是可用于在区块链上进行交易的签名。
2024-09-26 18:57:44 962
原创 一个必会算法模型,XGBoost !!
XGBoost是一种集成学习算法,基于决策树构建强大的预测模型。它通过迭代训练多个决策树模型,利用梯度提升技术不断优化模型性能。XGBoost在各种数据集上都表现出色,并且被广泛应用于分类和回归问题。
2024-09-26 11:38:30 751
原创 MySQL如何实现并发控制?(下)
可以看到,和前面不同的是,进入到悲观更新的逻辑时,会直接对 index 加 SX 锁(在 5.7 之前的版本中是直接加 X 锁,5.7 版本引入了 SX 锁,SX 锁和 S 锁不互斥,所以此时还可以读),所以在后续 B+tree 遍历的过程中,只是先收集索引经过的节点,并没有直接上锁。session 2 获得 40 上的记录锁(X),但是由于插入的区间是(20,40),且 session 3 已经持有了 (30, 40) 上的 Gap 锁,所以需要产生一个插入意向锁,最终导致死锁;
2024-09-23 18:49:13 738
原创 MySQL如何实现并发控制?(上)
在使用数据库的过程中,一个绕不开的操作就是 DDL,特别是在线上运行的库上直接进行 DDL 操作。通过上面一个简单的例子,我们知道了 MDL 锁的基本概念,也知道了所谓的 DDL 导致“锁表”的原因,严格的说,MDL 锁并不是表锁,而是元数据锁,关于 MDL 更深入的介绍,可以参考这篇文章,本文不再过多展开。狭义上来说,thr_lock接口加的锁就是 Server 层的表锁,具体的加锁逻辑、锁类型的互斥关系、锁等待的逻辑此处不再展开,有兴趣的同学可以自己结合代码进行查看。
2024-09-23 18:04:22 1160
原创 LevelDB RockesDB LSM
LevelDBlevelDB是同样也是一个Key-value数据库,但是相对于Redis、memcache来说,levelDB是基于内存-磁盘来实现的,但在大部分场景下也表现出了不逊色于Redis、Memcache的性能。levelDB由google实现并开源,轻松支持billion量级的数据,并且性能没有太大的衰退,下面来看一下LevelDB的具体实现。LevelDB实现既然是一个key-value 数据库,显而易见支持的api肯定有put/get/delete(delete实质上就是
2024-09-06 01:21:49 797
原创 阿里中间件——diamond
获取的地址列表,会保存在client本地,当出现网络异常,无法从网络获取地址列表时,client会使用本地保存的地址列表。c. diamond服务端是一个集群,集群中的每台机器连接同一个mysql,集群之间的数据同步通过两种方式进行,一是每台server定时去mysql dump数据到本地文件,二是某一台server接收发布数据请求,在更新完mysql和本机的本地文件后,发送一个HTTP请求(通知)到集群中的其他几台server,其他server收到通知,去mysql中将刚刚更新的数据dump到本地文件。
2024-09-06 00:56:24 1182
原创 没有Massa的并行执行区块链系统调研
编者按:我认为在并行区块链领域进行横向比较时,没有massa的加入,整个调研的结果将是有失水准的,不过我们还是可以看看其他区块链都是有哪些特点。无论是在传统的数据库领域还是在区块链技术中,并行执行模型的设计都较为复杂。这是因为,在设计过程中,需要综合考虑多个维度,而每个维度的选择都会对系统的整体性能和可扩展性产生深远影响。本文将深入探讨当前最具代表性的几种区块链执行层并行架构,并详细呈现我们针对这些架构在性能和可扩展性方面所做的实验结果。
2024-09-03 11:42:15 1472
转载 AI LLM预训练数据集及其清洗框架总结
本文从快速构建大型语言模型(LLM)训练数据集的角度出发,全面梳理了中文、英文和多语种数据集及其清洗规则,介绍了常用的数据清洗框架和主要流程,指出现有数据集存在的问题及其初步解决方案。站在开源数据集的肩膀上,通过数据整合和精细治理,我们能快速产出落地方案和结果,从而推动 LLM 的训练和优化任务。数据类别:已覆盖了所有常见的类别,包括网页、书籍、企业年报、法律文书、问答、新闻、百科、考试、专利、评论、博客、歌词、古诗文、中英平行语料等。训练语种:训练集包含中英双语。
2024-08-20 18:04:53 233 1
原创 50道深度NLP和人工智能领域面试题+答案
BERT是一种预训练语言模型,通过训练深度双向Transformer模型,实现了在大规模语料上学习通用的自然语言表示,广泛应用于各种NLP任务,如问答系统、命名实体识别和文本分类。RNN 是一种具有循环连接的神经网络,用于处理序列数据;词嵌入是将单词映射到连续向量空间的技术,它可以捕捉单词之间的语义和语法关系,常用的算法包括Word2Vec、GloVe和FastText。注意力机制是一种用于加强神经网络在处理序列数据时的性能的技术,它允许网络动态地关注输入序列的不同部分,提高模型的表现力。
2024-08-20 01:37:31 1248
原创 Massa Layer 1区块链 POS 安全性分析
Certik challenged Massa Labs to demonstrate the security of our proof-of-stake system against potential attackers attempting to bias the randomized draws. Massa Labs' researchers responded by providing a rigorous mathematical analysis, proving the robustne
2024-08-19 18:28:23 429
原创 2024最新50道NLP和人工智能领域面试题+答案(中文+英文双版本)
编者按:分享一个很硬核的免费学习网站,通俗易懂,风趣幽默, 可以当故事来看,轻松学习。
2024-08-19 18:00:04 1064
原创 java.sql.SQLException: txn too large, size: 104857606.
在tidb中尝试一次性删除了太多数据,超过了单个事务的总大小限制。减少每次删除的条数,从而降低tx的总的大小。
2024-08-19 12:05:29 242
转载 CompletableFuture原理深度解析
CompletableFuture之前FutureTask只是Future接口的一个基本实现,并且是作为一个Task对象存在的,FutureTask本身并不管理执行线程池相关的内容,我们生成一个FutureTask对象的动机是我们希望将我们的task包装成一个FutureTask对象,使得我们可以借助FutureTask的特性来控制我们的任务。
2024-08-14 01:08:52 44
原创 执行一条 SQL 查询语句,期间发生了什么?
索引下推后,虽然 reward 列无法使用到联合索引,但是因为它包含在联合索引(age,reward)里,所以直接在存储引擎过滤出满足 reward = 100000 的记录后,才去执行回表操作获取整个记录。相比于没有使用索引下推,节省了很多回表操作。当你发现执行计划里的 Extr 部分显示了 “Using index condition”,说明使用了索引下推。
2024-08-13 19:35:05 150
原创 机器学习中的训练集、验证集和测试集区别
编者按:分享一个很硬核的免费学习网站,通俗易懂,风趣幽默, 可以当故事来看,轻松学习。在机器学习中,数据集通常被划分为训练集、验证集和测试集,每个部分在模型的构建和评估中扮演着不同的角色。以下是对这三种数据集的详细解释及其作用。
2024-08-12 23:14:25 696
原创 深度学习中的梯度消失问题
梯度消失问题是深度学习中的一个重要挑战,尤其在训练深层神经网络时尤为突出。当网络层数较多时,反向传播过程中,梯度可能会逐层减小,最终导致前面的层几乎无法更新,从而阻碍网络的学习。这种现象会导致模型性能下降,训练过程变得非常缓慢或甚至停滞。:例如,ReLU(修正线性单元)及其变体,能够有效缓解梯度消失问题。:选择合适的权重初始化方法,如 Xavier 初始化或 He 初始化,能够提高训练的稳定性。:在每一层引入批归一化,可以帮助保持激活值的分布稳定,从而加速训练,并减轻梯度消失的问题。
2024-08-12 18:49:54 1107
原创 大模型训练过程中的过拟合是什么意思
如果模型太复杂,它可能会过度关注训练图片中的一些细节,比如特定猫的毛色、背景或光照条件,而不是学习猫和狗的通用特征(如形状、耳朵形状等)。:如果你训练一个模型来识别垃圾邮件,当模型过于复杂时,它可能学习到了特定垃圾邮件中的某些关键词或格式,而不是识别出垃圾邮件的普遍特征(例如 spam 的指示性内容或上下文)。:如果你使用一个复杂的模型来基于有限的历史数据预测房价,该模型可能会把某些特定房产的个别特征(例如特定房屋的花园大小)作为决定性因素,而未能捕捉到房价的总体市场趋势。
2024-08-12 17:35:22 744
原创 AI的未来是Python + Docker还是Rust + WebAssembly
然而,当涉及到为大型语言模型(LLM)应用程序构建基础设施时,这种组合的一些缺点变得更加严重,例如 Python 的性能问题和 Docker 的冷启动问题。本演讲重点关注为 LLM 生态构建基础设施的主要场景,并深入探讨 Python 和 Docker 组合的问题,更重要的是,为什么 Rust + WebAssembly (WASM) 优于 Python + Docker。在不断发展的技术世界中,由大语言模型驱动的应用程序,通常被称为“LLM应用”,已成为各种行业技术创新背后的驱动力。
2024-08-12 01:41:45 603
原创 利用Llama2 7b自己实现一套离线AI
另外,前些天发现了一个巨牛的,通俗易懂,风趣幽默,忍不住分享一下给大家, 可以当故事来看,轻松学习。离了 ChatGPT 本人简直寸步难行,今天 ChatGPT 大面积宕机,服务直到文章写作(下午5点)时尚未恢复,抓耳挠腮了一下午。已经习惯了用 AI 的我们该怎么办呢?答案就是——自己在本地运行一个大模型,只要电脑不关机,服务就一直在!那么怎么在自己电脑上轻松方便地运行大模型呢?一般来说,运行这些模型的 Python / PyTorch 往往包含有 3GB 以上的相互依赖的包。
2024-08-11 22:21:23 813
原创 使用 GPU 加速的 XGBoost 预测出租车费用
需要将由 ML 算法使用的特征进行转换,并将其放入特征向量,这些向量是代表每个特征值的数字向量。如下所示,我们使用 VectorAssembler 转换器返回带有标签和向量特征列的新 DataFrame。// 特征列名称// 创建转换器// transform 方法添加特征列result:使用 XGBoost GPU 版本时,不需使用 VectorAssembler。
2024-08-10 01:14:26 709
原创 Massa如何构建完全链上的去中心化网络?
如今,Web3 黑客攻击给 DeFi 协议造成了数百万美元的损失,并导致许多客户不满意。问题在于 Web3 仍然依赖于 Web2 技术,即控制网站托管、DNS 解析以及万维网运转所需的所有其他设备的集中服务提供商。集中式网络您可能已经猜到了,Massa 的目标是通过他们自己的去中心化网络解决一些 Web3 问题。自从我们在白皮书中第一次提到这个项目以来,它一直是我们的主要目标之一,我们很高兴终于能让我们的社区和新人对这个项目有所了解。
2024-08-08 18:50:33 1186 1
原创 深度学习四大框架之争(Tensorflow、Pytorch、Keras和Paddle)
近几年,随着深度学习指数级发展,深度学习的框架使用在人工智能领域也起着举足轻重的作用,这其中包括Tensoflow、Pytorch、Keras、paddle等等。那么面对这些框架,究竟使用哪个呢?其实,这几个框架都有各自的优点和缺点,大家了解后可以根据自己的情况进行选择;现在Keras API都融入tensorflow2.0进去了,因此学tensorflow就行,而paddle是百度推出的,且资料很资源最多,百度也开源了许多优秀的模型,值得推荐。(个人推荐tf、torch、paddle)
2024-08-08 16:42:21 2312 2
原创 深度认知大模型文件格式GGUF
Hugging Face Hub 支持所有文件格式,但内置了GGUF 格式的功能,这是一种二进制格式,针对快速加载和保存模型进行了优化,使其在推理方面非常高效。GGUF 旨在与 GGML 和其他执行器一起使用。GGUF 由@ggerganov开发,他也是流行的 C/C++ LLM 推理框架llama.cpp的开发者。最初在 PyTorch 等框架中开发的模型可以转换为 GGUF 格式,以便与这些引擎一起使用。正如我们在图中所看到的,与。
2024-08-06 17:19:53 910
原创 SaaS平台Flows.network
由于模型已经具备与 OpenAI 兼容的 API,我们可以像在 OpenAI 上做的那样,轻松地将模型与 Telegram、Slack 和 Discord 等其他 SaaS 集成。如果您不是程序员,但想使用社区为特定任务创建的流程函数,那么您可以简单地使用流程模板。无需编码即可使其运行!但是,使用 flows.network,当您的用例变得复杂时,您可以随时返回自定义流程函数代码。或者,如果您不是程序员,您可以重用模板中的现有流程函数。了解流程功能的工作原理以及如何创建自己的流程功能。
2024-08-06 16:07:13 758
原创 This version of ChromeDriver only supports Chrome version 100
根据报错提示,发现是版本不一致,根据对应关系。,重新下载正确的驱动版本即可。
2024-08-05 14:40:49 933
原创 RTS 与 FreeSWITCH
登录 GitHub 开拓 RTS 社区是必不可少的一项工作,但有时候由于网络限制或其他原因,我们可能无法直接访问 GitHub。在这篇文档中,将为您提供一种不使用代理的方法来访问 GitHub 网站。
2024-07-23 17:51:28 684
原创 以太坊的可扩展性危机:探索执行层的瓶颈
以太坊执行层承担着交易处理、智能合约执行以及保持一致和安全状态的维护等工作。Fuel Labs 撰文解析了以太坊执行层的工作原理,及其在可扩展性方面的发展瓶颈和影响。当全节点更新其账本副本以反映新的代币转移、智能合约代码更新和数据存储更改时,就会发生状态更改。执行层的主要功能包括:交易处理、智能合约执行以及状态管理。这可能是比单纯优化智能合约更大的障碍。:吞吐量直接指的是网络在给定时间内高效处理和管理大量交易的能力。:延迟是从提交交易到交易被确认并包含在区块链中所经过的时间。
2024-07-23 13:13:49 331
原创 RocketMQ 消息的顺序和重复
如果是新的消息,由于MQServer上面还没有创建对应的Topic,这个时候,如果上面的配置打开的话,会返回默认TOPIC的(RocketMQ会在每台broker上面创建名为TBW102的TOPIC)路由信息,然后Producer会选择一台Broker发送消息,选中的broker在存储消息时,发现消息的topic还没有创建,就会自动创建topic。第2条原理就是利用一张日志表来记录已经处理成功的消息的ID,如果新到的消息ID已经在日志表中,那么就不再处理这条消息。消息的中转者,负责存储和转发消息。
2024-07-22 17:07:54 1106
原创 kafka vs rocketmq: 不要只顾着吞吐量而忘了延迟这个指标
在大包和批量的场景下,RocketMQ 和 Kafka 目前已经相差无几,此时的瓶颈已经转移到磁盘的吞吐能力上。自从 RocketMQ 进入 Apache 基金会后,团队大力发展社区生态,包括和 Apache Spark,Apache Flink,Apache Storm,Apache Ignite 等顶级开源产品有了更多的生态连接与整合能力。RocketMQ 在低延迟,消息重试与追踪,海量 Topic,多租户,一致性多副本,数据可靠性等问题上进行了大量优化,对电商,金融领域的用户来说,是一大利好。
2024-07-22 01:25:00 295
原创 虫虫老师---义务教育核心课程改革
0~9 岁,是关键时期素质导向 综合育人 实践育人网状知识结构跨学科运用项目式学习发散思维学习的本质是理解理解是工具纪录片。
2024-07-19 20:47:04 76
原创 Sekiro原理
Sekiro主要提供的功能是: 受限上下文环境下的功能外放,服务提供者(provider)运行在一个受限环境中,导致这个服务不能作为一个普通的算法方便的转移到内部服务,而此时我们的业务又希望可以使用这种受限环境下的功能。SEKIRO是一个多语言的、分布式、网络拓扑无关的服务发布平台,通过书写各自语言的handler将功能发布到中心API市场,业务系统通过RPC的方式使用远端节点的能力。通常情况下,在后端微服务下RPC框架主要用于拆分复杂业务模块,以及多节点集群提升单机性能瓶颈的能力。
2024-07-01 16:21:14 316
原创 STUN原理
P2P网络要求通信双方都能主动发起访问,但是NAT设备的存在,却阻断了这种主动访问,导致P2P应用无法正常运行。STUN是一种解决P2P应用NAT穿越问题的常用技术。它允许网络设备找出通信端点经NAT设备后的IP地址和端口号,并利用这些信息在通信双方之间建立一条可以穿越NAT设备的数据通道,实现P2P通信。
2024-06-21 18:20:20 296
Natural Language Processing with Deep Learning CS224N/Ling284
2024-09-09
RFC9220 - HTTP Datagrams and the Capsule Protocol
2024-08-02
RFC9297 - Bootstrapping WebSockets with HTTP/3
2024-08-02
RFC9114 - HTTP/3
2024-08-02
RFC9000 - QUIC: A UDP-Based Multiplexed and Secure Transport
2024-08-02
RFC8446 -The Transport Layer Security (TLS) Protocol Version 1.3
2024-08-02
Web3+Decentralized+去中心化+存储
2024-04-30
Chainbase+Web3+APi+Data warehouse
2024-04-30
Graph+Web3+检索
2024-04-30
Web3+Nostr+区块链+去中心化+Relay+抗审查
2024-04-30
VISION FOR A HETEROGENEOUS MULTI-CHAIN FRAMEWORK DRAFT
2023-12-24
Security audit report for imtoken wallet
2023-12-24
Decentraland is a blockchain-based virtual world
2023-12-24
力场的定位是一个以公链共建挖矿为核心的社区平台以及UGC平台
2023-12-24
A Novel Metastable Consensus Protocol Family for Cryptocurrencie
2023-12-24
Measuring Ethereum Network Peers
2023-12-24
Firework Games White Paper
2023-12-24
CS251 Final Exam 2021
2023-12-24
Generic Construction of Ring Signatures with Efficient
2023-12-24
The Gridex Protocol
2023-12-24
Efficient Zero-Knowledge Arguments for Arithmetic Circuits
2023-12-24
KishuInu Whitepaper
2023-12-24
On the Instability of Bitcoin Without the Block Reward
2023-12-24
Shorter Proofs for Privacy-Enhanced Distributed Ledger
2023-12-24
Attacking Threshold Wallets
2023-12-23
This paper provides an architectural overview of the Avalanche
2023-12-23
Avalanche Native Token ($AVAX) Dynamics
2023-12-23
ZKSwap是一个基于 ZK-Rollup 的 Layer2 代币Swap协议
2023-12-23
ZEND White Paper
2023-12-23
KZen Curv Security Audit
2023-12-23
为什么虚拟资产值得投资:元宇宙虚拟地产报告
2023-10-27
元宇宙:未来数字绿洲入口已打开
2023-10-27
Code Assessment of Liquidations 2.0 Smart Contracts
2023-10-27
Scalable and Probabilistic Leaderless BFT Consensus through Meta
2023-10-27
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人