Take the trouble to do something verb phrase
To try very hard to do something
If you take the trouble of practicing for the dance competition, you may have a chance of winning.
In spite of the heavy rain, you took the trouble to come to my wedding.
This phrase is usually followed by "to do something" or "of doing something". The verb "take" should be conjugated according to its tense.