def to_flatmap(name, hemi=Ellipsis, <EOL>center=Ellipsis, center_right=Ellipsis, radius=Ellipsis, chirality=Ellipsis,<EOL>method=Ellipsis, registration=Ellipsis, sphere_radius=Ellipsis,<EOL>pre_affine=Ellipsis, post_affine=Ellipsis, meta_data=Ellipsis):
from neuropythy.mri import is_subject<EOL>kw = dict(center=center, center_right=center_right, radius=radius, chirality=chirality,<EOL>method=method, registration=registration, sphere_radius=sphere_radius,<EOL>pre_affine=pre_affine, post_affine=post_affine, meta_data=meta_data)<EOL>kw = {k:v for (k,v) in six.iteritems(kw) if v is not Ellipsis}<EOL>if pimms.is_vector(name):<EOL><INDENT>if   len(name) == <NUM_LIT:1>: name = name[<NUM_LIT:0>]<EOL>elif len(name) == <NUM_LIT:2>:<EOL><INDENT>(name, tmp) = name<EOL>if pimms.is_map(tmp):<EOL><INDENT>kw = {k:v for (k,v) in six.iteritems(pimms.merge(tmp, kw)) if v is not Ellipsis}<EOL><DEDENT>else: hemi = tmp<EOL><DEDENT>elif len(name) == <NUM_LIT:3>:<EOL><INDENT>(name, hemi, opts) = name<EOL>kw = {k:v for (k,v) in six.iteritems(pimms.merge(opts, kw)) if v is not Ellipsis}<EOL><DEDENT><DEDENT>if '<STR_LIT>' in kw:<EOL><INDENT>if hemi is Ellipsis: hemi = kw['<STR_LIT>']<EOL>del kw['<STR_LIT>']<EOL><DEDENT>mp = to_map_projection(name, hemi, **kw)<EOL>return mp(hemi)<EOL>
to_flatmap(name, topo) yields a flatmap of the given topology topo using the map projection
  obtained via to_map_projection(name).
to_flatmap(name, mesh) yields a flatmap of the given mesh. If no hemisphere is specified in the
  name argument nor in the mesh meta-data, then 'lr' is assumed.
to_flatmap(name, subj) uses the given hemisphere from the given subject.
to_flatmap((name, obj)) is equivalent to to_flatmap(name, obj).
to_flatmap((name, obj, opts_map)) is equivalent to to_flatmap(name, obj, **opts_map).

All optional arguments that can be passed to map_projection() may also be passed to the
to_flatmap() function and are copied into the map projection object prior to its use in creating
the resulting 2D mesh. Note that the named chirality argument is used to set the chirality of
the returned map projection but never to specify the chirality of a map projection that is being
looked up or loaded; for that use the second argument, second tuple entry, or hemi keyword.