I have assembled a bacterial genome using spades.
The coverage among the contigs is very heterogeneous, while some have more than 30 fold of coverage, other have less than 5 fold. Also, there are a lot of contigs with a length less than 500 bp.
I'm aware that I must filter contigs having low coverage and small length (they probably are spurious sequencing products), however what would be reasonable criteria for filtering them?
I have found scripts that remove contigs having less than 500 pb and 2 fold coverage. I believe this setting is too permissive, since most of the contigs of my assembly significantly deviate from it. 

EDIT:
![Here is the distribution of log10 contig length:][1]


![Here is the distribution of contig coverage:][2]


As we can see, most of contigs have less than 1000 bp, Most of these contigs have less than 5 fold of coverage. My plan is to filter contigs having less than 1000 bp and 5 fold of coverage. After, I am going to check the completeness of the filtered genome sequence using checkm (contrasting to the unfiltered genome).

EDIT 2:
![Length vs Coverage][3]


  [1]: https://image.ibb.co/iLswOb/semia4088_log_leng.png
  [2]: https://image.ibb.co/i7sMOb/semia4088_cov.png
  [3]: https://image.ibb.co/jVC6PG/semia4088_len_vs_coverage.png
If you're afraid of contamination or spurious sequencing products, I suggest to align by BLAST all of the contigs to some reference (or even to the NCBI NT or NCBI NR databases entirely), to decide which of the contigs are "Ok" (i.e. have matches to the species you are interested in). Then you can plot the distribution of coverages of good and bad contigs and define some threshold that separates them good enough