SAP BAPI 客户主数据创建:cmd_ei_api=>maintain_bapi

2024-01-04 14:28

本文主要是介绍SAP BAPI 客户主数据创建:cmd_ei_api=>maintain_bapi,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

BAPI函数:cmd_ei_api=>maintain_bapi

事物代码:XD01/XD02

客户主数据创建、修改、拓展功能开发

数据结构定义:

基本视图信息

公司代码信息结构:

销售视图信息结构:

客户主数据税分类信息结构:

代码参考

详细代码样例参考:

FUNCTION zsd_customer_maintain.
*"----------------------------------------------------------------------
*"*"本地接口:
*"  IMPORTING
*"     REFERENCE(IS_GENERAL) TYPE  ZSGENERAL OPTIONAL
*"  EXPORTING
*"     REFERENCE(KUNNR) TYPE  KUNNR
*"  TABLES
*"      IT_COMPANY_DATA STRUCTURE  ZSCOMPANY_DATA OPTIONAL
*"      IT_SALES_DATA STRUCTURE  ZSSALES_DATA OPTIONAL
*"      IT_TAX_DATA STRUCTURE  ZSTAX_DATA OPTIONAL
*"      ET_RETURN STRUCTURE  BAPIRET2 OPTIONAL
*"----------------------------------------------------------------------DATA: is_master_data           TYPE cmds_ei_main,es_error                 TYPE cvis_message,ls_messages              TYPE bapiret2,ls_return                TYPE bapiret2,ls_company_data          TYPE zscompany_data,ls_company               TYPE cmds_ei_company,ls_customers             TYPE cmds_ei_extern,ls_sales_data            TYPE zssales_data,ls_sales                 TYPE cmds_ei_sales,ls_tax_data              TYPE zstax_data,ls_tax                   TYPE cmds_ei_tax_ind,ls_banks                 TYPE cvis_ei_cvi_bankdetail,lv_kunnr                 TYPE knvk-kunnr,lt_knvk                  TYPE TABLE OF knvk,ls_knvk                  TYPE knvk,ls_adr6                  TYPE adr6,lv_name                  TYPE string,ls_contact               TYPE cmds_ei_contacts,gs_error                 TYPE cvis_message,ls_phone                 TYPE cvis_ei_phone_str,ls_smtp                  TYPE cvis_ei_smtp_str,ls_functions             TYPE cmds_ei_functions,es_master_data_correct   TYPE cmds_ei_main,es_message_correct       TYPE cvis_message,ls_customrers            TYPE cmds_ei_extern,es_master_data_defective TYPE cmds_ei_main,es_message_defective     TYPE cvis_message.*--------------------------------------------------------------------*
*  基本视图信息
*--------------------------------------------------------------------*ls_customers-header-object_task = 'M'.CLEAR: lv_kunnr.CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'EXPORTINGinput  = is_general-kunnrIMPORTINGoutput = lv_kunnr.IF lv_kunnr IS NOT INITIAL.ls_customers-header-object_instance-kunnr = lv_kunnr.ENDIF.IF is_general-ktokd IS NOT INITIAL.ls_customers-central_data-central-data-ktokd = is_general-ktokd. "客户帐户组ls_customers-central_data-central-datax-ktokd = 'X'.ENDIF.IF is_general-stcd5 IS NOT INITIAL.ls_customers-central_data-central-data-stcd5 = is_general-stcd5. "税号 5ls_customers-central_data-central-datax-stcd5 = 'X'.ENDIF.IF is_general-title IS NOT INITIAL.ls_customers-central_data-address-postal-data-title = is_general-title. "称谓默认公司:0003ls_customers-central_data-address-postal-datax-title = 'X'.ENDIF.IF is_general-name IS NOT INITIAL.ls_customers-central_data-address-postal-data-name = is_general-name. "名称 1ls_customers-central_data-address-postal-datax-name = 'X'.ENDIF.IF is_general-name_2 IS NOT INITIAL.ls_customers-central_data-address-postal-data-name_2 = is_general-name_2. "名称 2ls_customers-central_data-address-postal-datax-name_2 = 'X'.ENDIF.IF is_general-name_3 IS NOT INITIAL.ls_customers-central_data-address-postal-data-name_3 = is_general-name_3. "名称 3ls_customers-central_data-address-postal-datax-name_3 = 'X'.ENDIF.IF is_general-name_4 IS NOT INITIAL.ls_customers-central_data-address-postal-data-name_4 = is_general-name_4. "名称 4ls_customers-central_data-address-postal-datax-name_4 = 'X'.ENDIF.IF is_general-sort1 IS NOT INITIAL.ls_customers-central_data-address-postal-data-sort1 = is_general-sort1. "检索项1ls_customers-central_data-address-postal-datax-sort1 = 'X'.ENDIF.IF is_general-sort2 IS NOT INITIAL.ls_customers-central_data-address-postal-data-sort2 = is_general-sort2. "检索项2ls_customers-central_data-address-postal-datax-sort2 = 'X'.ENDIF.IF is_general-street IS NOT INITIAL.ls_customers-central_data-address-postal-data-street = is_general-street. "街道ls_customers-central_data-address-postal-datax-street = 'X'.ENDIF.IF is_general-country IS NOT INITIAL.ls_customers-central_data-address-postal-data-country = is_general-country. "国家键值ls_customers-central_data-address-postal-datax-country = 'X'.IF is_general-country = 'CN'.ls_customers-central_data-address-postal-data-langu = '1'. "语言代码ELSE.ls_customers-central_data-address-postal-data-langu = 'E'. "语言代码ENDIF.ls_customers-central_data-address-postal-datax-langu = 'X'.ENDIF.IF ls_customers-central_data-address IS NOT INITIAL.ls_customers-central_data-address-task = 'M'.ENDIF.IF is_general-banks IS NOT INITIAL.ls_banks-data_key-banks = is_general-banks. "银行国家代码ENDIF.IF is_general-bankl IS NOT INITIAL.ls_banks-data_key-bankl = is_general-bankl. "银行编号ENDIF.IF is_general-bankn IS NOT INITIAL.ls_banks-data_key-bankn = is_general-bankn. "银行帐户号码ENDIF.IF is_general-bvtyp IS NOT INITIAL.ls_banks-data-bvtyp = is_general-bvtyp. "合作银行类型ls_banks-datax-bvtyp = 'X'.ENDIF.IF is_general-bkref IS NOT INITIAL.ls_banks-data-bkref = is_general-bkref. "银行帐户的参考规定ls_banks-datax-bkref = 'X'.ENDIF.IF is_general-koinh IS NOT INITIAL.ls_banks-data-koinh = is_general-koinh. "帐户持有人姓名ls_banks-datax-koinh = 'X'.ENDIF.IF ls_banks IS NOT INITIAL.ls_banks-task = 'M'.APPEND ls_banks TO ls_customers-central_data-bankdetail-bankdetails[].CLEAR: ls_banks.ENDIF."检查联系人是否有创建,如果有的话,就进行修改,如果没有,则新建SELECT * INTO TABLE lt_knvkFROM knvkWHERE kunnr = lv_kunnr.LOOP AT lt_knvk INTO ls_knvk.CLEAR: lv_name.CONCATENATE ls_knvk-name1 ls_knvk-namev INTO lv_name.IF lv_name = is_general-name_c.ls_contact-task = 'U'.ls_contact-data_key-parnr = ls_knvk-parnr.EXIT.ELSE.ls_contact-task = 'M'.ENDIF.ENDLOOP.IF ls_contact-task = 'M'.cmd_ei_api=>get_contact_number( IMPORTING ev_parnr = ls_contact-data_key-parnres_error = gs_error ).ENDIF.IF is_general-telephone IS NOT INITIAL.ls_phone-contact-data-telephone = is_general-telephone.ls_phone-contact-datax-telephone = 'X'.ENDIF.IF is_general-extension IS NOT INITIAL.ls_phone-contact-data-extension = is_general-extension.ls_phone-contact-datax-extension = 'X'.ENDIF.IF is_general-tel_no IS NOT INITIAL.ls_phone-contact-data-tel_no = is_general-tel_no.ls_phone-contact-datax-tel_no = 'X'.ENDIF.IF ls_phone IS NOT INITIAL.ls_phone-contact-task = 'M'.APPEND ls_phone TO ls_contact-address_type_1-communication-phone-phone[].CLEAR: ls_phone.ENDIF.IF is_general-e_mail IS NOT INITIAL.READ TABLE lt_knvk INTO ls_knvk WITH KEY parnr = ls_contact-data_key-parnr.IF sy-subrc = 0.SELECT SINGLE * INTO ls_adr6FROM adr6WHERE persnumber = ls_knvk-prsnr.IF ls_adr6-smtp_addr IS INITIAL.ls_smtp-contact-task = 'I'.ELSE.ls_smtp-contact-task = 'U'.ENDIF.ENDIF.ls_smtp-contact-data-e_mail = is_general-e_mail.ls_smtp-contact-datax-e_mail = 'X'.APPEND ls_smtp TO ls_contact-address_type_1-communication-smtp-smtp[].APPEND ls_smtp TO ls_contact-address_type_3-communication-smtp-smtp[].CLEAR: ls_smtp.ENDIF.IF is_general-postl_cod1 IS NOT INITIAL.ls_contact-address_type_1-postal-data-postl_cod1 = is_general-postl_cod1.ls_contact-address_type_1-postal-datax-postl_cod1 = 'X'.ls_contact-address_type_2-postal-data-postl_cod1 = is_general-postl_cod1.ls_contact-address_type_2-postal-datax-postl_cod1 = 'X'.ENDIF.IF is_general-country IS NOT INITIAL.ls_contact-address_type_1-postal-data-country = is_general-country.ls_contact-address_type_1-postal-datax-country = 'X'.ls_contact-address_type_2-postal-data-country = is_general-country.ls_contact-address_type_2-postal-datax-country = 'X'.ENDIF.IF is_general-name_c IS NOT INITIAL.ls_contact-address_type_1-postal-data-name = is_general-name_c.ls_contact-address_type_1-postal-datax-name = 'X'.ls_contact-address_type_3-postal-data-fullname = is_general-name_c.ls_contact-address_type_3-postal-data-firstname = is_general-name_c.ls_contact-address_type_3-postal-data-lastname = is_general-name_c.ls_contact-address_type_3-postal-datax-fullname = 'X'.ls_contact-address_type_3-postal-datax-firstname = 'X'.ls_contact-address_type_3-postal-datax-lastname = 'X'.ENDIF.IF ls_contact IS NOT INITIAL.ls_contact-address_type_1-task = 'M'.ls_contact-address_type_2-task = 'M'.ls_contact-address_type_3-task = 'M'.APPEND ls_contact TO ls_customers-central_data-contact-contacts[].CLEAR: ls_contact.ENDIF."紧急联系人LOOP AT lt_knvk INTO ls_knvk.CLEAR: lv_name.CONCATENATE ls_knvk-name1 ls_knvk-namev INTO lv_name.IF lv_name = is_general-name_jj.ls_contact-task = 'U'.ls_contact-data_key-parnr = ls_knvk-parnr.EXIT.ELSE.ls_contact-task = 'M'.ENDIF.ENDLOOP.IF ls_contact-task = 'M'.cmd_ei_api=>get_contact_number( IMPORTING ev_parnr = ls_contact-data_key-parnres_error = gs_error ).ENDIF.IF is_general-telephone_jj IS NOT INITIAL.ls_phone-contact-data-telephone = is_general-telephone_jj.ls_phone-contact-datax-telephone = 'X'.ENDIF.IF is_general-extension_jj IS NOT INITIAL.ls_phone-contact-data-extension = is_general-extension_jj.ls_phone-contact-datax-extension = 'X'.ENDIF.IF is_general-tel_no_jj IS NOT INITIAL.ls_phone-contact-data-tel_no = is_general-tel_no_jj.ls_phone-contact-datax-tel_no = 'X'.ENDIF.IF ls_phone IS NOT INITIAL.ls_phone-contact-task = 'M'.APPEND ls_phone TO ls_contact-address_type_1-communication-phone-phone[].CLEAR: ls_phone.ENDIF.IF is_general-e_mail_jj IS NOT INITIAL.READ TABLE lt_knvk INTO ls_knvk WITH KEY parnr = ls_contact-data_key-parnr.IF sy-subrc = 0.SELECT SINGLE * INTO ls_adr6FROM adr6WHERE persnumber = ls_knvk-prsnr.IF ls_adr6-smtp_addr IS INITIAL.ls_smtp-contact-task = 'I'.ELSE.ls_smtp-contact-task = 'U'.ENDIF.ENDIF.ls_smtp-contact-data-e_mail = is_general-e_mail_jj.ls_smtp-contact-datax-e_mail = 'X'.APPEND ls_smtp TO ls_contact-address_type_1-communication-smtp-smtp[].APPEND ls_smtp TO ls_contact-address_type_3-communication-smtp-smtp[].CLEAR: ls_smtp.ENDIF.IF is_general-postl_cod1_jj IS NOT INITIAL.ls_contact-address_type_1-postal-data-postl_cod1 = is_general-postl_cod1_jj.ls_contact-address_type_1-postal-datax-postl_cod1 = 'X'.ls_contact-address_type_2-postal-data-postl_cod1 = is_general-postl_cod1_jj.ls_contact-address_type_2-postal-datax-postl_cod1 = 'X'.ENDIF.IF is_general-country IS NOT INITIAL.ls_contact-address_type_1-postal-data-country = is_general-country.ls_contact-address_type_1-postal-datax-country = 'X'.ls_contact-address_type_2-postal-data-country = is_general-country.ls_contact-address_type_2-postal-datax-country = 'X'.ENDIF.IF is_general-name_jj IS NOT INITIAL.ls_contact-address_type_1-postal-data-name = is_general-name_jj.ls_contact-address_type_1-postal-datax-name = 'X'.ls_contact-address_type_3-postal-data-fullname = is_general-name_jj.ls_contact-address_type_3-postal-data-firstname = is_general-name_jj.ls_contact-address_type_3-postal-data-lastname = is_general-name_jj.ls_contact-address_type_3-postal-datax-fullname = 'X'.ls_contact-address_type_3-postal-datax-firstname = 'X'.ls_contact-address_type_3-postal-datax-lastname = 'X'.ENDIF.IF ls_contact IS NOT INITIAL.ls_contact-address_type_1-task = 'M'.ls_contact-address_type_2-task = 'M'.ls_contact-address_type_3-task = 'M'.APPEND ls_contact TO ls_customers-central_data-contact-contacts[].CLEAR: ls_contact.ENDIF." 税分类LOOP AT it_tax_data INTO ls_tax_data.ls_tax-task = 'M'.ls_tax-data_key-aland = ls_tax_data-aland. "发货国(由该国家发货)ls_tax-data_key-tatyp = ls_tax_data-tatyp. "税类别(营业税,联邦营业税,...)ls_tax-data-taxkd = ls_tax_data-taxkd. "客户税分类ls_tax-datax-taxkd = 'X'.APPEND ls_tax TO ls_customers-central_data-tax_ind-tax_ind[].CLEAR: ls_tax, ls_tax_data.ENDLOOP.
*--------------------------------------------------------------------*
*  销售视图信息
*--------------------------------------------------------------------*LOOP AT it_sales_data INTO ls_sales_data.ls_sales-task = 'M'.ls_sales-data_key-vkorg = ls_sales_data-vkorg. "销售组织ls_sales-data_key-vtweg = ls_sales_data-vtweg. "分销渠道ls_sales-data_key-spart = ls_sales_data-spart. "产品组ls_sales-data-bzirk = ls_sales_data-bzirk."销售地区ls_sales-data-vkgrp = ls_sales_data-vkgrp. "销售组ls_sales-data-vkbur = ls_sales_data-vkbur. "销售部门ls_sales-data-awahr = ls_sales_data-awahr."该项目的订单可能性ls_sales-data-kdgrp = ls_sales_data-kdgrp. "客户组ls_sales-data-waers = ls_sales_data-waers. "货币ls_sales-data-kalks = ls_sales_data-kalks."定价过程分配到该客户ls_sales-data-zterm = ls_sales_data-zterm. "付款条件代码ls_sales-data-mrnkz = ls_sales_data-mrnkz. "人工发票维护ls_sales-data-bokre = ls_sales_data-bokre. "标识:客户将接受回扣ls_sales-data-prfre = ls_sales_data-prfre. "定价标识相关ls_sales-data-ktgrd = ls_sales_data-ktgrd. "客户组的帐户分配ls_sales-data-inco1 = ls_sales_data-inco1. "国际贸易条款 (部分1)ls_sales-data-inco2 = ls_sales_data-inco2. "国际贸易条件(部分2)ls_sales-data-kzazu = 'X'. "订单组合标识ls_functions-task = 'M'.ls_functions-data_key-parvw = 'AG'.IF lv_kunnr IS NOT INITIAL.ls_functions-data-partner = lv_kunnr.ls_functions-datax-partner = 'X'.ENDIF.APPEND ls_functions TO ls_sales-functions-functions[].CLEAR: ls_functions.ls_functions-task = 'M'.ls_functions-data_key-parvw = 'RE'.IF lv_kunnr IS NOT INITIAL.ls_functions-data-partner = lv_kunnr.ls_functions-datax-partner = 'X'.ENDIF.APPEND ls_functions TO ls_sales-functions-functions[].CLEAR: ls_functions.ls_functions-task = 'M'.ls_functions-data_key-parvw = 'RG'.IF lv_kunnr IS NOT INITIAL.ls_functions-data-partner = lv_kunnr.ls_functions-datax-partner = 'X'.ENDIF.APPEND ls_functions TO ls_sales-functions-functions[].CLEAR: ls_functions.ls_functions-task = 'M'.ls_functions-data_key-parvw = 'WE'.IF lv_kunnr IS NOT INITIAL.ls_functions-data-partner = lv_kunnr.ls_functions-datax-partner = 'X'.ENDIF.APPEND ls_functions TO ls_sales-functions-functions[].CLEAR: ls_functions.ls_sales-datax-bzirk = 'X'.ls_sales-datax-vkgrp = 'X'.ls_sales-datax-vkbur = 'X'.ls_sales-datax-awahr = 'X'.ls_sales-datax-kdgrp = 'X'.ls_sales-datax-waers = 'X'.ls_sales-datax-kalks = 'X'.ls_sales-datax-zterm = 'X'.ls_sales-datax-mrnkz = 'X'.ls_sales-datax-bokre = 'X'.ls_sales-datax-prfre = 'X'.ls_sales-datax-ktgrd = 'X'.ls_sales-datax-inco1 = 'X'.ls_sales-datax-inco2 = 'X'.ls_sales-datax-kzazu = 'X'.APPEND ls_sales TO ls_customers-sales_data-sales[].CLEAR: ls_sales, ls_sales_data.ENDLOOP.*--------------------------------------------------------------------*
*  公司代码视图信息
*--------------------------------------------------------------------*LOOP AT it_company_data INTO ls_company_data.ls_company-task = 'M'.ls_company-data_key-bukrs = ls_company_data-bukrs. "公司代码ls_company-data-akont = ls_company_data-akont. "统驭科目ls_company-datax-akont = 'X'.APPEND ls_company TO ls_customers-company_data-company[].CLEAR: ls_company, ls_company_data.ENDLOOP.APPEND ls_customers TO is_master_data-customers[].*  CALL METHOD cmd_ei_api=>maintain
*    EXPORTING
*      iv_test_run    = space
*      is_master_data = is_master_data
*    IMPORTING
*      es_error       = es_error.CALL METHOD cmd_ei_api=>maintain_bapiEXPORTING
*     iv_test_run              = SPACE
*     iv_collect_messages      = SPACEis_master_data           = is_master_dataIMPORTINGes_master_data_correct   = es_master_data_correctes_message_correct       = es_message_correctes_master_data_defective = es_master_data_defectivees_message_defective     = es_message_defective.READ TABLE es_master_data_correct-customers[] INTO ls_customrers INDEX 1.IF sy-subrc <> 0.CALL FUNCTION 'BAPI_TRANSACTION_ROLLBACK'
*     IMPORTING
*       RETURN        =.ELSE.CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'EXPORTINGwait = 'X'
*     IMPORTING
*       RETURN        =.
*    READ TABLE es_master_data_correct-customers[] INTO ls_customrers INDEX 1.kunnr = ls_customrers-header-object_instance-kunnr.ENDIF.LOOP AT es_error-messages INTO ls_messages.MOVE-CORRESPONDING ls_messages TO ls_return.APPEND ls_return TO et_return.CLEAR: ls_return, ls_messages.ENDLOOP.LOOP AT es_message_defective-messages INTO ls_messages..MOVE-CORRESPONDING ls_messages TO ls_return.APPEND ls_return TO et_return.CLEAR: ls_return, ls_messages.ENDLOOP.ENDFUNCTION.

