|
176 | 176 | ["max_regs_per_block", "Compact<u16>"],
|
177 | 177 | ["serving_rate_limit", "Compact<u64>"],
|
178 | 178 | ["max_validators", "Compact<u16>"],
|
| 179 | + ["adjustment_alpha", "Compact<u64>"], |
| 180 | + ["difficulty", "Compact<u64>"], |
179 | 181 | ],
|
180 | 182 | },
|
181 | 183 | }
|
@@ -882,6 +884,7 @@ class SubnetInfo:
|
882 | 884 | emission_value: float
|
883 | 885 | burn: Balance
|
884 | 886 | owner_ss58: str
|
| 887 | + # adjustment_alpha: int |
885 | 888 |
|
886 | 889 | @classmethod
|
887 | 890 | def from_vec_u8(cls, vec_u8: List[int]) -> Optional["SubnetInfo"]:
|
@@ -922,6 +925,8 @@ def fix_decoded_values(cls, decoded: Dict) -> "SubnetInfo":
|
922 | 925 | max_allowed_validators=decoded["max_allowed_validators"],
|
923 | 926 | min_allowed_weights=decoded["min_allowed_weights"],
|
924 | 927 | max_weight_limit=decoded["max_weights_limit"],
|
| 928 | + # adjustment_alpha=decoded["adjustment_alpha"], |
| 929 | + # bonds_moving_avg=decoded["bonds_moving_average"], |
925 | 930 | scaling_law_power=decoded["scaling_law_power"],
|
926 | 931 | subnetwork_n=decoded["subnetwork_n"],
|
927 | 932 | max_n=decoded["max_allowed_uids"],
|
@@ -975,6 +980,8 @@ class SubnetHyperparameters:
|
975 | 980 | max_regs_per_block: int
|
976 | 981 | serving_rate_limit: int
|
977 | 982 | max_validators: int
|
| 983 | + adjustment_alpha: int |
| 984 | + difficulty: int |
978 | 985 |
|
979 | 986 | @classmethod
|
980 | 987 | def from_vec_u8(cls, vec_u8: List[int]) -> Optional["SubnetHyperparameters"]:
|
@@ -1023,10 +1030,12 @@ def fix_decoded_values(cls, decoded: Dict) -> "SubnetHyperparameters":
|
1023 | 1030 | target_regs_per_interval=decoded["target_regs_per_interval"],
|
1024 | 1031 | min_burn=decoded["min_burn"],
|
1025 | 1032 | max_burn=decoded["max_burn"],
|
1026 |
| - bonds_moving_avg=decoded["bonds_moving_avg"], |
1027 | 1033 | max_regs_per_block=decoded["max_regs_per_block"],
|
1028 | 1034 | max_validators=decoded["max_validators"],
|
1029 | 1035 | serving_rate_limit=decoded["serving_rate_limit"],
|
| 1036 | + bonds_moving_avg=decoded["bonds_moving_avg"], |
| 1037 | + adjustment_alpha=decoded["adjustment_alpha"], |
| 1038 | + difficulty=decoded["difficulty"], |
1030 | 1039 | )
|
1031 | 1040 |
|
1032 | 1041 | def to_parameter_dict(self) -> "torch.nn.ParameterDict":
|
|
0 commit comments