Commons talk:CropTool/Archive 3

From Wikimedia Commons, the free media repository
Jump to navigation Jump to search
← Archive 2 Archive 3 Archive 4 →

Upload error

I was trying to upload a separate cropped version of an image when I got this error:

Upload failed! [api] Received error: modification-failed : The file "Mathieu Smedts.jpg" does not exist on [https://commons.wikimedia.org/ Wikimedia Commons].

Indeed, there's no Commons image by that name yet, but the cropping is supposed to create the image by that name. Is there any way to fix it? ミラP@Miraclepine 02:34, 3 November 2020 (UTC)

@Miraclepine: I managed to do it for you with File:Mathieu Smedts.jpg.   — Jeff G. please ping or talk to me 06:45, 13 December 2020 (UTC)
@Jeff G.: Thank you very much. ミラP@Miraclepine 06:47, 13 December 2020 (UTC)
@Miraclepine: You're welcome.   — Jeff G. please ping or talk to me 06:55, 13 December 2020 (UTC)

down for weeks

Why is nobody able to fix its functionality?! Not amused, --Mateus2019 (talk) 15:06, 12 March 2021 (UTC)

@Mateus2019: Can you give more details about what is not working for you, such as what files you have been unable to crop? I have not experienced any recent problems; for example, I cropped File:Davis Square 1913 postcard.jpg moments ago. Pi.1415926535 (talk) 22:07, 13 March 2021 (UTC)
Two blue lines are moving horizonally. The program waits for an action by the browser, I guess. Must be a issue with my Firefox. --Mateus2019 (talk) 00:43, 14 March 2021 (UTC)
I too have had no issues, and I'm using both Firefox and Chrome. Is there a particular image you are trying this on? Link? Huntster (t @ c) 04:49, 14 March 2021 (UTC)

Blocked user

The following report I received for uploading a cropped image: "Upload failed! [api] Received error: autoblocked : Your IP address has been blocked automatically, because it was used by a blocked user." In Commons I'm not blocked, I've no idea, why I should be blocked in CropTool, and no idea, how to be unblocked.
Why does the message only appear the moment I try to upload the image and not immediately? Why is the blocked user not named? Am I blocked or someone hijacked my IP address?--Im Fokus (talk) 03:25, 26 March 2021 (UTC)

It's not you — I get the same error. If I had to guess, I would say that an IP address used by CropTool server has been blocked. —Iketsi (talk) 04:07, 26 March 2021 (UTC)
I just got this same block for the first time today. What's happening? ɱ (talk) 14:51, 26 March 2021 (UTC)
Same I got the same block error and cannot crop images anymore. Anyone know how to fix this or who to reach out to. --TDKR Chicago 101 (talk) 14:58, 26 March 2021 (UTC)
It was happening because of some autoblocks which affected Toolforge, they are now unblocked. Should be good now. -- CptViraj (talk) 15:38, 26 March 2021 (UTC)
Works now, thanks. ɱ (talk) 17:03, 26 March 2021 (UTC)
The same for me, thanks --Im Fokus (talk) 04:03, 27 March 2021 (UTC)

.gif

Would be nice if it worked on .gifs. Tried to crop this[1] and got [2] which does not move. Doc James (talk · contribs · email) 17:12, 8 April 2021 (UTC)

uploaded an animated version. --C.Suthorn (talk) 08:14, 9 April 2021 (UTC)

Can't upload. Errors from abusefilter. Why?

Hello, I'm new to commons, but an established editor (itsfullofstars) on the en wikipedia. I'm trying to upload a cropped version of an existing commons image and I'm getting this error:

Upload failed! [api] Received error: abusefilter-disallowed : ⧼abusefilter-warning-scope

I have no idea why an abuse filter is being triggered. The original image I'm trying to crop (there's too much sky above the airplane) is here:

https://commons.wikimedia.org/wiki/File:Douglas_DC-7,_United_Airlines_JP6922277.jpg

I was attempting to upload the cropped version under a new name so as not to mess with the original. Can someone help? Thanks in advance. Itsfullofstars (talk) 16:47, 8 June 2021 (UTC)

Addendum: Maybe I used the wrong terminology when I said I was 'uploading'. I was just using the CropTool on an existing image of commons, not really uploading from my PC, per se. Also, I DO have a small upload history (I uploaded an image on May 15, 2021) so I'm not a brand-new commons user with zero history. I just wanted to make that clear, because after looking at the FAQ it seems that brand-new users have extra restrictions. While I was at the commons FAQ I searched for the word 'abuse' and there were no hits. I'm stumped why a mysterious 'abusefilter' doesn't like me, especially since the original file I want to create a cropped version of is already on commons, and has been there since 2014. Itsfullofstars (talk) 21:39, 8 June 2021 (UTC)
Looks like you were a false positive for an abuse filter. This particular filter disallows users with less than 10 edits from creating any page including the text "infobox" in order to prevent mistaken creation of articles. The file you were cropping happened to have an information template, {{Infobox aircraft image}}, which triggered the filter. The issue should go away once you have ten edits on Commons - you could make a few edits to your user page, or use your expertise to identify some files in Category:Unidentified jet-powered civil aircraft. Cheers, Pi.1415926535 (talk) 22:10, 8 June 2021 (UTC)
Thanks so much! I 've identified my first aircraft and categorized it...
https://commons.wikimedia.org/wiki/File:20150714_AIR,_Clinton_(Illinois),_N931LR_IMG_6371_by_sebaso.jpg
Itsfullofstars (talk) 04:42, 9 June 2021 (UTC)
I just used the CropTool successfully, now that I have enough edits. Thanks again. Itsfullofstars (talk) 06:16, 9 June 2021 (UTC)

