[Pywikipedia-bugs] [Maniphest] [Commented On] T76211: pywikibot external pycolorname used by catimages.py

2016-03-22 Thread DrTrigon
DrTrigon added a comment.


  Thanks for profiling. Looks good!
  
  Had a look at the pypi page and the color charts. I like it - good work!! 
(though I had no time to test the code yet)
  
  Thanks for you work!

TASK DETAIL
  https://phabricator.wikimedia.org/T76211

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: AbdealiJK, DrTrigon
Cc: Vlkyrie, DrTrigon, Aklapper, jayvdb, valhallasw, pywikibot-bugs-list, Anshoe



___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Commented On] T76211: pywikibot external pycolorname used by catimages.py

2016-03-07 Thread jayvdb
jayvdb added a comment.


  That is very nice!

TASK DETAIL
  https://phabricator.wikimedia.org/T76211

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: AbdealiJK, jayvdb
Cc: Vlkyrie, DrTrigon, Aklapper, jayvdb, valhallasw, pywikibot-bugs-list, Anshoe



___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Commented On] T76211: pywikibot external pycolorname used by catimages.py

2016-03-07 Thread AbdealiJK
AbdealiJK added a comment.


  @DrTrigon A benefit of using json :)
  
  
http://abdealijk.github.io/pycolorname/#/chart/pycolorname.pantone.pantonepaint.json
  
  PS : You can see all the color charts using the navbar on top

TASK DETAIL
  https://phabricator.wikimedia.org/T76211

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: AbdealiJK
Cc: Vlkyrie, DrTrigon, Aklapper, jayvdb, valhallasw, pywikibot-bugs-list, Anshoe



___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Commented On] T76211: pywikibot external pycolorname used by catimages.py

2016-03-06 Thread AbdealiJK
AbdealiJK added a comment.


  Just for completeness sake I tried out the profiler mentioned in the SO post 
for json vs pickle:
  
$ python profiler.py 
pickle:
5.83598685265
json:
0.551915884018
  
  I had to change this for 1000 runs as the default (100) took too long.
  was the times I got for logodesignteam's source. I used their source as they 
are exactly identical in the pkl and json (The others are not as can be seen in 
deprecation_test)

TASK DETAIL
  https://phabricator.wikimedia.org/T76211

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: AbdealiJK
Cc: Vlkyrie, DrTrigon, Aklapper, jayvdb, valhallasw, pywikibot-bugs-list, Anshoe



___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Commented On] T76211: pywikibot external pycolorname used by catimages.py

2016-03-06 Thread AbdealiJK
AbdealiJK added a comment.


  Hey,
  
  I believe everything has been already addressed except the following:
  
  JSON vs pickle
  --
  
  Even if speed is worse in json, I'd prefer it because human readable. We do 
not have a complicated class that requires pickling.
  This can easily have other language wrappers if it's json :)
  
  delta_e for color-math
  --
  
  There are multiple algorithms 76, 94, 2000, and cmc. I believe 2000 and cmc 
are popularly used, although there is no official standard. 2000 is the one 
color-math used to use by default and now it asks users to decide which 
algorithm to use. I was using cmc, but now I changed to 2000.
  Using 2000 I still get some differences, but 656 out of 992 have the same 
color as earlier. (They've re-factored how the delta_e works completely and 
that seems to have caused some change ?)
  Well, either way - I think this is not something that is high priority, as 
we're just using the pantonepaint dataset in pycolorname.
  
  Test with older datasets
  
  
  This was complicated. Because the websites have changed and the old data was 
quite different sometimes. But I've gotten something up and running.
  I've added a deprecationTest which compares the data from the last time. You 
can find it here 

  The email was just a quick way for you to convert pickle to json - you could 
easily use a difftool software to compare them then :) (But this test has 
explanations and is more detailed. You can ignore the email in favour of this)

TASK DETAIL
  https://phabricator.wikimedia.org/T76211

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: AbdealiJK
Cc: Vlkyrie, DrTrigon, Aklapper, jayvdb, valhallasw, pywikibot-bugs-list, Anshoe



___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Commented On] T76211: pywikibot external pycolorname used by catimages.py

2016-03-06 Thread DrTrigon
DrTrigon added a comment.


  > 1. Could you elaborate on how to do this ? I am not familiar with how to 
