--- license: mit tags: - pytorch - safetensors - threshold-logic - neuromorphic --- # threshold-xnor3 3-input XNOR gate. Outputs 1 when an even number of inputs are 1 (0 or 2). ## Architecture Cascade: XNOR3(a,b,c) = XOR(XNOR(a,b), c) ``` a,b ──► XNOR ──► XOR ──► output c ──┘ ``` ## Parameters | | | |---|---| | Neurons | 6 | | Layers | 4 | | Parameters | 18 | | Magnitude | 19 | ## Truth Table | a | b | c | output | |---|---|---|--------| | 0 | 0 | 0 | 1 | | 0 | 0 | 1 | 0 | | 0 | 1 | 0 | 0 | | 0 | 1 | 1 | 1 | | 1 | 0 | 0 | 0 | | 1 | 0 | 1 | 1 | | 1 | 1 | 0 | 1 | | 1 | 1 | 1 | 0 | ## Usage ```python from safetensors.torch import load_file w = load_file('model.safetensors') # See model.py for forward pass ``` ## License MIT