PDF quasi-extract

I and another editor (discussion) recently separated out the images in File:Prehistoric and Medieval Skis from Glaciers and Ice Patches in Norway.pdf for use on Wikisource . This entailed:

  1. Downloading the full file
  2. In my own PDF viewer offline, right-clicking on the first image, giving it an appropriate name in the form "Source-article-name_Figure-number_shortened-figure-caption", and saving it as a jpg, repeat for each of the images.
  3. Uploading all these high-res files (took awhile, and some uploads failed on the first try).
  4. Manually copying all the (machine-readable, already formatted in Wikisource) figure captions from the paper into the metadata of each image.
  5. Manually re-associating each image with the relevant position in the Wikisource text and formattiing it.

Had the PDF been a scan with one image per page, I'd have had to:

  1. crop the images manually
  2. name them
  3. save them
  4. possibly run them through a standard command-line script for restoring yellowed paper, or rotate them to be square and upright, using other desktop programs
  5. re-upload
  6. re-caption with text already machine-readable on Wikisource
  7. re-associate them with their positions in the book

Here's an example, from a historically important book. This book is linked to on Wikipedia, and contains many line drawings that could be useful there. The book is on a visual topic and greatly benefits from illustrations, some of which have been cropped and inserted, and some of which have also been restored, but most of which have simply been missing for years.

Volunteers could do much more were some of this automated and less tedious. Images, separated out, would be much more useful on Commons. It would encourage people to upload heavily-illustrated books to Commons. It would also save bandwidth and hence energy. I do not need millions of pixels to crop or rename an image; a thumbnail would do fine.

Really any incremental improvement on the status quo would be very welcome, so I hope no-one will be daunted by the perfectionist features list below.

Desired workflow, first rough draft, suggestions welcome

For PDF files with embedded image files, auto-extract, auto-name according to a given pattern, auto-add captions if such are identifiable (if in doubt, add surrounding text to the field in question and prompt human review before saving separate files; manual removal of extraneous text is faster).

If the images cannot be extracted automatically, semi-automate:

  • On the Wikisource document page, go to the template indicating that there was an illustration at this point in the original; this should link to a page loading the scanned page image in the croptool. Either:
    • Adjust automated guess as to which rectangles contain illustrations
    • Manually draw a polygon around the illustrations (rectangle default)
  • Rotate as needed, with a preview tool. This could probably be semi -automated, such as for images in rectangular frames which are 15 degrees or so off-square.
  • When all the images to be extracted have been displayed, if the colour adjustment is bad, click for automated colour adjustment (the aforementioned script's algorithm).
    • If the automatic colour adjustment is bad (unlikely), click to skip the colour adjustment and template the cropped Commons file as needing white balance adjustment. Otherwise, click "Done"
  • Click OK. The images are automatically cropped, adjusted, uploaded with suitable metadata (derived from Wikisource, which already has a machine-readable source and caption) to Commons, and inserted into the Wikisource text.

As this must be repeated for every illustrated scanned page in the book, it might be nice to save the previous settings as a default or make batches possible.

I should note that I tried to request a tool for semi-automating this task at last year's Community Wishlist Survey, but the nomination was rejected for lack of a clear description of the problem, and I did not respond in time, so it was never !voted on. Comments welcome! HLHJ (talk) 04:08, 23 September 2020 (UTC)

While not perfect, you can at least have commons extract the single pages from the pdf:
https://upload.wikimedia.org/wikipedia/commons/thumb/2/27/PDF_metadata.pdf/page2-1240px-PDF_metadata.pdf.jpg
insert the page number for the page you want to extract, and use the original size of the pdf as px-size.
--C.Suthorn (talk) 11:26, 21 December 2020 (UTC)
Yes, that's often not bad for full-page illustrations, though it does leave wide printer's margins which look odd online. For multiple images per page, and images with flowed text around them, it's not as good. Both are common in old books and digital-native academic papers (sorry for the slow reply, C.Suthorn!). HLHJ (talk) 03:38, 2 June 2021 (UTC)
Actually, just being able to crop multiple images from a PDF at once, then preview them all at once, would be a great time-saver. HLHJ (talk) 04:03, 11 June 2021 (UTC)

Difference b/w this and windows photos

Is there any difference in quality if instead of using this croptool, I download the image in windows computer and use edit mode of "photos" app and re-upload? -- Parnaval (talk) 16:49, 28 July 2021 (UTC)

@Parnaval: Yes, Photos for Windows can't crop losslessly, so you will get generational loss with it using any lossy compressed format like jpg.   — Jeff G. please ping or talk to me 17:04, 28 July 2021 (UTC)
Thanks -- Parnaval (talk) 07:15, 29 July 2021 (UTC)
@Jeff G.: In File:Disha-Patani-grace-the-premiere-of-Bharat-in-Mumbai-47.jpg, Yesterday I cropped using windows photos and today I reverted it to full body photo and now cropped using CropTool. I don't see image quality difference in both crops See photos version and croptool version. The difference is in photo size only. Why is it? and what is special "lossless" in croptool if its version is same as photos? -- Parnaval (talk) 07:39, 29 July 2021 (UTC)
@Parnaval: It's not much of a difference in the first generation. Please read COM:OW.   — Jeff G. please ping or talk to me 10:44, 29 July 2021 (UTC)
@Jeff G.: OK, thanks. Now I understood croptool.; I cropped the image to remove watermark but now I understood that it is a major crop. I will upload a separate file from next time. -- Parnaval (talk) 11:19, 30 July 2021 (UTC)
@Parnaval: You're welcome.   — Jeff G. please ping or talk to me 14:43, 30 July 2021 (UTC)

2 questions

Hi, thanks for developing this great tool. Recently, I want to crop images from both pages of the book into one image (see File:Serat Damar Wulan (page 12-13 crop).jpg for example), but the tool lack the option to do so, which is understandable. Hopefully this could be implemented in the future.

Since I don't want to upload 2 files to Commons (there's almost 200 illuminations in that PDF, I want to combine some of them that are side-by-side), I had to resort to upload one file (page 12), then overwrite it with the final image (page 12-13).

