Saved in:
Bibliographic Details
Main Authors: Horton, Maxwell, Mehta, Sachin, Farhadi, Ali, Rastegari, Mohammad
Format: Preprint
Published: 2023
Subjects:
Online Access:https://arxiv.org/abs/2306.00238
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866910509062684672
author Horton, Maxwell
Mehta, Sachin
Farhadi, Ali
Rastegari, Mohammad
author_facet Horton, Maxwell
Mehta, Sachin
Farhadi, Ali
Rastegari, Mohammad
contents Modern deep learning approaches usually utilize modality-specific processing. For example, the most common deep learning approach to image classification involves decoding image file bytes into an RGB tensor which is passed into a neural network. Instead, we investigate modality-independent representation learning by performing classification directly on file bytes, without the need for decoding files at inference time. This enables models to operate on various modalities without any hand-designed, modality-specific processing. Our model, ByteFormer, improves ImageNet Top-1 classification accuracy by $5\%$ (from $72.2\%$ to $77.33\%$) relative to DeIT models of similar size. Compared to Perceiver IO, our model requires absolutely no modality-specific processing at inference time, and uses an order of magnitude fewer parameters at equivalent accuracy on ImageNet. We demonstrate that the same ByteFormer architecture can perform audio classification without modifications or modality-specific preprocessing. We achieve $95.42\%$ classification accuracy on the Speech Commands V2 dataset (comparable to the state-of-the-art accuracy of $98.7\%$). Additionally, we demonstrate that ByteFormer can operate jointly on images and audio, handling joint classification without explicit knowledge of the input modality. We release our code at https://github.com/apple/corenet/tree/main/projects/byteformer.
format Preprint
id arxiv_https___arxiv_org_abs_2306_00238
institution arXiv
publishDate 2023
record_format arxiv
spellingShingle Bytes Are All You Need: Transformers Operating Directly On File Bytes
Horton, Maxwell
Mehta, Sachin
Farhadi, Ali
Rastegari, Mohammad
Computer Vision and Pattern Recognition
Modern deep learning approaches usually utilize modality-specific processing. For example, the most common deep learning approach to image classification involves decoding image file bytes into an RGB tensor which is passed into a neural network. Instead, we investigate modality-independent representation learning by performing classification directly on file bytes, without the need for decoding files at inference time. This enables models to operate on various modalities without any hand-designed, modality-specific processing. Our model, ByteFormer, improves ImageNet Top-1 classification accuracy by $5\%$ (from $72.2\%$ to $77.33\%$) relative to DeIT models of similar size. Compared to Perceiver IO, our model requires absolutely no modality-specific processing at inference time, and uses an order of magnitude fewer parameters at equivalent accuracy on ImageNet. We demonstrate that the same ByteFormer architecture can perform audio classification without modifications or modality-specific preprocessing. We achieve $95.42\%$ classification accuracy on the Speech Commands V2 dataset (comparable to the state-of-the-art accuracy of $98.7\%$). Additionally, we demonstrate that ByteFormer can operate jointly on images and audio, handling joint classification without explicit knowledge of the input modality. We release our code at https://github.com/apple/corenet/tree/main/projects/byteformer.
title Bytes Are All You Need: Transformers Operating Directly On File Bytes
topic Computer Vision and Pattern Recognition
url https://arxiv.org/abs/2306.00238