Giter Club home page Giter Club logo

fr-inr's Introduction

FR-INR

This repository is the official PyTorch implementation of "Improved Implicit Neural Representation with Fourier Reparameterized Training", CVPR, 2024. By Kexuan Shi, Xingyu Zhou, Shuhang Gu. (arxiv)

Abstract: Implicit Neural Representation (INR) as a mighty representation paradigm has achieved success in various computer vision tasks recently. Due to the low-frequency bias issue of vanilla multi-layer perceptron (MLP), existing methods have investigated advanced techniques, such as positional encoding and periodic activation function, to improve the accuracy of INR. In this paper, we connect the network training bias with the reparameterization technique and theoretically prove that weight reparameterization could provide us a chance to alleviate the spectral bias of MLP. Based on our theoretical analysis, we propose a Fourier reparameterization method which learns coefficient matrix of fixed Fourier bases to compose the weights of MLP. We evaluate the proposed Fourier reparameterization method on different INR tasks with various MLP architectures, including vanilla MLP, MLP with positional encoding and MLP with advanced activation function, etc. The superiority approximation results on different MLP architectures clearly validate the advantage of our proposed method. Armed with our Fourier reparameterization method, better INR with more textures and less artifacts can be learned from the training data.

Environment

conda create -n FR-INR python=3.8
conda activate FR-INR

cd FR-INR
pip install -r requirements.txt

1D Function fitting

Firstly, running 1d_function_fitting.py to get the fitting results and the empirical Neural Tangent Kernel of Fourier reparameterziation training in 1d function task. Then, running 1d_relative_error_in_frequency.py to analyze the approximation results in the frequency domain.

python 1d_function_fitting.py
python 1d_relative_error_in_frequency.py
Image 1 Image 2
Image 3 Image 4

2D Image fitting

Using 2d_image_fitting.py to get the fitting results in Image regression task.

python 2d_image_fitting.py

3D Occupance

Using 3D_occupance.py to get the results of Thai and Dragon Statue. Before running, you have to unzip the .mat file.

python 3D_occupance.py

Neural rendering

We provide the core code file dvgo.py and InstantNGP.py for DVGO and InstantNGP. The DVGO is recommended to evalute our FR as its official implementation and fast training.

Citation

@inproceedings{shi2024improved,
  title={Improved Implicit Neural Representation with Fourier Reparameterized Training},
  author={Shi, Kexuan and Zhou, Xingyu and Gu, Shuhang},
  booktitle={Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  pages={25985--25994},
  year={2024}
}

fr-inr's People

Contributors

skxgogo avatar labshuhanggu avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.