{"id":43916886,"url":"https://github.com/zooniverse/image-proc","last_synced_at":"2026-02-06T21:34:56.420Z","repository":{"id":65937139,"uuid":"44387600","full_name":"zooniverse/image-proc","owner":"zooniverse","description":"Image crop server for Zooniverse static","archived":false,"fork":false,"pushed_at":"2024-04-04T18:46:50.000Z","size":82,"stargazers_count":1,"open_issues_count":1,"forks_count":3,"subscribers_count":14,"default_branch":"master","last_synced_at":"2024-04-15T23:07:30.679Z","etag":null,"topics":["hacktoberfest"],"latest_commit_sha":null,"homepage":"https://imgproc.zooniverse.org","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/zooniverse.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2015-10-16T13:42:55.000Z","updated_at":"2024-02-06T15:10:01.000Z","dependencies_parsed_at":"2023-11-06T22:57:39.821Z","dependency_job_id":"4436ea49-8026-4b8c-8dc6-3626cf190e7b","html_url":"https://github.com/zooniverse/image-proc","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/zooniverse/image-proc","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zooniverse%2Fimage-proc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zooniverse%2Fimage-proc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zooniverse%2Fimage-proc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zooniverse%2Fimage-proc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zooniverse","download_url":"https://codeload.github.com/zooniverse/image-proc/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zooniverse%2Fimage-proc/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29177554,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-06T20:14:21.878Z","status":"ssl_error","status_checked_at":"2026-02-06T20:14:21.443Z","response_time":59,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["hacktoberfest"],"created_at":"2026-02-06T21:34:56.278Z","updated_at":"2026-02-06T21:34:56.408Z","avatar_url":"https://github.com/zooniverse.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# static_crop\n\nNodeJS web server thats crops and / or resizes images from the Zooniverse's static media server\n\n## What is it?\nA HTTP wrapper over image magic that offers crop, resize and crop_resize functions on the image specified by a query param `u`. Note: the `?u=` query param should be a path suffix from the specified static server hostname. E.g the following media resource `u` query param:\n+ `http://zooniverse-static.s3-website-us-east-1.amazonaws.com/panoptes-uploads.zooniverse.org/production/subject_location/90a3b642-55e2-4583-a4fb-2f0abeb5b285.jpeg`\n+ `u=panoptes-uploads.zooniverse.org/production/subject_location/90a3b642-55e2-4583-a4fb-2f0abeb5b285.jpeg`\n\n## /crop route\nCrop route can be specified in two formats and all dimensions are in pixels.\n\n1. Params are: w x h dimensions at the x, y offset.\n\n  + https://imgproc.zooniverse.org/crop?w=150\u0026h=150\u0026x=300\u0026y=175\u0026u=panoptes-uploads.zooniverse.org/production/subject_location/90a3b642-55e2-4583-a4fb-2f0abeb5b285.jpeg\n\n1. Params are part of the url path: /w/h/x/y/u, note the path to the image (u) should be url encoded, e.g.\n  + https://imgproc.zooniverse.org/crop/150/150/300/175/panoptes-uploads.zooniverse.org%2Fproduction%2Fsubject_location%2F90a3b642-55e2-4583-a4fb-2f0abeb5b285.jpeg\n\n## /resize route\nResize the image, dimensions are in pixels and can be overwritten by o url. See http://www.graphicsmagick.org/GraphicsMagick.html#details-resize.\n\nParams are: w x h dimensions and an options o to specify the resize options mentioned above.\n\n + https://imgproc.zooniverse.org/resize?w=500\u0026h=600\u0026u=panoptes-uploads.zooniverse.org/production/subject_location/90a3b642-55e2-4583-a4fb-2f0abeb5b285.jpeg\n + https://imgproc.zooniverse.org/resize?o=%\u0026w=100\u0026h=100\u0026u=panoptes-uploads.zooniverse.org/production/subject_location/90a3b642-55e2-4583-a4fb-2f0abeb5b285.jpeg\n\n\n## /resize_crop route\nThe image should be resized to fill the dimensions as much as possible, so cropping may be necessary. For example, if the image is 200x800, and you want to resize to 100x100, the image would first be resized to 100x400, and then the height would be cropped down to 100.\n\nParams are: w x h dimensions.\n\n+ https://imgproc.zooniverse.org/resize_crop?w=500\u0026h=600\u0026u=panoptes-uploads.zooniverse.org/production/subject_location/90a3b642-55e2-4583-a4fb-2f0abeb5b285.jpeg\n\n## /montage route\nTile several images together to create a multi-image subject image. Requires at least two images\n\nParams are: w for tile width, mw for max desired width (for the final image)\n\n+ https://imgproc.zooniverse.org/montage?u=panoptes-uploads.zooniverse.org/production/subject_location/90a3b642-55e2-4583-a4fb-2f0abeb5b285.jpeg\u0026u=panoptes-uploads.zooniverse.org/production/subject_location/90a3b642-55e2-4583-a4fb-2f0abeb5b285.jpeg\n\n## Require\nRequires [GraphicsMagick](http://www.graphicsmagick.org/) **and** (for now) [ImageMagick](http://imagemagick.org/) CLI tools to be installed:\n\nDebian/Ubuntu:\n\n`apt-get install imagemagick graphicsmagick`\n\nOSX:\n\n`brew install imagemagick` or `port install ImageMagick`\n\n## Install and run\n```js\nnpm install\nnpm start\n#memory issues? defaults to 512mb and 1GB respectively\n#limits are 1.4GB in 32-bit node and 4GB in 64-bit node\nnode --max_old_space_size={size in mb} server.js\n```\n## Env vars\n```\nNODE_STATIC_SERVER || \"http://zooniverse-static.s3-website-us-east-1.amazonaws.com/\"\nNODE_PORT || 8080\nNODE_ENV || \"development\"\nNODE_DEBUG || false\n```\n\n## Notes\n  - Uses docker (cron \u0026 tmpreaper) to clean up the media in the /img directory. See the docker/static_crop_cron tabfile for more details.\n\n## Credits\nInspired by the good work from Philmod, https://github.com/Philmod/node-resize-image-server\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzooniverse%2Fimage-proc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzooniverse%2Fimage-proc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzooniverse%2Fimage-proc/lists"}