My questions are:

  1. After I arrive at the last step just before clicking upload, where does the full size (not thumbnail) version is stored? Is it possible to download it without uploading it to the Commons first? I believe it would be useful provide a link to download the cropped image, not just upload it to Commons.
  2. If the above method is not possible for whatever reason, is it possible to upload and overwrite a file (a temp file) in Commons? (in my case I tried it at File:Serat Damar Wulan (page crop).jpg) That way I could upload the temp files there, and at the end I would ask admin to delete just that one file (compare to uploading and asking to delete ~100 files). I'm asking because there's already a feature to upload the original file, so making a feature to upload to another file should not be a problem.
    It could be pointing to Test.jpg or something...

Thank you for whoever maintain this tool and/or could help me with this! Bennylin (yes?) 09:58, 30 September 2021 (UTC)

Bennylin, I cannot answer question #1 as I'm not a developer, but I can answer #2. Yes, you can perform test uploads to specific filenames based on the image format. They are: File:JPG Test.jpg, File:PNG Test.png, File:Test.gif, File:Test.svg, and File:Test.pdf. Just remember to revert your upload back to the test placard when you're finished testing! Huntster (t @ c) 18:33, 30 September 2021 (UTC)
Huntster Thanks for the response! What I meant for #2 is to upload (and overwrite) the test file from the croptool. It goes back to #1, because I don't have the full size image to download, so I need to upload it first, but I don't want to upload ~100 images that I have to request to delete. (croptool is the only way for me to get the high-res crop from the PDF. Feel free to suggest any other cropping tool that can crop up to 3000px).
The flow would be: I crop the page, when there's form asking if I want to upload to a new file, I enter File:Serat Damar Wulan (page crop).jpg as the target filename, and when I click "Upload", there will be a prompt "Do you want to overwrite that file?", then I click "Yes", and it will be overwritten. Repeat ~100 times. I know it's not ideal, but I'd prefer to upload the highest possible res while I can for this collection, and the images are not meant to be separate, but joined (left and right page). Bennylin (yes?) 18:39, 30 September 2021 (UTC)
Bennylin, I agree that the highest resolution files are best. I see no problem with the route you are proposing, using the filename as a temporary host. Let me know on my talk page when you are finished and I can remove it for you. Huntster (t @ c) 19:34, 30 September 2021 (UTC)

SSL certificate problem error message

I go to make use of CropTool on some images which I've just uploaded (having previous made use of it) and I get a prompt asking to connect to my Wikimedia account. Odd in that i've used it in the past, but I've not used it for a while so probably some housekeeping done in the interim. I tell it to connect, but I get this for an error message: "Curl error: SSL certificate problem: certificate has expired." Huh?? Tabercil (talk) 14:25, 30 September 2021 (UTC)

@Tabercil and Danmichaelo: https://croptool.toolforge.org/ and https://croptool.toolforge.org/api/auth/login? give me that error message.   — Jeff G. please ping or talk to me 15:26, 30 September 2021 (UTC)
Thank you, so it's not just me. Tabercil (talk) 17:06, 30 September 2021 (UTC)
Did some playing around - error message appears irregardless of what browser I use to access it. Whether it's Firefox that's locked down with script and cookie filters, or Edge in it's default state (which I deliberately keep that way for those rare sites that do not play nice with Firefix). So it doesn't appear to be something that's on my end. Tabercil (talk) 19:43, 30 September 2021 (UTC)
Needs fixing; I can't use the CropTool either. Schwede66 21:34, 30 September 2021 (UTC)
Looks like https://lists.wikimedia.org/hyperkitty/list/cloud-announce@lists.wikimedia.org/thread/BULX5O3EL4TN5BKHQFAG5TTMEEZLXLOY/MarcoAurelio 21:55, 30 September 2021 (UTC)
Interesting... so how does a fix happen on that? Is there a way it can be done at this end? Tabercil (talk) 05:43, 1 October 2021 (UTC)
@Tabercil, Schwede66, MarcoAurelio, and Xaosflux: It's not just CropTool. You may track progress of the fixes at phab:T291387.   — Jeff G. please ping or talk to me 11:05, 1 October 2021 (UTC)
Working again, so looks like they fixed the certificate issue. Tabercil (talk) 21:52, 1 October 2021 (UTC)

500 API error

Looks like a great tool. However, when I added it to my preferences and went to an image then clicked on the #CropTool link (step 2 in the Commons:CropTool instructions), I get the following error message: "500 [api] Received error: mwoauth-invalid-authorization-invalid-user : The authorization headers in your request are for a user that does not exist here." If I continue to step 3, to Allow OAuth server, click Allow, then I go back to the error page again. --Greg Henderson (talk) 21:57, 9 October 2021 (UTC)

