Imageapi

cloudmersive-image-api-client的Python项目详细描述


cloudmersive_image_api_客户端

图像识别和图像处理也可以使用API进行。在

这个Python包为Cloudmersive Image Recognition and Processing提供了一个本机API客户机

  • API版本:v1
  • 软件包版本:3.0.1
  • 生成包:io.swagger.codegen.语言.PythonClientCodegen在

要求

Python 2.7和3.4+

安装和使用

pip安装

如果python包托管在Github上,则可以直接从Github安装

pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git

(您可能需要使用根权限运行pipsudo pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git

然后导入包:

^{pr2}$

设置工具

通过Setuptools安装。在

python setup.py install --user

(或sudo python setup.py install为所有用户安装软件包)

然后导入包:

importcloudmersive_image_api_client

入门

请按照installation procedure操作,然后运行以下命令:

from__future__importprint_functionimporttimeimportcloudmersive_image_api_clientfromcloudmersive_image_api_client.restimportApiExceptionfrompprintimportpprint# Configure API key authorization: Apikeyconfiguration=cloudmersive_image_api_client.Configuration()configuration.api_key['Apikey']='YOUR_API_KEY'# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed# configuration.api_key_prefix['Apikey'] = 'Bearer'# create an instance of the API classapi_instance=cloudmersive_image_api_client.ArtisticApi(cloudmersive_image_api_client.ApiClient(configuration))style='style_example'# str | The style of the painting to apply.  To start, try \"udnie\" a painting style.  Possible values are: \"udnie\", \"wave\", \"la_muse\", \"rain_princess\".image_file='/path/to/file.txt'# file | Image file to perform the operation on.  Common file formats such as PNG, JPEG are supported.try:# Transform an image into an artistic painting automaticallyapi_response=api_instance.artistic_painting(style,image_file)pprint(api_response)exceptApiExceptionase:print("Exception when calling ArtisticApi->artistic_painting: %s\n"%e)

API终结点文档

所有uri都是相对于https://api.cloudmersive.com

ClassMethodHTTP requestDescription
ArtisticApiartistic_paintingPOST /image/artistic/painting/{style}Transform an image into an artistic painting automatically
ConvertApiconvert_to_bmpPOST /image/convert/to/bmpConvert input image to Bitmap BMP format
ConvertApiconvert_to_gifPOST /image/convert/to/gifConvert input image to GIF format
ConvertApiconvert_to_jpgPOST /image/convert/to/jpg/{quality}Convert input image to JPG, JPEG format
ConvertApiconvert_to_photoshopPOST /image/convert/to/psdConvert input image to Photoshop PSD format
ConvertApiconvert_to_pngPOST /image/convert/to/pngConvert input image to PNG format
ConvertApiconvert_to_tiffPOST /image/convert/to/tiffConvert input image to TIFF format
ConvertApiconvert_to_web_pPOST /image/convert/to/webpConvert input image to WebP format
EditApiedit_auto_orientPOST /image/edit/auto-orient/remove-exifNormalizes image rotation and removes EXIF rotation data
EditApiedit_composite_basicPOST /image/edit/composite/{location}Composite two images together
EditApiedit_contrast_adaptivePOST /image/edit/contrast/{gamma}/adaptiveAdaptively adjust the contrast of the image to be more appealing and easy to see
EditApiedit_crop_rectanglePOST /image/edit/crop/rectangle/{left}/{top}/{width}/{height}Crop an image to a rectangular area
EditApiedit_draw_polygonPOST /image/edit/draw/polygonDraw a polygon onto an image
EditApiedit_draw_rectanglePOST /image/edit/draw/rectangleDraw a rectangle onto an image
EditApiedit_draw_textPOST /image/edit/draw/textDraw text onto an image
EditApiedit_drop_shadowPOST /image/edit/drop-shadow/{X}/{Y}/{sigma}/{opacity}Add a customizeable drop shadow to an image
EditApiedit_invertPOST /image/edit/invertInvert, negate the colors in the image
EditApiedit_remove_exif_dataPOST /image/edit/remove-exifRemove EXIF data from the image
EditApiedit_remove_transparencyPOST /image/edit/remove-transparencyRemove transparency from the image
EditApiedit_rotatePOST /image/edit/rotate/{degrees}/angleRotate an image any number of degrees
FaceApiface_comparePOST /image/face/compare-and-matchCompare and match faces
FaceApiface_crop_firstPOST /image/face/crop/firstCrop image to face with square crop
FaceApiface_crop_first_roundPOST /image/face/crop/first/roundCrop image to face with round crop
FaceApiface_detect_agePOST /image/face/detect-ageDetect the age of people in an image
FaceApiface_detect_genderPOST /image/face/detect-genderDetect the gender of people in an image
FaceApiface_locatePOST /image/face/locateDetect and find faces in an image
FaceApiface_locate_with_landmarksPOST /image/face/locate-with-landmarksDetect and find faces and landmarks eyes and nose and mouth in image
FilterApifilter_black_and_whitePOST /image/filter/black-and-whiteConvert image to black-and-white grayscale
FilterApifilter_despecklePOST /image/filter/despeckleDespeckle to remove point noise from the image
FilterApifilter_edge_detectPOST /image/filter/edge-detect/{radius}Detect and highlight edges in an image
FilterApifilter_embossPOST /image/filter/emboss/{radius}/{sigma}Emboss an image
FilterApifilter_gaussian_blurPOST /image/filter/blur/guassian/{radius}/{sigma}Perform a guassian blur on the input image
FilterApifilter_motion_blurPOST /image/filter/blur/motion/{radius}/{sigma}/{angle}Perform a motion blur on the input image
FilterApifilter_posterizePOST /image/filter/posterizePosterize the image by reducing distinct colors
FilterApifilter_swirlPOST /image/filter/swirlSwirl distort the image
InfoApiinfo_get_dominant_colorPOST /image/get-info/dominant-colorReturns the dominant colors of the image
InfoApiinfo_get_metadataPOST /image/get-info/metadataReturns the image metadata including EXIF and resolution
NsfwApinsfw_classifyPOST /image/nsfw/classifyNot safe for work NSFW racy content classification
RecognizeApirecognize_describePOST /image/recognize/describeDescribe an image in natural language
RecognizeApirecognize_detect_and_unskew_documentPOST /image/recognize/detect-document/unskewDetect and unskew a photo of a document
RecognizeApirecognize_detect_objectsPOST /image/recognize/detect-objectsDetect objects including types and locations in an image
RecognizeApirecognize_detect_peoplePOST /image/recognize/detect-peopleDetect people including locations in an image
RecognizeApirecognize_detect_text_finePOST /image/recognize/detect-text/fineDetect fine text in a photo of a document
RecognizeApirecognize_detect_text_largePOST /image/recognize/detect-text/largeDetect large text in a photo
RecognizeApirecognize_detect_vehicle_license_platesPOST /image/recognize/detect-vehicle-license-platesDetect vehicle license plates in an image
RecognizeApirecognize_find_symbolPOST /image/recognize/find/symbolFind the location of a symbol in an image
ResizeApiresize_postPOST /image/resize/preserveAspectRatio/{maxWidth}/{maxHeight}Resize an image while preserving aspect ratio
ResizeApiresize_resize_simplePOST /image/resize/target/{width}/{height}Resize an image

模型文档

授权文件

阿皮基

  • Type:API密钥
  • API key参数名:Apikey
  • Location:HTTP头

作者

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
java如何在数据库中存储工作日数据以及开始时间和结束时间?   mysql Java JPA内部联接查询不起作用   java MQ消息在不同的客户端应用程序中显示不同   javascript如何在xPage上提高typeAhead性能?   java在尝试保存EditText时无法暂停   mongodb“未能使用带参数的构造函数NO_构造函数实例化java.util.List”,   java如何修改使IllegalArgumentException:列“\u id”不存在的游标   转换Android。网Uri到Java。伊奥。输入流   java NetBeans RCP居中弹出窗口无法按预期工作   java将sql开发人员与netbeans连接起来   带有xmldsig签名的java JAXB编组   java ORACLE JDBC批处理执行不会返回受影响行的实际计数   java无法理解如何在由swagger自动生成的jaxrs服务器中访问请求头   java如何处理漏洞CVE20181258,同时将Spring安全版本5与外部客户端(最新版本)一起使用?   JavaSpring数据JPA存储库多租户单模式技术