load_ratings#

popo.profiles.smartds.load_ratings(loads_dir, kind='res')#

Per-customer kW and kvar ratings, read from Loads.dss files.

The two per-unit profiles in load_pool() are each normalised to their own maximum, so a power factor computed from them alone is meaningless. The ratings are what carry the P-to-Q relationship: OpenDSS applies them as P(t) = kW * mult(t) and Q(t) = kvar * qmult(t). Any transfer of these profiles to another network has to carry the rating ratio with them, or the reactive behaviour is lost and an assumed power factor creeps back in.

A profile is reused across many loads with different ratings, so keeping the first match would pick an arbitrary one and bias the pool towards whichever load happens to be read first; the median over a profile’s users is used instead, and the kvar/kW ratio is preserved because it is taken per-load, not assembled from two independent medians.

Parameters:
  • loads_dir (Path) – Directory tree to search recursively for Loads.dss files (glob pattern */*/Loads.dss).

  • kind (str) – Customer class, matched in the yearly= reference, e.g. "res" or "com".

Return type:

DataFrame

Returns:

A frame indexed by profile id with columns kw_rating, kvar_rating and n_loads (the number of loads sharing that profile).