Apply ruff flake8-comprehensions (#21694)
This commit is contained in:
@@ -1099,7 +1099,7 @@ class FlaxModelTesterMixin:
|
||||
index = json.loads(f.read())
|
||||
|
||||
all_shards = set(index["weight_map"].values())
|
||||
shards_found = set(f for f in os.listdir(tmp_dir) if f.endswith(".msgpack"))
|
||||
shards_found = {f for f in os.listdir(tmp_dir) if f.endswith(".msgpack")}
|
||||
self.assertSetEqual(all_shards, shards_found)
|
||||
|
||||
# Finally, check the model can be reloaded
|
||||
|
||||
Reference in New Issue
Block a user