Add ruff and ty as dev dependencies, fix lint/type findings
ruff removed unused imports across analysis.py and several test files. ty caught a wrong dict[int, int] annotation on StreamingStepsDataset's mat_map (materials are strings) and a real bug in steps_to_parquet.py where --compression none passed None to polars' write_parquet, which only accepts the literal "uncompressed". Also narrows a few Optional-typed attributes (ddpm_schedule, Normalizer.mean/std) with asserts and aligns __getitem__'s parameter name with torch's Dataset base class. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
+1
-2
@@ -1,8 +1,7 @@
|
||||
import torch
|
||||
import pytest
|
||||
from giant.model.network import DenoisingMLP
|
||||
from giant.model.schedule import CosineSchedule, flow_matching_loss
|
||||
from giant.sample import sample_flow, sample_ddpm, sample_ddim
|
||||
from giant.sample import sample_flow, sample_ddim
|
||||
|
||||
|
||||
def _small_model():
|
||||
|
||||
Reference in New Issue
Block a user