diff --git a/dask_cuda/proxify_device_objects.py b/dask_cuda/proxify_device_objects.py index 5783d36f0..cd067d3d1 100644 --- a/dask_cuda/proxify_device_objects.py +++ b/dask_cuda/proxify_device_objects.py @@ -166,9 +166,8 @@ def wrapper(*args, **kwargs): def proxify(obj, proxied_id_to_proxy, found_proxies, subclass=None): _id = id(obj) if _id not in proxied_id_to_proxy: - proxied_id_to_proxy[_id] = ret = asproxy(obj, subclass=subclass) - else: - ret = proxied_id_to_proxy[_id] + proxied_id_to_proxy[_id] = asproxy(obj, subclass=subclass) + ret = proxied_id_to_proxy[_id] found_proxies.append(ret) return ret diff --git a/dask_cuda/proxify_host_file.py b/dask_cuda/proxify_host_file.py index f0e4c9d3c..34d9c828d 100644 --- a/dask_cuda/proxify_host_file.py +++ b/dask_cuda/proxify_host_file.py @@ -133,7 +133,7 @@ class ProxyManager: memory usage. It turns out having to re-calculate memory usage continuously is too expensive. - The idea is to have the ProxifyHostFile or the proxies themself update + The idea is to have the ProxifyHostFile or the proxies themselves update their location (device or host). The manager then tallies the total memory usage. Notice, the manager only keeps weak references to the proxies. diff --git a/dask_cuda/proxy_object.py b/dask_cuda/proxy_object.py index 4bfb42a31..5dd8651b4 100644 --- a/dask_cuda/proxy_object.py +++ b/dask_cuda/proxy_object.py @@ -450,7 +450,7 @@ def __repr__(self): return ret @property # type: ignore # mypy doesn't support decorated property - @_obj_pxy_cache_wrapper("type_serialized") # + @_obj_pxy_cache_wrapper("type_serialized") def __class__(self): return pickle.loads(self._obj_pxy["type_serialized"])