Title: Write function doesn't take into account quality · Issue #21 · UsingNet/nvjpeg-python · GitHub
Open Graph Title: Write function doesn't take into account quality · Issue #21 · UsingNet/nvjpeg-python
X Title: Write function doesn't take into account quality · Issue #21 · UsingNet/nvjpeg-python
Description: Hello there! I'm trying to do some speed tests writting encoded images to disk playing with jpeg quality factor. I'm using the python wrapper for NvJpeg_write as follows: foo = nj.write('test.jpg', raw, quality) print(foo) I have tried w...
Open Graph Description: Hello there! I'm trying to do some speed tests writting encoded images to disk playing with jpeg quality factor. I'm using the python wrapper for NvJpeg_write as follows: foo = nj.write('test.jpg',...
X Description: Hello there! I'm trying to do some speed tests writting encoded images to disk playing with jpeg quality factor. I'm using the python wrapper for NvJpeg_write as follows: foo = nj.write(...
Opengraph URL: https://github.com/UsingNet/nvjpeg-python/issues/21
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Write function doesn't take into account quality","articleBody":"Hello there!\r\nI'm trying to do some speed tests writting encoded images to disk playing with jpeg quality factor.\r\nI'm using the python wrapper for NvJpeg_write as follows:\r\n```\r\nfoo = nj.write('test.jpg', raw, quality)\r\nprint(foo)\r\n```\r\nI have tried with quality = [10, 70, 90] but I'm always obtaining the same buffer/file size (217936 for my case)\r\n\r\nRegardless, when I directly use the NvJpeg_encode wrapper I achieve to get the proper sizes:\r\n```\r\nbar = nj.encode(raw, quality)\r\nprint(len(bar))\r\n# 53096 for quality=10, 217936 for quality=70 and 447357 for quality=95\r\n```\r\n\r\nI've looked at the source code and it seems that NvJpeg_write just calls NvJpeg_encode and passes the arguments, but I'm not used at all to C code, so I'm probably missing out something.\r\n\r\nCan anyone lend me a hand?","author":{"url":"https://github.com/manuelporta","@type":"Person","name":"manuelporta"},"datePublished":"2024-03-04T10:06:15.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/21/nvjpeg-python/issues/21"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:d3e2705b-cb41-b27b-1d98-642295418cda |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | AF74:59670:4B34A7:617668:698E9484 |
| html-safe-nonce | 6166280083e9ab1004d1badea4368b9271209916b38296321dbeb7ba7b795d92 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBRjc0OjU5NjcwOjRCMzRBNzo2MTc2Njg6Njk4RTk0ODQiLCJ2aXNpdG9yX2lkIjoiMTY5NjM4Mzc5NzMxMjc4NzU4OCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 18c2a8fb60f0eb977e4485437e32a161a0f406a2cd2c1924d94049ab633776e2 |
| hovercard-subject-tag | issue:2166450711 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/UsingNet/nvjpeg-python/21/issue_layout |
| twitter:image | https://opengraph.githubassets.com/e90aea91f6afc496aba89b9c4d32d1cf982b7ff92f86de795fbadcb44b5fda62/UsingNet/nvjpeg-python/issues/21 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/e90aea91f6afc496aba89b9c4d32d1cf982b7ff92f86de795fbadcb44b5fda62/UsingNet/nvjpeg-python/issues/21 |
| og:image:alt | Hello there! I'm trying to do some speed tests writting encoded images to disk playing with jpeg quality factor. I'm using the python wrapper for NvJpeg_write as follows: foo = nj.write('test.jpg',... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | manuelporta |
| hostname | github.com |
| expected-hostname | github.com |
| None | cb2828a801ee6b7be618f3ac76fbf55def35bbc30f053a9c41bf90210b8b72ba |
| turbo-cache-control | no-preview |
| go-import | github.com/UsingNet/nvjpeg-python git https://github.com/UsingNet/nvjpeg-python.git |
| octolytics-dimension-user_id | 23328403 |
| octolytics-dimension-user_login | UsingNet |
| octolytics-dimension-repository_id | 334122746 |
| octolytics-dimension-repository_nwo | UsingNet/nvjpeg-python |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 334122746 |
| octolytics-dimension-repository_network_root_nwo | UsingNet/nvjpeg-python |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | e6b91a7e6e46287d26887e3fb7a4161657bab8f7 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width