@Greghenderson2006: Hi, and welcome. Are you logged in to https://www.mediawiki.org ? Are you accepting cookies from there? Are you allowing cross-site scripting on WMF domains?   — Jeff G. please ping or talk to me 22:50, 9 October 2021 (UTC)
@Jeff G.: Yes, I am logged in; I am using the default preferences. I do accept cookies unless there is a prefernce to turn ON; Not sure about cross-site scripting on WMF domains; Is there anything you have to do in mediawiki.org? I am using a Mac and Safari. --Greg Henderson (talk) 23:02, 9 October 2021 (UTC)
@Greghenderson2006: Do you have "no-cross-site-tracking on"? That turned out to be the problem at Commons talk:DerivativeFX#Tool down?.   — Jeff G. please ping or talk to me 23:47, 9 October 2021 (UTC)
@Jeff G.: Yes, prevent cross-site-tracking is OFF. With Google Chrome it works without a problem. Must be a Safari issue. Thanks for your help! --Greg Henderson (talk) 00:11, 10 October 2021 (UTC)
@Greghenderson2006: You're welcome!   — Jeff G. please ping or talk to me 11:40, 10 October 2021 (UTC)

Wrong categories

Hello,

this file, like many others, is not a featured picture. But the CropTool adds it in wrong categories. I've fixed the issue here, here, and in other files (none were my own derivative works), but that's not finished. Other photographers are not active on the project, or not ready to fix others' mistakes. So I'd like to learn how to deal with the issue.

According to the archives (here), the problem was raised by Geagea: "Also most of users do not remove extra categories. Maybe if they have the list of categories with +/- it would be easier for them remove them." But apparently not managed. Best regards -- Basile Morin (talk) 06:33, 11 October 2021 (UTC)

Yes, it was good suggestion but nobody fix it. moving the info from "description" field to " Original file description" is essential change. Letting an option to add description would be also useful. and the last issue is the categories. Now I see that removing "Featured pictures" templates are also needed. -- Geagea (talk) 07:36, 11 October 2021 (UTC)
Thanks, Geagea. I agree with your proposal. The tool seems to remove automatically the QI-related categories, but not the FP ones. Concerning the standard categories, the uploaders don't bother with them, and the interface does not help. Example with my photographs, but that's easy to verify also on many others (for example Kim Jong Un (alone) "with Vladimir Putin", until someone notices several months later). The users of this tool consider there is no CropTool manual or interface, "so this might be a documentation issue." The page COM:CropTool does not say anything either -- Basile Morin (talk) 08:11, 11 October 2021 (UTC)

False positive?

When I attempted to crop this image, I got this notice: "The overwrite option is disabled because the image has passed an assessment process." Unnamed UserName me 07:46, 7 October 2021 (UTC)

@Danmichaelo: What "assessment process"?   — Jeff G. please ping or talk to me 22:56, 9 October 2021 (UTC)
@Jeff G.: I didn't get that tag... again. The tool seems to have some kind of false positive. When I attempted to overwrite it, I checked the history over and over again just to make sure that the only revision was original uploader's. Unnamed UserName me 19:24, 16 October 2021 (UTC)
Probably because the image was assessed as "digital watermark"ed. (which is funny, bacause the watermark could be removed by cropping) --C.Suthorn (talk) 04:55, 17 October 2021 (UTC)
@C.Suthorn: That would be counterproductive. @NguoiDungKhongDinhDanh: Did you get this?   — Jeff G. please ping or talk to me 09:16, 17 October 2021 (UTC)
Yes, finally. Unnamed UserName me 09:21, 17 October 2021 (UTC)

error while trying to extract image from DjVu files

Recently, when trying to extract a picture from a djvu file, Croptool failed, with message " Command "convert '/mnt/nfs/labstore-secondary-tools-project/croptool/public_html/files/72063e998a89064c9173fb0d87fcd10262969354.djvu.page1.jpg.tiff' '/mnt/nfs/labstore-secondary-tools-project/croptool/public_html/files/72063e998a89064c9173fb0d87fcd10262969354.djvu.page1.jpg' 2>&1" exited with code 1: convert-im6.q16: memory allocation failed `/mnt/nfs/labstore-secondary-tools-project/croptool/public_html/files/72063e998a89064c9173fb0d87fcd10262969354.djvu.page1.jpg.tiff' @ error/tiff.c/ReadTIFFImage/1622. convert-im6.q16: no images defined `/mnt/nfs/labstore-secondary-tools-project/croptool/public_html/files/72063e998a89064c9173fb0d87fcd10262969354.djvu.page1.jpg' @ error/convert.c/ConvertImageCommand/3258."

example on https://croptool.toolforge.org/?title=Thoinan_-_Les_Relieurs_fran%C3%A7ais,_1893.djvu

Thanks for your help on this --Hsarrazin (talk) 10:56, 3 February 2022 (UTC)

[Error] undefined

C.Suthorn (talk) 12:09, 9 November 2021 (UTC)

@C.Suthorn: I reported this problem here. Seudo (talk) 10:59, 23 February 2022 (UTC)

Not working

CropTool is not working on Chrome. Leonprimer (talk) 04:01, 3 June 2022 (UTC)

Chrome OS

CropTool is not working on Chrome OS.

A red triangle and the message "{{ warning | translate }}" appears when I go here.

Some Dude From North Carolina (talk) 18:08, 24 March 2022 (UTC)

Getting a bad gateway on clickthrough here. — LlywelynII 01:52, 3 June 2022 (UTC)
I'm getting 502 Bad Gateway on both Chrome and Firefox right now. Pi.1415926535 (talk) 04:30, 3 June 2022 (UTC)
Pinging @Danmichaelo.   — Jeff G. please ping or talk to me 00:37, 4 June 2022 (UTC)

Tif not working

Possibly I crashed it yesterday when trying to use it on a large tiff file (> 300 MB). Would you check? Enhancing999 (talk) 07:11, 8 June 2022 (UTC)

Pinging @Danmichaelo what do you think? Enhancing999 (talk) 08:24, 10 June 2022 (UTC)

Webp

The crop tool doesn't work for .webp images - is there a reason it can't be made to do so? Andy Mabbett (Pigsonthewing); Talk to Andy; Andy's edits 12:47, 15 June 2022 (UTC)

Croptool used gs for pdfs and ddjvu for djvu files but stopped to do so recently. For webp files it is not shown on the file descripiton page.
It looks like the maintainer is not available at the moment, otherwise he would fix pdf and djvu. It does not like that he will add webp soon. C.Suthorn (talk) 13:13, 15 June 2022 (UTC)

Lossless mode no longer working?

@Danmichaelo, is lossless mode still working. I used to get messages that the crop size had been adjusted because I wasn't starting on a multiple of 8 or 16, but this has gone away. Similarly, there's a bug report on github (#170) reporting that files that should be uncroppable in lossless mode are now working, but produce the same files as if they were in precise mode. Is the tool silently falling back to precise when lossless doesn't work (which would be undesirable), or is something else going on here? Perhaps a bug introduced in the September 2020 refactoring? Ahecht (TALK
PAGE
) 14:59, 15 June 2022 (UTC)

Looking into the code more, it seems like the September 2020 refactor fundamentally broke things. The various types of crop were broken out into subclasses (for example, lossless Jpeg cropping was broken out into JpegFile and Gif cropping to GifFile), but as far as I can tell the only subclasses that are actually being called out by the program in FileRepository.php are TiffFile, DjvuFile, PdfFile, and SvgFile, all of which return errors instead of actually working. All other file types are being handled by the generic imagemagick call in File.php.
This is why lossless crops are no longer lossless, Gif files say they are being cropped with precise or lossless mode instead of "gif mode", and TIFFs, PDFs, and DJVUs no longer work.
If these issues aren't easy to resolve, perhaps to the tool should be rolled back to 1.4 (before the refactoring). Ahecht (TALK
PAGE
) 14:18, 17 June 2022 (UTC)

Tiff files

Should we not block use of this tool for cropping tiff files?

Reference files should kept as original. Only jpg's are good for cropping, tiff are not. If used on wikipedia they (tiff) should be converted into jpg, cropped or not?

Arguably the same should be for png's (depending on size). ̴̴ Broichmore (talk) 15:09, 15 January 2022 (UTC)

@Broichmore: We should not. Some people have old scanners and software that can only produce full-page tiff files for scans.   — Jeff G. please ping or talk to me 15:52, 17 January 2022 (UTC)
@Jeff G.: None uploaded this year. The only tiff's that have been uploaded have come pre-cooked from institutions. In any event they are already cropped. I have yet to see any privately uploaded tiff files, and in any event they would not want cropping. Numbers must be miniscule. Abuse of reference files is a more pressing problem. If they want cropping they should be presented as jpg's. Broichmore (talk) 16:33, 17 January 2022 (UTC)
@Broichmore: File:Air Bellows Gap, Milepost 237.1, Blue Ridge Parkway (331f93c4a4a541bc87ba31e155973b6a).tif was uploaded this year and cropped by BMacZero. File:Constance Byström, rollporträtt - SMV - GB192.tif was cropped this year by Chiswick Chap. That's all I could get from this log.   — Jeff G. please ping or talk to me 14:36, 26 January 2022 (UTC)
Well that would only justify blocking the 'Overwrite' option, but even that is rather doubtful - all I did was trim a bit of deadspace, and institutions can be quite relaxed about providing images with plenty of that. I don't think it's worth messing with the tool, actually: it's clear that people use the option very rarely. A bigger problem is with the size of some of the TIFFs which can be approaching the 100 Mbyte limit, making the images difficult or impossible to manipulate on ordinary PCs. Chiswick Chap (talk) 14:51, 26 January 2022 (UTC)
I agree with Jeff G. and Chiswick Chap; there are valid reasons to crop tiffs and PNGs following the same rules as any other file type. If it is true that tiffs are most frequently used for archival/reference material, the furthest I'd go is adding an extra-noticeable warning suggesting new file mode when cropping tiffs in overwrite mode. That would have prevented me from overwriting the file above (oops). – BMacZero (🗩) 23:20, 27 January 2022 (UTC)
What valid reasons?, cropping is a degrade on any type of image, and reference files are supposed to be maximum definition, why else have them?
Here is a warning (not mine) on File:Receiving ship "Vermont.", from Robert N. Dennis collection of stereoscopic views.jpg
This image is a JPEG version of the original PNG image at File: Receiving ship "Vermont.", from Robert N. Dennis collection of stereoscopic views.png.
Generally, this JPEG version should be used when displaying the file from Commons, in order to reduce the file size of thumbnail images. However, any edits to the image should be based on the original PNG version in order to prevent generation loss, and both versions should be updated. Do not make edits based on this version. See here for more information.
As for old scanners that were tiff only, your talking about the year 2000. Broichmore (talk) 15:25, 28 January 2022 (UTC)
Many museums, for example the Cleveland Museum of Art, have very kindly uploaded thousands of tif files that often have huge margins and need considerable cropping before using on wp & no doubt many other places. Here's an example. Johnbod (talk) 17:15, 23 June 2022 (UTC)

Error: Command not found

Command not found: "gs -sDEVICE=jpeg -dNOPAUSE -dBATCH -dSAFER -dFirstPage='1' -dLastPage='1' -r300 -dUseCropBox -sOutputFile='/data/project/croptool/public_html/files/dd0c7d93e00a8129ba4635e9d19ac3a605da9601.pdf.page1.jpg' '/data/project/croptool/public_html/files/dd0c7d93e00a8129ba4635e9d19ac3a605da9601.pdf' 2>&1" 

