摘要: timedalte 是datetime中的一个对象,该对象表示两个时间的差值 构造函数:datetime.timedelta(days=0, seconds=0, microseconds=0, milliseconds=0, minutes=0, hours=0, weeks=0) 其中参数都是可选,默认值为0 下面应该是常识,几乎每个人都知道: 1 millisecond = 1000 microseconds 1 minute = 60 seconds 1 hour = 3600 seconds 1 week = 7 days 在构造函数中,参数值的范围如下: 0 <= microseconds < 1000000 0 <= seconds < 3600*24 (the number of seconds in one day) -999999999 <= days <= 999999999 timedalte 有三个只读属性: timedelta.min:负数最大时间差,相当于 timedelta(-99999999 阅读全文
posted @ 2018-09-18 22:01 X18301096 阅读(940) 评论(0) 推荐(0) 编辑
摘要: 获取Tensor维度的两种方法: Tensor.get_shape() 返回TensorShape对象, 如果需要确定的数值而把TensorShape当作list使用,肯定是不行的。 需要调用TensorShape的as_list()方法, 需要调用TensorShape.as_list()方法来获 阅读全文
posted @ 2018-09-18 18:52 X18301096 阅读(5301) 评论(0) 推荐(0) 编辑