vllm.model_executor.models.aria ¶
Classes:
-
AriaForConditionalGeneration–Aria model for conditional generation tasks.
-
AriaImagePixelInputs–Dimensions:
-
AriaProjector–A projection module with one cross attention layer and one FFN layer, which
-
AriaTextDecoderLayer–Custom Decoder Layer for the AriaMoE model which modifies the standard
-
AriaTextMoELayer–Mixture of Experts (MoE) Layer for the AriaMoE model.
-
AriaTextModel–Custom LlamaModel for the AriaMoE model which modifies the standard
AriaForConditionalGeneration ¶
Bases: Module, SupportsMultiModal
Aria model for conditional generation tasks.
This model combines a vision tower, a multi-modal projector, and a language model to perform tasks that involve both image and text inputs.
Source code in vllm/model_executor/models/aria.py
484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 | |
AriaImagePixelInputs ¶
Bases: TensorSchema
Dimensions
- b: Batch size
- n: Number of images
- c: Number of channels
- h: Height of each image
- w: Width of each image
Source code in vllm/model_executor/models/aria.py
AriaProjector ¶
Bases: Module
A projection module with one cross attention layer and one FFN layer, which projects ViT's outputs into MoE's inputs.
Parameters:
-
(config¶AriaConfig) –AriaConfig containing projector configuration parameters.
Outputs
A tensor with the shape of (batch_size, query_number, output_dim)
Source code in vllm/model_executor/models/aria.py
AriaTextDecoderLayer ¶
Bases: LlamaDecoderLayer
Custom Decoder Layer for the AriaMoE model which modifies the standard LlamaDecoderLayer by replacing the traditional MLP with a Mixture of Experts (MoE) Layer.
Source code in vllm/model_executor/models/aria.py
AriaTextMoELayer ¶
Bases: Module
Mixture of Experts (MoE) Layer for the AriaMoE model.
This layer implements the MoE mechanism, which routes input tokens to different experts based on a routing algorithm, processes them through the experts, and then combines the outputs.
Methods:
-
forward–Forward pass of the MoE Layer.
Source code in vllm/model_executor/models/aria.py
forward(hidden_states) ¶
Forward pass of the MoE Layer.
Parameters:
Returns:
-
Tensor–torch.Tensor: Output tensor after passing through the MoE layer.
Source code in vllm/model_executor/models/aria.py
AriaTextModel ¶
Bases: LlamaModel, SupportsQuant
Custom LlamaModel for the AriaMoE model which modifies the standard LlamaModel by replacing the LlamaDecoderLayer with MoEDecoderLayer.