A filtering device for removing particles from a bodily fluid of a patient is disclosed. The device is implantable in the patient's body and comprises a tube forming a main fluid passageway for bodily fluid, through which the bodily fluid passes when the tube is implanted, wherein the tube is sized and adapted to be fluidly connected to the bodily fluid. The device further comprises a filter connected to the tube, and a filter cleaning device for cleaning the filter.