[논문 리뷰] Hopfield Networks is All You Need
이 논문은 차분 상태 Hopfield 네트워크를 도입하여 구별 가능한 메모리 층으로 작동하고, 트랜스포머의 어텐션과 동등하며 지수적 저장 및 원샷 조회를 가능하게 하며, MIL, 면역 리퍼토리, 소규모 데이터셋 및 약물 설계에서의 효과를 입증합니다.
We introduce a modern Hopfield network with continuous states and a corresponding update rule. The new Hopfield network can store exponentially (with the dimension of the associative space) many patterns, retrieves the pattern with one update, and has exponentially small retrieval errors. It has three types of energy minima (fixed points of the update): (1) global fixed point averaging over all patterns, (2) metastable states averaging over a subset of patterns, and (3) fixed points which store a single pattern. The new update rule is equivalent to the attention mechanism used in transformers. This equivalence enables a characterization of the heads of transformer models. These heads perform in the first layers preferably global averaging and in higher layers partial averaging via metastable states. The new modern Hopfield network can be integrated into deep learning architectures as layers to allow the storage of and access to raw input data, intermediate results, or learned prototypes. These Hopfield layers enable new ways of deep learning, beyond fully-connected, convolutional, or recurrent networks, and provide pooling, memory, association, and attention mechanisms. We demonstrate the broad applicability of the Hopfield layers across various domains. Hopfield layers improved state-of-the-art on three out of four considered multiple instance learning problems as well as on immune repertoire classification with several hundreds of thousands of instances. On the UCI benchmark collections of small classification tasks, where deep learning methods typically struggle, Hopfield layers yielded a new state-of-the-art when compared to different machine learning methods. Finally, Hopfield layers achieved state-of-the-art on two drug design datasets. The implementation is available at: https://github.com/ml-jku/hopfield-layers
연구 동기 및 목표
- 메모리 보강 아키텍처를 RNN의 대안으로 동기 부여하고 심층 네트워크의 저장 및 검색을 개선합니다.
- 새로운 에너지 함수와 원 업데이트 검색을 갖춘 연속 상태 Hopfield 네트워크를 고안합니다.
- Hopfield 층을 심층 아키텍처에 풀링, 메모리 또는 어텐션 메커니즘으로 통합할 수 있음을 보여줍니다.
- MIL, 소형 분류 작업, 면역 리퍼토리 분류 및 약물 설계에 걸친 광범위한 적용 가능성을 시연합니다.
제안 방법
- 연속 상태 Hopfield 네트워크를 위한 -lse와 제곱 상태 항을 결합하여 노름을 한정하는 새로운 에너지 함수 E를 정의합니다.
- 전역적으로 E의 고정점으로 수렴하는 xi_new = X softmax(beta X^T xi) 한 업데이트 규칙을 도입합니다.
- 패턴 구분 및 네트워크 매개변수 측면에서 수렴 특성과 지수적 검색 정확도를 증명합니다.
- 업데이트 규칙이 트랜스포머의 핵심-키-값 어텐션(셀프 어텐션)에 해당함을 보여줍니다.
- 통합을 위한 세 가지 Hopfield 층 유형(Hopfield, HopfieldPooling, HopfieldLayer)을 설명합니다.
실험 결과
연구 질문
- RQ1연속 상태로 현대 Hopfield 네트워크가 d차원 공간에서 기하급수적으로 많은 패턴을 저장하고 한 업데이트에서 높은 정확도로 검색할 수 있는가?
- RQ2Hopfield 네트워크를 differentiable 층으로 통합하여 심층 아키텍처에 메모리, 풀링 및 어텐션을 제공할 수 있는가?
- RQ3Hopfield 기반 층이 MIL, 면역 리퍼토리 분류, 소규모 UCI 과제 및 약물 설계 데이터셋의 성능을 향상시키는가?
주요 결과
- 차원에서 저장 용량은 지수적으로 증가하며, 특정 조건에서 증명 가능한 하한은 N ≥ sqrt(p) c^{(d-1)/4} 입니다.
- 원 업데이트 검색은 패턴이 잘 구분될 때 고정점에 ε에 가까운 값을 가지는 경향이 있습니다(구분 Δi에서 지수적으로 증가).
- Hopfield 층은 여러 MIL 벤치마크(면역 리퍼토리 및 이미지 기반 MIL 데이터셋)에서 최첨단 결과를 달성했습니다.
- MIL 벤치마크에서 HopfieldPooling은 Tiger, Fox, Elephant, UCSB Breast Cancer 데이터셋에서 경쟁력 있거나 우수한 AUC 점수를 보였습니다.
- HopfieldLayer는 단일 층 내에서 SVM, k-NN, LVQ를 모방할 수 있어 유연한 분류를 가능하게 합니다.
- 트랜스포머의 어텐션 메커니즘은 Hopfield 업데이트에 대응하며, 현대 메모리 네트워크와 셀프 어텐션을 연결합니다.
더 나은 연구,지금 바로 시작하세요
연구 설계부터 논문 작성까지, 연구 시간을 획기적으로 줄여보세요.
카드 등록 없음 · 무료 플랜 제공
이 리뷰는 AI가 만들고, 인간 에디터가 검토했습니다.