ai-edge-torch-nightly 0.6.0.dev20250821__py3-none-any.whl → 0.6.0.dev20250822__py3-none-any.whl

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.
@@ -124,9 +124,11 @@ class LoweringInterpreter(torch.fx.Interpreter):
124
124
  def run_node(self, node: torch.fx.Node):
125
125
  loc = self._build_loc(node)
126
126
  with loc:
127
- self.lctx = self.lctx.replace(ir_location=loc, node=node)
127
+ self.lctx.ir_location = loc
128
+ self.lctx.node = node
128
129
  res = super().run_node(node)
129
- self.lctx = self.lctx.replace(ir_location=None, node=None)
130
+ self.lctx.ir_location = None
131
+ self.lctx.node = None
130
132
  return res
131
133
 
132
134
  def call_function(self, target, args, kwargs):
@@ -63,7 +63,10 @@ def inline(
63
63
  while True:
64
64
  is_changed = False
65
65
  for op in block.operations:
66
- if op.OPERATION_NAME != func.CallOp.OPERATION_NAME:
66
+ if (
67
+ not hasattr(op, "OPERATION_NAME")
68
+ or op.OPERATION_NAME != func.CallOp.OPERATION_NAME
69
+ ):
67
70
  continue
68
71
 
69
72
  call_op = cast(func.CallOp, op)
@@ -96,7 +99,10 @@ def clone_func_body_ops(func_op: func.FuncOp, ir_inputs: Sequence[ir.Value]):
96
99
 
97
100
  for op in list(func_op.entry_block.operations):
98
101
  cloned_operands = [value_mapping[val] for val in op.operands]
99
- if op.OPERATION_NAME == func.ReturnOp.OPERATION_NAME:
102
+ if (
103
+ hasattr(op, "OPERATION_NAME")
104
+ and op.OPERATION_NAME == func.ReturnOp.OPERATION_NAME
105
+ ):
100
106
  return cloned_operands
101
107
 
102
108
  cloned = cast(ir.Operation, op.operation.clone())
@@ -37,6 +37,3 @@ class LoweringContext:
37
37
  def loc(self):
38
38
  """Shortcut for ir_location."""
39
39
  return self.ir_location
40
-
41
- def replace(self, **kwargs):
42
- return dataclasses.replace(self, **kwargs)
ai_edge_torch/version.py CHANGED
@@ -15,4 +15,4 @@
15
15
 
16
16
  # The next version of ai-edge-torch.
17
17
  # The minor version code should be bumped after every release.
18
- __version__ = "0.6.0.dev20250821"
18
+ __version__ = "0.6.0.dev20250822"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: ai-edge-torch-nightly
3
- Version: 0.6.0.dev20250821
3
+ Version: 0.6.0.dev20250822
4
4
  Summary: Supporting PyTorch models with the Google AI Edge TFLite runtime.
5
5
  Home-page: https://github.com/google-ai-edge/ai-edge-torch
6
6
  Keywords: On-Device ML,AI,Google,TFLite,PyTorch,LLMs,GenAI
@@ -2,7 +2,7 @@ ai_edge_torch/__init__.py,sha256=lemyLCNoGYRnJsmDuGZu7qOqLbLqG6CGDFtu3ue1syU,129
2
2
  ai_edge_torch/_config.py,sha256=AiqhbcheF7j_ozIGDLC89k1we95aVgFDa-tR6h7UI0s,2529
3
3
  ai_edge_torch/conftest.py,sha256=r0GTrhMRhlmOGrrkvumHN8hkmyug6WvF60vWq8wRIBI,758
4
4
  ai_edge_torch/model.py,sha256=A7loFu8jE9CsXsfMmHYZ-KDFJiaD8Kkqwm_9d3IVzk0,5638
5
- ai_edge_torch/version.py,sha256=KCQW3wwoSg8zjssrnlyquD4aO-OeN7u1jWFHk_-trYY,806
5
+ ai_edge_torch/version.py,sha256=3opXPBORBcfxsu8h1LE4OMIWY6oXA1l6xSP65lCMRog,806
6
6
  ai_edge_torch/_convert/__init__.py,sha256=hHLluseD2R0Hh4W6XZRIXY_dRQeYudjsrKGf6LZz65g,671
7
7
  ai_edge_torch/_convert/conversion.py,sha256=iQk3R-pLq4c1nfLqPB4xTRj78gghxPGzJCJtILLdg5o,6123
8
8
  ai_edge_torch/_convert/conversion_utils.py,sha256=Sr8qXVcTwc-ZnZmK7yxVrIOOp1S_vNrwzC0zUvLTI2o,2160
@@ -235,8 +235,8 @@ ai_edge_torch/lowertools/translate_recipe.py,sha256=Oavs0ENKVnIeB-WidXvokTPqNlFf
235
235
  ai_edge_torch/odml_torch/__init__.py,sha256=S8jOzE9nLof-6es3XDiGJRN-9H_XTxsVm9dE7lD3RWo,812
236
236
  ai_edge_torch/odml_torch/_torch_future.py,sha256=jSYHf1CMTJzMizPMbu2b39hAt0ZTR6gQLq67GMe9KTo,2336
237
237
  ai_edge_torch/odml_torch/_torch_library.py,sha256=Lw1gqL2HWNRspdTwNhIkYAHDyafHedHtkXyKKxn-Wss,805
238
- ai_edge_torch/odml_torch/export.py,sha256=FDseiAOOcgN8HOuwv6HT9sALZgXGj7vZi6kwZPWPF14,14935
239
- ai_edge_torch/odml_torch/export_utils.py,sha256=QeA37Irlty6AiIBuqmHmJgn3lqahBQ5xsh6IKRoKm1g,4774
238
+ ai_edge_torch/odml_torch/export.py,sha256=WPsATMFsc62aETExBsb1v6Ec1fL3r0CEvxwE7r2C_CA,14931
239
+ ai_edge_torch/odml_torch/export_utils.py,sha256=Eax4QUefIzpmVuQxo1y9FqJ6g0qXjg4C0IVZ5uYPscs,4899
240
240
  ai_edge_torch/odml_torch/optimization_barrier.py,sha256=2lmSiu5iXWLFWpupZHvsVeNYNzG5AVGSK3K_CNhS5Sk,2290
241
241
  ai_edge_torch/odml_torch/tf_integration.py,sha256=NN29WeXmHZ0S1RPDFHUnBi2DEjMvAtwczStPYIsQ1w8,4849
242
242
  ai_edge_torch/odml_torch/composite/__init__.py,sha256=71GM_gDZxJyo38ZSoYSwhZX3xKA9rknO93JS9kw9w_c,778
@@ -257,7 +257,7 @@ ai_edge_torch/odml_torch/lowerings/_jax_lowerings.py,sha256=xUuQjoR0NJhuwG36Guyc
257
257
  ai_edge_torch/odml_torch/lowerings/_layer_norm.py,sha256=khJIvDVk2s332Nd2Be-5dM6-wp5DGff61HCV5lskHmQ,3011
258
258
  ai_edge_torch/odml_torch/lowerings/_quantized_decomposed.py,sha256=XDZ0zLej_XaQDJnaAAxhNFAd7NfQm5SOVEp_nno_krA,6178
259
259
  ai_edge_torch/odml_torch/lowerings/_rand.py,sha256=g6SuqDkuC6hD35lyP1-5H7ASDIzPSmKukeNT5naZSv8,4133
260
- ai_edge_torch/odml_torch/lowerings/context.py,sha256=jslcCv7r_HtImSRTxJwHAUV_QCu9Jub51lovmoBkmFA,1295
260
+ ai_edge_torch/odml_torch/lowerings/context.py,sha256=dhGS9oFjKLKvc-aBFbNUhb4LqggP_AmPrgpT1EnOw0w,1216
261
261
  ai_edge_torch/odml_torch/lowerings/registry.py,sha256=Tp2h11l5uTifO0aIkuUOWAF_ibEjmd65Xx99w3EXuGE,1924
262
262
  ai_edge_torch/odml_torch/lowerings/utils.py,sha256=YagY2IDqtJTpPxjPz2dhb3eyCFTpTSu3ptEPSvEuDtk,10574
263
263
  ai_edge_torch/odml_torch/passes/__init__.py,sha256=AVwIwUTMx7rXacKjGy4kwrtMd3XB2v_ncdc40KOjUqQ,1245
@@ -269,8 +269,8 @@ ai_edge_torch/testing/__init__.py,sha256=_yGgvnBZWb7T3IN3mc4x1sS4vM96HZwM8pwIcPG
269
269
  ai_edge_torch/testing/export.py,sha256=k5mGDGzwc23Z4zaIVDs8CNh-oOt64gsf9MS9NjhbPy4,3293
270
270
  ai_edge_torch/testing/model_coverage/__init__.py,sha256=5P8J6Zk5YYtDvTBucFvB9NGSRI7Gw_24WnrbhXgycEE,765
271
271
  ai_edge_torch/testing/model_coverage/model_coverage.py,sha256=UPB448aMDUyC0HNYVqio2rcJPnDN0tBQMP08J6vPYew,4718
272
- ai_edge_torch_nightly-0.6.0.dev20250821.dist-info/LICENSE,sha256=z8d0m5b2O9McPEK1xHG_dWgUBT6EfBDz6wA0F7xSPTA,11358
273
- ai_edge_torch_nightly-0.6.0.dev20250821.dist-info/METADATA,sha256=HNSeR4DnS8ax0bUi9CSIOzakw0lJk1ZA8JM889_0rSg,2074
274
- ai_edge_torch_nightly-0.6.0.dev20250821.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
275
- ai_edge_torch_nightly-0.6.0.dev20250821.dist-info/top_level.txt,sha256=5KXRaF2hwkApYxf7Y8y_tVb9aulGTlbOoNdbx1aKRkE,14
276
- ai_edge_torch_nightly-0.6.0.dev20250821.dist-info/RECORD,,
272
+ ai_edge_torch_nightly-0.6.0.dev20250822.dist-info/LICENSE,sha256=z8d0m5b2O9McPEK1xHG_dWgUBT6EfBDz6wA0F7xSPTA,11358
273
+ ai_edge_torch_nightly-0.6.0.dev20250822.dist-info/METADATA,sha256=m65Q6FH51OLricsQOL0tRYM50M0Mp3NKniIlZqfdhhc,2074
274
+ ai_edge_torch_nightly-0.6.0.dev20250822.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
275
+ ai_edge_torch_nightly-0.6.0.dev20250822.dist-info/top_level.txt,sha256=5KXRaF2hwkApYxf7Y8y_tVb9aulGTlbOoNdbx1aKRkE,14
276
+ ai_edge_torch_nightly-0.6.0.dev20250822.dist-info/RECORD,,