这篇关于SAP BAPI 客户主数据创建:cmd_ei_api=>maintain_bapi的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/569610

相关文章

大模型研发全揭秘:客服工单数据标注的完整攻略

在人工智能(AI)领域,数据标注是模型训练过程中至关重要的一步。无论你是新手还是有经验的从业者,掌握数据标注的技术细节和常见问题的解决方案都能为你的AI项目增添不少价值。在电信运营商的客服系统中,工单数据是客户问题和解决方案的重要记录。通过对这些工单数据进行有效标注,不仅能够帮助提升客服自动化系统的智能化水平,还能优化客户服务流程,提高客户满意度。本文将详细介绍如何在电信运营商客服工单的背景下进行

基于MySQL Binlog的Elasticsearch数据同步实践

一、为什么要做 随着马蜂窝的逐渐发展,我们的业务数据越来越多,单纯使用 MySQL 已经不能满足我们的数据查询需求,例如对于商品、订单等数据的多维度检索。 使用 Elasticsearch 存储业务数据可以很好的解决我们业务中的搜索需求。而数据进行异构存储后,随之而来的就是数据同步的问题。 二、现有方法及问题 对于数据同步,我们目前的解决方案是建立数据中间表。把需要检索的业务数据,统一放到一张M

关于数据埋点,你需要了解这些基本知识

