Conversation
Signed-off-by: Justin Chu <justinchuby@users.noreply.github.com>
Signed-off-by: Justin Chu <justinchuby@users.noreply.github.com>
Signed-off-by: Justin Chu <justinchuby@users.noreply.github.com>
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2457 +/- ##
===========================================
- Coverage 70.46% 10.84% -59.62%
===========================================
Files 224 214 -10
Lines 26572 25011 -1561
Branches 2637 2530 -107
===========================================
- Hits 18723 2712 -16011
- Misses 6928 22288 +15360
+ Partials 921 11 -910 ☔ View full report in Codecov by Sentry. |
| op_signature, args, kwargs | ||
| ) | ||
| args = [self._translate_opt_expr(x) for x in args] | ||
| onnx_inputs = [self._translate_opt_expr(x) for x in inputs] |
Check warning
Code scanning / lintrunner
PYLINT/W0612 Warning
| op_signature, args, kwargs | ||
| ) | ||
| args = [self._translate_opt_expr(x) for x in args] | ||
| onnx_inputs = [self._translate_opt_expr(x) for x in inputs] |
Check warning
Code scanning / lintrunner
RUFF/F841 Warning
| elif kwargs.get(param.name) is not None: | ||
| attribute = kwargs[param.name] # type: ignore[assignment] | ||
| else: | ||
| if param.required: |
Check notice
Code scanning / lintrunner
PYLINT/R1720 Note
| from __future__ import annotations | ||
|
|
||
| import collections.abc | ||
| import copy |
Check warning
Code scanning / lintrunner
PYLINT/W0611 Warning
| from __future__ import annotations | ||
|
|
||
| import collections.abc | ||
| import copy |
Check warning
Code scanning / lintrunner
RUFF/F401 Warning
| top_level_ast = ast.parse(source) | ||
| f_ast = top_level_ast.body[0] | ||
| cvt = converter.Converter( | ||
| cvt = _converter.Converter( |
Check failure
Code scanning / lintrunner
PYLINT/E1120 Error
| # TODO: cleanup Converter interface/API, separating checker from | ||
| # converter | ||
| convert = converter.Converter( | ||
| convert = _converter.Converter( |
Check failure
Code scanning / lintrunner
PYLINT/E1120 Error
| global_names = module.__dict__.copy() | ||
| global_names.update(closure.nonlocals) | ||
| converter = converter_module.Converter( | ||
| converter = _converter.Converter( |
Check failure
Code scanning / lintrunner
PYLINT/E1120 Error
Signed-off-by: Justin Chu <justinchuby@users.noreply.github.com>
Signed-off-by: Justin Chu <justinchuby@users.noreply.github.com>
Signed-off-by: Justin Chu <justinchuby@users.noreply.github.com>
Signed-off-by: Justin Chu <justinchuby@users.noreply.github.com>
| converter_: _converter.Converter, | ||
| op_schema: Optional[OpSchema], | ||
| args: Sequence[Optional[converter.Variable]], | ||
| args: Sequence[Optional[_converter.Variable]], |
Check failure
Code scanning / lintrunner
MYPY/name-defined Error
| """ | ||
|
|
||
| def get_type_info(x: Optional[converter.Variable]) -> Optional[converter.Variable]: | ||
| def get_type_info(x: Optional[_converter.Variable]) -> Optional[_converter.Variable]: |
Check failure
Code scanning / lintrunner
MYPY/name-defined Error
|
|
||
| def cast_like( | ||
| x: Optional[converter.Variable], y: Optional[converter.Variable] | ||
| x: Optional[_converter.Variable], y: Optional[_converter.Variable] |
Check failure
Code scanning / lintrunner
MYPY/name-defined Error
| tensor = autocast.pyvalue_to_onnx_tensor(ovar, pyvalue) | ||
| except ValueError as e: | ||
| tensor = ir.tensor(pyvalue, name=var_name) | ||
| except Exception as e: |
Check warning
Code scanning / lintrunner
PYLINT/W0718 Warning
| preferred_name = f"return_val{suffix}" | ||
| return_var = self._translate_expr(exp, preferred_name).name | ||
| val = self._lookup(return_var, self._source_of(exp), False) | ||
| assert type(val) is values.Dynamic |
Check notice
Code scanning / lintrunner
PYLINT/C0123 Note
| return tuple(reversed(inputs_reversed)), named_attrs | ||
|
|
||
|
|
||
| def _to_onnx_ref_attr(val: values.AttrRef, info: sourceinfo.SourceInfo | None) -> ir.Attr: |
Check failure
Code scanning / lintrunner
MYPY/name-defined Error
|
|
||
| from onnxscript import converter as converter_module | ||
| from onnxscript import irbuilder, sourceinfo, type_annotation | ||
| from onnxscript import _converter, irbuilder, sourceinfo, type_annotation |
Check warning
Code scanning / lintrunner
PYLINT/W0611 Warning
|
|
||
| from onnxscript import converter as converter_module | ||
| from onnxscript import irbuilder, sourceinfo, type_annotation | ||
| from onnxscript import _converter, irbuilder, sourceinfo, type_annotation |
Check warning
Code scanning / lintrunner
RUFF/F401 Warning
Signed-off-by: Justin Chu <justinchuby@users.noreply.github.com>
Signed-off-by: Justin Chu <justinchuby@users.noreply.github.com>
Signed-off-by: Justin Chu <justinchuby@users.noreply.github.com>
| Sequence, | ||
| Tuple, | ||
| Union, | ||
| _GenericAlias |
Check warning
Code scanning / lintrunner
RUFF/F401 Warning
| """ | ||
| self.name = name | ||
| self.is_castable = castable | ||
| class DynamicKind(IntFlag): |
Check failure
Code scanning / lintrunner
PYLINT/E0602 Error
| """ | ||
| self.name = name | ||
| self.is_castable = castable | ||
| class DynamicKind(IntFlag): |
Check failure
Code scanning / lintrunner
RUFF/F821 Error
| """ | ||
| self.name = name | ||
| self.is_castable = castable | ||
| class DynamicKind(IntFlag): |
Check failure
Code scanning / lintrunner
MYPY/name-defined Error
| self._converter = converter | ||
|
|
||
| def get_or_create_value( | ||
| self, var: str, info: sourceinfo.SourceInfo |
Check warning
Code scanning / lintrunner
PYLINT/W0613 Warning
|
Replaced by #2665 |
Signed-off-by: Justin Chu justinchuby@users.noreply.github.com