The Big Picture
Each subnet has MaxAllowedUids slots. SubnetworkN tells you how many are filled. When SubnetworkN = MaxAllowedUids, the subnet is full and new registrations must prune existing neurons. Lower SubnetworkN means available slots for easy registration.
Why This Matters
Want to register on a subnet? If SubnetworkN < MaxAllowedUids, there's room and registration is straightforward. If equal, you'll need to beat someone's pruning score to get in.
Example Scenario
Query SubnetworkN(netuid=1) returns 240. MaxAllowedUids is 256. The subnet has 16 open slots - you can register without pruning anyone. At 256/256, it's full competition.
Common Questions
- What's a typical utilization rate?
- Popular subnets are often 100% full. Newer or less popular subnets may have open slots. Full subnets indicate high demand and competition.
- Does higher N mean a better subnet?
- More neurons indicates interest, but quality matters more than quantity. Check emission rates and performance metrics too.
- Can this exceed MaxAllowedUids?
- No, SubnetworkN is capped at MaxAllowedUids. That's the maximum capacity.
Use Cases
- Check if subnet has room for new registrations
- Calculate subnet utilization percentage
- Compare competition levels across subnets
- Build capacity dashboards
- Track subnet growth over time
From Chain Metadata
MAP ( netuid ) --> subnetwork_n (Number of UIDs in the network).
Purpose & Usage
Purpose
Track subnet utilization and remaining capacity - how many of the available slots are filled.
Common Query Patterns
- Query by netuid
- Check if subnet has capacity for registration
- Calculate utilization rate with MaxAllowedUids
Query Keys
| # | Name | Type | Description |
|---|---|---|---|
| 1 | netuid | u16 | Subnet ID |
Stored Value
Relationships
Modified By
Related Events
Code Examples
import { createClient, Binary } from "polkadot-api";
import { getWsProvider } from "polkadot-api/ws";
import { sub } from "@polkadot-api/descriptors"; // generated by: npx papi add sub -w wss://entrypoint-finney.opentensor.ai:443
const client = createClient(getWsProvider("wss://entrypoint-finney.opentensor.ai:443"));
const api = client.getTypedApi(sub);
// Query SubnetworkN storage
const netuid = 1;
const result = await api.query.SubtensorModule.SubnetworkN.getValue(netuid);
console.log("SubnetworkN:", result);On-Chain Activity
100K–1M estimated writes
#40 most written storage item
Modified by both user extrinsics and runtime hooks
As of block 7,429,232
Version History
Runtime Info
View Source- Pallet
- SubtensorModule
- Storage Kind
- Map
- First Version
- v101
- Current Version
- v411