tico 0.3.0.dev261001__tar.gz → 0.3.0.dev261007__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/PKG-INFO +1 -1
- tico-0.3.0.dev261007/tico/_version.py +1 -0
- tico-0.3.0.dev261007/tico/passes/lower_multi_index_to_gather_nd.py +188 -0
- tico-0.3.0.dev261007/tico/passes/remove_empty_cat_inputs.py +183 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/remove_unused_placeholder.py +69 -30
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/qwen3_vl_gptq/gptq.py +6 -2
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/qwen3_vl_gptq/quantizer.py +1 -1
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/universal_gptq/quantizer.py +353 -178
- tico-0.3.0.dev261007/tico/quantization/config/gptq.py +379 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/script/mini_vqa_eval.py +9 -19
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/adapters/__init__.py +43 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/adapters/base.py +16 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/adapters/gemma4.py +27 -103
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/adapters/gemma4_assistant.py +6 -7
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/adapters/qwen3_vl.py +31 -106
- tico-0.3.0.dev261007/tico/quantization/recipes/evaluation/llava_bench.py +149 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/stages/gptq.py +11 -11
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/quantize_qwen3_vl_with_gptq.py +12 -22
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/convert.py +4 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/signature.py +51 -19
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico.egg-info/PKG-INFO +1 -1
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico.egg-info/SOURCES.txt +3 -0
- tico-0.3.0.dev261001/tico/_version.py +0 -1
- tico-0.3.0.dev261001/tico/quantization/config/gptq.py +0 -190
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/LICENSE +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/README.md +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/pyproject.toml +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/setup.cfg +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/_buffer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/_object.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/_schema.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/analysis/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/analysis/effects.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/analysis/purity.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/analysis/structural_hash.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/analysis/tensor_contract.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/builder.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/cli/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/cli/__main__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/cli/main.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/document.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/errors.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/export.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/graph.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/inspect/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/inspect/printer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/inspect/summary.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/io.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/mutation.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/operations/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/operations/extract.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/base.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/cleanup/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/cleanup/compact_indices.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/cleanup/dead_code_elimination.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/cleanup/graph_inputs.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/manager.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/_pattern_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/canonicalize/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/canonicalize/equivalent_ops.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/compatibility/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/compatibility/custom_ops.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/compatibility/fc_gelu_fc.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/cse.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fold/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fold/constant_subgraph.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fold/evaluators/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fold/evaluators/base.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fold/evaluators/elementwise.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fold/evaluators/heavy.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fold/evaluators/indexing.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fold/evaluators/shape.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fold/profiles.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fuse/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fuse/activation.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fuse/composite.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fuse/linear.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fuse/requantize.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/fuse/spatial.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/legalize/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/legalize/dynamic_fully_connected.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/policy.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/simplify/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/simplify/_layout_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/simplify/arithmetic.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/simplify/identity_ops.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/simplify/reductions.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/simplify/transpose_region.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/simplify/transpose_region_rules.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/optimization/simplify/views.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/presets.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/rules.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/passes/worklist.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/rewrite.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/runtime/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/runtime/errors.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/runtime/executor.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/runtime/kernels/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/runtime/kernels/base.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/runtime/kernels/elementwise.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/runtime/kernels/nn.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/runtime/kernels/quantize.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/runtime/kernels/reduction.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/runtime/kernels/shape_ops.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/runtime/program.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/runtime/quantization.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/selector.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/session.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/value/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/value/codec.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/value/dtype.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/value/tensor.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/circle/verify.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/config/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/config/base.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/config/factory.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/config/v1.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/experimental/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/interpreter/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/interpreter/backends.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/interpreter/infer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/interpreter/interpreter.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/ops/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/ops/concat.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/ops/resize_bilinear.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/ops/same_padding_conv2d.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/cast_aten_where_arg_type.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/cast_clamp_mixed_type_args.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/cast_mixed_type_args.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/const_prop_pass.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/convert_conv1d_to_conv2d.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/convert_conv3d_to_conv2d.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/convert_expand_to_slice_cat.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/convert_gather_to_gather_nd.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/convert_layout_op_to_reshape.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/convert_matmul_to_linear.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/convert_repeat_to_expand_copy.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/convert_sym_size_to_circle_shape.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/convert_to_relu6.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/decompose_addmm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/decompose_batch_norm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/decompose_fake_quantize.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/decompose_fake_quantize_tensor_qparams.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/decompose_group_norm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/decompose_grouped_conv2d.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/decompose_slice_scatter.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/eliminate_rank_round_trip_region.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/extract_dtype_kwargs.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/fill_meta_val.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/fuse_leading_unsqueeze_reshape.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/fuse_redundant_reshape_to_mean.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/legalize_causal_mask_value.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/legalize_predefined_layout_operators.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/lower_copy.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/lower_pow2_to_mul.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/lower_to_resize_nearest_neighbor.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/lower_to_slice.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/merge_consecutive_cat.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/ops.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/remove_nop.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/remove_redundant_assert_nodes.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/remove_redundant_expand.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/remove_redundant_permute.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/remove_redundant_reshape.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/remove_redundant_slice.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/remove_redundant_to_copy.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/restore_linear.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/passes/segment_index_select.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/pt2_to_circle.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/adaround/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/adaround/discrete_refinement.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/adaround/global_refinement.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/adaround/joint.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/adaround/joint_runner.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/adaround/rounding.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/adaround/runner.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/adaround/screened_refinement.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/block_reconstruction/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/block_reconstruction/cache.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/block_reconstruction/multistart.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/block_reconstruction/observer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/block_reconstruction/qdrop.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/block_reconstruction/runner.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/block_reconstruction/selection.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/cle/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/cle/cle.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/cle/quantizer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/fpi_gptq/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/fpi_gptq/fpi_gptq.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/fpi_gptq/quantizer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/fpi_gptq/util.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/gemma4_gptq/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/gemma4_gptq/gptq.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/gemma4_gptq/quantizer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/gemma4_gptq/utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/gptq/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/gptq/gptq.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/gptq/quant.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/gptq/quantizer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/gptq/utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/qwen3_vl_gptq/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/qwen3_vl_gptq/utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/smoothquant/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/smoothquant/observer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/smoothquant/quantizer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/smoothquant/smooth_quant.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/spinquant/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/spinquant/fuse_norm_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/spinquant/hadamard_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/spinquant/quantizer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/spinquant/qwen3_vl_model_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/spinquant/qwen3_vl_quantizer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/spinquant/qwen3_vl_rotation_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/spinquant/rotation_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/spinquant/spin_llama.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/spinquant/spin_qwen3_vl.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/analysis/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/analysis/ablation.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/analysis/clipping.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/analysis/inputs.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/analysis/metrics.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/analysis/output_quantization.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/analysis/outputs.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/analysis/profile.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/analysis/report.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/analysis/selector.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/analysis/sensitivity.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/base.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/builders.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/cle.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/fpi_gptq.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/gemma4_assistant_builders.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/gemma4_attention.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/gemma4_builders.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/gemma4_gptq.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/llama_attention.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/ptq.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/qwen3_vl_attention.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/qwen3_vl_gptq.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/qwen3_vl_spinquant.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/smoothquant.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/specs.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/spinquant.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/config/utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/backend.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/evaluate.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/executor/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/executor/backend_executor.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/executor/circle_executor.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/executor/triv24_executor.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/hellaswag_eval_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/llava_bench_judge_eval_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/lmms_eval_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/lmms_gemma4.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/lmms_tasks/videomme_mini/utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/metric.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/mmlu_eval_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/mmmu_eval_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/optional_deps.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/script/llm_tasks_eval.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/evaluation/vlm_eval_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/examples/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/examples/compare_side_by_side.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/examples/configs/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/examples/evaluate.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/examples/export.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/examples/inspector.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/examples/quantize.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/passes/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/passes/concat_qparam.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/passes/fold_quant_ops.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/passes/insert_quantize_on_dtype_mismatch.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/passes/legalize_quantized_clamp.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/passes/propagate_qparam_backward.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/passes/propagate_qparam_forward.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/passes/qparam_safe_const_prop.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/passes/quantize_bias.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/passes/remove_weight_dequant_op.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/public_interface.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/quant_stub.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/quantizer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/quantizer_registry.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/adapters/llama.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/config.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/context.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/data/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/data/dataset_config.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/data/dataset_usage.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/data/llm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/data/vlm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/static_gemma4_assistant_runtime.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/static_gemma4_runtime.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/static_llama_runtime.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/static_qwen3_vl_runtime.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/tied_embedding.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/trace.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/wrapper_smoke/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/wrapper_smoke/case.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/wrapper_smoke/cases/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/wrapper_smoke/cases/gemma4.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/wrapper_smoke/cases/gemma4_assistant.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/wrapper_smoke/cases/llama.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/wrapper_smoke/cases/nn.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/wrapper_smoke/cases/qwen3_vl.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/wrapper_smoke/registry.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/wrapper_smoke/result.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/wrapper_smoke/runner.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/debug/wrapper_smoke/utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/evaluation/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/evaluation/hellaswag.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/evaluation/llava_bench_judge.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/evaluation/llm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/evaluation/mmlu.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/evaluation/mmmu.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/evaluation/selection.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/evaluation/video_mme.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/evaluation/vlm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/export/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/export/checkpoint.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/export/circle.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/export/gemma4.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/export/gemma4_assistant.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/export/llama.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/export/qwen3_vl.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/extensions.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/override_policies.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/qparams.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/runner.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/stages/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/stages/base.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/stages/cle.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/stages/ptq.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/stages/smoothquant.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/stages/spinquant.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/recipes/utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/control.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/dtypes.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/compare_ppl.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/debug_quant_outputs.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/evaluate_fk_llama_model.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/gemma4/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/gemma4/quantize_for_causal_lm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/gemma4/quantize_for_conditional_generation.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/gemma4/quantize_model.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/gemma4/quantize_multimodal_embedder.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/gemma4/quantize_text_scaled_word_embedding.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/gemma4/quantize_vision_model.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/gemma4/quantize_vision_patch_embedder.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/gemma4/quantize_vision_pooler.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/llama/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/llama/quantize_attention_decode.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/llama/quantize_attention_prefill.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/llama/quantize_decoder_layer_decode.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/llama/quantize_decoder_layer_prefill.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/llama/quantize_mlp.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/nn/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/nn/quantize_conv3d.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/nn/quantize_conv3d_special_case.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/nn/quantize_layernorm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/nn/quantize_linear.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/nn/quantize_tied_embedding.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/quantize_full_qmodel_with_gptq.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/quantize_with_gptq.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/qwen/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/qwen/quantize_for_conditional_generation.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/qwen/quantize_model.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/qwen/quantize_text_attention.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/qwen/quantize_text_decoder_layer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/qwen/quantize_text_mlp.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/qwen/quantize_text_model.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/qwen/quantize_vision_attention.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/qwen/quantize_vision_block.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/qwen/quantize_vision_mlp.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/qwen/quantize_vision_model.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/qwen/quantize_vision_patch_embed.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/qwen/quantize_vision_patch_merger.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/qwen/trace_qwen.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/examples/static_llama_layer_runtime.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/mode.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/observers/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/observers/affine_base.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/observers/base.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/observers/ema.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/observers/identity.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/observers/minmax.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/observers/mx.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/observers/percentile.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/qscheme.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/quantizer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/utils/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/utils/check_missing_qparam.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/utils/introspection.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/utils/linear_folding.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/utils/metrics.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/utils/reduce_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/utils/utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/utils/version.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrap_helper.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/fairseq/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/fairseq/decoder_export_single_step.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/fairseq/quant_decoder.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/fairseq/quant_decoder_layer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/fairseq/quant_encoder.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/fairseq/quant_encoder_layer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/fairseq/quant_mha.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/embedding_scale_fusion.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/export_adapters.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/ple_embedding_host.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_clippable_linear.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_for_causal_lm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_for_conditional_generation.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_model.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_multimodal_embedder.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_rmsnorm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_text_attention.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_text_decoder_layer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_text_mlp.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_text_model.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_text_scaled_word_embedding.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_vision_attention.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_vision_encoder.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_vision_encoder_layer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_vision_mlp.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_vision_model.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_vision_patch_embedder.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/quant_vision_pooler.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/rope.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/static_vision_profile.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4/vision_split_export.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4_assistant/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4_assistant/export_adapters.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4_assistant/quant_backbone.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4_assistant/quant_for_causal_lm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4_assistant/quant_masked_embedder.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4_assistant/sparse_head.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4_assistant/static_inputs.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/gemma4_assistant/utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/llama/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/llama/export_adapters.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/llama/quant_attention.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/llama/quant_decoder_layer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/llama/quant_mlp.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/llama/quant_model.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/llama/quant_model_for_causal_lm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/nn/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/nn/quant_conv2d.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/nn/quant_conv3d.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/nn/quant_conv3d_decomposed.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/nn/quant_conv_transpose2d.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/nn/quant_embedding.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/nn/quant_layernorm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/nn/quant_linear.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/nn/quant_maxpool2d.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/nn/quant_prelu.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/nn/quant_silu.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/ops/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/ops/quant_concat.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/ops/quant_resize_bilinear.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/ops/quant_rmsnorm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/ops/quant_same_padding_conv2d.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/ptq_wrapper.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/quant_elementwise.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/quant_module_base.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/quant_stub.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/qwen_vl/export_adapters.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/qwen_vl/quant_for_conditional_generation.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/qwen_vl/quant_model.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/qwen_vl/quant_text_attention.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/qwen_vl/quant_text_decoder_layer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/qwen_vl/quant_text_mlp.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/qwen_vl/quant_text_model.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/qwen_vl/quant_vision_attention.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/qwen_vl/quant_vision_block.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/qwen_vl/quant_vision_mlp.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/qwen_vl/quant_vision_model.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/qwen_vl/quant_vision_patch_embed.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/qwen_vl/quant_vision_patch_merger.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/qwen_vl/vision_profile.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/wrapq/wrappers/registry.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/circle_binary.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/circle_graph.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/circle_mapping.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/circle_serializer.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/adapters/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/adapters/llama_rmsnorm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/adapters/onert/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/adapters/onert/llama_attention.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/hashable_opcode.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/node_visitor.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_abs.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_add.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_alias_copy.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_any.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_arange_start_step.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_argmax.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_attention.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_avg_pool2d.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_bitwise_and.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_bmm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_cat.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_circle_gather_nd.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_circle_shape.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_clamp.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_clone.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_constant_pad_nd.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_conv2d.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_cos.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_cumsum.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_depthwise_conv2d.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_dequantize_per_channel.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_dequantize_per_tensor.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_div.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_elu.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_embedding.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_eq.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_exp.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_expand.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_full.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_full_like.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_ge.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_gelu.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_gt.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_index.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_index_select.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_instance_norm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_le.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_leaky_relu.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_linear.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_log.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_log1p.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_logical_and.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_logical_not.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_lt.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_max_dim.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_max_pool2d_with_indices.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_maximum.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_mean.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_minimum.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_mm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_mul.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_ne.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_neg.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_permute.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_pow.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_prelu.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_quantize_per_tensor.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_reciprocal.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_relu.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_relu6.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_repeat.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_reshape.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_resize_bilinear.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_resize_nearest_neighbor.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_rmsnorm.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_round.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_rsqrt.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_scalar_tensor.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_select_copy.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_sigmoid.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_sin.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_slice.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_softmax.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_split_with_sizes.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_sqrt.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_squeeze.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_sub.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_sum.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_tanh.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_to_copy.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_transpose_conv.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_unsqueeze.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_view.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/op_where.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/operators/utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/pack.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/serialize/quant_param.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/compat/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/compat/torch.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/compat/torch_version_policy.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/compat/transformers.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/define.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/diff_graph.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/dtype.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/errors.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/graph.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/installed_packages.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/logging.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/model.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/mx/__init__.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/mx/dtypes.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/mx/elemwise_ops.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/mx/formats.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/mx/mx_ops.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/padding.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/passes.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/pytree_utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/record_input.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/register_custom_op.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/serialize.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/trace_decorators.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/utils.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/validate_args_kwargs.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/utils/version.py +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico.egg-info/dependency_links.txt +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico.egg-info/entry_points.txt +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico.egg-info/requires.txt +0 -0
- {tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico.egg-info/top_level.txt +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "0.3.0.dev261007"
|
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
# Copyright (c) 2026 Samsung Electronics Co., Ltd. All Rights Reserved
|
|
2
|
+
#
|
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
# you may not use this file except in compliance with the License.
|
|
5
|
+
# You may obtain a copy of the License at
|
|
6
|
+
#
|
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
#
|
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
|
+
# See the License for the specific language governing permissions and
|
|
13
|
+
# limitations under the License.
|
|
14
|
+
|
|
15
|
+
from typing import List, TYPE_CHECKING
|
|
16
|
+
|
|
17
|
+
if TYPE_CHECKING:
|
|
18
|
+
import torch.fx
|
|
19
|
+
|
|
20
|
+
import torch
|
|
21
|
+
from torch.export import ExportedProgram
|
|
22
|
+
|
|
23
|
+
from tico.passes.convert_gather_to_gather_nd import ConvertGatherToGatherNd
|
|
24
|
+
from tico.utils import logging
|
|
25
|
+
from tico.utils.errors import NotYetSupportedError
|
|
26
|
+
from tico.utils.graph import create_node
|
|
27
|
+
from tico.utils.passes import PassBase, PassResult
|
|
28
|
+
from tico.utils.trace_decorators import trace_graph_diff_on_pass
|
|
29
|
+
from tico.utils.utils import is_target_node, set_new_meta_val
|
|
30
|
+
from tico.utils.validate_args_kwargs import IndexArgs
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
@trace_graph_diff_on_pass
|
|
34
|
+
class LowerMultiIndexToGatherNd(PassBase):
|
|
35
|
+
"""
|
|
36
|
+
Lower ``aten.index.Tensor`` with several index tensors to
|
|
37
|
+
``circle_custom.gather_nd``.
|
|
38
|
+
|
|
39
|
+
PyTorch advanced indexing with ``k`` leading index tensors broadcasts the
|
|
40
|
+
indices to a common shape ``B`` and reads one coordinate per element::
|
|
41
|
+
|
|
42
|
+
out[b...] = input[i0[b...], i1[b...], ..., i(k-1)[b...], ...]
|
|
43
|
+
|
|
44
|
+
Circle ``GATHER_ND`` reads full coordinates from the last dimension of its
|
|
45
|
+
``indices`` input, so the lowering stacks the broadcast indices::
|
|
46
|
+
|
|
47
|
+
aten.index(input, [i0, ..., i(k-1)])
|
|
48
|
+
-> circle_custom.gather_nd(
|
|
49
|
+
input, cat([unsqueeze(expand(int32(i), B), -1) ...], -1))
|
|
50
|
+
|
|
51
|
+
The resulting ``indices`` tensor has shape ``B + [k]`` and the output keeps
|
|
52
|
+
PyTorch's shape ``B + input.shape[k:]``.
|
|
53
|
+
|
|
54
|
+
Preconditions
|
|
55
|
+
- The node is ``aten.index.Tensor`` whose ``indices`` list contains at
|
|
56
|
+
least two non-``None`` entries.
|
|
57
|
+
- The non-``None`` entries are FX nodes that occupy the leading positions
|
|
58
|
+
``0 .. k-1``; any remaining entries are ``None``. Advanced indices that
|
|
59
|
+
start after a sliced dimension or are separated by one are left
|
|
60
|
+
untouched (the serializer reports them as unsupported).
|
|
61
|
+
- Every index tensor has an int32 or int64 dtype and a static shape, and
|
|
62
|
+
the input has a static shape.
|
|
63
|
+
|
|
64
|
+
Transformation
|
|
65
|
+
- Index tensors are cast to int32 when needed, broadcast to the common
|
|
66
|
+
shape with ``aten.expand`` when their shape differs from it, unsqueezed
|
|
67
|
+
and concatenated along a new trailing dimension.
|
|
68
|
+
- The ``aten.index`` node is replaced by ``circle_custom.gather_nd`` with
|
|
69
|
+
recomputed metadata; its users are redirected.
|
|
70
|
+
|
|
71
|
+
Postconditions
|
|
72
|
+
No ``aten.index.Tensor`` with two or more leading index tensors remains.
|
|
73
|
+
|
|
74
|
+
Semantic assumptions
|
|
75
|
+
Index values are non-negative, as for the single-index ``GATHER``
|
|
76
|
+
lowering in the serializer. ``GATHER_ND`` does not wrap negative
|
|
77
|
+
coordinates.
|
|
78
|
+
"""
|
|
79
|
+
|
|
80
|
+
def __init__(self):
|
|
81
|
+
super().__init__()
|
|
82
|
+
|
|
83
|
+
def call(self, exported_program: ExportedProgram) -> PassResult:
|
|
84
|
+
logger = logging.getLogger(__name__)
|
|
85
|
+
|
|
86
|
+
graph_module = exported_program.graph_module
|
|
87
|
+
graph = graph_module.graph
|
|
88
|
+
modified = False
|
|
89
|
+
for node in list(graph.nodes):
|
|
90
|
+
if not is_target_node(node, torch.ops.aten.index.Tensor):
|
|
91
|
+
continue
|
|
92
|
+
|
|
93
|
+
args = IndexArgs(*node.args, **node.kwargs) # type: ignore[arg-type]
|
|
94
|
+
input_node = args.input
|
|
95
|
+
indices = list(args.indices)
|
|
96
|
+
|
|
97
|
+
index_nodes: List["torch.fx.Node"] = []
|
|
98
|
+
for position, index in enumerate(indices):
|
|
99
|
+
if index is None:
|
|
100
|
+
continue
|
|
101
|
+
if not isinstance(index, torch.fx.Node):
|
|
102
|
+
# Non-node indices are outside this lowering.
|
|
103
|
+
index_nodes = []
|
|
104
|
+
break
|
|
105
|
+
if position != len(index_nodes):
|
|
106
|
+
# Advanced indices must be leading and contiguous.
|
|
107
|
+
index_nodes = []
|
|
108
|
+
break
|
|
109
|
+
index_nodes.append(index)
|
|
110
|
+
|
|
111
|
+
if len(index_nodes) < 2:
|
|
112
|
+
continue
|
|
113
|
+
|
|
114
|
+
for index in index_nodes:
|
|
115
|
+
if index.meta["val"].dtype not in (torch.int32, torch.int64):
|
|
116
|
+
raise NotYetSupportedError(
|
|
117
|
+
"aten.index.Tensor indices must have int32 or int64 dtype "
|
|
118
|
+
"for GatherNd lowering."
|
|
119
|
+
)
|
|
120
|
+
|
|
121
|
+
get_static_shape = ConvertGatherToGatherNd._get_static_shape
|
|
122
|
+
get_static_shape(input_node, "aten.index input")
|
|
123
|
+
index_shapes = [
|
|
124
|
+
get_static_shape(index, "aten.index index") for index in index_nodes
|
|
125
|
+
]
|
|
126
|
+
broadcast_shape = list(torch.broadcast_shapes(*index_shapes))
|
|
127
|
+
|
|
128
|
+
logger.debug(
|
|
129
|
+
"%s: lowering aten.index with %d indices to circle_custom.gather_nd "
|
|
130
|
+
"(broadcast shape %r)",
|
|
131
|
+
node,
|
|
132
|
+
len(index_nodes),
|
|
133
|
+
broadcast_shape,
|
|
134
|
+
)
|
|
135
|
+
|
|
136
|
+
with graph.inserting_before(node):
|
|
137
|
+
coordinates = []
|
|
138
|
+
for index, index_shape in zip(index_nodes, index_shapes):
|
|
139
|
+
coordinate = ConvertGatherToGatherNd._cast_index_to_int32(
|
|
140
|
+
graph, index
|
|
141
|
+
)
|
|
142
|
+
if index_shape != broadcast_shape:
|
|
143
|
+
coordinate = create_node(
|
|
144
|
+
graph,
|
|
145
|
+
torch.ops.aten.expand.default,
|
|
146
|
+
args=(coordinate, broadcast_shape),
|
|
147
|
+
origin=node,
|
|
148
|
+
)
|
|
149
|
+
set_new_meta_val(coordinate)
|
|
150
|
+
unsqueezed = create_node(
|
|
151
|
+
graph,
|
|
152
|
+
torch.ops.aten.unsqueeze.default,
|
|
153
|
+
args=(coordinate, -1),
|
|
154
|
+
origin=node,
|
|
155
|
+
)
|
|
156
|
+
set_new_meta_val(unsqueezed)
|
|
157
|
+
coordinates.append(unsqueezed)
|
|
158
|
+
|
|
159
|
+
full_indices = create_node(
|
|
160
|
+
graph,
|
|
161
|
+
torch.ops.aten.cat.default,
|
|
162
|
+
args=(coordinates, -1),
|
|
163
|
+
origin=node,
|
|
164
|
+
)
|
|
165
|
+
set_new_meta_val(full_indices)
|
|
166
|
+
|
|
167
|
+
gather_nd = create_node(
|
|
168
|
+
graph,
|
|
169
|
+
torch.ops.circle_custom.gather_nd,
|
|
170
|
+
args=(input_node, full_indices),
|
|
171
|
+
origin=node,
|
|
172
|
+
)
|
|
173
|
+
set_new_meta_val(gather_nd)
|
|
174
|
+
|
|
175
|
+
assert gather_nd.meta["val"].shape == node.meta["val"].shape, (
|
|
176
|
+
f"{node.name}: GatherNd output shape {gather_nd.meta['val'].shape} "
|
|
177
|
+
f"differs from aten.index output shape {node.meta['val'].shape}"
|
|
178
|
+
)
|
|
179
|
+
node.replace_all_uses_with(gather_nd, propagate_meta=False)
|
|
180
|
+
modified = True
|
|
181
|
+
logger.debug("%s is replaced with %s", node.name, gather_nd.name)
|
|
182
|
+
|
|
183
|
+
if modified:
|
|
184
|
+
graph.eliminate_dead_code()
|
|
185
|
+
graph.lint()
|
|
186
|
+
graph_module.recompile()
|
|
187
|
+
|
|
188
|
+
return PassResult(modified)
|
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
# Copyright (c) 2026 Samsung Electronics Co., Ltd. All Rights Reserved
|
|
2
|
+
#
|
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
# you may not use this file except in compliance with the License.
|
|
5
|
+
# You may obtain a copy of the License at
|
|
6
|
+
#
|
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
#
|
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
|
+
# See the License for the specific language governing permissions and
|
|
13
|
+
# limitations under the License.
|
|
14
|
+
|
|
15
|
+
from typing import List, TYPE_CHECKING
|
|
16
|
+
|
|
17
|
+
if TYPE_CHECKING:
|
|
18
|
+
import torch.fx
|
|
19
|
+
|
|
20
|
+
import torch
|
|
21
|
+
from torch.export import ExportedProgram
|
|
22
|
+
|
|
23
|
+
from tico.passes import ops
|
|
24
|
+
from tico.passes.remove_unused_placeholder import remove_unused_constant_placeholders
|
|
25
|
+
from tico.serialize.circle_mapping import extract_shape
|
|
26
|
+
from tico.utils import logging
|
|
27
|
+
from tico.utils.passes import PassBase, PassResult
|
|
28
|
+
from tico.utils.trace_decorators import (
|
|
29
|
+
trace_const_diff_on_pass,
|
|
30
|
+
trace_graph_diff_on_pass,
|
|
31
|
+
)
|
|
32
|
+
from tico.utils.utils import is_target_node
|
|
33
|
+
from tico.utils.validate_args_kwargs import CatArgs
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
def _is_legacy_empty_tensor(node: "torch.fx.Node") -> bool:
|
|
37
|
+
"""
|
|
38
|
+
Return whether ``node`` is a rank-1 tensor with a static size of zero.
|
|
39
|
+
|
|
40
|
+
``torch.cat`` skips such tensors even when the other inputs have a different
|
|
41
|
+
rank (a legacy behavior kept for backward compatibility).
|
|
42
|
+
"""
|
|
43
|
+
val = node.meta.get("val")
|
|
44
|
+
if not isinstance(val, torch.Tensor):
|
|
45
|
+
return False
|
|
46
|
+
if val.dim() != 1:
|
|
47
|
+
return False
|
|
48
|
+
size = val.shape[0]
|
|
49
|
+
# A symbolic size is a SymInt, not an int, and is never treated as empty.
|
|
50
|
+
if not isinstance(size, int) or size != 0:
|
|
51
|
+
return False
|
|
52
|
+
return True
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
def _promoted_dtype(nodes: List["torch.fx.Node"]) -> torch.dtype:
|
|
56
|
+
"""Return the dtype ``torch.cat`` produces for the given tensor inputs."""
|
|
57
|
+
dtypes = [node.meta["val"].dtype for node in nodes]
|
|
58
|
+
result = dtypes[0]
|
|
59
|
+
for dtype in dtypes[1:]:
|
|
60
|
+
result = torch.promote_types(result, dtype)
|
|
61
|
+
return result
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
@trace_graph_diff_on_pass
|
|
65
|
+
@trace_const_diff_on_pass
|
|
66
|
+
class RemoveEmptyCatInputs(PassBase):
|
|
67
|
+
"""
|
|
68
|
+
Remove rank-1 empty inputs from ``aten.cat`` and drop the ``cat`` when a single
|
|
69
|
+
input remains.
|
|
70
|
+
|
|
71
|
+
PyTorch lets ``torch.cat`` accept a 1-D tensor of shape ``[0]`` next to inputs of
|
|
72
|
+
any other rank and simply ignores it. Hugging Face ``DynamicCache`` relies on
|
|
73
|
+
this: the first ``update()`` concatenates ``torch.tensor([])`` with the new key
|
|
74
|
+
and value states. Circle ``CONCATENATION`` requires every input to have the same
|
|
75
|
+
rank, so the exported operator is rejected by Circle consumers.
|
|
76
|
+
|
|
77
|
+
Preconditions
|
|
78
|
+
- The node is ``aten.cat``.
|
|
79
|
+
- At least one input has a tensor ``meta["val"]`` of rank 1 with a static
|
|
80
|
+
size of zero.
|
|
81
|
+
- At least one input does not satisfy the previous bullet.
|
|
82
|
+
- The dtype promoted from the remaining inputs equals the ``cat`` output
|
|
83
|
+
dtype, so the removed inputs did not take part in type promotion.
|
|
84
|
+
|
|
85
|
+
Transformation
|
|
86
|
+
- Matching inputs are removed from the ``cat`` input list.
|
|
87
|
+
- When exactly one input remains, all uses of the ``cat`` are redirected to
|
|
88
|
+
that input; its shape and dtype equal the ``cat`` output by construction.
|
|
89
|
+
- Lifted constant placeholders that only fed removed inputs are deleted from
|
|
90
|
+
the graph, the ``ExportedProgram`` constants, and the graph signature.
|
|
91
|
+
User input placeholders are never removed.
|
|
92
|
+
|
|
93
|
+
Postconditions
|
|
94
|
+
No ``aten.cat`` keeps a rank-1 zero-size input of the output dtype.
|
|
95
|
+
|
|
96
|
+
Semantic assumptions
|
|
97
|
+
A rank-1 zero-size tensor contributes no elements along any concatenation
|
|
98
|
+
dimension, so removing it preserves the value, shape, and dtype of the
|
|
99
|
+
result as long as it does not change type promotion. Empty inputs that
|
|
100
|
+
widen the result dtype, inputs with symbolic sizes, and zero-size inputs
|
|
101
|
+
with the same rank as the output are left untouched.
|
|
102
|
+
"""
|
|
103
|
+
|
|
104
|
+
def __init__(self):
|
|
105
|
+
super().__init__()
|
|
106
|
+
|
|
107
|
+
def call(self, exported_program: ExportedProgram) -> PassResult:
|
|
108
|
+
logger = logging.getLogger(__name__)
|
|
109
|
+
|
|
110
|
+
graph_module = exported_program.graph_module
|
|
111
|
+
graph = graph_module.graph
|
|
112
|
+
modified = False
|
|
113
|
+
placeholder_candidates: List["torch.fx.Node"] = []
|
|
114
|
+
for cat in graph.nodes:
|
|
115
|
+
if not is_target_node(cat, ops.aten.cat):
|
|
116
|
+
continue
|
|
117
|
+
|
|
118
|
+
cat_val = cat.meta.get("val")
|
|
119
|
+
if not isinstance(cat_val, torch.Tensor):
|
|
120
|
+
continue
|
|
121
|
+
|
|
122
|
+
args = CatArgs(*cat.args, **cat.kwargs) # type: ignore[arg-type]
|
|
123
|
+
inputs = args.tensors
|
|
124
|
+
dim = args.dim
|
|
125
|
+
|
|
126
|
+
kept = [t for t in inputs if not _is_legacy_empty_tensor(t)]
|
|
127
|
+
if len(kept) == len(inputs) or len(kept) == 0:
|
|
128
|
+
continue
|
|
129
|
+
if any(not isinstance(t.meta.get("val"), torch.Tensor) for t in kept):
|
|
130
|
+
continue
|
|
131
|
+
# Dropping an input must not change the promoted result dtype.
|
|
132
|
+
if _promoted_dtype(kept) != cat_val.dtype:
|
|
133
|
+
continue
|
|
134
|
+
|
|
135
|
+
removed = [t for t in inputs if t not in kept]
|
|
136
|
+
for node in removed:
|
|
137
|
+
if node.op == "placeholder":
|
|
138
|
+
placeholder_candidates.append(node)
|
|
139
|
+
placeholder_candidates.extend(
|
|
140
|
+
n for n in node.all_input_nodes if n.op == "placeholder"
|
|
141
|
+
)
|
|
142
|
+
|
|
143
|
+
if len(kept) == 1:
|
|
144
|
+
remaining = kept[0]
|
|
145
|
+
assert extract_shape(remaining) == extract_shape(cat), (
|
|
146
|
+
f"{cat.name}: shape mismatch after removing empty inputs "
|
|
147
|
+
f"({extract_shape(remaining)} vs {extract_shape(cat)})"
|
|
148
|
+
)
|
|
149
|
+
remaining_val = remaining.meta.get("val")
|
|
150
|
+
assert (
|
|
151
|
+
isinstance(remaining_val, torch.Tensor)
|
|
152
|
+
and remaining_val.dtype == cat_val.dtype
|
|
153
|
+
)
|
|
154
|
+
cat.replace_all_uses_with(remaining, propagate_meta=False)
|
|
155
|
+
logger.debug(
|
|
156
|
+
f"{cat.name} is replaced with {remaining.name}; "
|
|
157
|
+
f"empty inputs removed: {[n.name for n in removed]}"
|
|
158
|
+
)
|
|
159
|
+
else:
|
|
160
|
+
cat.args = (kept, dim)
|
|
161
|
+
cat.kwargs = {}
|
|
162
|
+
logger.debug(
|
|
163
|
+
f"Empty inputs removed from {cat.name}: {[n.name for n in removed]}"
|
|
164
|
+
)
|
|
165
|
+
|
|
166
|
+
modified = True
|
|
167
|
+
|
|
168
|
+
if not modified:
|
|
169
|
+
return PassResult(False)
|
|
170
|
+
|
|
171
|
+
graph.eliminate_dead_code()
|
|
172
|
+
graph.lint()
|
|
173
|
+
graph_module.recompile()
|
|
174
|
+
|
|
175
|
+
removed_placeholders = remove_unused_constant_placeholders(
|
|
176
|
+
exported_program, candidates=placeholder_candidates
|
|
177
|
+
)
|
|
178
|
+
if removed_placeholders:
|
|
179
|
+
logger.debug(
|
|
180
|
+
f"Unused constant placeholders are removed: {removed_placeholders}"
|
|
181
|
+
)
|
|
182
|
+
|
|
183
|
+
return PassResult(modified)
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
# See the License for the specific language governing permissions and
|
|
13
13
|
# limitations under the License.
|
|
14
14
|
|
|
15
|
-
from typing import TYPE_CHECKING
|
|
15
|
+
from typing import Iterable, List, Optional, TYPE_CHECKING
|
|
16
16
|
|
|
17
17
|
if TYPE_CHECKING:
|
|
18
18
|
import torch.fx
|
|
@@ -75,6 +75,71 @@ def _remove_constant_placeholder(
|
|
|
75
75
|
exported_program.graph.erase_node(node)
|
|
76
76
|
|
|
77
77
|
|
|
78
|
+
def remove_unused_constant_placeholders(
|
|
79
|
+
exported_program: ExportedProgram,
|
|
80
|
+
candidates: Optional[Iterable["torch.fx.Node"]] = None,
|
|
81
|
+
) -> List[str]:
|
|
82
|
+
"""
|
|
83
|
+
Remove unused constant placeholders and update the graph signature.
|
|
84
|
+
|
|
85
|
+
FX dead-code elimination does not remove placeholder nodes even when they have
|
|
86
|
+
no users. This helper removes placeholders that correspond to parameters,
|
|
87
|
+
buffers, or lifted tensor constants and have no users, then rebuilds the
|
|
88
|
+
ExportedProgram input specs so that they match the remaining placeholders.
|
|
89
|
+
|
|
90
|
+
Parameters
|
|
91
|
+
----------
|
|
92
|
+
exported_program
|
|
93
|
+
The program whose graph and signature are updated in place.
|
|
94
|
+
candidates
|
|
95
|
+
Placeholder nodes to consider. When ``None``, every placeholder of the graph
|
|
96
|
+
is considered. Nodes that are not constant placeholders or that still have
|
|
97
|
+
users are ignored.
|
|
98
|
+
|
|
99
|
+
Returns
|
|
100
|
+
-------
|
|
101
|
+
List[str]
|
|
102
|
+
Names of the removed placeholders, in graph order. Empty when nothing was
|
|
103
|
+
removed; the graph is left untouched in that case.
|
|
104
|
+
|
|
105
|
+
Runtime user input placeholders are never removed.
|
|
106
|
+
"""
|
|
107
|
+
|
|
108
|
+
graph_module = exported_program.graph_module
|
|
109
|
+
graph: torch.fx.Graph = graph_module.graph
|
|
110
|
+
|
|
111
|
+
candidate_set = None if candidates is None else set(candidates)
|
|
112
|
+
unused_placeholders = [
|
|
113
|
+
node
|
|
114
|
+
for node in graph.nodes
|
|
115
|
+
if (candidate_set is None or node in candidate_set)
|
|
116
|
+
and _is_constant_placeholder(exported_program, node)
|
|
117
|
+
and len(node.users) == 0
|
|
118
|
+
]
|
|
119
|
+
|
|
120
|
+
if not unused_placeholders:
|
|
121
|
+
return []
|
|
122
|
+
|
|
123
|
+
removed_names = [node.name for node in unused_placeholders]
|
|
124
|
+
|
|
125
|
+
for node in unused_placeholders:
|
|
126
|
+
_remove_constant_placeholder(exported_program, node)
|
|
127
|
+
|
|
128
|
+
existing_name_to_spec = {
|
|
129
|
+
spec.arg.name: spec for spec in exported_program.graph_signature.input_specs
|
|
130
|
+
}
|
|
131
|
+
exported_program.graph_signature.input_specs = [
|
|
132
|
+
existing_name_to_spec[node.name]
|
|
133
|
+
for node in graph.nodes
|
|
134
|
+
if node.op == "placeholder"
|
|
135
|
+
]
|
|
136
|
+
|
|
137
|
+
graph.lint()
|
|
138
|
+
graph_module.recompile()
|
|
139
|
+
|
|
140
|
+
return removed_names
|
|
141
|
+
|
|
142
|
+
|
|
78
143
|
@trace_graph_diff_on_pass
|
|
79
144
|
@trace_const_diff_on_pass
|
|
80
145
|
class RemoveUnusedPlaceholder(PassBase):
|
|
@@ -95,36 +160,10 @@ class RemoveUnusedPlaceholder(PassBase):
|
|
|
95
160
|
def call(self, exported_program: ExportedProgram) -> PassResult:
|
|
96
161
|
logger = logging.getLogger(__name__)
|
|
97
162
|
|
|
98
|
-
|
|
99
|
-
graph: torch.fx.Graph = graph_module.graph
|
|
100
|
-
|
|
101
|
-
unused_placeholders = [
|
|
102
|
-
node
|
|
103
|
-
for node in graph.nodes
|
|
104
|
-
if _is_constant_placeholder(exported_program, node) and len(node.users) == 0
|
|
105
|
-
]
|
|
106
|
-
|
|
107
|
-
if not unused_placeholders:
|
|
108
|
-
return PassResult(False)
|
|
109
|
-
|
|
110
|
-
removed_names = [node.name for node in unused_placeholders]
|
|
111
|
-
|
|
112
|
-
for node in unused_placeholders:
|
|
113
|
-
_remove_constant_placeholder(exported_program, node)
|
|
114
|
-
|
|
115
|
-
existing_name_to_spec = {
|
|
116
|
-
spec.arg.name: spec for spec in exported_program.graph_signature.input_specs
|
|
117
|
-
}
|
|
118
|
-
exported_program.graph_signature.input_specs = [
|
|
119
|
-
existing_name_to_spec[node.name]
|
|
120
|
-
for node in graph.nodes
|
|
121
|
-
if node.op == "placeholder"
|
|
122
|
-
]
|
|
123
|
-
|
|
124
|
-
graph.lint()
|
|
125
|
-
graph_module.recompile()
|
|
163
|
+
removed_names = remove_unused_constant_placeholders(exported_program)
|
|
126
164
|
|
|
127
|
-
|
|
165
|
+
if removed_names:
|
|
166
|
+
logger.debug(f"Unused constant placeholders are removed: {removed_names}")
|
|
128
167
|
|
|
129
168
|
# Run only once.
|
|
130
169
|
return PassResult(False)
|
{tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/qwen3_vl_gptq/gptq.py
RENAMED
|
@@ -274,6 +274,7 @@ class GPTQ:
|
|
|
274
274
|
normalize_H: bool = True,
|
|
275
275
|
hessian_dtype: torch.dtype = torch.float32,
|
|
276
276
|
inp_dtype: torch.dtype = torch.float32,
|
|
277
|
+
gptq_v2_alpha: float = 0.25,
|
|
277
278
|
):
|
|
278
279
|
"""
|
|
279
280
|
Initialize GPTQ state for a single layer.
|
|
@@ -291,12 +292,16 @@ class GPTQ:
|
|
|
291
292
|
the GPTQv2 dXXT cross-term (dX @ inp.T). Hessian storage and
|
|
292
293
|
factorization follow hessian_dtype. Defaults to torch.float32
|
|
293
294
|
it is faster and uses less memory.
|
|
295
|
+
gptq_v2_alpha: Scaling factor for the GPTQv2 P-correction matrix.
|
|
296
|
+
A value of 0 disables the correction (standard GPTQ). Values
|
|
297
|
+
around 0.25 provide the best empirical results.
|
|
294
298
|
"""
|
|
295
299
|
self.layer = layer
|
|
296
300
|
self.dev = self.layer.weight.device
|
|
297
301
|
self.normalize_H = normalize_H
|
|
298
302
|
self.hessian_dtype = hessian_dtype
|
|
299
303
|
self.inp_dtype = inp_dtype
|
|
304
|
+
self.gptq_v2_alpha = gptq_v2_alpha
|
|
300
305
|
|
|
301
306
|
w = layer.weight.data.clone()
|
|
302
307
|
if isinstance(layer, (nn.Conv1d, nn.Conv2d, nn.Conv3d)):
|
|
@@ -495,7 +500,6 @@ class GPTQ:
|
|
|
495
500
|
actorder: bool = False,
|
|
496
501
|
static_groups: bool = False,
|
|
497
502
|
verbose: bool = False,
|
|
498
|
-
alpha: float = 0.25,
|
|
499
503
|
) -> None:
|
|
500
504
|
"""
|
|
501
505
|
Run blockwise GPTQ quantization on the layer weights.
|
|
@@ -584,7 +588,7 @@ class GPTQ:
|
|
|
584
588
|
P = None
|
|
585
589
|
if self.dXXT is not None:
|
|
586
590
|
dXXT = self.dXXT.to(hinv.dtype)
|
|
587
|
-
P =
|
|
591
|
+
P = self.gptq_v2_alpha * ((dXXT @ hinv.T).triu(diagonal=1)) @ hinv
|
|
588
592
|
|
|
589
593
|
# Downcast to float32 for the weight-update loop (w is float32);
|
|
590
594
|
# the hessian_dtype precision of H/dXXT and of the Cholesky
|
{tico-0.3.0.dev261001 → tico-0.3.0.dev261007}/tico/quantization/algorithm/qwen3_vl_gptq/quantizer.py
RENAMED
|
@@ -1684,6 +1684,7 @@ class Qwen3VLGPTQQuantizer(BaseQuantizer):
|
|
|
1684
1684
|
normalize_H=gptq_conf.normalize_H,
|
|
1685
1685
|
hessian_dtype=gptq_conf.hessian_dtype,
|
|
1686
1686
|
inp_dtype=gptq_conf.inp_dtype,
|
|
1687
|
+
gptq_v2_alpha=gptq_conf.gptq_v2_alpha,
|
|
1687
1688
|
)
|
|
1688
1689
|
|
|
1689
1690
|
full_name = module_name.get(submodule, local_name)
|
|
@@ -1781,7 +1782,6 @@ class Qwen3VLGPTQQuantizer(BaseQuantizer):
|
|
|
1781
1782
|
actorder=gptq_conf.actorder,
|
|
1782
1783
|
static_groups=gptq_conf.static_groups,
|
|
1783
1784
|
verbose=gptq_conf.verbose,
|
|
1784
|
-
alpha=gptq_conf.gptq_v2_alpha,
|
|
1785
1785
|
)
|
|
1786
1786
|
|
|
1787
1787
|
full_name = module_name.get(submodule, local_name)
|