I got this error when I tried to crop from File:Chrita.pdf - https://croptool.toolforge.org/?page=1&site=commons.wikimedia.org&title=Chrita.pdf. Bennylin (yes?) 13:47, 11 June 2022 (UTC)

Yes, pdf and tiff documents seem to have the same problem Enhancing999 (talk) 18:14, 11 June 2022 (UTC)
V2c cannot find ghostscript. Maybe the path has changed. C.Suthorn (talk) 18:48, 11 June 2022 (UTC)
Both worked on the 6, maybe the 7 Enhancing999 (talk) 18:51, 11 June 2022 (UTC)
A patch was added around these dates by @Danmichaelo. This may have lost us tif,pdf,djvu .. Enhancing999 (talk) 19:45, 15 June 2022 (UTC)
I'm getting " Command not found: "convert '/data/project/croptool/public_html/files/a6cf9d2ddcda95f65576379fef1961f2163b0332.tiff[0]' '/data/project/croptool/public_html/files/a6cf9d2ddcda95f65576379fef1961f2163b0332.tiff.page1.tiff' 2>&1" " on a tiff. Johnbod (talk) 16:57, 23 June 2022 (UTC)

djvu and pdf files

The Crop Tool no longer works for me on .djvu files. I get an error like this one:

Command not found: "ddjvu -page='1' -format=tiff '/data/project/croptool/public_html/files/3a60eb397cdb491aef21fa9d985c12deb25ec4fe.djvu' '/data/project/croptool/public_html/files/3a60eb397cdb491aef21fa9d985c12deb25ec4fe.djvu.page1.jpg.tiff' 2>&1"

Gamaliel (talk) 16:33, 14 June 2022 (UTC)

@Gamaliel: same for a pdf file (File:FR631136102 - La fortification, le théâtre du monde ou le petit atlas - MS 267.pdf) « Command not found:

gs -sDEVICE=jpeg -dNOPAUSE -dBATCH -dSAFER -dFirstPage='1' -dLastPage='1' -r300 -dUseCropBox -sOutputFile='/data/project/croptool/public_html/files/661f92acc646dd9220ef8db42c343d1db64d8e75.pdf.page1.jpg' '/data/project/croptool/public_html/files/661f92acc646dd9220ef8db42c343d1db64d8e75.pdf' 2>&1"

Cdlt, VIGNERON en résidence (talk) 07:40, 13 July 2022 (UTC)
Edit: the problem is known and reported here github.com/danmichaelo/croptool/issues/174. Cdlt, VIGNERON en résidence (talk) 07:42, 13 July 2022 (UTC)

Fork for tiff/pdf?

To continue to use this for tiff/pdf files, it would be good to have a separate version with the code as of last month. -- Enhancing999 (talk) 10:21, 21 June 2022 (UTC)

Since the error message is "Command not found", the problem is not necessarily related to a code change. Maybe a file or path has been modified on the server. Seudo (talk) 10:09, 11 July 2022 (UTC)
The last code changes were on the day it broke. Enhancing999 (talk) 11:59, 11 July 2022 (UTC)

Bulk processing of border removal

Is there are a way to do bulk processing? I noticed at Category:Views from Peak Walk (Scex Rouge), most photos have a border that probably looks good in some contexts, but not necessarily here or in Wikipedia.

The feature "magic border locator" correctly recognizes it.

This might apply to many more in Category:Photographs by János Korom (40000+ images). Enhancing999 (talk) 11:15, 14 July 2022 (UTC)

Structured data

When creating a new image with the tool, would it be possible to copy across some or all of the structured data to the new image? (Plus any suitable additional statements to identify the new image as based on (P144) the old one)

I recently used the tool on this geograph photo to extract the just the plaque, and got a bit of a shock when the new image had a description template that was completely blank. (Because all of the metadata for the geograph image had been stored as structured data, and none of it had been copied across).

This is presumably going to become more and more of an issue, as increasingly more images have more of their metadata stored as structured data rather than wikitext. -- Jheald (talk) 18:37, 16 July 2022 (UTC)

Remove border, but upload under new name

It could be interesting to make the following work:

as here.

It means the border should be removed, but uploaded under a new name. This works mostly (overwrite is disabled, edit summary "border removed" is added) except that {{Remove border}} doesn't get removed during the crop [3] and {{Border is intentional}} ends up on the new version without the border [4]. Enhancing999 (talk) 20:12, 28 July 2022 (UTC)

@Enhancing999: The tool has nothing to do with those templates, it just copies them with almost everything else from old file description page to new.   — Jeff G. please ping or talk to me 20:56, 28 July 2022 (UTC)
It recognizes them and does some sensible things:
- Enhancing999 (talk) 21:06, 28 July 2022 (UTC)

To summarize the changes:

  • make the checkbox "removed border" appear by default (unchecked unless magic border removal is used or (as currently) {{Remove border}} is present)
  • remove {{Border is intentional}} when uploaded as new file (always)
  • {{Remove border}} from original file when uploaded as new file option is used and "removed border" was checked (same as when original file is overwritten).

{{Do not crop}} should do the same as {{Border is intentional}}. Enhancing999 (talk) 05:43, 29 July 2022 (UTC)

% of original image in summary

In the summary, there is just "11 % horizontally, 24 % vertically" (percentages from a random crop).

"32 % overall" (or something like it, based on the other percentages) could indicate the percentage of the original image surface that was cropped. Enhancing999 (talk) 20:00, 28 July 2022 (UTC)