credit appropriately. The questions I have on this point are:
  >   - Where else should I credit developers ? (Currently Ive written your 
name as author in pypi and my name as maintainer - each of these can only be 1 
name according to PEPs)
  >   - Who are the other developers ? (The git log showed only your name)
  
  I only know of me as contributor - so if nothing else happened meanwhile, 
it's you and me.
  
  > - How do we mention the sources ? (Should I remove them from the readme?)
  
  I would remove the sources from the readme, yes but you can keep them in the 
code and comments of course. But may be not at the most prominet place... ;)
  
  > 3. In general json is supposed to be faster. The reason I personally prefer 
json is because it's human readable and easy to parse by anything. Note:
  >   - The colors from the pickle should be the same for most of them (I will 
check this myself and probably add a test for it too).
  
  Where is the test script located? (you mentioned something in a mail)
  
  > - The colors for cal-print source are different because it seems 
`colormath` changed it's implementation of `delta_e`. And they do not have docs 
nor code of the older releases so I'm unable to verify which method of 
computing delta_e they used.
  
  Indeed this is a good point. So we should include our own calculation method 
according to the international standards. Did you try to get in contact with 
the colormath developer?
  
  > 4. Yes, docs are important. Will make them :) Created 
https://github.com/AbdealiJK/pycolorname/issues/23 to handle this
  
  Write a very brief first example into the readme/pypi page, that will alrady 
allow others to get started with.
  
  > I have planned assignColorName like functionality check here 
 but I think it's best for 
a second release - as I'd like to read up on colortheory a bit more before 
doing that. So I was thinking after the gsoc proposal deadline.
  
  ...nice - so again we need colomath functionality included - good to see that 
you are working on it. Please include good literature into the docu as well, 
that important as a reference for later.
  
  Greetings

TASK DETAIL
  https://phabricator.wikimedia.org/T76211

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: AbdealiJK, DrTrigon
Cc: Vlkyrie, DrTrigon, Aklapper, jayvdb, valhallasw, pywikibot-bugs-list, Anshoe



___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Commented On] T76211: pywikibot external pycolorname used by catimages.py

2016-03-05 Thread jayvdb
jayvdb added a comment.


  Nice.  Based on your analysis, and the following addition by me, I believe it 
is safe to assume that @DrTrigon was the only prior contributor to pycolorname.
  
  From https://sourceforge.net/p/toolserver/code/3409/ we can see that the 
`catimages.py` code before pycolorname was a hard coded list, so there was no 
prior code from anyone else in that branch. (even if multiple people helped 
build the static list of colors, that list isnt code, and doesnt need 
crediting).

TASK DETAIL
  https://phabricator.wikimedia.org/T76211

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: AbdealiJK, jayvdb
Cc: Vlkyrie, DrTrigon, Aklapper, jayvdb, valhallasw, pywikibot-bugs-list, Anshoe



___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Commented On] T76211: pywikibot external pycolorname used by catimages.py

2016-03-05 Thread AbdealiJK
AbdealiJK added a comment.


  @DrTrigon Thanks for the comments
  
  1. Could you elaborate on how to do this ? I am not familiar with how to 
credit appropriately.
  
  The questions I have on this point are:
  
  - Where else should I credit developers ?
  - Who are the other developers ? (The git log showed only your name)
  - How do we mention the sources ? (Should I remove them from the readme?)
  
  I've created an issue on the repo too : 
https://github.com/AbdealiJK/pycolorname/issues/21
  
  2. yes. There's a bug at  https://github.com/AbdealiJK/pycolorname/issues/20
  
  3. In general json is supposed to be faster. The reason I personally prefer 
json is because it's human readable and easy to parse by anything.
  
  Note:
  
  - The colors from the pickle should be the same for most of them (I will 
check this myself and probably add a test for it too).
  - The colors for cal-print source are different because it seems `colormath` 
changed it's implementation of `delta_e`. And they do not have docs nor code of 
the older releases so I'm unable to verify which method of computing delta_e 
they used.
  
  4. Yes, docs are important. Will make them :)
  
  Created https://github.com/AbdealiJK/pycolorname/issues/23 to handle this
  
  I have planned assignColorName like functionality check here 
 but I think it's best for 
