| 616 | } |
| 617 | |
| 618 | shape module::get_parameter_shape(std::string name) const |
| 619 | { |
| 620 | auto ins = std::find_if( |
| 621 | impl->instructions.begin(), impl->instructions.end(), [&](const instruction& x) { |
| 622 | if(x.name() == "@param") |
| 623 | { |
| 624 | return any_cast<builtin::param>(x.get_operator()).parameter == name; |
| 625 | } |
| 626 | else |
| 627 | { |
| 628 | return false; |
| 629 | } |
| 630 | }); |
| 631 | if(ins != this->end()) |
| 632 | return ins->get_shape(); |
| 633 | else |
| 634 | return {}; |
| 635 | } |
| 636 | |
| 637 | std::vector<std::string> module::get_parameter_names() const |
| 638 | { |