'Strip cards specific to a certain kind of header.
Strip cards like ``SIMPLE``, ``BITPIX``, etc. so the rest of
the header can be used to reconstruct another kind of header.'

def _strip(self):

    if ('NAXIS' in self):
        naxis = self['NAXIS']
    else:
        naxis = 0
    if ('TFIELDS' in self):
        tfields = self['TFIELDS']
    else:
        tfields = 0
    for idx in range(naxis):
        try:
            del self[('NAXIS' + str((idx + 1)))]
        except KeyError:
            pass
    for name in ('TFORM', 'TSCAL', 'TZERO', 'TNULL', 'TTYPE', 'TUNIT', 'TDISP', 'TDIM', 'THEAP', 'TBCOL'):
        for idx in range(tfields):
            try:
                del self[(name + str((idx + 1)))]
            except KeyError:
                pass
    for name in ('SIMPLE', 'XTENSION', 'BITPIX', 'NAXIS', 'EXTEND', 'PCOUNT', 'GCOUNT', 'GROUPS', 'BSCALE', 'BZERO', 'TFIELDS'):
        try:
            del self[name]
        except KeyError:
            pass