@Enhancing999: Where H=% horizontally and V=% vertically, one can calculate C (cropped out %) as (1-(1-(H/100))*(1-(V/100)))*100, or K (kept %) as (1-(H/100))*(1-(V/100))*100.   — Jeff G. please ping or talk to me 20:52, 28 July 2022 (UTC)
Yes, wouldn't it be easier to have the result directly? Enhancing999 (talk) 21:07, 28 July 2022 (UTC)
@Enhancing999: I see, a feature request when the maintainer has no spare time as it is. Good luck with that.   — Jeff G. please ping or talk to me 21:10, 28 July 2022 (UTC)

Problems with border crop on tiff files

Somehow this didn't work out, despite preview. File sizes are also much smaller. How can it be fixed? Enhancing999 (talk) 22:36, 27 July 2022 (UTC)

Problem with MediaWiki thumbnails

@Enhancing999: The file sizes may be smaller because the 87-90 MB source files are uncompressed. The tool may be trying to compress them, but running out of memory or disk space to do that. On the other hand, I have been experimenting with File:ETH-BIB-Hitzkirch-Bahnhof, Mosterei-LBS H1-015688.tif, and I think the thumbnailers may be overloaded or malfunctioning.   — Jeff G. please ping or talk to me 04:59, 28 July 2022 (UTC)
Thanks. Enhancing999 (talk) 08:30, 28 July 2022 (UTC)
@Enhancing999: You're welcome.   — Jeff G. please ping or talk to me 08:38, 28 July 2022 (UTC)

Problem with croptool

I fixed other borders recently, but missed that these 3 files have a large file size.
Removing the border from File:ETH-BIB-Altwis-LBS H1-015690.tif (90.44 MB) lead to the same result. The cropped tiff version (28.97 MB) loads correctly. I added it to Category:Images without thumbnails for now. Enhancing999 (talk) 09:19, 28 July 2022 (UTC)
It seems to work just fine at 79.39 MB (see File:ETH-BIB-Linthebene, Speer mit Wolken v. S. W. aus 1200 m-Inlandflüge-LBS MH01-003667.tif). Enhancing999 (talk) 09:37, 28 July 2022 (UTC)
and 86.11 MB (File:ETH-BIB-Bütschwil, Dietfurt v. O. aus 1100 m-Inlandflüge-LBS MH01-005437.tif) Enhancing999 (talk) 09:39, 28 July 2022 (UTC)
Maybe it's still a problem with the tool.
When does it do the compression? File:ETH-BIB-Freiburg, Brauerei Cardinal-Inlandflüge-LBS MH03-0269.tif went from 100.4 MB to 94.78 MB (supposedly that means no compression was applied) and it displays fine. Enhancing999 (talk) 05:46, 29 July 2022 (UTC)

Some more:

I reverted both to the original, but these don't display any more either. Enhancing999 (talk) 15:17, 9 August 2022 (UTC)

Improve handling of templates for crop on detail

When images use {{Information}}, it is simple to edit the description and indicate what is shown.

How could this be made easier when images use {{Photograph}}? Enhancing999 (talk) 10:01, 3 August 2022 (UTC)

Unwanted compression of tiff files and broken images

Trying to fix larger tiff files still leads to broken uploads at unpredictable image size (>80 MB).

See #Problem with crop tool found in July above. Enhancing999 (talk) 22:58, 2 September 2022 (UTC)

"An error occured: 500 undefined" while trying to use the "magic border locator"

I just got "An error occured: 500 undefined" while trying to use the "magic border locator" on File:Model for extrusion.jpg. I reported it as issue 176.   — Jeff G. please ping or talk to me 11:59, 10 September 2022 (UTC)

add page number to automated edit summary

That seems to be missing when extracting from multipage djvu or pdf. I was going to suggest this, but apparently it has already been requested.

When adding it, maybe #% of original image in summary above could be done too. Enhancing999 (talk) 11:36, 13 January 2023 (UTC)

White or transparent instead of black (added space in borders)

When rotating 0.31° a file, the added space is in black.

By default, white or transparent would be preferable. Enhancing999 (talk) 11:31, 4 February 2023 (UTC)

Distorted image

Hey y'all.

I recently cropped the following file of American rapper Desiigner, and on the English Wikipedia, his image has become distorted as a result. This is only an issue on the English Wikipedia, which was the only place outside of Wikimedia Commons that featured the image before it was trimmed. And now I am finding that this is an issue with thumbnail generation considering that when I added this image here on this page, it was also distorted. I'm leaving it here if anyone could fix it or inform me of anything I can do. Knightoftheswords281 (talk) 23:17, 11 February 2023 (UTC)

@Knightoftheswords281: looks fine to me. Probably a caching issue on your end. If you can't kill your cache, try looking with a different browser. - Jmabel ! talk 00:34, 12 February 2023 (UTC)
As above, you have to clear you local cache. See w:Wikipedia:Bypass your cache/Simple instructions. Jonteemil (talk) 17:08, 28 February 2023 (UTC)

Recently added "Problems" section

The recently added "Problems" section has… problems.

  1. I can see no good reason for "overwrote" to be past tense. It should be "after you overwrite".
  2. The advice to append ?action=purge to the URL is OK, and solves some server-side problems, but it doesn't solve others; and of course it does nothing for client-side issues. If we are going to go into this on this page (and I honestly don't know if we should) we also need to explain that if it works correctly under a different browser then it is certainly a client-side issue, and we need to explain how to do a hard refresh in the popular browsers. - Jmabel ! talk 01:26, 11 March 2023 (UTC)
