GenerateThumbnails¶
-
class
GenerateThumbnails.
GenerateThumbnails
(concurrency=1, concurrentTimeout=100.0, errorCol=None, handler=None, height=None, imageBytes=None, imageUrl=None, outputCol=None, smartCropping=None, subscriptionKey=None, timeout=60.0, url=None, width=None)[source]¶ Bases:
mmlspark.Utils.ComplexParamsMixin
,pyspark.ml.util.JavaMLReadable
,pyspark.ml.util.JavaMLWritable
,pyspark.ml.wrapper.JavaTransformer
Parameters: - concurrency (int) – max number of concurrent calls (default: 1)
- concurrentTimeout (double) – max number seconds to wait on futures if concurrency >= 1 (default: 100.0)
- errorCol (str) – column to hold http errors (default: [self.uid]_error)
- handler (object) – Which strategy to use when handling requests (default: UserDefinedFunction(<function2>,StringType,None))
- height (object) – the desired height of the image
- imageBytes (object) – bytestream of the image to use
- imageUrl (object) – the url of the image to use
- outputCol (str) – The name of the output column (default: [self.uid]_output)
- smartCropping (object) – whether to intelligently crop the image
- subscriptionKey (object) – the API key to use
- timeout (double) – number of seconds to wait before closing the connection (default: 60.0)
- url (str) – Url of the service
- width (object) – the desired width of the image
-
getConcurrentTimeout
()[source]¶ Returns: max number seconds to wait on futures if concurrency >= 1 (default: 100.0) Return type: double
-
getErrorCol
()[source]¶ Returns: column to hold http errors (default: [self.uid]_error) Return type: str
-
getHandler
()[source]¶ Returns: Which strategy to use when handling requests (default: UserDefinedFunction(<function2>,StringType,None)) Return type: object
-
getOutputCol
()[source]¶ Returns: The name of the output column (default: [self.uid]_output) Return type: str
-
getTimeout
()[source]¶ Returns: number of seconds to wait before closing the connection (default: 60.0) Return type: double
-
setConcurrency
(value)[source]¶ Parameters: concurrency (int) – max number of concurrent calls (default: 1)
-
setConcurrentTimeout
(value)[source]¶ Parameters: concurrentTimeout (double) – max number seconds to wait on futures if concurrency >= 1 (default: 100.0)
-
setErrorCol
(value)[source]¶ Parameters: errorCol (str) – column to hold http errors (default: [self.uid]_error)
-
setHandler
(value)[source]¶ Parameters: handler (object) – Which strategy to use when handling requests (default: UserDefinedFunction(<function2>,StringType,None))
-
setOutputCol
(value)[source]¶ Parameters: outputCol (str) – The name of the output column (default: [self.uid]_output)
-
setParams
(concurrency=1, concurrentTimeout=100.0, errorCol=None, handler=None, height=None, imageBytes=None, imageUrl=None, outputCol=None, smartCropping=None, subscriptionKey=None, timeout=60.0, url=None, width=None)[source]¶ Set the (keyword only) parameters
Parameters: - concurrency (int) – max number of concurrent calls (default: 1)
- concurrentTimeout (double) – max number seconds to wait on futures if concurrency >= 1 (default: 100.0)
- errorCol (str) – column to hold http errors (default: [self.uid]_error)
- handler (object) – Which strategy to use when handling requests (default: UserDefinedFunction(<function2>,StringType,None))
- height (object) – the desired height of the image
- imageBytes (object) – bytestream of the image to use
- imageUrl (object) – the url of the image to use
- outputCol (str) – The name of the output column (default: [self.uid]_output)
- smartCropping (object) – whether to intelligently crop the image
- subscriptionKey (object) – the API key to use
- timeout (double) – number of seconds to wait before closing the connection (default: 60.0)
- url (str) – Url of the service
- width (object) – the desired width of the image
-
setSmartCropping
(value)[source]¶ Parameters: smartCropping (object) – whether to intelligently crop the image
-
setSmartCroppingCol
(value)[source]¶ Parameters: smartCropping (object) – whether to intelligently crop the image