You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

constant.py 1.9 kB

3 years ago
3 years ago
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. # Copyright (c) Alibaba, Inc. and its affiliates.
  2. class Fields(object):
  3. """ Names for different application fields
  4. """
  5. image = 'image'
  6. video = 'video'
  7. cv = 'cv'
  8. nlp = 'nlp'
  9. audio = 'audio'
  10. multi_modal = 'multi-modal'
  11. class Tasks(object):
  12. """ Names for tasks supported by maas lib.
  13. Holds the standard task name to use for identifying different tasks.
  14. This should be used to register models, pipelines, trainers.
  15. """
  16. # vision tasks
  17. image_to_text = 'image-to-text'
  18. pose_estimation = 'pose-estimation'
  19. image_classification = 'image-classification'
  20. image_tagging = 'image-tagging'
  21. object_detection = 'object-detection'
  22. image_segmentation = 'image-segmentation'
  23. image_editing = 'image-editing'
  24. image_generation = 'image-generation'
  25. image_matting = 'image-matting'
  26. # nlp tasks
  27. sentiment_analysis = 'sentiment-analysis'
  28. text_classification = 'text-classification'
  29. relation_extraction = 'relation-extraction'
  30. zero_shot = 'zero-shot'
  31. translation = 'translation'
  32. token_classification = 'token-classification'
  33. conversational = 'conversational'
  34. text_generation = 'text-generation'
  35. table_question_answering = 'table-question-answering'
  36. feature_extraction = 'feature-extraction'
  37. sentence_similarity = 'sentence-similarity'
  38. fill_mask = 'fill-mask '
  39. summarization = 'summarization'
  40. question_answering = 'question-answering'
  41. # audio tasks
  42. auto_speech_recognition = 'auto-speech-recognition'
  43. text_to_speech = 'text-to-speech'
  44. speech_signal_process = 'speech-signal-process'
  45. # multi-media
  46. image_captioning = 'image-captioning'
  47. visual_grounding = 'visual-grounding'
  48. text_to_image_synthesis = 'text-to-image-synthesis'
  49. class InputFields(object):
  50. """ Names for input data fileds in the input data for pipelines
  51. """
  52. img = 'img'
  53. text = 'text'
  54. audio = 'audio'

致力于通过开放的社区合作,开源AI模型以及相关创新技术,推动基于模型即服务的生态繁荣发展