A bacterial bloom will last as long as it keeps getting fed. So, making sure you limit the amount of food and nutrients that are entering your system will help shorten the bloom period.
If it's a new tank without fish, let it run its course. This will take about 4-6 weeks for healthy bacteria to establish.
Continue to filter and change your water until the problem clears up. Remember, bacteria is your best friend unless it gets out of control.