جریان تنسور:: عملیات:: AdjustContrast
#include <image_ops.h>
کنتراست یک یا چند تصویر را تنظیم کنید.
خلاصه
images
یک تانسور حداقل 3 بعدی است. 3 بعد آخر به عنوان [height, width, channels]
تفسیر می شوند. ابعاد دیگر فقط مجموعه ای از تصاویر را نشان می دهد، مانند [batch, height, width, channels].
کنتراست به طور مستقل برای هر کانال از هر تصویر تنظیم می شود.
برای هر کانال، Op ابتدا میانگین پیکسل های تصویر را در کانال محاسبه می کند و سپس هر جزء از هر پیکسل را به (x - mean) * contrast_factor + mean
تنظیم می کند.
استدلال ها:
- scope: یک شی Scope
- تصاویر: تصاویر برای تنظیم. حداقل سه بعدی
- contrast_factor: یک ضرب شناور برای تنظیم کنتراست.
برمیگرداند:
-
Output
: تصویر یا تصاویر با کنتراست تنظیم شده.
صفات عمومی
عملیات
Operation operation
خروجی
::tensorflow::Output output
توابع عمومی
AdjustContrast
AdjustContrast(
const ::tensorflow::Scope & scope,
::tensorflow::Input images,
::tensorflow::Input contrast_factor
)
گره
::tensorflow::Node * node() const
operator::tensorflow::Input() const
عملگر::tensorflow::خروجی
operator::tensorflow::Output() const
جز در مواردی که غیر از این ذکر شده باشد،محتوای این صفحه تحت مجوز Creative Commons Attribution 4.0 License است. نمونه کدها نیز دارای مجوز Apache 2.0 License است. برای اطلاع از جزئیات، به خطمشیهای سایت Google Developers مراجعه کنید. جاوا علامت تجاری ثبتشده Oracle و/یا شرکتهای وابسته به آن است.
تاریخ آخرین بهروزرسانی 2025-07-26 بهوقت ساعت هماهنگ جهانی.
[null,null,["تاریخ آخرین بهروزرسانی 2025-07-26 بهوقت ساعت هماهنگ جهانی."],[],[],null,["# tensorflow::ops::AdjustContrast Class Reference\n\ntensorflow::ops::AdjustContrast\n===============================\n\n`#include \u003cimage_ops.h\u003e`\n\nAdjust the contrast of one or more images.\n\nSummary\n-------\n\n`images` is a tensor of at least 3 dimensions. The last 3 dimensions are interpreted as `[height, width, channels]`. The other dimensions only represent a collection of images, such as `[batch, height, width, channels].`\n\nContrast is adjusted independently for each channel of each image.\n\nFor each channel, the Op first computes the mean of the image pixels in the channel and then adjusts each component of each pixel to `(x - mean) * contrast_factor + mean`.\n\nArguments:\n\n- scope: A [Scope](/versions/r2.1/api_docs/cc/class/tensorflow/scope#classtensorflow_1_1_scope) object\n- images: Images to adjust. At least 3-D.\n- contrast_factor: A float multiplier for adjusting contrast.\n\n\u003cbr /\u003e\n\nReturns:\n\n- [Output](/versions/r2.1/api_docs/cc/class/tensorflow/output#classtensorflow_1_1_output): The contrast-adjusted image or images.\n\n\u003cbr /\u003e\n\n| ### Constructors and Destructors ||\n|---|---|\n| [AdjustContrast](#classtensorflow_1_1ops_1_1_adjust_contrast_1a817234337682fcf4afdfe94eb7c6bcc2)`(const ::`[tensorflow::Scope](/versions/r2.1/api_docs/cc/class/tensorflow/scope#classtensorflow_1_1_scope)` & scope, ::`[tensorflow::Input](/versions/r2.1/api_docs/cc/class/tensorflow/input#classtensorflow_1_1_input)` images, ::`[tensorflow::Input](/versions/r2.1/api_docs/cc/class/tensorflow/input#classtensorflow_1_1_input)` contrast_factor)` ||\n\n| ### Public attributes ||\n|---------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------|\n| [operation](#classtensorflow_1_1ops_1_1_adjust_contrast_1ad06f8f55756cdb0ea76bda27f433c069) | [Operation](/versions/r2.1/api_docs/cc/class/tensorflow/operation#classtensorflow_1_1_operation) |\n| [output](#classtensorflow_1_1ops_1_1_adjust_contrast_1ac8e60cb2d1938fbf4467419d9bed3e27) | `::`[tensorflow::Output](/versions/r2.1/api_docs/cc/class/tensorflow/output#classtensorflow_1_1_output) |\n\n| ### Public functions ||\n|---------------------------------------------------------------------------------------------------------------------------|------------------------|\n| [node](#classtensorflow_1_1ops_1_1_adjust_contrast_1afef7b99274258f8232f30829973001b3)`() const ` | `::tensorflow::Node *` |\n| [operator::tensorflow::Input](#classtensorflow_1_1ops_1_1_adjust_contrast_1ad6c68cabac0d2c21e087ed3547d64eae)`() const ` | ` ` ` ` |\n| [operator::tensorflow::Output](#classtensorflow_1_1ops_1_1_adjust_contrast_1a56529eeed8eb996474cf2f47f8658ca2)`() const ` | ` ` ` ` |\n\nPublic attributes\n-----------------\n\n### operation\n\n```text\nOperation operation\n``` \n\n### output\n\n```text\n::tensorflow::Output output\n``` \n\nPublic functions\n----------------\n\n### AdjustContrast\n\n```gdscript\n AdjustContrast(\n const ::tensorflow::Scope & scope,\n ::tensorflow::Input images,\n ::tensorflow::Input contrast_factor\n)\n``` \n\n### node\n\n```gdscript\n::tensorflow::Node * node() const \n``` \n\n### operator::tensorflow::Input\n\n```gdscript\n operator::tensorflow::Input() const \n``` \n\n### operator::tensorflow::Output\n\n```gdscript\n operator::tensorflow::Output() const \n```"]]