how to define a colormap dynamically

I would like to be able to define a new colormap dynamically, that is without altering code in

It would not appear to be too difficult to some one who knew what they were doing. I have made
some attempts following the code in and other places, but I do not seem to be able to get the
normalization correct.

I know that I could just put the data into but I would rather not have to remember to alter this code
for every release of matplotlib and I am sure most people do not want my colormaps.

I have used GMT (Generic Mapping Tools) extensively in the past and have code to translate the GMT color map
into a form usable by matplotlib.
The site: has a very large number of colormaps in the GMT format and would be a useful resource for matplotlib,
   if the data files there could be easily imported.

Thanks for any pointers.