Skip to content

Commit b2f479d

Browse files
committed
obj: add __slots__
We are creating lots of these, so it will help to save up on memory and improve performance. Similar to iterative/dvc-data#56
1 parent c7d7b4b commit b2f479d

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/dvc_objects/obj.py

+2
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55

66

77
class Object:
8+
__slots__ = ("path", "fs", "oid")
9+
810
def __init__(
911
self,
1012
path: "AnyFSPath",

0 commit comments

Comments
 (0)