Skip to content

Commit ffe7a27

Browse files
committed
Fix aliases parameter issues
1 parent 53816b1 commit ffe7a27

File tree

2 files changed

+10
-11
lines changed

2 files changed

+10
-11
lines changed

CHANGELOG.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,6 @@ This file contains the changelog for the Deeploy project. The changelog is divid
101101
- Added missing shape annotation to the testTypeInferenceDifferentTypes
102102

103103
### Fixed
104-
- Fixed bug in alias_of node parameter handling, that takes care of the lifetime of buffers in skip connection situations.
105104
- Fixed bug for non-batched elements in the PULPOpen FP GEMM and matmul templates.
106105
- Added underscore to the beginning of closure names to avoid naming issues when they start with unsupported first characters (like numbers).
107106
- Data types in the PULPOpen FP add and mul templates.

Deeploy/DeeployTypes.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -325,41 +325,41 @@ def fromNode(cls, node: gs.Node):
325325
return (cls(
326326
name = node.name,
327327
shape = node.shape if not isinstance(node, gs.Constant) else node.values.shape,
328-
alias_of = [],
328+
aliases = [],
329329
))
330330

331331
def add_aliases(self, aliases_to_add: List[str]):
332332
"""
333-
Adds list of aliases to the alias_of attribute.
333+
Adds list of aliases to the aliases attribute.
334334
Parameters
335335
----------
336336
alias_to_add : List[str]
337-
List of names of aliases to add to the alias_of attribute.
337+
List of names of aliases to add to the aliases attribute.
338338
Returns
339339
-------
340340
None
341341
"""
342342

343-
if not hasattr(self, "alias_of"):
343+
if not hasattr(self, "aliases"):
344344
return None
345345

346346
for alias in aliases_to_add:
347-
if alias not in self.alias_of:
348-
self.alias_of.append(alias)
347+
if alias not in self.aliases:
348+
self.aliases.append(alias)
349349

350350
return None
351351

352352
def get_aliases_of(self):
353353
"""
354-
Getter function for the alias_of attribute.
354+
Getter function for the aliases attribute.
355355
Returns
356356
-------
357357
List[str]
358358
List of names o all aliases of this VariableBuffer.
359359
"""
360360

361-
if hasattr(self, "alias_of"):
362-
return list(self.alias_of)
361+
if hasattr(self, "aliases"):
362+
return list(self.aliases)
363363
else:
364364
return list()
365365

@@ -1174,7 +1174,7 @@ def parseOutputs(cls, ctxt: NetworkContext, node: gs.Node) -> NetworkContext:
11741174
nb = ctxt.VariableBuffer(
11751175
name = name,
11761176
shape = node.shape,
1177-
alias_of = [],
1177+
aliases = [],
11781178
)
11791179
ctxt.add(nb, 'local')
11801180
else:

0 commit comments

Comments
 (0)