What is data type for Python Keras deep learning package?

前端 未结 1 818
野趣味
野趣味 2021-02-06 13:38

I didn\'t find anything about data type that we need to work with Python Keras deep learning package with this link. I checked array and list but returned error. An

相关标签:
1条回答
  • 2021-02-06 13:54

    Keras uses numpy arrays containing the theano.config.floatX floating point type. This can be configured in your .theanorc file.

    Typically, it will be float64 for CPU computations and float32 for GPU computations, although you can also set it to float32 when working on the CPU if you prefer.

    You can create a zero-filled array of the proper type by the command

    X = numpy.zeros((4,3), dtype=theano.config.floatX)
    
    0 讨论(0)
提交回复
热议问题