PHYSICAL PDF PAGE 7 / 20

                            Outlier-Aware Post-Training Quantization for Discrete Graph Diffusion Models





Table 1. Molecule generation performance of full-precision Digress (Vignac et al., 2023) (i.e., baseline) and quantized Digress with

different quantization methods on QM9 and MOSES datasets. “WxAy” denotes that the weights (W) and activations (A) are represented

in x-bit and y-bit precision, respectively. “Mem.” refers to the peak memory usage during the model inference.



          Molecule Generation                           QM9                                        MOSES

                                       Valid   Unique    Speedup        Mem.    Novel    Valid    Unique    Speedup      Mem.

           Method        Precision

                                        (%)     (%)        (↑)         (GB ↓)    (%)      (%)      (%)        (↑)       (GB ↓)

                           FP32        99.0     96.2       1×           6.4      93.8     82.5     99.8        1×         8.7

           baseline

                           BF16        98.8     96.0      1.3×          3.4      93.6     82.5     99.7       1.3×        4.6

            RTN           W4A4         57.6     88.6      2.7×          1.6      84.2     63.8     87.9       2.8×        2.3

           GPTQ           W4A4         72.4     86.1      2.7×          1.6      85.1     72.0     92.6       2.8×        2.3

         SVDQuant         W4A4         95.6     92.7      2.2×          2.0      91.6     80.6     96.5       2.2×        3.0

          DuQuant         W4A4         96.5     94.6      2.1×          2.1      92.8     81.1     98.0       2.1×        3.2

        SqueezeLLM        W4A16        95.9     94.8      1.1×          2.3      92.5     81.3     98.0       1.1×        3.6

         Bit-DGDM         W4A4         98.2     95.5      2.5×          2.3      93.1     81.9     98.9       2.5×        3.8





critical role. The term XSW , where SW adheres to α-                    and MOSES (Polykovskiy et al., 2020), as well as non-

Sparsity, implies that each row and column contains at most             molecular benchmarks (Martinkus et al., 2022) such as SBM

an α-fraction of nonzero entries. In other words, the nonzero           and planar graphs. Moreover, we investigate protein inverse

elements are evenly distributed across each row and column.             folding task, an essential application of graph generation,

To address this, we design a equidistributed sparse-dense               where node relationships are provided by 3D coordinates

kernel that assigns each thread a column, ensuring uniform              and assess the model’s ability to recover the correct amino

workload distribution across threads. For the term SX LR> ,             acid sequence given protein’s 3D structure. We utilize the

given that the occurrence of outliers in the activations is ran-        SOTA GRADE-IF (Yi et al., 2023) as the DGDM, based on

dom, we have developed an adaptive sparse-dense kernel                  Equivariant Graph Neural Network (Satorras et al., 2021).

based on (Flegar & Quintana-Ortı́, 2017). This approach

                                                                        Baselines. As there is a lack of PTQ baselines for DGDMs,

assigns an equal number of nonzero entries to each thread.

                                                                        we compare Bit-DGDM against various PTQ methods

Although this necessitates additional synchronization, as

                                                                        for LLMs and IDMs including RTN (round-to-nearest),

each column of L is processed by multiple threads, it en-

                                                                        GPTQ (Frantar et al., 2023), SqueezeLLM (Kim et al.,

sures a more balanced workload in terms of time. Since

                                                                        2024), SVDQuant (Li et al., 2024b), DuQuant (Lin et al.,

the computations for XSW and SX LR> are independent,

                                                                        2024). Their descriptions are provided in Appendix F.1.

the equidistributed and adaptive sparse-dense kernels are

launched in a single call. The detailed descriptions of these           Metrics. The metrics for evaluating the effectiveness of

two kernels are demonstrated in Appendix E.                             molecular graph generation include Validity, Uniqueness,

                                                                        and Novelty, while the key metrics for assessing 3D pro-

5. Experiments                                                          tein inverse folding are Perplexity and Recovery (detailed

                                                                        descriptions can be found in Appendix F.2). The efficiency

In this section, we conduct empirical experiments to demon-             of model inference after quantization is evaluated using

strate the efficacy of our Bit-DGDM1 . We include quantiza-             Speedup and Peak Memory Usage (Mem.).

tion cost analysis and other results in Appendix F.

                                                                        Quantization details. For Bit-DGDM, we first determine

                                                                        the thresholds, τmax and τmin , for identifying activation out-

5.1. Experimental Setup                                                 liers by selecting the top 0.1% highest and lowest values,

Models and Datasets. We conduct a comprehensive eval-                   respectively. To obtain the activation values, we randomly

uation of Bit-DGDM’s effectiveness in the quantization of               generate 32 samples using the full-precision DGDMs. For

various DGDMs and their applications. For 2D structured                 low-rank weight decomposition, we set the rank r to 32, the

graphs, where node relationships are represented using adja-            α-sparsity parameter α to 1%, and the step size η to 0.1.

cency matrices, we employ the widely used discrete DGDM,                Latency Profiling. We use the Torch CUDA profiler to

Digress (Vignac et al., 2023), which utilize FiLM (Perez                measure the latency and peak memory usage for generating

et al., 2018) and Graph Transformer (Dwivedi & Bresson,                 graphs with a batch size of 16 on a single NVIDIA RTX-

2020) as backbones. These models are applied to molec-                  3090 GPU, complemented by two 2.20GHz Intel Xeon Gold

ular synthesis datasets, including QM9 (Wu et al., 2018)                5220R CPU, and 512GB of CPU memory. The node size

   1

       Our code is publicly available here.

                                                                        n and cardinalities of nodes and edges |X |, |E| is decided

                                                                        based on the dataset settings.



                                                                   7

