Robust PCA in Python. Methods are from the http://perception.csl.illinois.edu/matrix-rank/sample_code.html and papers therein.
- scipy
- numpy
- pypropack(optional)
- scikit-learn
- nosetest
test_robustpca.py
test whether the algorithms included can recovery the synthetic data successfully. Usenosetest test_robustpca.py
plot_benchmark.py
plot the benchmarks with synthetic data generated with different parameters. Usepython2 plot_benchmark.py
background_subtraction.py
generate the result using the escalator dataset. Usepython2 background_subtraction.py
. This will generate the.mat
files with respect to each algorithms and can be directly readable from matlab. Furthermore,background_subtraction_visualize.py
could be used to generate a video. The temporary image files are located in/tmp/robust_pca_tmp/
which should be created first.topic_extraction.py
extracts the keywords from the 20newsgroup dataset. It will generate two files, one isorigin.txt
and another iskeyword.txt
. The keyword and the original text on the same line is one-one mapped.
Special thanks for the following two resources and their authors.