Journal of Computer Applications

    Next Articles

3D models generating method of industrial manufacturing based on Gaussian fault-tolerant loss

  

  • Received:2025-11-07 Revised:2026-01-09 Accepted:2026-03-13 Online:2026-03-09 Published:2026-03-09
  • Supported by:
    Sichuan Provincial Natural Science Foundation

基于高斯容错损失的工业制造三维模型生成方法

干艳桃1,2#,郭一墨1#,李阳2,万明远2,史建成2,张飞絮1,吕建成1*,刘祥根1*   

  1. 1. 四川大学 计算机学院,成都 610065;2. 西南电子设备研究所,成都 610036
  • 通讯作者: 吕建成,刘祥根
  • 基金资助:
    四川省自然科学基金

Abstract: In intelligent Computer-Aided Design (CAD), a key challenge is to enable three-dimensional model automatic generation systems to not only follow precise geometric constraints but also tolerate reasonable manufacturing errors. The traditional cross-entropy loss function, commonly used in generative models, tends to over-penalize minor parameter deviations. Additionally, it fails to adequately incorporate attribute constraints — such as area or volume — during the modeling process, often resulting in generated outputs that deviate from engineering realities.To address these issues, a CAD command generation method based on a Gaussian tolerant cross-entropy loss function — named GTCG-Transformer (Gaussian Tolerant CAD Generation Transformer) — was proposed. The core innovations of this method include: 1) A Gaussian fault-tolerant cross-entropy loss function was designed. By introducing Gaussian weights to smooth the target value neighborhood, the model is enabled to distinguish "serious errors" from "acceptable deviations," significantly improving fault tolerance for continuous parameter prediction. 2) A Transformer generation architecture with embedded geometric constraints was constructed. Geometric attributes such as area and volume were encoded as conditional inputs to drive the decoder to generate CAD command sequences complying with preset constraints, achieving constraint-aware end-to-end automated design. Experimental results on the filtered DeepCAD dataset indicate that GTCG-Transformer comprehensively outperforms mainstream baseline models in predicting geometric attributes like area and volume. Specifically, under dual constraints of area and volume, compared with the state-of-the-art CAD-LM (Computer-Aided Design-Language Model) method, the proposed method achieves the best performance in Mean Square Error (MSE), Mean Absolute Error (MAE), and Pearson Correlation Coefficient (PCC), with the area MSE reduced to 1.262 and the volume MSE reduced to 0.018.This research provides a novel method with controllable constraints and robust fault tolerance for CAD automatic generation, demonstrating clear application potential in fields requiring high-precision geometric compliance, such as intelligent manufacturing and parametric design.

Key words: Three-dimensional CAD modeling, Transformer, Command generation, Geometric constraints, Automated design, Gaussian fault-tolerant cross-entropy

摘要: 在智能化计算机辅助设计 (CAD)中,如何使三维模型自动生成系统既遵循精确的几何约束,又对制造中的合理误差具备容错能力,是当前面临的关键挑战。传统生成方法常用的交叉熵损失函数对参数微小偏差惩罚过度,且难以在建模过程中有效融入如面积、体积等属性约束,导致生成结果往往不符合工程实际。针对上述问题,本文提出一种基于高斯容错交叉熵损失函数的CAD命令生成方法——GTCG-Transformer (Gaussian Tolerant CAD Generation Transformer)。该方法核心工作在于:1)设计高斯容错交叉熵损失函数,通过引入高斯权重对目标值邻域进行平滑,使模型能够区分“严重错误”与“可接受偏差”,显著提升对连续参数预测的容错性;2)构建几何约束嵌入的Transformer生成架构,将面积、体积等几何属性作为条件输入编码器,驱动解码器生成符合预设约束的CAD命令序列,实现约束感知的端到端自动化设计。在经过筛选的DeepCAD数据集上的实验结果表明,GTCG-Transformer在面积、体积等几何属性的预测上全面优于主流基线模型。特别在面积与体积双重约束的场景中,与当前较为先进的CAD-LM (Computer-Aided Design-Language Model)方法相比,本方法在均方误差(MSE)、平均绝对误差(MAE)与皮尔逊相关系数(PCC)上均取得最佳性能,其中面积MSE降低至1.262,体积MSE降低至0.018。本文为CAD自动生成提供了一种约束可控、容错鲁棒的新方法,在需要高精度几何遵从的智能制造与参数化设计领域具有明确的应用价值。

关键词: 三维CAD建模, Transformer, 命令生成, 几何约束, 自动化设计, 高斯容错交叉熵

CLC Number: