Neural Slicer for Multi-Axis 3D Printing
Tao Liu Tianyu Zhang Yongxue Chen Yuming Huang Charlie C. L. Wang




0000-0003-1016-4191
[1]

  The University of Manchester
  Manchester
  United Kingdom


0000-0003-0372-0049
Joint first authors.

  The University of Manchester
  Manchester
  United Kingdom


0000-0001-6236-4158

  The University of Manchester
  Manchester
  United Kingdom


0000-0001-5900-2164

  The University of Manchester
  Manchester
  United Kingdom


0000-0003-4406-8480
Corresponding author: changling.wang@manchester.ac.uk (Charlie C. L. Wang).  

  The University of Manchester
  Manchester
  United Kingdom


Authors' addresses: 
Tao Liu, The University of Manchester, Manchester, United Kingdom, tao.liu@manchester.ac.uk; Tianyu Zhang, The University of Manchester, Manchester, United Kingdom, tianyu.zhang-10@postgrad.manchester.ac.uk; Yongxue Chen, The University of Manchester, Manchester, United Kingdom, yongxue.chen@postgrad.manchester.ac.uk; Yuming Huang, The University of Manchester, Manchester, United Kingdom, yuming.huang@postgrad.manchester.ac.uk; Charlie C. L. Wang, The University of Manchester, Manchester, United Kingdom, changling.wang@manchester.ac.uk.





We introduce a novel neural network-based computational pipeline as a representation-agnostic slicer for multi-axis 3D printing. This advanced slicer can work on models with diverse representations and intricate topology. The approach involves employing neural networks to establish a deformation mapping, defining a scalar field in the space surrounding an input model. Isosurfaces are subsequently extracted from this field to generate curved layers for 3D printing. Creating a differentiable pipeline enables us to optimize the mapping through loss functions directly defined on the field gradients as the local printing directions. New loss functions have been introduced to meet the manufacturing objectives of support-free and strength reinforcement. Our new computation pipeline relies less on the initial values of the field and can generate slicing results with significantly improved performance.



<ccs2012>
   <concept>
       <concept_id>10010147.10010371.10010396</concept_id>
       <concept_desc>Computing methodologies Shape modeling</concept_desc>
       <concept_significance>500</concept_significance>
       </concept>
   <concept>
       <concept_id>10010147.10010257.10010293</concept_id>
       <concept_desc>Computing methodologies Machine learning approaches</concept_desc>
       <concept_significance>500</concept_significance>
       </concept>
 </ccs2012>


[500]Computing methodologies Shape modeling
[500]Computing methodologies Machine learning approaches







    
    < g r a p h i c s >

    (-505,155)(a)
    (-330,155)(b)
    (-350,8)(c)
    (-168,8)(d)


Our Neural Slicer for multi-axis 3D printing can compute curved layers for a Bunny Head model (a), incorporating diverse representations within the same model. These representations encompass a tetrahedral mesh (depicted in blue) as solid, an open surface (depicted in green) as the kernel of a shell, the skeletons (depicted in thin black lines) of struts as cylindrical solids, and also the skeletons (depicted in bold black lines) of tubular solids. (b) The curved layers are generated through the optimization of a neural network-based mapping according to the objectives of support-free (SF) and strength reinforcement (SR), which are formulated as the loss functions in terms of local printing directions (LPDs). (c) The red bands in the histograms depict the required angle ranges between LPDs and other reference vectors. (d) Curved layers satisfying these requirements can be effectively generated to supervise the physical fabrication taken on a robotic system with eight degree-of-freedoms (DOFs). The mapping is numerically computed with the assistance of a caging mesh that is independent of the discrete representations of the input model. In this example, the genus numbers of the input model and the caging mesh are g=22 and g=0 respectively.



Neural Slicer for Multi-Axis 3D Printing
    Charlie C. L. Wang
    April 29, 2024
========================================






§ INTRODUCTION

The additional degree-of-freedoms (DOFs) provided by multi-axis 3D printing offer many advantages over planar layer based printing, including the relieved need for support structures <cit.>, the improved surface smoothness <cit.>, and the enhanced mechanical strength <cit.>. For an input model ℳ, these methods always define a scalar field G(𝐱) inside the input model ℳ and extract the isosurfaces of G(𝐱) as curved layers for multi-axis 3D printing. Different strategies have been applied to compute an optimized field G(𝐱). 



The most recent work of S^3-slicer <cit.> can achieve multiple objectives on the same model by deforming the tetrahedral mesh of ℳ via nonlinear optimization driven by rotations. Height values on the deformed mesh are mapped back to the input model as G(𝐱) and therefore obtain the curved layers. Although it can generate curved layers satisfying multiple manufacturing objectives, S^3-Slicer also has the following problems:


  * The computation requires a tetrahedral mesh with high quality – i.e., the mesh can become dense and challenging to obtain when applied to models with complex geometry and topology;


  * Objective functions of optimization are indirectly defined as rotations of elements rather than directly on the curved layers – as a result, there is a risk of violating manufacturing requirements due to the distortion between the deformed space and the model space (see Fig.<ref> for an example);


  * The success of nonlinear optimization is significantly dependent on the initial pose of an input model, which may give sub-optimal results if the initial orientation is not well-selected (see Fig.<ref> for an example).

We propose a computational pipeline based on neural networks (NN) to address the challenges associated with curved slicers in multi-axis 3D printing. For instance, as shown in Fig.<ref>, our slicer generates curved layers for a Bunny Head model with diverse representations and complex topology. The curved layers are optimized in accordance with manufacturing objectives of support-free (SF) and strength reinforcement (SR), formulated as the requirements for local printing directions (LPDs). The resultant curved layers for the Bunny Head model have been verified through physical fabrication conducted on a robotic system with 8-DOFs.



 §.§ Our Method

For all discrete representations, an input model ℳ can always be evaluated as an implicit function H(𝐱), where the value defines whether a query point 𝐱 is inside (i.e., H(𝐱)<0) or outside the solid of ℳ (i.e., H(𝐱)>0). The smaller the absolute value |H(𝐱)| returned, the closer the query point 𝐱 is to the boundary surface of ℳ, approximated as the zero level-set of H(𝐱). The function H(𝐱) only needs to exhibit this monotonic property near the model's boundary, rather than strictly adhering to being a distance field. We compute a continuous mapping λ: 𝐱↦𝐲, ∀𝐱, 𝐲∈ℝ^3 that defines the scalar field G(𝐱) for layer generation by the z-component of 𝐲. The optimization of this mapping occurs within the model ℳ (i.e., ∀𝐱∈ℝ^3, H(𝐱) ≤ 0), and it is tailored to meet various manufacturing demands specific to multi-axis 3D printing.

We parameterize the mapping with two continuous functions, 𝐪(𝐱) and 𝐬(𝐱), represented as λ(𝐪(𝐱),𝐬(𝐱)), where 𝐪(𝐱) and 𝐬(𝐱) specify the local deformation's quaternion and scaling ratios for all 𝐱∈ℝ^3. The functions 𝐪(𝐱) and 𝐬(𝐱) are modeled by neural networks with coefficients θ, which are the weights associated with activation functions. The mapping λ(·) is computed numerically as a deformation applied to a volumetric mesh 𝒞 caging the input model ℳ with our effort to make the deformation differentiable. Then, the scalar field is defined as 


    G(𝐱) := 𝗉𝗋𝗈𝗃_z𝐲 = 𝗉𝗋𝗈𝗃_zλ_θ (𝐱).

Different fields are defined by different network coefficients θ. 

With this new formulation, we develop a neural network-based computational pipeline to generate the optimized curved layers (i.e., the scalar field G(𝐱)), utilizing θ as variables. This new pipeline effectively addresses all the previously mentioned challenges:


  * The highly nonlinear nature of NN can help model more complicated deformation than those defined as piecewise functions in tetrahedral elements (i.e., the optimization is less blocked by the topology of meshes employed);


  * By establishing a differentiable neural pipeline for evaluating G(𝐱), we can directly define loss functions based on G(𝐱) and its gradients ∇ G(𝐱) (e.g., the LPD requirements for SF and SR) at any point in the computation domain;


  * With our novel neural pipeline, LPDs can be easily adjusted during the optimization of the scalar field G(𝐱), facilitated by the robustness of modern stochastic NN solvers to different initial guesses. 

We employ NN to represent continuous functions for 𝐪(𝐱) and 𝐬(𝐱) so that the mapping λ(𝐪(𝐱),𝐬(𝐱)) can be effectively and efficiently optimized by borrowing the computational power of the modern machine learning pipeline.

The volumetric mesh employed for caging an input model ℳ is independent of ℳ's discrete representation. It is an intermediate representation used in numerical computation to evaluate the mapping λ. This volumetric mesh is also employed for extracting the isosurfaces of G(𝐱). The resultant curved layers are obtained by trimming these isosurfaces using the implicit solid defined by H(𝐱).



 §.§ Contributions

We present a neural network-based computational pipeline as a representation-agnostic slicer for multi-axis 3D printing, which makes the following technical contributions:


  * Formulation of the curved slicing problem as an optimization task for two continuous functions, 𝐪(𝐱) and 𝐬(𝐱), defining a mapping λ(𝐪(𝐱),𝐬(𝐱)), and consequently, the scalar field G(𝐱) for slicing.


  * Development of a differentiable pipeline of neural networks for optimization, with loss functions directly based on ∇ G(𝐱) (representing real LPDs), which reduces dependency on initial guesses.


  * Derivation of loss functions within the neural pipeline to address manufacturing objectives for multi-axis 3D printing, including support-free and strength reinforcement. 

To the best of our knowledge, this is the first curved slicer that can handle models with diverse representations and complex topology. The manufacturing demands on LPDs are directly optimized, leading to improved slicing solutions, as validated through physical fabrication experiments. 


§ RELATED WORK



 §.§ Multi-axis 3D Printing

Conventional planar layer based 3D printing has relatively simpler software implementation, which however introduces many limitations such the weak mechanical strength <cit.> and the poor surface quality <cit.>. Supporting structures are needed for large overhangs, leading to challenges such as hard to remove, surface damage and material waste <cit.>. With the help of additional DOFs in motion, multi-axis 3D printing offers opportunities to improve these aspects substantially. Recent developments enable the function of support-free material accumulation <cit.>, enhance the mechanical strength of 3D printed parts <cit.>, and reduce the staircase effect <cit.>. Many of these approaches were implemented on robotic hardware (e.g., <cit.>) or those modified from a multi-axis CNC machine (e.g., <cit.>), which have caught a lot of attention in the community of computational fabrication (e.g., <cit.>).

Scalar fields have been widely employed to define curved layers inside a solid by the isosurfaces. For instance, Dai et al. dai2018support-free sought the help of voxel representation to progressively compute a material accumulation field while keeping a convex-front as a conservative method to prevent potential collisions. To improve the surface quality of 3D printed models, Etienne et al. etienne2019curvislicer developed a height-field like deformation to generate slightly curved layers for 3-axis machines. Fang et al. fang2020reinforced presented a pipeline exploiting the anisotropy of mechanical properties in fused filament fabrication with the help of vector fields. They first optimized a vector field to align with the minimal stresses, and later computed a scalar field with its gradients approximating the vector field. The gradients of scalar fields are not directly optimized. Similar indirect problem exists in the recent work of S^3-Slicer <cit.>. Moreover, many of these methods require a volumetric mesh with high quality, which is challenging for models with complex geometry. 



 §.§ Field-based Optimization

The challenge of achieving different objectives in multi-axis 3D printing can be formulated as a problem of optimizing LPDs at different points, essentially forming vector fields. A possible approach to model LPDs is to extend the techniques for processing vector fields defined on mesh surfaces (e.g., <cit.>) to volumetric meshes. Another option is frame-based field optimization <cit.>, which has been used to tackle other problems of computational fabrication (e.g., <cit.>). However, these methods can be very time-consuming, as evidenced by the work presented in <cit.> for volumetric Michell trusses.

Recently, neural network-based implicit neural representation (INR) has become very popular because of its capability to effectively solve problems in reconstruction and optimization <cit.>. INRs are usually formulated as neural networks in a differentiable pipeline of computation and determined by self-learning based optimization using a NN solver (e.g., Adams <cit.>). Example works include DeepSDF <cit.> that approximates continuous signed distance functions for surface reconstruction and SIRENs <cit.> that introduces periodic activation functions for modeling complex natural signals and solving partial differential equations. 

With the help of INR, recent effort has been made to overcome the limitations caused by the discrete nature of meshes in deformation. Methods such as <cit.> utilized the implicit vector fields to represent the deformation, which can be applied to models in different representations. The optimized deformation of a template model can be computed by optimizing INR according to different objectives and constraints. This strategy has been adopted to solve problems of non-rigid registration <cit.>, surface reconstruction  <cit.> and parameterization <cit.>. However, the translation based nature of implicit vector fields does not provide rotational-invariant deformation. In this paper, we employ NNs as continuous functions for quaternions and scaling ratios to determine optimized curved layers for multi-axis 3D printing. 



 §.§ Mesh-based Deformation and Parameterization

Deforming a given model is usually formulated as an optimization problem (e.g., <cit.>). Earlier approaches mainly defined the geometric structures according to the local connectivity, where a surface mesh or a volumetric mesh with high quality is needed. To overcome this challenge, cage-based deformation (e.g., <cit.>) has been employed to handle wild geometry such as scattered points or polygon soups. 

We proposed to construct a `cage'-like tetrahedral mesh, which encloses the input model but has completely different connectivity, as the intermediate discretization for computing the mapping. The scale-controlled deformation proposed in <cit.> is employed in our work to compute the mapping. Specifically, the as-rigid-as-possible (ARAP) energy <cit.> is defined as the function to be minimized while allowing to scale with specified ratios along three orthogonal directions. The ARAP energy can be efficiently minimized by a local/global scheme <cit.>.
Although the effort of differentiation has been made in <cit.>, ARAP deformation has not been employed in the NN-based computational pipeline – especially with respect to the fields of quaternions and scaling ratios.



Our work to compute an optimized mapping shares certain similarities with the volumetric parameterization problems <cit.>. Specifically, the task of computing a mapping for the SF and SR demands can be viewed as a specialized volumetric parameterization, incorporating orientation constraints. Different from the large literature of parameterization that mainly focus on resolving foldovers to ensure local injectivity (ref. <cit.> ), local injectivity is not particularly required in our problem. 



§ NEURAL OPTIMIZATION FOR SLICING

We introduce the computational pipeline of our Neural Slicer in this section. First of all, a neural network-based formulation is introduced for the mapping λ(·) to be optimized. After that, the steps of our slicing algorithm are presented. An overview illustration is given in Fig.<ref>. 



 §.§ Differentiable Mapping as Neural Network

The basic idea of our approach is to construct a differentiable mapping  λ(·) ∈ℝ^3 by neural networks. The scalar field for layer generation can be defined by the z-component of λ(·) as G(𝐱), where the function λ(·) is parameterized with the network coefficients θ. Therefore, the scalar field G(𝐱) for curved layer generation can be optimized by self-learning according to the manufacturing requirements directly defined on G(𝐱) and ∇ G(𝐱) as loss functions.

Simply defining the mapping λ(·) by a neural network without any geometric meaning leads to a learning process that converges very slowly. We propose to formulate λ(·) as λ(𝐪(𝐱),𝐬(𝐱)) by two continuous functions 𝐪(𝐱) ∈ℝ^4 and 𝐬(𝐱) ∈ℝ^3 that define the local rotation (as quaternion) and the local scaling ratios at any point 𝐱∈ℝ^3. 𝐪(𝐱) and s(𝐱) ∈ℝ^3 are represented by two neural networks with coefficients θ_q and θ_s respectively. λ(·) are then computed from 𝐪(𝐱) and 𝐬(𝐱) in a discrete manner. The space Ω around the input model ℳ is discretized into a volumetric mesh 𝒞 with tetrahedral elements, where 𝒞 encloses the solid of ℳ as a cage. The scale-controlled ARAP deformation <cit.> is employed[Note that the deformation is computed in a space Ω instead of the input model to determine the mapping.] to compute a deformed caging mesh 𝒞^d so that the quaternions and the scaling ratios can be approximated at every element of 𝒞. Here we use the centers of elements as the sample points. With the help of barycentric coordinates, every point 𝐱∈Ω is mapped to a new position 𝐲∈Ω^d in the new space Ω^d defined around 𝒞^d. A discrete form of the mapping  λ(·) is obtained, the z-component of which is the scalar field  G(𝐱). By deriving the formulas to compute ∂ G / ∂θ_q and ∂ G / ∂θ_s w.r.t. the positions of vertices on 𝒞^d (details can be found in Sec. <ref>), a mapping λ(·) can be optimized via the differentiable pipeline of neural networks. 



 §.§ Slicing Algorithm

The algorithm consists of three major stages: pre-processing (Steps 1-5), mapping optimization (Steps 6-10), and post-processing (Step 11). The steps are presented as follows (see the illustration in Fig.<ref>):


  * Construct the solid ℋ as an implicit function H(𝐱) for the input model ℳ;


  * Apply voxel-based FEA to compute stress field inside the solid H(𝐱) ≤ 0;


  * Generate a tetrahedral mesh 𝒞 as the intermediate discretization of the space Ω enclosing ℋ (Sec. <ref>);


  * Build a set of sample points as ℬ on the surface boundary of ℳ, which is employed to evaluate the loss functions for SF requirements;


  * Build a set of sample points as 𝒯 at the center of voxels for evaluating the strength reinforcement loss in the relevant region – i.e., the region of the top 10% maximal stresses; 


  * Initialize the neural networks for 𝐪(𝐱) and 𝐬(𝐱);


  * Compute a deformed mesh of 𝒞 as 𝒞^d by the scale-controlled ARAP deformation;


  * Evaluate the differentiation of the deformation to prepare for backpropagation (Sec. <ref>);


  * Update the networks of 𝐪(𝐱) and 𝐬(𝐱) by the NN solver according to the loss functions (Sec. <ref>);


  * Go back to step (7) until the learning converges;


  * Extract the isosurfaces of G(𝐱) from the volumetric mesh 𝒞 and trim them by the implicit solid H(𝐱) ≤ 0 (Sec. <ref>).

As the mapping is computed on an intermediate mesh 𝒞, our slicing algorithm does not require a perfect volumetric mesh as the discretization of the input model ℳ. 


§ LOSS FUNCTIONS

In order to optimize a mapping function that leads to curved layers satisfying different manufacturing requirements, loss functions are defined in this section for strength reinforcement, support-free, and collision avoidance. All loss functions are defined according to the LPDs – i.e., 𝐝_p = ∇ G(𝐱) / ∇ G(𝐱) w.r.t. the scalar field G(𝐱) to be optimized. Harmonic losses of 𝐪(𝐱) and 𝐬(𝐱) are introduced for the purpose of regularization. 



 §.§ Strength Reinforcement

[6]r0.22



    < g r a p h i c s >



 
Anisotropic mechanical behavior is a prominent characteristic observed in models fabricated through filament-based 3D printing, primarily due to the limited adhesion between deposited filaments <cit.>. Under specific load conditions, the mechanical strength of printed models can be significantly enhanced when the filaments are aligned along the distribution of principal stresses <cit.>. Specifically, the 3D printed model can have a reinforced strength when the LPDs are nearly perpendicular to directions of the maximal principal stresses τ_max as |𝐝_p ·τ_max| ≤sinβ (ref. <cit.>). According to this criterion, we define the following loss function evaluated at the sample points 𝐩∈𝒯 (i.e., the centers of voxels in the relevant region) for the purpose of strength reinforcement.

    ℒ_SR:=∑_𝐩∈𝒯 |V_e|  σ( k_SR (|𝐝_p ·τ_max(𝐩) | -sinβ ) )

where σ(·) is the sigmoid function and |V_e| is the volume of each voxel element for FEA. β is a parameter that introduces a level of tolerance and is related to material properties and printing temperature. k_SR is the logistic growth rate to tune the `steepness' of the loss function. By experimental tests, β=10^∘ and k_SR=15 are employed for all examples in this paper.



 §.§ Support-Free

Two different criteria are considered to define the loss functions to optimize the curved layers to enable support-free (SF) 3D printing based on 1) surface normal and 2) point extremity respectively. All are evaluated on the sample points 𝐩∈ℬ. Note that ℬ can exclude points in the regions that have been naturally supported by the printing platform (e.g., those on the bottom plate of the Bunny Head model). 

[8]r0.35




    < g r a p h i c s >



 
Given an implicit function H(𝐱), the surface normal at a sample point 𝐩∈ℬ can generally be evaluated by the implicit function as 𝐧(𝐩) = - ∇ H(𝐩) / ∇ H(𝐩). Specifically, 𝐧(𝐩) can be precisely obtained from the input model or the skeleton of the convolution solid (including the shell, the cylindrical solid, and the tubular solid) as shown above. In the context of multi-axis 3D printing, the SF requirement for LPDs and surface normals is defined according to the local self-supporting angle α as - 𝐧(𝐩) ·𝐝_p  ≤sinα (ref. <cit.>). Therefore, we define the following loss function.

    ℒ_SF:=∑_𝐩∈ℬ |A_𝐩|  σ( k_SF (- 𝐧(𝐩) ·𝐝_p -sinα ) )

where σ(·) is the sigmoid function and k_SF = 30 was used as the logistic growth rate for this loss function. |A_𝐩| is a weight reflecting the surface area covered by a sample point, which can be estimated by the average squared distance between 𝐩 and its k-nearest neighbors. We use k=10 for all our examples. 

[8]r0.4



    < g r a p h i c s >



 
Similar to the scenario of point overhang discussed in <cit.>, we need to prevent making a surface point as local minimal with reference to the LPD 𝐝_p. Specifically, giving 𝒩_𝐩 as the set of 𝐩's k-nearest neighbors, 𝐩 is a local minimum (i.e., point overhang) when 


(𝐩_j - 𝐩) ·𝐝_p > 0  (∀𝐩_j ∈𝒩_𝐩).

 
The following loss is defined to avoid generating LPDs that lead to local `minimum' on boundary surfaces (i.e., point overhang).

    ℒ_PO:=∑_𝐩∈ℬ |A_𝐩| max (0, min_𝐩_j ∈𝒩_𝐩 ( (𝐩_j - 𝐩) ·𝐝_p ))

where min(·) function is implemented by the min pooling layer and max(0, ·) can be easily realized by the ReLU function. Again, |A_𝐩| is the area weight of a sample point. 



 §.§ Collision Avoidance

[8]r0.5



    < g r a p h i c s >



 
As more DOFs of motion are enabled for the process of multi-axis 3D printing, the collision can happen locally between the working surface and the printer head if the curved layers are not designed properly. As shown on the right, the geometry of a printer head forms a cone shape with the apex angle φ. When using this cone to touch a point on the working surface, local collision will occur in any concave region with a dihedral angle less than φ. 

When the scalar field G(𝐱) is defined in a piecewise linear manner on the elements of the caging mesh 𝒞, the normal of isosurfaces in an element e is a constant vector as 𝐧_e = ∇ G(𝐱) / ∇ G(𝐱). The concavity of isosurfaces in two neighboring elements can be evaluated by (𝐧_L ×𝐧_R) ·𝐡, where 𝐧_L and 𝐧_R are the normal vectors in the left and the right elements e_L and e_R and h is the unit vector obtained from the isoline of G(𝐱) defined on the triangle shared by two elements. Borrowing the study of gouging (i.e., local collision) in multi-axis CNC machining <cit.>, the local concavity needs to satisfy the following condition to be collision-free

    {[ -sinφ≤ (𝐧_L ×𝐧_R) ·𝐡 <0                (φ≤π/2),;    (𝐧_L ×𝐧_R) ·𝐡≤ -sinφ              (φ > π/2). ].

This can be further formulated into a loss as

    ℒ_CA:= ∑_(e_L,e_R)∈𝒩_e   max(0,(𝐧_L×𝐧_R)·𝐡) 
        + max(0,-(𝐧_L×𝐧_R)·𝐡-sin(φ))

for a relative sharp printer head with φ≤π/2. Or we define the loss function as follows

    ℒ_CA:= ∑_(e_L,e_R)∈𝒩_emax(0,(𝐧_L×𝐧_R)·𝐡+sin(φ))

for a relatively flat printer head with φ > π/2. Again, max(0, ·) is realized by the ReLU function in our implementation.
 
Different from previous loss functions, ℒ_CA = 0 needs to be processed as a hard constraint to ensure collision-free. Details can be found in Sec. <ref>. This collision avoidance loss only considers the local collision. Global collision is checked and resolved during the motion planning process of the physical realization (ref. <cit.>), which is not the focus of this paper.




 §.§ Harmonics

Harmonic losses are employed to control the smoothness of 𝐪(𝐱) and 𝐬(𝐱) to be learned. Let 𝒩_e define the set of neighboring element pairs in the caging mesh 𝒞, the differences of scale ratios and quaternions are measured on pairs of neighboring elements.  

First, a loss is introduced to minimize the difference of scaling ratios 𝐬(·) so that avoids the radical change of layer thickness in neighboring regions.

    ℒ_HS := ∑_(e_i, e_j)∈𝒩e1/2(|V_e_i|+|V_e_j|) 𝐬(𝐜_e_i) - 𝐬(𝐜_e_j)^2

where 𝐜_e_i and 𝐜_e_j are the centers of the neighboring elements e_i, e_j, and |V_e_i| and |V_e_j| are the volumes of the elements. The scaling ratios are evaluated on the NN-based continuous function 𝐬(·).

Furthermore, it is important to generate curved layers with smoothly varied normals to ensure smooth and continuous motion of the printer head during fabrication. We control this property of resultant curved layers by introducing a loss that evaluates the difference of quaternions in neighboring regions. 

    ℒ_HQ := ∑_(e_i, e_j)∈𝒩e1/2(|V_e_i|+|V_e_j|) ( 1 - 𝐪(𝐜_e_i)/𝐪(𝐜_e_i) ·𝐪(𝐜_e_j)/𝐪(𝐜_e_j) )^2

where 𝐪(·) is the NN-based continuous function of quaternions. 

Among all metrics for 3D rotations <cit.>, we select one with a simple form that is normalized to bound the loss value.




 §.§ Total Loss

In summary, the curved layer generation problem can be formulated as a learning-based optimization process to minimize the total loss:

    ℒ = w_1 ℒ_SF + w_2 ℒ_SR + w_3 ℒ_OP + ℒ_HS + ℒ_HQ,

where w's are the balancing weights for different loss terms. Considering the collision avoidance loss as a hard constraint, that is 

    min_θ_q, θ_sℒ   s.t.  ℒ_CA = 0.




§ IMPLEMENT DETAILS



 §.§ Differentiable Deformation as Mapping


In our current implementation, the mapping λ(·) is computed on the volumetric caging mesh 𝒞 by using the scale-controlled ARAP deformation <cit.>. That is to determine the new position 𝐯^d for every vertex 𝐯∈𝒞 so that the quaternions and the scale ratios given by the functions q(·) and s(·) are satisfied in the elements of 𝒞 via an optimization formulation. We provide the details of this deformation below and then analyze its differentiability. 

For every element e ∈𝒞, we determine its rotation matrix 𝐑_e by the quaternion 𝐪(𝐜_e) at the element's center 𝐜_e. Its scale matrix 𝐒_e = diag(𝐬^x(𝐜_e),𝐬^y(𝐜_e),𝐬^z(𝐜_e)) is also computed by s(·) at the center 𝐜_e. Then, the locally scaled and rotated element e can be computed by 𝐑_e𝐒_e(𝐍𝐕_e)^T with 𝐕_e being a position matrix formed by the coordinates of e's four vertices. 𝐍 is used to transfer an element’s center to the origin as 𝐍=𝐈_4×4-1/41_4×4. We compute the deformed caging mesh 𝒞^d as

    min_𝒞^d∑_e∈𝒞(𝐍𝐕_e^d)^T -  𝐑_e 𝐒_e (𝐍𝐕_e)^T_F^2_Position-Compatibility + γ∑_𝐯∈𝒞𝐯^d - 𝐯^2_Regularization

where ·_F is the Frobenius norm, and the positions of vertices in 𝒞^d to be determined are kept in the position matrix 𝐕_e^d. The regularization term is added to improve the conditional number of the linear system for solving this problem. 

Denoting ξ^0={𝐯} and ξ = {𝐯^d } as the vectors containing the positions of all vectors before and after deformation, the above equation is actually in the regularized least-squares form as

    min_ξ𝐀ξ - 𝐛^2 + γξ - ξ^0^2.

with 𝐀 and 𝐛 derived from the the position compatibility term of Eq.(<ref>). Then, the positions of the deformed mesh are obtained as 

    ξ = (𝐀^T𝐀+γ𝐈)^-1(𝐀^T𝐛+ γξ^0)

with 𝐈 as an identity matrix.

Given a query point 𝐱∈ℝ^3 contained by an element of 𝒞 with four vertices 𝐯_i (i=1,…,4), we can determine 𝐱's barycentric coordinate as a_i(𝐱) with ∑_i a_i(𝐱) ≡ 1 and a_i(𝐱) ∈ [0,1]. As a result, the mapping λ(·) is obtained as 𝐲 = ∑_i a_i(𝐱) 𝐯^d_i. The scalar field G(𝐱) as the z-components of 𝐲 is 

    G(𝐱) = diag(0,0,1) ∑_i a_i(𝐱) 𝐯^d_i.


This scalar field G(𝐱) determined by the NN-based mapping is differentiable with reference to the network coefficients θ_q and θ_s. Specifically, we have

    ∂ G/∂θ_q = ∑_i ∂ G/∂𝐯^d_i( ∂𝐯^d_i/∂𝐪d 𝐪/d θ_q) 
     and ∂ G/∂θ_s = ∑_i  ∂ G/∂𝐯^d_i( ∂𝐯^d_i/∂𝐬d 𝐬/d θ_s),

among which d 𝐪/d θ_q and  d 𝐬/d θ_s can be directly obtained from the neural networks representing 𝐪(𝐱) and 𝐬(𝐱). By using the calculus of matrix, we can also have

    ∂ξ/∂𝐬 =
        (𝐀ξ^0)^T⊗
        ((𝐀^T𝐀+γ𝐈)^-1𝐀^T𝐑)


    ∂ξ/∂𝐪 
        = ∂ξ/∂𝐑∂𝐑/∂𝐪 
        = (𝐬𝐀ξ^0)^T⊗((𝐀^T𝐀+γ𝐈)^-1𝐀^T)∂𝐑/∂𝐪


where ⊗ denotes the Kronecker product and 𝐑 is the rotation matrix form of 𝐪. ∂𝐯^d_i/∂𝐬 and ∂𝐯^d_i/∂𝐪 can then be obtained from ∂ξ/∂𝐬 and ∂ξ/∂𝐪 from the corresponding location of 𝐯^d in ξ.

By the chain rule, the total derivatives from the loss function ℒ to the network coefficients θ_q and θ_s are given as follows

    d ℒ/d θ_q = ∂ℒ/∂ G( ∑_i ∂ G/∂𝐯^d_i( ∂𝐯^d_i/∂𝐪d 𝐪/d θ_q) )
                + ∂ℒ/∂𝐪d 𝐪/d θ_q,


    d ℒ/d θ_s = ∂ℒ/∂ G( ∑_i ∂ G/∂𝐯^d_i( ∂𝐯^d_i/∂𝐬d 𝐬/d θ_s) )
                + ∂ℒ/∂𝐬d 𝐬/d θ_s.

The backpropagation of our NN-based computational pipeline can be realized. In practical implementation, the total derivatives can be computed by automatic differentiation <cit.>. 



 §.§ Network Architecture and Constrained Optimization

An architecture of Sinusoidal Representation Network (SIREN) is adopted for 𝐪(𝐱) and 𝐬(𝐱) that contains 10 hidden layers, each of which is formed by 512 neurons with the periodic activation functions. The hyperparameters of this network are chosen by the strategy introduced in <cit.>. The input of the networks is 𝐱∈ℝ^3, and the output is a four-dimensional vector for 𝐪(𝐱) ∈ℝ^4 and a three-dimensional vector as scaling ratios for 𝐬(𝐱) ∈ℝ^3. 
 
When computing the network coefficients according to the total loss, the Adam optimizer <cit.> is employed due to its efficacy in handling large-scale data and complex computation. The initial learning rate is set to 1.0e-3, with a minimum learning rate threshold established at 1.0e-6. To adaptively adjust the learning rate during the optimization process, we utilize the `ReduceLROnPlateau` learning rate scheduler that can dynamically alter the learning rate based on the optimization progress.

To implement the optimization with hard constraints in our NN-based computational pipeline, we adopt the DC3 framework as introduced in <cit.>. Specifically, we implement a gradient-based correction step before the loss calculation and back-propagation. This involves taking gradient steps in the parameter space (θ_q, θ_s) towards the feasible region with ℒ_CA = 0, thereby aligning solutions closer to the feasible region.






 §.§ Pre-processing: Sampling and Cage Generation

As discussed above, a tetrahedral mesh 𝒞 caging the input model ℳ is constructed in our approach as the intermediate representation to determine the mapping λ(·) according to 𝐪(𝐱) and 𝐬(𝐱). This representation for numerical computation is selected because of its good balance between the computational efficiency and the fidelity of deformation, making it highly suitable for our NN-based slicing framework. Meanwhile, the loss function of support-free is evaluated on a set of surface sampling points ℬ. The methods for generating ℬ and 𝒞 are introduced below.


 

After converting all different representations of the input model ℳ into an implicit function H(𝐱) (see Fig.<ref>(a)), a polygonal mesh ℋ of its zero level-set surface H(𝐱)=0 is extracted by the Marching Cubes algorithm <cit.>. Surface points are sampled on ℋ and projected onto H(𝐱)=0 by using the gradient ∇ H(𝐱). Sample points in ℬ are obtained. 

A surface caging mesh can then be generated by using the Nested Cage approach <cit.>, which encloses all regions with H(𝐱) ≤ 0 (see Fig.<ref>(b)). Lastly, the volumetric caging mesh 𝒞 is constructed from the surface caging mesh by Tetgen <cit.> (see Fig.<ref>(c)). The mapping and the curved layers are computed on this mesh 𝒞.



 §.§ Post-processing: Slicing on Cage

The resultant curved layers are computed from the scalar field G(𝐱) that is defined on the volume caging mesh 𝒞 (see Fig.<ref>(a)). The isosurfaces of G(𝐱) are firstly extracted from the tetrahedra of 𝒞 as piece-wise linear polygonal meshes {𝒢_i } (ref. <cit.>). The function values of H(𝐱) can then be evaluated at every point on a surface mesh 𝒢_i (see the values visualized as colors in Fig.<ref>(b)). Lastly, the polygons of {𝒢_i} are trimmed by the implicit solid H(𝐱) ≤ 0 to form the curved layers {𝒫_i }. Toolpaths are generated on each 𝒫_i and converted into trajectories of robot motion by the method of S^3-Slicer <cit.>. 



§ RESULT AND DISCUSSION

Our computational pipeline is implemented in Python together with C++. PyTorch <cit.> is employed for constructing neural networks, automatic differentiation, and solving linear equation systems. PyVista  <cit.> is employed for mesh processing. Time-consuming steps such as the point-to-surface distance query by <cit.>, the surface cage generation by <cit.>, and the toolpath generation by <cit.> are based on C++ implementation. The source code of our Neural Slicer will be released upon the acceptance of this paper.






 §.§ Computational Experiments

All the computational experiments are conducted on a desktop PC with an Intel(R) Core(TM) i5-12600K CPU (10 cores @3.6GHz), NVIDIA RTX 4080 GPU, and 32GB RAM, running Ubuntu 20.04 LTS (Focal Fossa). 



  §.§.§ Examples and computational statistics.

We have tested our Neural Slicer on a variety of models with complicated geometry and topology. The first model is a Bunny Head model in hybrid representations (see Fig.<ref>(a)), including 15,635 tetrahedra for solid (blue), 3,495 triangles for shell (green), 41 skeletons (thin black lines) for the struts as cylindrical solids and 36 skeletons (bold black lines) for the tubular solids. The genus number of this input model is g=22. The implicit function H(x) of this model is computed with the help of the signed distance function and the convolution surfaces. Both the support-free (SF) and the strength reinforcement (SR) requirements are applied to this model. Curved layers can be successfully computed by our Neural Slicer (see Fig.<ref>(b)). The second example is the Yoga model with both the SF and SR objectives required as shown in Fig.<ref>, where the input is a mesh surface with 13,938 triangles. The third example is a Shelf model generated by topology optimization. It is a model with a high genus number as g=30 and again both the SF and the SR requirements are applied. The resultant curved layers are shown in Fig.<ref>. We can find that the curved layers follow the directions of maximal stresses very well. 

We also tested our Neural Slicer on a few other models by applying only the SF requirement, including the Ring model (Fig.<ref>), the Tubes model (Fig.<ref>) and the Spiral Fish model (Fig.<ref>). The Ring model is selected to compare with the curved layers generated by S^3-Slicer. As illustrated in Fig.<ref>, S^3-Slicer defined the SF objective in the deformed space. Layers that are self-supported in the deformed space can become overhangs in the model space caused by the mapping distortion. Differently, our Neural Slicer directly evaluates the SF loss in the model space so that the overhang can be better prevented (see the comparison shown in Fig.<ref>). The Tubes model is an implicit solid generated by convolution surfaces from the representation of 186 line segments as skeletons. Our slicer can generate curved layers directly from the implicit solid. The Spiral Fish model is employed to demonstrate that our approach is robust to different initial guesses. Details will discussed later in Sec. <ref>. 

Lastly, we have tested this Neural Slicer on the Bridge example and compared our approach with the S^3-Slicer (see Fig.<ref>). Only the SR requirement is applied in this example. Computational statistics of all examples are given in Table <ref>, where the computation of our Neural Slicer can be completed within 15 minutes. It can be observed that the genus number of a caging mesh can be different from an input model. In other words, we can use a caging mesh with simple topology as the computational domain to generate curved layers for a model with complicated topology (see the Bunny Head model and its cage in Fig.<ref> for an example). The toolpaths on the curved layers are generated by the method presented in <cit.>, the computing time of which has also been reported in Table <ref>.





  §.§.§ Statistics in LPDs

As both the SF and the SR requirements are defined according to the LPDs, we evaluate the quality of results generated by our Neural Slicer as the histograms in terms of i) the angles between LPDs and the surface normals at H(x)=0 for the SF requirement and ii) the angles between LPDs and the maximal stresses for the SR requirement. The histograms are generated by LPDs (i.e., ∇ G(𝐱) / ∇ G(𝐱)) evaluated at all the sample points in the set ℬ for SF and the set 𝒯 for SR. We have given these statistical results as histograms for the Bunny Head model in Fig.<ref> and the Shelf model in Fig.<ref>. It can be observed from the histograms that both the SF and the SR requirements have been well achieved on the curved layers generated by our Neural Slicer. Despite this, supporting structures are still needed to help mount the Shelf model tightly on the platform during the printing process.

The statistics for the curved layers generated by the S^3-slicer <cit.> are also given on the Tubes model (Fig.<ref>) and the Bridge model (Fig.<ref>) for the purpose of comparison. It is found that our Neural Slicer can further reduce the remaining overhang region by 95% on the Tubes model. The results are also visualized by the histogram shown in Fig.<ref>(c). Note that the result of the Tubes model is computed by S^3-slicer on a very dense tetrahedral mesh with 430k elements while our Neural Slicer only employs a caging mesh with 16.5k elements.





When applying our Neural Slicer on the Bridge model for the SR requirement (see Fig.<ref>), we can generate a result of curved layers that outperform those obtained from the S^3-slicer <cit.>. Instead of the highly curved layers, our slicer automatically generates a very `smart' solution with nearly planar layers (see Fig.<ref>(d & f)), which surprisingly aligns better with the maximal stresses – see the histogram given in Fig.<ref>(b). 



  §.§.§ Verification by FEA
 
To verify the mechanical strength of models to be fabricated by different layers, we conducted the FEA simulation with anisotropic material properties by assigning different Young’s modulus along different directions at the element level. Specifically, Y_1 = 3.5 GPa is used as the strongest modulus and is assigned to the toolpath's tangential direction. The weakest modulus is assigned both to the surface normal direction of each layer and the third orthogonal direction as Y_2 = Y_3 = 1.2 GPa. 

FEA results of the Shelf model have been given in Fig.<ref>(d), where the model with curved layers generated by our Neural Slicer has reduced the maximal strain by  43.3% compared to the model using planar layers. For the FEA simulation conducted on the Bridge model, the Neural Slicer can reduce the maximal strain by 40.5% than the S^3-Slicer (see Fig.<ref>(g & h)). In Fig.<ref>, we compare the FEA results on the Bunny Head model for the results with only the SF requirement vs. with both the SF and the SR requirements. Adding the SR requirement can reduce the maximal strain by 36.8%.







  §.§.§ Ablation Study for Point Overhang Loss

To demonstrate the effectiveness of the point overhang loss ℒ_PO (Eq.(<ref>)), we conducted an ablation study on the Bunny Head model imposing both the SF and the SR requirements. The only difference is whether the point overhang loss is omitted. When skipping the point overhang loss, the optimization will lead to a deformed caging mesh 𝒞^d as shown in Fig.<ref>(a). Compared to the result with the full set of losses (as Fig.<ref>(c)), this omission leads to an overhang at the tip of the right ear. As a result, the printing sequence determined according to 𝒞^d in Fig.<ref>(b) will require additional support at the tip of the right ear. Differently, the printing sequence given in Fig.<ref>(d) can be realized in a completely support-free way.  



  §.§.§ Robustness to Initial Guess

One major issue of previous approaches based on nonlinear optimization is how to obtain good initial guesses for LPDs. As can be found in the example of the Tubes model shown in Fig.<ref>, the S^3-Slicer computes results by using the distance field generated by the heat method <cit.> as an initial guess. Apparently, the resultant curved layers are less smoother than those generated by our Neural Slicer (see the zoom views of Fig.<ref>). Another example is the Bridge model as shown in Fig.<ref>. When posing the input model into an orientation as Fig.<ref>(d) and using the height field as the initial guess for LPDs, the S^3-Slicer can obtain a result similar to our Neural Slicer. However, a `good' initial guess is never easy to be obtained in general. 



Differently, our Neural Slicer is robust to the initial guess of the mapping λ(·). A study has been conducted on the Spiral Fish model as shown in Fig.<ref> to demonstrate this advantage of our approach. The computing processes starting from different initial guesses are tested, which include:


  * Height Field – We first test the initial guess as planar layers, which is in fact an identity mapping for λ(·) that can be easily realized by setting 𝐪(𝐱) and 𝐬(𝐱) with neither rotation nor scaling (see Fig.<ref>(a)). 


  * Heat Transfer – The other initial field is obtained by using the heat method <cit.> to generate an approximated geodesic distance field to the bottom of the model (see Fig.<ref>(b)). The network coefficients θ_q and θ_s for 𝐪(𝐱) and 𝐬(𝐱) are pre-trained to make G(x) fit this field by minimizing the mean squared error. 


  * S^3-Slicer – The scalar field obtained from the S^3-Slicer (see Fig.<ref>(c)) is employed to pre-train the initial network coefficients θ_q and θ_s for 𝐪(𝐱) and 𝐬(𝐱).

When applying our Neural Slicer to compute curved layers by using the above different initial guesses, the learning curves of the NN optimizer are as shown in Fig.<ref>(d). All converge to the same result of curved layers as shown in Fig.<ref>(e). The area of overhang on our result can be further reduced by 94.2% w.r.t. the result from S^3-Slicer. This study demonstrates the robustness of our framework with different initial guesses.  




 §.§ Physical Experiments

The curved layers generated by our framework are tested to fabricate models on a multi-axis 3D printing hardware system as shown in Fig.<ref>(d), which is composed of an ABB IRB 2600 robotic arm with 6-DOFs and an ABB A250 positioner with 2-DOFs. The repeatability of this robotic system is ±0.05mm and the TCP/IP protocol is used for the communication between the extrusion system, the robotic arms, and the PC. With the kinematic redundancy provided by this system, materials can be deposed onto the in-process model along arbitrary directions in the model's space while still controlling the physical orientation and the speed / acceleration of the printer head. The extruder system is controlled by a Duet3D board and the nozzle dimension is 1.0mm. Polylactic Acid (PLA) and Polyvinyl Alcohol (PVA) filaments with 1.75mm diameter are used in our physical fabrication, where all models are printed by PLA filaments. PVA is only used to print the support structures for the Bridge model. With the help of speed control, layers with thickness in the range of [0.4mm, 1.0mm] can be reliably produced by this hardware system.










The models fabricated by our system using support-free curved layers are shown in Fig.<ref>. The statistics of physical fabrication are given in Table <ref>. For the purpose of comparison, a few models are also fabricated by planar layers, where additional supporting structures need to be printed therefore the models are heavier. To have a larger search space, curved layers of the Bridge model are computed by only imposing the SR requirement. Two Bridge models are fabricated using layers generated by the S^3-Slicer and our Neural Slicer (see Fig.<ref>).

Mechanical tests have been conducted to test the strength of 3D printed models on an INSTRON tensile machine 5960 with a capacity of 10kN. First of all, the 3-point bending tests are conducted on two Bridge models shown in Fig.<ref> after removing the PVA supports. Force-displacement curves are measured during the bending tests (see Fig.<ref>). An improvement of 101.9% in the breaking force can be observed on the specimen fabricated from the layers generated by our Neural Slicer, which is consistent with the simulation results as given in Fig.<ref>. We also tested the mechanical strength of the 3D printed Bunny Head model on the same tensile machine. The bottom of the model is fixed by a specially designed fixture and the compressing force is applied on the right ear of the model (see Fig.<ref>). Two specimens are tested in our experiment. One is fabricated from the layers generated by imposing only the SF requirement while the other is from the layered with both the SF and the SR requirements. From the force-displacement curves, we can observe a 30.6% increase of the breaking force on the specimen with SR requirement. The broken region is changed from the root of the ear to the hole of the ear (see the zoom-views in Fig.<ref>). The results of mechanical tests are also consistent with the simulation results given in Fig.<ref>, where the maximal strain on the model with the SF + SR requirements is reduced by 36.5% compared to the one with only the SF requirement. 



 §.§ Discussion

One major limitation of our current approach is that the stress field employed to define the strength reinforcement loss ℒ_SR is obtained from FEA using isotropic material properties (i.e., τ_max is given and unchanged during the optimization). This simplification ignores the change of τ_max caused by the anisotropic material properties introduced by curved layers. We study this influence by studying the change of angles between LPDs and the maximal stress directions when using anisotropic FEA instead of the input distribution obtained from isotropic FEA. The anisotropic FEA in this study employs the same parameters as those used in Sec. <ref>. The statistics of angle changes on two models have been given in Fig.<ref>. It can be found that this change indeed has a certain level of influence but is not very significant. Moreover, considering the change of τ_max in curved slicing needs to incorporate the anisotropic FEA in the loop of optimization, which will further increase the computational complexity. How to make the procedure of principal stress analysis differentiable is also a problem to be further explored. We plan to consider this in our future research.



The second limitation is that the computation of mapping is based on an intermediate representation – the caging mesh 𝒞. We conducted the computational tests on the Spiral Fish model by using 𝒞 in three different resolutions. As shown in Fig.<ref>, the computation of our Neural Slicer successes on all cages although the converging speed and the level of final loss are different. Caging meshes in different resolutions may have different genus numbers. 



The third limitation comes from how global collision is handled. When the collision between a printer-head and the model / platform occurs, we employ the same strategy as S^3-slicer <cit.> to increase the weight of the harmonic term to give more flat layers. In extreme cases, it will give planar layers that can guarantee no collision while other manufacturing objectives are compromised. The collision with robotic arms can be prevented in the downstream steps of motion planning <cit.>.




In our Neural Slicer, the mapping λ(·) is `parameterized' as a quaternion field 𝐪(𝐱) and a scaling field 𝐬(𝐱) (simply denoted as Q-S fields). In literature, shifting-vector based fields and scalar fields are widely used to represent a deformation field for non-rigid registration (ref. <cit.>. We argue that the deformation parameterized on the quaternion and the scaling fields is more efficient for computing a mapping for curved slicing. However, we are not able to prove this by theory. Comparisons are conducted on example models to study the computational efficiency by using different fields (see Fig.<ref>). 

To demonstrate the effectiveness of our NN-based method to optimize the deformation as a mapping for slicing, we have conducted tests of directly using stochastic gradient descent (SGD) and Adaptive Moment Estimation (Adam) <cit.> to optimize the quaternions and scales at the center of tetrahedral elements and compared with our NN-based approach using different SIREN layers (5 & 10 layers) on both the Bridge model and the Spiral Fish model (see Fig.<ref> for the comparison). Significant differences in convergence speed can be observed – especially when SIREN with 10 layers is employed. This is because such a neural network structure can capture and realize the required deformation more easily.

Explicitly imposing the requirement of injectivity in ARAP is not necessary in our framework. This is due to the fact that we directly evaluate manufacturing objectives as loss functions defined in the model space but not in the deformed space. The resultant G(𝐱) is a function mapping from ℝ^3 to ℝ which allows the local rotation around the z-axis in the deformed space. This gives more flexibility to achieve optimal slicing results. The quality of resultant layers as isosurfaces are softly controlled by the harmonic terms. In examples with challenging geometry (e.g., the Spiral Fish model), we find that the allowed self-intersection is helpful to obtain results satisfying the manufacturing objectives better.






§ CONCLUSION

This paper introduces a representation-agnostic slicer for multi-axis 3D printing, utilizing a computational pipeline based on neural networks. Our slicer is designed to work on models with diverse representations and complex topology. We leverage a deformation field to compute the mapping, determining a scalar field in the space surrounding an input model. Isosurfaces of this scalar field are then extracted to generate curved layers for 3D printing. In contrast to previous approaches, where manufacturing objectives are indirectly optimized, our approach enables direct optimization of the scalar field by using loss functions directly based on local printing directions. This optimization is achieved through the implementation of a differentiable computation pipeline.
 Our approach demonstrates the successful handling of models with intricate topology, facilitated by the utilization of a volumetric mesh as a numerical computation cage. Notably, this allows for the input model and the cage to possess (i.e., different genus numbers). Leveraging the capabilities of a robust neural network solver, our approach allows for the flexible adjustment of local printing directions within a model, eliminating the need of good initial guesses for the optimization process. Our Neural Slicer presented in this paper can generate results with significantly enhanced performance, which has been verified in a variety of examples and in physical experiments.


            The project is supported by the chair professorship fund at the University of Manchester and UK Engineering and Physical Sciences Research Council (EPSRC) Fellowship Grant (Ref.#: EP/X032213/1).


ACM-Reference-Format


