Is the Python types module superfluous?

  • Thread starter Colin J. Williams
  • Start date
C

Colin J. Williams

Travis said:
Gerard said:
On Wed, 01 Feb 2006 11:15:09 -0500

[ currently numpy uses ndarray, with synonym ArrayType, for a
multidimensional array ]


[Dbg]>>> import types
[Dbg]>>> dir(types)
['BooleanType', 'BufferType', 'BuiltinFunctionType',
'BuiltinMethodType', 'ClassType', 'CodeType', 'ComplexType',
'DictProxyType', 'DictType', 'DictionaryType', 'EllipsisType',
'FileType', 'FloatType', 'FrameType', 'FunctionType', 'GeneratorType',
'Instance
Type', 'IntType', 'LambdaType', 'ListType', 'LongType', 'MethodType',
'ModuleType', 'NoneType', 'NotImplementedType', 'ObjectType',
'SliceType', 'StringType', 'StringTypes', 'TracebackType', 'TupleType',
'TypeType', 'UnboundMethodType', 'UnicodeType', 'XRan
geType', '__builtins__', '__doc__', '__file__', '__name__']
[Dbg]>>>


Isn't the types module becoming superfluous?
That's the point I was trying to make. ArrayType is to ndarray as
DictionaryType is to dict. My understanding is that the use of
types.DictionaryType is discouraged.

-Travis
I was simply trying to suggest that the name ArrayType is more
appropriate name that ndbigarray or ndarray for the multidimensional
array. Since the intent is, in the long run, to integrate numpy with
the Python distribution, the use of a name in the style of the existing
Python types would appear to be better.

Is the types module becoming superfluous? I've cross posted to c.l.p to
seek information on this.

Colin W.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Members online

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top