Skip to content
EntityQ161690· pop 18· linked from 32 articles

Also known as one-hot code, one hot, 1-hot, 1-of-n code, 1-of-10 code

{| class="wikitable" border="1" align="right" |- ! Decimal !! Binary !! Unary !! One-hot |- | 0 || 000 || 00000000 || 00000001 |- | 1 || 001 || 00000001 || 00000010 |- | 2 || 010 || 00000011 || 00000100 |- | 3 || 011 || 00000111 || 00001000 |- | 4 || 100 || 00001111 || 00010000 |- | 5 || 101 || 00011111 || 00100000 |- | 6 || 110 || 00111111 || 01000000 |- | 7 || 111 || 01111111 || 10000000 |}

~6 min read

Article

9 sections
Contents
  • Applications
  • Digital circuitry
  • Comparison with other encoding methods
  • Advantages
  • Disadvantages
  • Natural language processing
  • Machine learning and statistics
  • See also
  • References

{| class="wikitable" border="1" align="right" |- ! Decimal !! Binary !! Unary !! One-hot |- | 0 || 000 || 00000000 || 00000001 |- | 1 || 001 || 00000001 || 00000010 |- | 2 || 010 || 00000011 || 00000100 |- | 3 || 011 || 00000111 || 00001000 |- | 4 || 100 || 00001111 || 00010000 |- | 5 || 101 || 00011111 || 00100000 |- | 6 || 110 || 00111111 || 01000000 |- | 7 || 111 || 01111111 || 10000000 |}

In digital circuits and machine learning, a one-hot is a group of bits among which the legal combinations of values are only those with a single high (1) bit and all the others low (0). A similar implementation in which all bits are '1' except one '0' is sometimes called one-cold. In statistics, dummy variables represent a similar technique for representing categorical data.

Connections

Categories