Skip to content

Commit

Permalink
Enable ORT model support to INC quantizer (#436)
Browse files Browse the repository at this point in the history
* add ort model support to INC quantizer

* add test

* fix format

* refactorization modeling
  • Loading branch information
echarlaix authored Oct 13, 2023
1 parent 1981499 commit b14059f
Show file tree
Hide file tree
Showing 10 changed files with 379 additions and 462 deletions.
14 changes: 7 additions & 7 deletions docs/source/reference_inc.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -19,32 +19,32 @@ specific language governing permissions and limitations under the License.

## INCModel

[[autodoc]] neural_compressor.quantization.INCModel
[[autodoc]] neural_compressor.modeling_base.INCModel

## INCModelForSequenceClassification

[[autodoc]] neural_compressor.quantization.INCModelForSequenceClassification
[[autodoc]] neural_compressor.modeling_base.INCModelForSequenceClassification

## INCModelForQuestionAnswering

[[autodoc]] neural_compressor.quantization.INCModelForQuestionAnswering
[[autodoc]] neural_compressor.modeling_base.INCModelForQuestionAnswering

## INCModelForTokenClassification

[[autodoc]] neural_compressor.quantization.INCModelForTokenClassification
[[autodoc]] neural_compressor.modeling_base.INCModelForTokenClassification

## INCModelForMultipleChoice

[[autodoc]] neural_compressor.quantization.INCModelForMultipleChoice
[[autodoc]] neural_compressor.modeling_base.INCModelForMultipleChoice

## INCModelForMaskedLM

[[autodoc]] neural_compressor.quantization.INCModelForMaskedLM
[[autodoc]] neural_compressor.modeling_base.INCModelForMaskedLM

## INCModelForCausalLM

[[autodoc]] neural_compressor.modeling_decoder.INCModelForCausalLM

## INCModelForSeq2SeqLM

[[autodoc]] neural_compressor.quantization.INCModelForSeq2SeqLM
[[autodoc]] neural_compressor.modeling_base.INCModelForSeq2SeqLM
7 changes: 3 additions & 4 deletions optimum/intel/neural_compressor/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@

from ..utils.import_utils import is_diffusers_available
from .configuration import INCConfig
from .modeling_decoder import INCModelForCausalLM
from .quantization import (
from .modeling_base import (
INCModel,
INCModelForMaskedLM,
INCModelForMultipleChoice,
Expand All @@ -24,9 +23,9 @@
INCModelForSequenceClassification,
INCModelForTokenClassification,
INCModelForVision2Seq,
INCQuantizationMode,
INCQuantizer,
)
from .modeling_decoder import INCModelForCausalLM
from .quantization import INCQuantizationMode, INCQuantizer
from .trainer import INCTrainer
from .trainer_seq2seq import INCSeq2SeqTrainer

Expand Down
Loading

0 comments on commit b14059f

Please sign in to comment.