产品汪每天都在和数据打交道,你知道数据来自哪里吗? 移动app端内的用户行为数据大多来自埋点,了解一些埋点知识,能和数据分析师、技术侃大山,参与到前期的数据采集,更重要是让最终的埋点数据能为我所用,否则可怜巴巴等上几个月是常有的事。   埋点类型 根据埋点方式,可以区分为: 手动埋点半自动埋点全自动埋点 秉承“任何事物都有两面性”的道理:自动程度高的,能解决通用统计,便于统一化管理,但个性化定

使用SecondaryNameNode恢复NameNode的数据

1)需求: NameNode进程挂了并且存储的数据也丢失了,如何恢复NameNode 此种方式恢复的数据可能存在小部分数据的丢失。 2)故障模拟 (1)kill -9 NameNode进程 [lytfly@hadoop102 current]$ kill -9 19886 (2)删除NameNode存储的数据(/opt/module/hadoop-3.1.4/data/tmp/dfs/na

异构存储(冷热数据分离)

异构存储主要解决不同的数据,存储在不同类型的硬盘中,达到最佳性能的问题。 异构存储Shell操作 (1)查看当前有哪些存储策略可以用 [lytfly@hadoop102 hadoop-3.1.4]$ hdfs storagepolicies -listPolicies (2)为指定路径(数据存储目录)设置指定的存储策略 hdfs storagepolicies -setStoragePo

Hadoop集群数据均衡之磁盘间数据均衡

生产环境,由于硬盘空间不足,往往需要增加一块硬盘。刚加载的硬盘没有数据时,可以执行磁盘数据均衡命令。(Hadoop3.x新特性) plan后面带的节点的名字必须是已经存在的,并且是需要均衡的节点。 如果节点不存在,会报如下错误: 如果节点只有一个硬盘的话,不会创建均衡计划: (1)生成均衡计划 hdfs diskbalancer -plan hadoop102 (2)执行均衡计划 hd

【Prometheus】PromQL向量匹配实现不同标签的向量数据进行运算

✨✨ 欢迎大家来到景天科技苑✨✨ 🎈🎈 养成好习惯,先赞后看哦~🎈🎈 🏆 作者简介:景天科技苑 🏆《头衔》:大厂架构师,华为云开发者社区专家博主,阿里云开发者社区专家博主,CSDN全栈领域优质创作者,掘金优秀博主,51CTO博客专家等。 🏆《博客》:Python全栈,前后端开发,小程序开发,人工智能,js逆向,App逆向,网络系统安全,数据分析,Django,fastapi

【Python编程】Linux创建虚拟环境并配置与notebook相连接

1.创建 使用 venv 创建虚拟环境。例如,在当前目录下创建一个名为 myenv 的虚拟环境: python3 -m venv myenv 2.激活 激活虚拟环境使其成为当前终端会话的活动环境。运行: source myenv/bin/activate 3.与notebook连接 在虚拟环境中,使用 pip 安装 Jupyter 和 ipykernel: pip instal

在cscode中通过maven创建java项目

在cscode中创建java项目 可以通过博客完成maven的导入 建立maven项目 使用快捷键 Ctrl + Shift + P 建立一个 Maven 项目 1 Ctrl + Shift + P 打开输入框2 输入 "> java create"3 选择 maven4 选择 No Archetype5 输入 域名6 输入项目名称7 建立一个文件目录存放项目,文件名一般为项目名8 确定

烟火目标检测数据集 7800张 烟火检测 带标注 voc yolo

一个包含7800张带标注图像的数据集,专门用于烟火目标检测,是一个非常有价值的资源,尤其对于那些致力于公共安全、事件管理和烟花表演监控等领域的人士而言。下面是对此数据集的一个详细介绍: 数据集名称:烟火目标检测数据集 数据集规模: 图片数量:7800张类别:主要包含烟火类目标,可能还包括其他相关类别,如烟火发射装置、背景等。格式:图像文件通常为JPEG或PNG格式;标注文件可能为X