a second release - as I'd like to read up on colortheory a bit more before 
doing that. So I was thinking after the gsoc proposal deadline.

TASK DETAIL
  https://phabricator.wikimedia.org/T76211

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: AbdealiJK
Cc: Vlkyrie, DrTrigon, Aklapper, jayvdb, valhallasw, pywikibot-bugs-list, Anshoe



___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Commented On] T76211: pywikibot external pycolorname used by catimages.py

2016-03-05 Thread DrTrigon
DrTrigon added a comment.


  In https://phabricator.wikimedia.org/T76211#2091018, @jayvdb wrote:
  
  > More docstrings, especially module level docstrings, would be especially 
helpful, but structurally it looks very good to me.  Give @DrTrigon  a day or 
two to look at it before publishing.
  
  
  I agree with docstrings, it should give an nice docu with sphinx and or 
doxygen.
  
  I would be very happy, if I could get more than 2 days - more like 1 week or 
so... as I am not in wiki anymore partly due to this rush all the time. Thanks.
  
  In https://phabricator.wikimedia.org/T76211#2091114, @AbdealiJK wrote:
  
  > Hi,
  >
  > Just an FYI here. I've made a development release of pycolornames as 
@jayvdb was ok with it.
  >  You can see that at https://pypi.python.org/pypi/pycolorname
  >
  > Also, I've set it up so we have "nightly builds" whenever any Pull Request 
is merged using `rultor`.
  >  When @DrTrigon completes his review I will release a stable version.
  
  
  So first I would to tanks you for your work! I downloaded 
pycolorname-0.0.1.dev20160305125219.tar.gz and examined it as well as the pypi 
page at https://pypi.python.org/pypi/pycolorname. I think we still have some 
work to do in order to make the first major relase:
  
  1. I totally miss credits for other developers involved as well as proper 
licensing for http://www.pantonepaint.co.kr, http://www.logodesignteam.com, 
http://www.cal-print.com as well as http://www.ralcolor.com (it's questionable 
to me whether we should mention them at all - actually we would have to pay 
license fees to pantone to get such a table - these web pages have been kind or 
careless enough such that we were able to get the data - at least for once ;) - 
however you can mention Pantone and RAL - https://en.wikipedia.org of course. I 
don't like insisting on that stuff but I think we have to do this properly.
  
  2. There are formatting issues on the pypi page.
  
  3. I cannot compare databases under pycolorname/data/ easily due to changed 
format. I would have to sit down and write code for comparison. Is JSON faster 
than pickle for that size of data?
  
  4. Extending on jayvdb's comment I have to ask for docu containing examples, 
that explain how to use the code (I currently don't understand how, sorry). 
Therefore I cannot comment on the code yet.
  
  To extend on 4. a bit more,  basically we should implement something like in 
assignColorNames done:
  
  - a method that allows to search for a color's name given the RGB value of 
that color
  - this method should return the most close match out of the set of names we 
have in the database and the distance (colormath)
  - this assignments for every RGB value could be pre-calculated and stored in 
a DB in advance as well - not sure whether I tried this once but the DB was 
insanely big... - we should give it a try, it would speed the code up and 
remove the colormath dependency for end-users
  
  This is what I've found so far - all the best!

TASK DETAIL
  https://phabricator.wikimedia.org/T76211

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: AbdealiJK, DrTrigon
Cc: Vlkyrie, DrTrigon, Aklapper, jayvdb, valhallasw, pywikibot-bugs-list, Anshoe



___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs


[Pywikipedia-bugs] [Maniphest] [Commented On] T76211: pywikibot external pycolorname used by catimages.py

2016-03-05 Thread AbdealiJK
AbdealiJK added a comment.


  Hi,
  
  Just an FYI here. I've made a development release of pycolornames as @jayvdb 
was ok with it.
  You can see that at https://pypi.python.org/pypi/pycolorname
  
  Also, I've set it up so we have "nightly builds" whenever any Pull Request is 
merged using `rultor`.
  When @DrTrigon completes his review I will release a stable version.

TASK DETAIL
  https://phabricator.wikimedia.org/T76211

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: AbdealiJK
Cc: Vlkyrie, DrTrigon, Aklapper, jayvdb, valhallasw, pywikibot-bugs-list, Anshoe



___
pywikibot-bugs mailing list
pywikibot-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs