Skip to content
Switch branches/tags

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

Code and Pretrained Networks from
"Data-driven Estimation of Sinusoid Frequencies"

This repository contains information, code and models from the paper Data-driven Estimation of Sinusoid Frequencies by Gautier Izacard, Sreyas Mohan and Carlos Fernandez-Granda. Please visit the project webpage here.

Code and Pre-trained Models

Please refer to requirements.txt for required packages.

pre-trained models

The directory pretrained_models contains the pretained models of DeepFreq.

Example code for using Pre-Trained models

In example_notebook.ipynb, DeepFreq is applied to different signals and the results are visualized.

Train provides the code for training a model from scratch. An example usage of the script with some options is given below:

python \
	--n_training 200000 \
	--n_epochs_fr 200 \
	--n_epochs_fc 100 \
	--output_dir /checkpoint/experiment_name \

Please refer to the argparse module in for additional training options.

Test provides the script to bechmark the performance of DeepFreq against several baselines. An example usage of the script is provided below.

python \
	--data_dir test_dataset/ \
  	--output_dir results/ \
  	--fr_path pretrained_models/DeepFreq/frequency_representation_module.pth \
  	--fc_path pretrained_models/DeepFreq/frequency_counting_module.pth \
  	--psnet_path pretrained_models/PSnet/psnet.pth \
	--psnet_fc_path pretrained_models/PSnet/frequency_counting_psnet.pth \

The implementation of CBLasso is based on the code available here. CBLasso takes a long time to run, therefore, the result of running CBLasso on test_dataset is precomputed and provided in test_dataset/cblasso_results. Performance of CBLasso is obtained with, it requires to install CVX and MATLAB for Python.

Generate test data provides the code to generate data. An example usage is shown below:

python \
    	--output_dir my_testset/ \
    	--n_test 1000 \
	--signal_dimension 50 \
   	--minimum_separation 1. \
    	--dB 0 5 10 15 20 25 30 35 40 45 50 \

The particular instance of test data used in the original paper is available in the test_dataset.


Code, Pre-trained Models and some materials accompanying "Data-driven Estimation of Sinusoid Frequencies"




No releases published


No packages published