[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"similar-titu1994--LSTM-FCN":3,"tool-titu1994--LSTM-FCN":61},[4,18,28,37,45,53],{"id":5,"name":6,"github_repo":7,"description_zh":8,"stars":9,"difficulty_score":10,"last_commit_at":11,"category_tags":12,"status":17},4358,"openclaw","openclaw\u002Fopenclaw","OpenClaw 是一款专为个人打造的本地化 AI 助手，旨在让你在自己的设备上拥有完全可控的智能伙伴。它打破了传统 AI 助手局限于特定网页或应用的束缚，能够直接接入你日常使用的各类通讯渠道，包括微信、WhatsApp、Telegram、Discord、iMessage 等数十种平台。无论你在哪个聊天软件中发送消息，OpenClaw 都能即时响应，甚至支持在 macOS、iOS 和 Android 设备上进行语音交互，并提供实时的画布渲染功能供你操控。\n\n这款工具主要解决了用户对数据隐私、响应速度以及“始终在线”体验的需求。通过将 AI 部署在本地，用户无需依赖云端服务即可享受快速、私密的智能辅助，真正实现了“你的数据，你做主”。其独特的技术亮点在于强大的网关架构，将控制平面与核心助手分离，确保跨平台通信的流畅性与扩展性。\n\nOpenClaw 非常适合希望构建个性化工作流的技术爱好者、开发者，以及注重隐私保护且不愿被单一生态绑定的普通用户。只要具备基础的终端操作能力（支持 macOS、Linux 及 Windows WSL2），即可通过简单的命令行引导完成部署。如果你渴望拥有一个懂你",349277,3,"2026-04-06T06:32:30",[13,14,15,16],"Agent","开发框架","图像","数据工具","ready",{"id":19,"name":20,"github_repo":21,"description_zh":22,"stars":23,"difficulty_score":24,"last_commit_at":25,"category_tags":26,"status":17},9989,"n8n","n8n-io\u002Fn8n","n8n 是一款面向技术团队的公平代码（fair-code）工作流自动化平台，旨在让用户在享受低代码快速构建便利的同时，保留编写自定义代码的灵活性。它主要解决了传统自动化工具要么过于封闭难以扩展、要么完全依赖手写代码效率低下的痛点，帮助用户轻松连接 400 多种应用与服务，实现复杂业务流程的自动化。\n\nn8n 特别适合开发者、工程师以及具备一定技术背景的业务人员使用。其核心亮点在于“按需编码”：既可以通过直观的可视化界面拖拽节点搭建流程，也能随时插入 JavaScript 或 Python 代码、调用 npm 包来处理复杂逻辑。此外，n8n 原生集成了基于 LangChain 的 AI 能力，支持用户利用自有数据和模型构建智能体工作流。在部署方面，n8n 提供极高的自由度，支持完全自托管以保障数据隐私和控制权，也提供云端服务选项。凭借活跃的社区生态和数百个现成模板，n8n 让构建强大且可控的自动化系统变得简单高效。",184740,2,"2026-04-19T23:22:26",[16,14,13,15,27],"插件",{"id":29,"name":30,"github_repo":31,"description_zh":32,"stars":33,"difficulty_score":10,"last_commit_at":34,"category_tags":35,"status":17},10095,"AutoGPT","Significant-Gravitas\u002FAutoGPT","AutoGPT 是一个旨在让每个人都能轻松使用和构建 AI 的强大平台，核心功能是帮助用户创建、部署和管理能够自动执行复杂任务的连续型 AI 智能体。它解决了传统 AI 应用中需要频繁人工干预、难以自动化长流程工作的痛点，让用户只需设定目标，AI 即可自主规划步骤、调用工具并持续运行直至完成任务。\n\n无论是开发者、研究人员，还是希望提升工作效率的普通用户，都能从 AutoGPT 中受益。开发者可利用其低代码界面快速定制专属智能体；研究人员能基于开源架构探索多智能体协作机制；而非技术背景用户也可直接选用预置的智能体模板，立即投入实际工作场景。\n\nAutoGPT 的技术亮点在于其模块化“积木式”工作流设计——用户通过连接功能块即可构建复杂逻辑，每个块负责单一动作，灵活且易于调试。同时，平台支持本地自托管与云端部署两种模式，兼顾数据隐私与使用便捷性。配合完善的文档和一键安装脚本，即使是初次接触的用户也能在几分钟内启动自己的第一个 AI 智能体。AutoGPT 正致力于降低 AI 应用门槛，让人人都能成为 AI 的创造者与受益者。",183572,"2026-04-20T04:47:55",[13,36,27,14,15],"语言模型",{"id":38,"name":39,"github_repo":40,"description_zh":41,"stars":42,"difficulty_score":10,"last_commit_at":43,"category_tags":44,"status":17},3808,"stable-diffusion-webui","AUTOMATIC1111\u002Fstable-diffusion-webui","stable-diffusion-webui 是一个基于 Gradio 构建的网页版操作界面，旨在让用户能够轻松地在本地运行和使用强大的 Stable Diffusion 图像生成模型。它解决了原始模型依赖命令行、操作门槛高且功能分散的痛点，将复杂的 AI 绘图流程整合进一个直观易用的图形化平台。\n\n无论是希望快速上手的普通创作者、需要精细控制画面细节的设计师，还是想要深入探索模型潜力的开发者与研究人员，都能从中获益。其核心亮点在于极高的功能丰富度：不仅支持文生图、图生图、局部重绘（Inpainting）和外绘（Outpainting）等基础模式，还独创了注意力机制调整、提示词矩阵、负向提示词以及“高清修复”等高级功能。此外，它内置了 GFPGAN 和 CodeFormer 等人脸修复工具，支持多种神经网络放大算法，并允许用户通过插件系统无限扩展能力。即使是显存有限的设备，stable-diffusion-webui 也提供了相应的优化选项，让高质量的 AI 艺术创作变得触手可及。",162132,"2026-04-05T11:01:52",[14,15,13],{"id":46,"name":47,"github_repo":48,"description_zh":49,"stars":50,"difficulty_score":24,"last_commit_at":51,"category_tags":52,"status":17},1381,"everything-claude-code","affaan-m\u002Feverything-claude-code","everything-claude-code 是一套专为 AI 编程助手（如 Claude Code、Codex、Cursor 等）打造的高性能优化系统。它不仅仅是一组配置文件，而是一个经过长期实战打磨的完整框架，旨在解决 AI 代理在实际开发中面临的效率低下、记忆丢失、安全隐患及缺乏持续学习能力等核心痛点。\n\n通过引入技能模块化、直觉增强、记忆持久化机制以及内置的安全扫描功能，everything-claude-code 能显著提升 AI 在复杂任务中的表现，帮助开发者构建更稳定、更智能的生产级 AI 代理。其独特的“研究优先”开发理念和针对 Token 消耗的优化策略，使得模型响应更快、成本更低，同时有效防御潜在的攻击向量。\n\n这套工具特别适合软件开发者、AI 研究人员以及希望深度定制 AI 工作流的技术团队使用。无论您是在构建大型代码库，还是需要 AI 协助进行安全审计与自动化测试，everything-claude-code 都能提供强大的底层支持。作为一个曾荣获 Anthropic 黑客大奖的开源项目，它融合了多语言支持与丰富的实战钩子（hooks），让 AI 真正成长为懂上",161147,"2026-04-19T23:31:47",[14,13,36],{"id":54,"name":55,"github_repo":56,"description_zh":57,"stars":58,"difficulty_score":24,"last_commit_at":59,"category_tags":60,"status":17},2271,"ComfyUI","Comfy-Org\u002FComfyUI","ComfyUI 是一款功能强大且高度模块化的视觉 AI 引擎，专为设计和执行复杂的 Stable Diffusion 图像生成流程而打造。它摒弃了传统的代码编写模式，采用直观的节点式流程图界面，让用户通过连接不同的功能模块即可构建个性化的生成管线。\n\n这一设计巧妙解决了高级 AI 绘图工作流配置复杂、灵活性不足的痛点。用户无需具备编程背景，也能自由组合模型、调整参数并实时预览效果，轻松实现从基础文生图到多步骤高清修复等各类复杂任务。ComfyUI 拥有极佳的兼容性，不仅支持 Windows、macOS 和 Linux 全平台，还广泛适配 NVIDIA、AMD、Intel 及苹果 Silicon 等多种硬件架构，并率先支持 SDXL、Flux、SD3 等前沿模型。\n\n无论是希望深入探索算法潜力的研究人员和开发者，还是追求极致创作自由度的设计师与资深 AI 绘画爱好者，ComfyUI 都能提供强大的支持。其独特的模块化架构允许社区不断扩展新功能，使其成为当前最灵活、生态最丰富的开源扩散模型工具之一，帮助用户将创意高效转化为现实。",109154,"2026-04-18T11:18:24",[14,15,13],{"id":62,"github_repo":63,"name":64,"description_en":65,"description_zh":66,"ai_summary_zh":66,"readme_en":67,"readme_zh":68,"quickstart_zh":69,"use_case_zh":70,"hero_image_url":71,"owner_login":72,"owner_name":73,"owner_avatar_url":74,"owner_bio":75,"owner_company":76,"owner_location":77,"owner_email":78,"owner_twitter":79,"owner_website":80,"owner_url":81,"languages":82,"stars":87,"forks":88,"last_commit_at":89,"license":79,"difficulty_score":24,"env_os":90,"env_gpu":91,"env_ram":90,"env_deps":92,"category_tags":97,"github_topics":98,"view_count":24,"oss_zip_url":79,"oss_zip_packed_at":79,"status":17,"created_at":104,"updated_at":105,"faqs":106,"releases":151},9983,"titu1994\u002FLSTM-FCN","LSTM-FCN","Codebase for the paper LSTM Fully Convolutional Networks for Time Series Classification","LSTM-FCN 是一个专为时间序列分类任务设计的开源深度学习模型库。它巧妙地将全卷积网络（FCN）的高效特征提取能力与长短期记忆网络（LSTM）对长期依赖关系的精准捕捉能力相结合，旨在解决单一模型在处理复杂时间序列数据时性能不足的问题。\n\n该工具不仅提供了基础的单变量分类模型，还特别推出了针对多变量数据集优化的 MLSTM-FCN 版本，有效提升了多维数据下的分类准确率。其独特的技术亮点在于引入了“维度洗牌”（Dimension Shuffle）机制，在不破坏循环神经网络特性的前提下，实现了卷积层与循环层的无缝融合。此外，项目还包含了详尽的消融实验代码，帮助使用者深入理解各模块对最终性能的贡献。\n\nLSTM-FCN 非常适合人工智能研究人员、数据科学家以及从事时序数据分析的开发者使用。无论是需要复现经典论文结果，还是希望在 UCR 等标准数据集上快速构建高性能基线模型，它都能提供基于 Keras 和 TensorFlow 后端的成熟实现与预训练权重，帮助用户高效开展实验与研究。","# LSTM FCN for Time Series Classification\nLSTM FCN models, from the paper [LSTM Fully Convolutional Networks for Time Series Classification](https:\u002F\u002Fieeexplore.ieee.org\u002Fdocument\u002F8141873\u002F), augment the fast classification performance of Temporal Convolutional layers with the precise classification of Long Short Term Memory Recurrent Neural Networks.\n\n\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftitu1994_LSTM-FCN_readme_2c804cbeec89.png\" height=100% width=100%>\n\n## Multivariate LSTM-FCN for Time Series Classification\nGeneral LSTM-FCNs are high performance models for univariate datasets. However, on multivariate datasets, we find that their performance is not optimal if applied directly. Therefore, we introduce **Multivariate LSTM-FCN (MLSTM-FCN)** for such datasets.\n\nPaper: [Multivariate LSTM-FCNs for Time Series Classification](https:\u002F\u002Farxiv.org\u002Fabs\u002F1801.04503) \u003Cbr>\nRepository: [MLSTM-FCN](https:\u002F\u002Fgithub.com\u002Ftitu1994\u002FMLSTM-FCN)\n\n## Ablation Study of LSTM-FCN for Time Series Classification\nOver the past year there have been several questions that have been raised by the community about the details of the model such as :\n\n - Why we chose to augment a Fully Convolutional Network with an LSTM?\n - What is dimension shuffle actually doing?\n - After dimension shuffle, does the LSTM simply lose all recurrent behaviour?\n - Why not replace the LSTM by another RNN such as GRU?\n - Whether there is any actual improvement to be obtained from this augmentation?\n\nWe therefore perform a detailed ablation study, composing nearly 3,627 experiments that attempt to analyse and answer these questions and to provide a better understanding of the LSTM-FCN\u002FALSTM-FCN time series classification model and each of its sub-module.\n\nThe paper, titled **Insights into LSTM Fully Convolutional Networks for Time Series Classification** can be read for a thorough discussion and statistical analysis of the benefit of the Dimension Shuffled LSTM to the Fully Convolutional Network.\n\nPaper: [Insights into LSTM Fully Convolutional Networks for Time Series Classification](https:\u002F\u002Farxiv.org\u002Fabs\u002F1902.10756)\nRepository: [LSTM-FCN-Ablation](https:\u002F\u002Fgithub.com\u002Ftitu1994\u002FLSTM-FCN-Ablation)\n\n# Installation \nDownload the repository and apply `pip install -r requirements.txt` to install the required libraries. \n\nKeras with the Tensorflow backend has been used for the development of the models, and there is currently no support for Theano or CNTK backends. The weights have not been tested with those backends.\n\nThe data can be obtained as a zip file from here - http:\u002F\u002Fwww.cs.ucr.edu\u002F~eamonn\u002Ftime_series_data\u002F\n\nExtract that into some folder and it will give 127 different folders. Copy paste the util script `extract_all_datasets.py` to this folder and run it to get a single folder `_data` with all 127 datasets extracted. Cut-paste these files into the `Data` directory.\n\n**Note** : The input to the Input layer of all models will be pre-shuffled to be in the shape (Batchsize, 1, Number of timesteps), and the input will be shuffled again before being applied to the CNNs (to obtain the correct shape (Batchsize, Number of timesteps, 1)). This is in contrast to the paper where the input is of the shape (Batchsize, Number of timesteps, 1) and the shuffle operation is applied before the LSTM to obtain the input shape (Batchsize, 1, Number of timesteps). These operations are equivalent.\n\n# Training and Evaluation\nAll 127 UCR datasets can be evaluated with the provided code and weight files. Refer to the weights directory for clarification.\n\nThere is now exactly 1 script to run all combinations of the LSTM-FCN, and its Attention variant, on the three different Cell combinations (8, 64, 128), on all 127 datasets in a loop.\n\n- To use the LSTM FCN model : `model = generate_lstmfcn()`\n- To use the ALSTM FCN model : `model = generate_alstmfcn()`\n\n## Training\nTraining now occurs in the innermost loop of the `all_datasets_training.py`. \n\nA few parameters must be set in advance :\n\n- Datasets: Datasets must be listed as a pair (dataset name, id). The (name, id) pair for all 127 datasets has been preset. They correspond to the ids inside `constants.py` inside the `utils` directory.\n`\n- Models : Models in the list must be defined as a (`model_name`, `model_function`) pair. Please note : The `model_function` must be a model that returns a Keras Model, not an actual Model itself. The `model_function` can accept 3 parameters - maximum sequence length, number of classes and optionally the number of cells.\n\n- Cells : The configurations of cells required to be trained over. The default is [8, 64, 128], corresponding to the paper.\n\nAfter this, once training begins, each model will trained according to specificiation and log files will be written to which describe all the parameters for convenience along with the training and testing set accuracy at the end of training.\n\nWeight files will automatically be saved in the correct directories and can be used for later analysis.\n\n#### Training Inner-loop\nTo train the a model, uncomment the line below and execute the script. **Note** that '???????' will already be provided, so there is no need to replace it. It refers to the prefix of the saved weight file. Also, if weights are already provided, this operation will overwrite those weights.\n\n`train_model(model, did, dataset_name_, epochs=2000, batch_size=128,normalize_timeseries=normalize_dataset)`\n\n#### Evaluate Inner-loop\nTo evaluate the performance of the model, simply execute the script with the below line uncommented.\n\n`evaluate_model(model, did, dataset_name_, batch_size=128,normalize_timeseries=normalize_dataset)`\n\n## Evaluate \n\nThere is no seperate script for evaluation. In order to re-evaluate trained models, please comment out the `train_model` function in the inner-most loop.\n\n## Visualization\n\nDue to the automatic name generation of folders and weight paths, careful selection of 3 common parameters will be required for all of the visualizations below:\n\n- DATASET_ID: The unique integer id inside `constants.py` referring to the dataset.\n\n- num_cells: The number of LSTM \u002F Attention LSTM Cells.\n\n- model: The model function used to build the corresponding Keras Model.\n\nNext is the selection of the `dataset_name` and `model_name`. The `dataset_name` must match the name of the dataset inside the `all_dataset_traning.py` script. Similarly, the `model_name` must match the name of the model in `MODELS` inside `all_dataset_training.py`. \n\n## Filters Visualization\nTo visualize the output of the Convolution filters of either the LSTMFCN or the Attention LSTMFCN, utilize the `visualize_filters.py` script.\n\nThere are two parameters, `CONV_ID` which refers to the convolution block number (and therefore ranges from [0, 2]) and `FILTER_ID` whose value dictates which filters of the convolution layer is selected. Its range depends on the `CONV_ID` selected, rangeing from [0, 127] for `CONV_ID = {0, 2}` and [0, 255] for `CONV_ID = 1`.\n\n## Context Visualization \nTo visualize the context vector of the Attention LSTM module, please utilize the `visualize_context.py` script. \n\nTo generate the context over all samples in the dataset, modify `LIMIT=None`. Setting `VISUALIZE_CLASSWISE=False` is also recommended to speed up the computation. Note that for the larger datasets, generation of the image may take exorbitant amounts of time, and the output may not be pleasant. We suggest visualizing classwise with 1 sample per class instead, as shown above.\n\n## Class Activation Maps\nTo visualize the class activation map of the final convolution layer, execute the `visualize_cam.py`. The class of the input signal being visualized can be changed by changing the `CLASS_ID` from (0 to NumberOfClasses - 1).\n\n# Results\n\n## Results Based on Test Validation Checkpoint\n\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftitu1994_LSTM-FCN_readme_86b1f56acc4c.png\" height=100% width=100%>\n\n## Results Based on Minimum Training Loss\n\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftitu1994_LSTM-FCN_readme_6f057b23edc4.jpeg\" height=100% width=100%>\n\n## Critical Difference Diagram\n\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftitu1994_LSTM-FCN_readme_6cfcdc3695aa.jpeg\" height=100% width=100%>\n\n## Wilcoxson Signed Rank Test - Statistical Test\nAfter applying a Dunn-Sidak Correction, we compare the p-value table to an alpha level of 0.00465. Results show ALSTM, LSTM, and the Ensemble Methods (COTE and EE) are statistically the same.\n\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftitu1994_LSTM-FCN_readme_72902ab5dffd.jpeg\" height=100% width=100%>\n\n# Citation\n```\n@article{karim2018lstm,\n  title={LSTM fully convolutional networks for time series classification},\n  author={Karim, Fazle and Majumdar, Somshubra and Darabi, Houshang and Chen, Shun},\n  journal={IEEE Access},\n  volume={6},\n  pages={1662--1669},\n  year={2018},\n  publisher={IEEE}\n}\n```\n","# 用于时间序列分类的LSTM FCN\nLSTM FCN模型源自论文《LSTM全卷积网络用于时间序列分类》（https:\u002F\u002Fieeexplore.ieee.org\u002Fdocument\u002F8141873\u002F），它结合了时序卷积层的快速分类性能与长短期记忆循环神经网络的精确分类能力。\n\n\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftitu1994_LSTM-FCN_readme_2c804cbeec89.png\" height=100% width=100%>\n\n## 多变量LSTM-FCN用于时间序列分类\n通用的LSTM-FCN模型在单变量数据集上表现优异。然而，在多变量数据集上，我们发现直接应用该模型的效果并不理想。因此，我们针对此类数据集提出了**多变量LSTM-FCN (MLSTM-FCN)**。\n\n论文：[多变量LSTM-FCN用于时间序列分类](https:\u002F\u002Farxiv.org\u002Fabs\u002F1801.04503) \u003Cbr>\n仓库：[MLSTM-FCN](https:\u002F\u002Fgithub.com\u002Ftitu1994\u002FMLSTM-FCN)\n\n## LSTM-FCN用于时间序列分类的消融研究\n过去一年里，社区围绕该模型的细节提出了许多问题，例如：\n\n- 为什么选择将全卷积网络与LSTM相结合？\n- 维度洗牌到底起到了什么作用？\n- 维度洗牌之后，LSTM是否就完全失去了其循环特性？\n- 为什么不直接用GRU等其他RNN替代LSTM？\n- 这种组合究竟带来了哪些实际的性能提升？\n\n为此，我们进行了一项详尽的消融研究，共设计并执行了近3,627组实验，旨在分析和解答上述问题，从而更深入地理解LSTM-FCN\u002FALSTM-FCN时间序列分类模型及其各个子模块。\n\n题为《关于LSTM全卷积网络用于时间序列分类的见解》的论文详细探讨并从统计学角度分析了维度洗牌后的LSTM对全卷积网络所带来的优势。\n\n论文：[关于LSTM全卷积网络用于时间序列分类的见解](https:\u002F\u002Farxiv.org\u002Fabs\u002F1902.10756)  \n仓库：[LSTM-FCN-Ablation](https:\u002F\u002Fgithub.com\u002Ftitu1994\u002FLSTM-FCN-Ablation)\n\n# 安装 \n下载本仓库，并运行 `pip install -r requirements.txt` 以安装所需的依赖库。\n\n模型开发过程中使用的是Keras配合TensorFlow后端，目前暂不支持Theano或CNTK后端。权重文件尚未在这些后端上进行测试。\n\n数据可从以下链接以压缩包形式获取：http:\u002F\u002Fwww.cs.ucr.edu\u002F~eamonn\u002Ftime_series_data\u002F  \n解压后会得到127个不同的文件夹。将工具脚本 `extract_all_datasets.py` 复制到该文件夹中并运行，即可生成一个名为 `_data` 的文件夹，其中包含所有127个数据集的解压内容。随后将这些文件剪切并粘贴到 `Data` 目录下。\n\n**注意**：所有模型的输入层输入会被预先洗牌成形状为 (Batchsize, 1, Number of timesteps)，并在送入CNN之前再次洗牌（以获得正确的形状 (Batchsize, Number of timesteps, 1)）。这与论文中的做法有所不同：论文中输入的形状为 (Batchsize, Number of timesteps, 1)，且洗牌操作是在LSTM之前进行，以得到 (Batchsize, 1, Number of timesteps) 的输入形状。这两种操作在功能上是等价的。\n\n# 训练与评估\n提供的代码和权重文件可用于评估全部127个UCR数据集。具体说明请参阅权重目录。\n\n现在只需运行一个脚本，即可在三个不同的单元配置（8、64、128）下，对LSTM-FCN及其注意力变体在127个数据集上进行所有可能的组合循环训练。\n\n- 使用LSTM FCN模型：`model = generate_lstmfcn()`\n- 使用ALSTM FCN模型：`model = generate_alstmfcn()`\n\n## 训练\n训练过程位于 `all_datasets_training.py` 的最内层循环中。\n\n需提前设置以下几个参数：\n\n- 数据集：数据集应以 (dataset name, id) 的形式列出。所有127个数据集的 (name, id) 对已预先设定好，对应于 `utils` 目录下的 `constants.py` 文件中的ID。\n- 模型：模型列表应以 (`model_name`, `model_function`) 的形式定义。请注意：`model_function` 必须是一个返回Keras Model的对象，而非实际的模型实例。该函数可以接受3个参数——最大序列长度、类别数以及可选的单元数量。\n\n- 单元：需要训练的单元配置。默认为 [8, 64, 128]，与论文一致。\n\n完成上述设置后，训练开始时，每个模型将按照指定参数进行训练，并生成日志文件，记录所有相关参数以及训练结束时的训练集和测试集准确率。权重文件会自动保存到相应目录，可供后续分析使用。\n\n#### 训练内循环\n要训练某个模型，请取消注释下方代码行并执行脚本。**注意**：`???????'` 已经被预设，无需替换，它代表保存的权重文件前缀。此外，如果已有权重文件存在，此操作将会覆盖原有权重。\n\n`train_model(model, did, dataset_name_, epochs=2000, batch_size=128,normalize_timeseries=normalize_dataset)`\n\n#### 评估内循环\n要评估模型性能，只需取消注释下方代码行并执行脚本即可。\n\n`evaluate_model(model, did, dataset_name_, batch_size=128,normalize_timeseries=normalize_dataset)`\n\n## 评估 \n\n没有单独的评估脚本。若需重新评估已训练好的模型，请在最内层循环中注释掉 `train_model` 函数。\n\n## 可视化\n\n由于文件夹和权重路径的命名是自动生成的，因此在进行以下所有可视化操作时，需要仔细选择3个共同参数：\n\n- DATASET_ID：`constants.py` 中用于标识数据集的唯一整数ID。\n- num_cells：使用的LSTM或注意力LSTM单元数量。\n- model：用于构建相应Keras模型的模型函数。\n\n接下来还需要选择 `dataset_name` 和 `model_name`。`dataset_name` 必须与 `all_dataset_traning.py` 脚本中列出的数据集名称一致。同样，`model_name` 必须与 `all_dataset_training.py` 中 `MODELS` 列表里的模型名称匹配。\n\n## 滤波器可视化\n要可视化LSTMFCN或注意力LSTMFCN的卷积滤波器输出，请使用 `visualize_filters.py` 脚本。\n\n该脚本有两个参数：`CONV_ID` 表示卷积块编号（取值范围为 [0, 2]），而 `FILTER_ID` 则决定了选择哪一组卷积层滤波器。其取值范围取决于所选的 `CONV_ID`：当 `CONV_ID = {0, 2}` 时，取值范围为 [0, 127]；当 `CONV_ID = 1` 时，取值范围为 [0, 255]。\n\n## 上下文可视化\n要可视化 Attention LSTM 模块的上下文向量，请使用 `visualize_context.py` 脚本。\n\n要在数据集的所有样本上生成上下文，需将 `LIMIT=None` 修改为相应值。同时建议将 `VISUALIZE_CLASSWISE=False` 设置为真，以加快计算速度。请注意，对于较大的数据集，生成图像可能需要极长的时间，且输出效果可能并不理想。我们建议改为按类别分别可视化，每类取一个样本，如上所示。\n\n## 类激活图\n要可视化最后一层卷积层的类激活图，请执行 `visualize_cam.py` 脚本。可通过更改 `CLASS_ID` 的值（从 0 到类数减 1）来改变所可视化输入信号的类别。\n\n# 结果\n\n## 基于测试验证检查点的结果\n\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftitu1994_LSTM-FCN_readme_86b1f56acc4c.png\" height=100% width=100%>\n\n## 基于最小训练损失的结果\n\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftitu1994_LSTM-FCN_readme_6f057b23edc4.jpeg\" height=100% width=100%>\n\n## 临界差异图\n\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftitu1994_LSTM-FCN_readme_6cfcdc3695aa.jpeg\" height=100% width=100%>\n\n## Wilcoxon 符号秩检验——统计检验\n在应用 Dunn-Sidak 校正后，我们将 p 值表与显著性水平 α=0.00465 进行比较。结果显示，ALSTM、LSTM 以及集成方法（COTE 和 EE）在统计学上无显著差异。\n\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftitu1994_LSTM-FCN_readme_72902ab5dffd.jpeg\" height=100% width=100%>\n\n# 引用\n```\n@article{karim2018lstm,\n  title={LSTM 全卷积网络用于时间序列分类},\n  author={Karim, Fazle 和 Majumdar, Somshubra 和 Darabi, Houshang 和 Chen, Shun},\n  journal={IEEE Access},\n  volume={6},\n  pages={1662--1669},\n  year={2018},\n  publisher={IEEE}\n}\n```","# LSTM-FCN 快速上手指南\n\nLSTM-FCN 是一种用于时间序列分类的高性能模型，它结合了全卷积网络（FCN）的快速分类能力与长短期记忆网络（LSTM）的精确时序特征提取能力。本指南将帮助您快速搭建环境并运行模型。\n\n## 环境准备\n\n在开始之前，请确保您的开发环境满足以下要求：\n\n*   **操作系统**：Linux, macOS 或 Windows\n*   **Python 版本**：推荐 Python 3.6 - 3.8\n*   **核心框架**：本项目基于 **Keras** 开发，后端必须使用 **TensorFlow**。\n    *   *注意：目前不支持 Theano 或 CNTK 后端。*\n*   **硬件建议**：虽然可在 CPU 上运行，但建议使用 NVIDIA GPU 以加速训练过程。\n\n## 安装步骤\n\n1.  **克隆仓库**\n    首先下载项目源代码：\n    ```bash\n    git clone https:\u002F\u002Fgithub.com\u002Ftitu1994\u002FLSTM-FCN.git\n    cd LSTM-FCN\n    ```\n\n2.  **安装依赖**\n    使用 pip 安装所需的 Python 库。国内用户建议使用清华源或阿里源以加速下载：\n    ```bash\n    # 默认源\n    pip install -r requirements.txt\n    \n    # 推荐：使用清华镜像源加速安装\n    pip install -r requirements.txt -i https:\u002F\u002Fpypi.tuna.tsinghua.edu.cn\u002Fsimple\n    ```\n\n3.  **准备数据集**\n    本项目默认使用 UCR 时间序列归档数据集。\n    *   下载地址：[http:\u002F\u002Fwww.cs.ucr.edu\u002F~eamonn\u002Ftime_series_data\u002F](http:\u002F\u002Fwww.cs.ucr.edu\u002F~eamonn\u002Ftime_series_data\u002F)\n    *   解压下载的 zip 文件，您将得到 127 个文件夹。\n    *   将项目中的工具脚本 `extract_all_datasets.py` 复制到解压后的目录中并运行，它将生成一个包含所有数据的 `_data` 文件夹。\n    *   将生成的数据文件剪切并粘贴到项目根目录下的 `Data` 文件夹中。\n\n## 基本使用\n\n本项目提供了统一的脚本来处理模型的训练与评估。以下是如何调用不同变体模型的最简示例。\n\n### 1. 选择模型\n\n在代码中，您可以通过调用相应的生成函数来实例化模型：\n\n*   **使用标准 LSTM-FCN 模型**：\n    ```python\n    model = generate_lstmfcn()\n    ```\n\n*   **使用带注意力机制的 ALSTM-FCN 模型**：\n    ```python\n    model = generate_alstmfcn()\n    ```\n\n### 2. 训练模型\n\n训练逻辑位于 `all_datasets_training.py` 脚本的内层循环中。您需要配置数据集列表、模型定义以及 LSTM 单元数量（默认为 `[8, 64, 128]`）。\n\n取消注释以下代码行即可开始训练单个模型：\n\n```python\n# 参数说明：\n# model: 上述生成的模型对象\n# did: 数据集 ID (对应 utils\u002Fconstants.py)\n# dataset_name_: 数据集名称\n# epochs: 训练轮数\n# batch_size: 批次大小\n# normalize_timeseries: 是否归一化\n\ntrain_model(model, did, dataset_name_, epochs=2000, batch_size=128, normalize_timeseries=normalize_dataset)\n```\n\n*注：权重文件会自动保存在指定目录。如果目录中已存在权重文件，再次运行将会覆盖。*\n\n### 3. 评估模型\n\n若要评估已训练好的模型性能，无需单独的运行脚本。只需在 `all_datasets_training.py` 中注释掉 `train_model` 函数，并取消注释 `evaluate_model` 函数即可：\n\n```python\nevaluate_model(model, did, dataset_name_, batch_size=128, normalize_timeseries=normalize_dataset)\n```\n\n### 4. 可视化（可选）\n\n项目提供了三个脚本用于分析模型内部机制：\n\n*   **卷积滤波器可视化**：\n    ```bash\n    python visualize_filters.py\n    ```\n    需设置 `CONV_ID` (0-2) 和 `FILTER_ID`。\n\n*   **注意力上下文向量可视化**：\n    ```bash\n    python visualize_context.py\n    ```\n    建议设置 `LIMIT=None` 以生成全量样本的上下文，或按类别采样以加快速度。\n\n*   **类激活图 (CAM) 可视化**：\n    ```bash\n    python visualize_cam.py\n    ```\n    通过修改 `CLASS_ID` 来查看不同类别的激活区域。","某工业预测性维护团队正在利用传感器时序数据，实时监测大型旋转机械的健康状态以预防突发故障。\n\n### 没有 LSTM-FCN 时\n- **特征提取困难**：传统机器学习方法依赖人工设计统计特征，难以捕捉振动信号中复杂的局部模式与长期依赖关系。\n- **多变量处理乏力**：面对温度、压力、转速等多通道传感器数据，普通单变量模型无法有效融合不同维度的关联信息，导致判断片面。\n- **误报率居高不下**：由于模型对噪声敏感且泛化能力弱，频繁将正常波动误判为故障前兆，造成不必要的停机检修成本。\n- **训练效率低下**：尝试堆叠深层网络往往导致梯度消失或过拟合，调参过程耗时耗力却难以收敛到最优解。\n\n### 使用 LSTM-FCN 后\n- **自动捕获时空特征**：LSTM-FCN 结合全卷积层的局部感知与 LSTM 的长短期记忆能力，自动提取出从瞬时冲击到长期趋势的关键特征。\n- **多变量协同分析**：通过引入 Multivariate LSTM-FCN 变体，模型能精准对齐并融合多维传感器数据，显著提升对复杂工况的理解力。\n- **分类精度大幅跃升**：在 UCR 标准数据集验证过的架构有效抑制了噪声干扰，将故障识别的准确率提升至新高度，极大降低了误报率。\n- **部署流程标准化**：基于 Keras\u002FTensorFlow 的成熟代码库支持一键加载预训练权重，团队无需从零调参即可快速在新设备上落地应用。\n\nLSTM-FCN 通过将卷积的高效性与循环网络的时序敏感性完美融合，为工业时序分类任务提供了高精度且易落地的解决方案。","https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Ftitu1994_LSTM-FCN_d7ddf8f2.png","titu1994","Somshubra Majumdar","https:\u002F\u002Foss.gittoolsai.com\u002Favatars\u002Ftitu1994_8b4ca043.jpg","Interested in Machine Learning, Deep Learning and Data Science in general","NVIDIA","San Jose, CA","titu1994@gmail.com",null,"http:\u002F\u002Ftitu1994.github.io\u002F","https:\u002F\u002Fgithub.com\u002Ftitu1994",[83],{"name":84,"color":85,"percentage":86},"Python","#3572A5",100,804,265,"2026-03-04T06:39:05","未说明","未明确必需，但依赖 TensorFlow 后端（通常建议使用 GPU 加速深度学习训练），具体型号、显存及 CUDA 版本未在文中提及",{"notes":93,"python":90,"dependencies":94},"该工具仅支持使用 TensorFlow 后端的 Keras，不支持 Theano 或 CNTK 后端。用户需自行从 UCR 时间序列数据档案库下载数据集，并运行提供的脚本进行解压和整理。代码中包含针对 127 个数据集的批量训练和评估脚本，输入数据在模型内部会自动进行维度置换（Dimension Shuffle）处理。",[95,96],"Keras (with TensorFlow backend)","TensorFlow",[14],[99,100,101,102,103],"deep-learning","lstm","keras","cnn","timeseries","2026-03-27T02:49:30.150509","2026-04-20T12:54:01.120522",[107,112,116,121,125,130,134,139,143,147],{"id":108,"question_zh":109,"answer_zh":110,"source_url":111},44845,"为什么在 LSTM 之前要进行维度洗牌（Dimension Shuffle）？这会不会导致模型忽略时间序列的时间信息？","维度洗牌是将输入形状从 (batch, timesteps, features) 转换为 (batch, features, timesteps)，使得每个特征作为一个独立的时间序列输入到 LSTM 中。虽然这看起来像全连接网络，但实验表明带维度洗牌的 LSTM 表现优于 GRU、普通 RNN 甚至不带洗牌的 LSTM。这是因为 LSTM 的复杂门控机制能更好地捕捉特征内的时序依赖。详细消融实验见论文：https:\u002F\u002Farxiv.org\u002Fabs\u002F1902.10756。","https:\u002F\u002Fgithub.com\u002Ftitu1994\u002FLSTM-FCN\u002Fissues\u002F12",{"id":113,"question_zh":114,"answer_zh":115,"source_url":111},44846,"是否尝试过用双向 LSTM（BiLSTM）或多层 LSTM 替代当前结构？","项目团队进行过广泛的消融实验，包括替换为 GRU、基础 RNN 和带 Sigmoid 激活的全连接层。结果显示，带维度洗牌的单层 LSTM 在大多数情况下表现最佳。虽然未明确测试 BiLSTM，但实验表明简单的全连接层（带 Sigmoid）性能接近 LSTM，说明 LSTM 的门控机制是关键。建议优先使用当前架构，除非有特定长程依赖需求。",{"id":117,"question_zh":118,"answer_zh":119,"source_url":120},44847,"运行代码时出现 'OSError: Unable to open file' 错误，提示找不到权重文件（如 bird_chicken_weights.h5），如何解决？","该错误通常由数据文件命名或配置引起。解决方法：1) 将数据文件名中的 '.csv' 后缀去掉，例如改为 'a_TRAIN' 和 'a_TEST'；2) 检查 constants.py 中的 MAX_SEQUENCE_LENGTH，应设为实际特征列数（总列数减 1，因为第一列是标签），例如若原始数据有 2048 列，则设为 2047；3) 拉取最新代码，作者已修复相关 bug。","https:\u002F\u002Fgithub.com\u002Ftitu1994\u002FLSTM-FCN\u002Fissues\u002F2",{"id":122,"question_zh":123,"answer_zh":124,"source_url":120},44848,"训练时出现 'ValueError: expected input_1 to have 3 dimensions, but got array with shape (5000, 2048)' 错误，原因是什么？","此错误是因为输入数据形状不符合模型要求。LSTM-FCN 需要三维输入 (samples, timesteps, features)。如果你的数据是二维的 (samples, timesteps)，需将其 reshape 为 (samples, timesteps, 1)。此外，确保数据预处理时正确分离了标签列（第一列），并设置了正确的 MAX_SEQUENCE_LENGTH（应为特征列数，不含标签）。",{"id":126,"question_zh":127,"answer_zh":128,"source_url":129},44849,"代码中使用测试集作为验证集来监控回调函数（如 ModelCheckpoint 和 ReduceLROnPlateau），是否存在数据泄露问题？","是的，原代码存在数据泄露风险。回调函数中 monitor 参数设置为 'val_acc'，但实际使用的是测试集。为避免泄露，应将 monitor 改为 'acc' 或 'loss'（基于训练集），或在训练时划分独立的验证集。修改 utils\u002Fkeras_utils.py 中的回调配置，确保不使用测试集进行模型选择或学习率调整。","https:\u002F\u002Fgithub.com\u002Ftitu1994\u002FLSTM-FCN\u002Fissues\u002F7",{"id":131,"question_zh":132,"answer_zh":133,"source_url":129},44850,"维度洗牌后，模型是否还能处理可变长度的时间序列输入？","不能。维度洗牌后，时间步长 T 变成了输入维度，而 Keras\u002FTensorFlow 在构建模型时需固定输入形状以初始化权重矩阵。因此，动态时间步长不再支持。如需处理可变长度序列，必须对数据进行填充（padding）或截断（clipping）至统一长度。",{"id":135,"question_zh":136,"answer_zh":137,"source_url":138},44851,"面对严重过拟合问题（训练准确率很高但验证准确率很低），有什么建议？","过拟合可能由数据噪声、模型复杂度过高或缺乏正则化引起。建议：1) 减少 LSTM 单元数量，尤其是使用 Attention LSTM 时（其参数量约为普通 LSTM 的两倍）；2) 增加 EarlyStopping 的 patience 值或使用更严格的停止条件；3) 尝试添加 Dropout 层；4) 对于长序列或高噪声数据，自注意力机制可能有帮助，但需权衡参数量。","https:\u002F\u002Fgithub.com\u002Ftitu1994\u002FLSTM-FCN\u002Fissues\u002F6",{"id":140,"question_zh":141,"answer_zh":142,"source_url":111},44852,"滑动窗口（Sliding Window）是否能提升时间序列分类性能？","滑动窗口有助于捕捉局部时序模式，但在 LSTM-FCN 架构中尚未正式测试。由于该模型已通过维度洗牌将每个特征视为独立序列，滑动窗口的效果可能有限。如果任务特别依赖短时局部模式，可尝试结合滑动窗口预处理，但需注意会增加计算成本且可能破坏原有特征结构。",{"id":144,"question_zh":145,"answer_zh":146,"source_url":111},44853,"带维度洗牌的 LSTM 与直接将整个时间序列输入带 Tanh 激活的全连接层有何区别？","主要区别在于建模能力：1) 维度洗牌 +LSTM 利用 LSTM 的门控机制（输入门、遗忘门、输出门）动态控制信息流，适合捕捉复杂时序依赖；2) 全连接层虽能对每个时间点做非线性变换，但缺乏记忆机制，无法有效建模长程依赖。实验显示，即使使用 Sigmoid 激活的全连接层，性能也略低于 LSTM，说明门控机制至关重要。",{"id":148,"question_zh":149,"answer_zh":150,"source_url":138},44854,"如何选择使用普通 LSTM 还是 Attention LSTM？","目前尚无正式准则，但一般建议：若数据存在长程依赖、关键信息仅分布在部分时间步，或信号噪声较大，可尝试 Attention LSTM。注意 Attention LSTM 参数量约为普通 LSTM 的两倍，易导致过拟合，使用时应减少单元数或加强正则化。推荐同时试验两种结构，根据验证集表现选择。",[152],{"id":153,"version":154,"summary_zh":155,"released_at":156},356950,"v1.0","数据集重构之前的代码库快照。","2019-02-28T16:34:20"]