rasbt/watermark

Lack of ISO 8601 date if we use options

ianozsvald opened this issue · 3 comments

Continuing the last thought...

Without options we get a summary of information and an ISO 8601 date.

%watermark

2016-01-31T21:17:31

CPython 3.4.4
IPython 4.0.1

compiler   : GCC 4.4.7 20120313 (Red Hat 4.4.7-1)
system     : Linux
release    : 3.16.0-38-generic
machine    : x86_64
processor  : x86_64
CPU cores  : 8
interpreter: 64bit

If we add extra options, we lose the ISO 8601 date-time (and just have the date):

%watermark -d -m -v -p numpy,matplotlib -g

2016-01-31 

CPython 3.4.4
IPython 4.0.1

numpy 1.10.2
matplotlib 1.5.0

compiler   : GCC 4.4.7 20120313 (Red Hat 4.4.7-1)
system     : Linux
release    : 3.16.0-38-generic
machine    : x86_64
processor  : x86_64
CPU cores  : 8
interpreter: 64bit
Git hash   : bd6a7a30199b5d52248b26ad0b6898a63b44a56a

Could we either have a new flag for an ISO 8601 date, perhaps -i which uses the same new strftime('%Y-%m-%dT%H:%M:%S')?

rasbt commented

Good point. I briefly thought about that when I switched over to the ISO 8601 format by default. However, I think many people may prefer to just show the date without data in certain cases, thus, I'd leave the -d argument as is.

On the other hand, there's the -c --custom_time flag which takes a strtime string as input so that one could feed it the '%Y-%m-%dT%H:%M:%S' string manually. In any case, I agree with you, an -i, --isodate flag sounds like a good idea to me.

How about adding an --isodate flag that takes the different iso strings as input and defaults to 'ISO8601'?

I think defaulting to the full ISO 8601 spec (with the option to override)
makes the best sense, cheers :-)

On 31 January 2016 at 21:33, Sebastian Raschka notifications@github.com
wrote:

Good point. I briefly thought about that when I switched over to the ISO
8601 format by default. However, I think many people may prefer to just
show the date without data in certain cases, thus, I'd leave the -d
argument as is.

On the other hand, there's the -c --custom_time flag which takes a
strtime string as input so that one could feed it the '%Y-%m-%dT%H:%M:%S'
string manually. In any case, I agree with you, an -i, --isodate flag
sounds like a good idea to me.

How about adding an --isoflag that takes the different iso strings as
input and defaults to 'ISO8601'?


Reply to this email directly or view it on GitHub
#10 (comment).

Ian Ozsvald (A.I. researcher)
ian@IanOzsvald.com

http://IanOzsvald.com
http://ModelInsight.io
http://MorConsulting.com
http://Annotate.IO
http://SocialTiesApp.com
http://TheScreencastingHandbook.com
http://FivePoundApp.com
http://twitter.com/IanOzsvald
http://ShowMeDo.com

rasbt commented

The date via -d was already in YYYY-MM-DD format, the only difference between the default ISO 8601 string vs -d -t was that the former uses a "T" as separator instead of a white space. To have -t and -d (i.e., some people may only want to use one or the other, not both?!), I added a -i/--iso8601 flag in #19