@Jmabel: I have updated it. Ahecht (TALK
PAGE
) 22:19, 14 March 2023 (UTC)
@Ahecht: it seems pdf and djvu can be cropped? File:Tissandier - La navigation aerienne 1886 (page 79 crop).jpg was cropped from djvu yesterday.--RZuo (talk) 18:36, 15 March 2023 (UTC)
@Enhancing999: dont add things that are not problems. adding black or white/transparent space is a choice of design. you want something different? you can write a feature request. not everything that doesnt meet your need is a problem and not every problem is worth mentioning. RZuo (talk) 18:36, 15 March 2023 (UTC)
It's a matter of POV if it's a problem or not, but maybe you have a sample where it's actually a wanted feature. If you prefer to phrase it differently, please do so, but avoid leaving it to users to eventually rediscover the limitations. It's just a waste of time. Good to hear that feature requests will be handled. Enhancing999 (talk) 20:12, 15 March 2023 (UTC)

1 page tiffs and "The overwrite option is disabled because this is a multipage file."

The warning used to be displayed before, but it may no longer possible to overwrite such files.

An "Upload failed!" message appears after selecting "overwrite" and "upload". It worked quite well before. Enhancing999 (talk) 20:03, 29 March 2023 (UTC)

Maybe it's the file size (150 MB). It worked for a smaller one (75 MB) Enhancing999 (talk) 20:11, 29 March 2023 (UTC)

500 Internal Server Error

https://croptool.toolforge.org/?title=Daikoku_Pier.jpg shows me the empty "Enter the URL or filename for an image you would like to crop" form.

Entering "Daikoku Pier.jpg" manually then pressing "open", I am told "File «Daikoku Pier.jpg» found on «commons.wikimedia.org»." but then nothing happens.

Developer tools shows "500 Internal Server Error" for https://croptool.toolforge.org/api/file/info?site=commons.wikimedia.org&title=Daikoku+Pier.jpg

Any workaround? Thanks! Syced (talk) 05:14, 3 April 2023 (UTC)

Confirmed, the problem still persists - I cannot crop anything. --Enyavar (talk) 10:14, 3 April 2023 (UTC)
Seems fixed by now. --Enyavar (talk) 15:13, 3 April 2023 (UTC)

What’s the best way to rotate and crop the horizon with CropTool?

It’s easy to rotate and crop the horizon on an iPhone, is there an easy way to do it with the crop tool? I tried rotating -3, which worked but then how to crop the rotation around the edges

Fix horizon with CropTool

Raquel Baranow (talk) 02:26, 15 April 2023 (UTC)

Woke up this morning with the answer: Use laptop computer instead of iPad. Raquel Baranow (talk) 13:33, 15 April 2023 (UTC)

Tool bug?

Has anyone encountered a bug where the CropTool thinks everything is a bad file name, yet saves the name as an extracted file name even tho the file didn’t save? You can see all my attempts on this file: File:L-23-01-03-A-0260 (52606773274).jpg, which I’ll tidy later but will leave for now to illustrate the issue. I’ll work around it but wanted to flag in case it’s not an isolated issue. Innisfree987 (talk) 00:26, 6 May 2023 (UTC)

yes i've had this problem before. croptool would edit the source file page even if the upload as a new file fails. RZuo (talk) 12:28, 6 May 2023 (UTC)

WebP format support

Just realized that WebP format is not supported so requesting its support be added, thanks. Ohsin (talk) 05:33, 27 April 2023 (UTC)

Ditto. SVTCobra 07:51, 26 May 2023 (UTC)
Another one. In the meantime, can someone point me in the right direction of how to crop otherwise, I'm trying to get File:Jude Belligham vs Almería.webp in a better size for a portraint in a infobox. Ortizesp (talk) 07:19, 16 October 2023 (UTC)

504 Gateway Time-out

CropTool isn't working for me. I get a "504 Gateway Time-out". Is something wrong with the tool, or is it a toolforge issue? Schwede66 00:09, 1 September 2023 (UTC)

Also getting a timeout error! --Engineerchange (talk) 04:08, 1 September 2023 (UTC)
Same problem. Mehedi Abedin 06:55, 1 September 2023 (UTC)
@Schwede66: and @Mehediabedin: works for me now! --Engineerchange (talk) 14:34, 1 September 2023 (UTC)
Excellent! Schwede66 14:38, 1 September 2023 (UTC)

Received error: no-such-entity

I'm trying to crop https://croptool.toolforge.org/?title=Catherine_McCord.jpg - when I select the rectangle I want, and press "Preview" I get "[Error] [api] Received error: no-such-entity : Could not find an entity with the ID "##Q2942000"." --GRuban (talk) 20:26, 13 September 2023 (UTC)

@GRuban: I cropped it to File:Catherine McCord (cropped).jpg with Jpegcrop for you, and replaced what I could. Usages should catch up eventually.   — 🇺🇦Jeff G. please ping or talk to me🇺🇦 13:01, 16 October 2023 (UTC)
WikiThanks
WikiThanks
--GRuban (talk) 14:06, 16 October 2023 (UTC)
@GRuban: You're welcome.   — 🇺🇦Jeff G. please ping or talk to me🇺🇦 17:49, 16 October 2023 (UTC)

cropping fails after rotation of large files

When trying to rotate and crop the file for this, it failed. To work-around it, I cropped it in two steps.

I had the same problem when trying to crop the same region from another large file. Error message displayed was "[Error] undefined". Enhancing999 (talk) 09:56, 16 October 2023 (UTC)

new option: crop from several tiles

Map tile #1165 is part of a series 250 tiles.

Sometimes one would want to crop an area stretching across two adjacent tiles (with the one left, right, above or below).

Ideally, one would specify two files with their alignment and then be able to crop from both at once. Enhancing999 (talk) 10:01, 16 October 2023 (UTC)