探索Allure Report:提升自动化测试效率的秘密武器

一.使用 Allure2 运行方式-Python

 
  1. # --alluredir 参数生成测试报告。

  2. # 在测试执行期间收集结果

  3. pytest [测试用例/模块/包] --alluredir=./result/  (—alluredir这个选项 用于指定存储测试结果的路径)

  4. # 生成在线的测试报告

  5. allure serve ./result

二.使用 Allure2 运行方式-Java

1.使用 allure:report 参数生成测试报告

 
  1. # 在测试执行期间收集结果

  2. # mvn命令行使用 maven插件安装

  3. mvn clean test allure:report

  4. # 生成在线的测试报告

  5. # mvn 直接找target/allure-results目录

  6. mvn allure:serve 

2.运行mvn命令对应没有在target下面生成allure-results目录。在src/test/resources路径下配置allure配置文件allure.properties,指名allure报告生成路径。

allure.results.directory=target/allure-resultsa

3.运行mvn命令一直卡在下载中,解决方法

①在项目下创建.allure文件夹。

②下载allure解压到.allure文件夹下。

三.生成测试报告

1.生成测试报告需要使用命令行工具allure

2.命令格式allure [option] [command] [command options]

 
  1. # 步骤一:在测试执行期间收集结果

  2. # —alluredir这个选项 用于指定存储测试结果的路径

  3. pytest  [测试文件] -s –q --alluredir=./result/

  4. # 如果要清除已经生成的报告的历史记录,可以添加参数--clean-alluredir

  5. pytest  [测试文件] -s –q --alluredir=./result/ --clean-alluredir

  6. # 步骤二:查看测试报告,注意这里的serve书写

  7. allure serve ./result/

3.Allure报告生成的两种方式

方式一:在线报告,会直接打开默认浏览器展示当前报告。

 
  1. # 方式一:测试完成后查看实际报告,在线查看报告,会直接打开默认浏览器展示当前报告。

  2. allure serve ./result/

方式二:静态资源文件报告(带 index.htmlcssjs等文件),需要将报告布署到 web服务器上。

 
  1. a.应用场景:如果希望随时打开报告,可以生成一个静态资源文件报告,将这个报告布署到 web 服务器上,启动 web 服务,即可随时随地打开报告。

  2. b.解决方案:使用allure generate 生成带有 index.html 的结果报告。这种方式需要两个步骤:第一步:生成报告。第二步:打开报告。

  3. # 生成报告

  4. allure generate ./result

  5. # 打开报告

  6. allure open ./report/

4.常用参数

 
  1. ①allure generate 可以指定输出路径,也可以清理上次的报告记录。

  2. ②-o / –output 输出报告的路径。

  3. ③-c / –clean 如果报告路径重复。

  4. ④allure open 打开报告。

  5. ⑤-h / –host 主机 IP 地址,此主机将用于启动报表的 web 服务器。

  6. ⑥-p / –port 主机端口,此端口将用于启动报表的 web 服务器,默认值:0。

  7. # 生成报告,指定输出路径,清理报告。

  8. allure generate ./result -o ./report --clean

  9. # 打开报告,指定IP地址和端口。

  10. allure open -h 127.0.0.1 -p 8883 ./report/

四.Allure2 报告中添加用例标题

通过使用装饰器@allure.title可以为测试用例自定义一个可阅读性的标题。allure.title的三种使用方式如下

方式一:直接使用装饰器@allure.title 为测试用例自定义标题。

 
  1. import allure

  2. import pytest

  3. @allure.title("自定义测试用例标题")

  4. def test_with_title():

  5.     assert True

方式二:@allure.title支持通过占位符的方式传递参数,可以实现测试用例标题参数化,动态生成测试用例标题。

 
  1. import allure

  2. import pytest

  3. @allure.title("参数化用例标题:参数一:{param1} ,参数二: {param2}")

  4. @pytest.mark.parametrize("param1, param2, expected", [

  5.     (1, 1, 2),

  6.     (0.1, 0.3, 0.4)

  7. ])

  8. def test_with_parametrize_title(param1, param2, expected):

  9.     assert param1 + param2 == expected

方式三:allure.dynamic.title 动态更新测试用例标题。

 
  1. @allure.title("原始标题")

  2. def test_with_dynamic_title():

  3.     assert True

  4.     allure.dynamic.title("更改后的新标题")

五.Allure2报告中添加用例步骤

方法一:使用装饰器定义一个测试步骤,在测试用例中使用。

 
  1. # 方法一:使用装饰器定义一个测试步骤,在测试用例中使用

  2. import allure

  3. import pytest

  4. # 定义测试步骤:simple_step1

  5. @allure.step

  6. def simple_step1(step_param1, step_param2 = None):

  7.     '''定义一个测试步骤'''

  8.     print(f"步骤1:打开页面,参数1: {step_param1}, 参数2:{step_param2}")

  9. # 定义测试步骤:simple_step2

  10. @allure.step

  11. def simple_step2(step_param):

  12.     '''定义一个测试步骤'''

  13.     print(f"步骤2:完成搜索 {step_param} 功能")

  14. @pytest.mark.parametrize('param1', ["pytest", "allure"], ids=['search pytest', 'search allure'])

  15. def test_parameterize_with_id(param1):

  16.       simple_step2(param1)         # 调用步骤二

  17. @pytest.mark.parametrize('param1', [True, False])

  18. @pytest.mark.parametrize('param2', ['value 1', 'value 2'])

  19. def test_parametrize_with_two_parameters(param1, param2):

  20.       simple_step1(param1, param2)   # 调用步骤一

  21. @pytest.mark.parametrize('param2', ['pytest', 'unittest'])

  22. @pytest.mark.parametrize('param1,param3', [[1,2]])

  23. def test_parameterize_with_uneven_value_sets(param1, param2, param3):

  24.     simple_step1(param1, param3)    # 调用步骤一

  25.     simple_step2(param2)      # 调用步骤二

方法二:使用 with allure.step() 添加测试步骤。

 
  1. # 方法二:使用 `with allure.step()` 添加测试步骤

  2. @allure.title("搜索用例")

  3. def test_step_in_method():

  4.     with allure.step("测试步骤一:打开页面"):

  5.         print("操作 a")

  6.         print("操作 b")

  7.     with allure.step("测试步骤二:搜索"):

  8.         print("搜索操作 ")

  9.     with allure.step("测试步骤三:断言"):

  10.         assert True

六.Allure2报告中添加用例链接

应用场景:将报告与bug管理系统或测试用例管理系统集成,可以添加链接装饰器@allure.link@allure.issue@allure.testcase

 
  1. 1.@allure.link(url, name) 添加一个普通的 link 链接。

  2. 2.@allure.testcase(url, name) 添加一个用例管理系统链接。

  3. 3.@allure.issue(url, name),添加 bug 管理系统


 
  1. # 格式1:添加一个普通的link 链接

  2. @allure.link('https://ceshiren.com/t/topic/15860')

  3. def test_with_link():

  4.     pass

  5. # 格式1:添加一个普通的link 链接,添加链接名称

  6. @allure.link('https://ceshiren.com/t/topic/15860', name='这是用例链接地址')

  7. def test_with_named_link():

  8.     pass

  9. # 格式2:添加用例管理系统链接

  10. TEST_CASE_LINK = 'https://github.com/qameta/allure-integrations/issues/8#issuecomment-268313637'

  11. @allure.testcase(TEST_CASE_LINK, '用例管理系统')

  12. def test_with_testcase_link():

  13.     pass

  14. # 格式3:添加bug管理系统链接

  15. # 这个装饰器在展示的时候会带 bug 图标的链接。可以在运行时通过参数 `--allure-link-pattern` 指定一个模板链接,以便将其与提供的问题链接类型链接模板一起使用。执行命令需要指定模板链接:

  16. `--allure-link-pattern=issue:https://abc.com/t/topic/{}`

  17. @allure.issue("15860", 'bug管理系统')

  18. def test_with_issue():

  19.     pass

七.Allure2报告中添加用例分类

1.Allure分类

(1)应用场景:可以为项目,以及项目下的不同模块对用例进行分类管理。也可以运行某个类别下的用例。

(2)报告展示:类别会展示在测试报告的Behaviors栏目下。

(3)Allure提供了三个装饰器:

  • @allure.epic:敏捷里面的概念,定义史诗,往下是 feature

  • @allure.feature:功能点的描述,理解成模块往下是 story

  • @allure.story:故事 story 是 feature 的子集。

2.Allure分类 - epic

  • 场景:希望在测试报告中看到用例所在的项目,需要用到 epic,相当于定义一个项目的需求,由于粒度比较大,在epic下面还要定义略小粒度的用户故事。

  • 装饰器:@allure.epic

 
  1. import allure

  2. @allure.epic("需求1")

  3. class TestEpic:

  4.     def test_case1(self):

  5.         print("用例1")

  6.     def test_case2(self):

  7.         print("用例2")

  8.     def test_case3(self):

  9.         print("用例3")

3.Allure分类 - feature/story

  • 场景: 希望在报告中看到测试功能,子功能或场景。

  • 装饰器: @allure.Feature@allure.story

 
  1. import allure

  2. @allure.epic("需求1")

  3. @allure.feature("功能模块1")

  4. class TestEpic:

  5.     @allure.story("子功能1")

  6.     @allure.title("用例1")

  7.     def test_case1(self):

  8.         print("用例1")

  9.     @allure.story("子功能2")

  10.     @allure.title("用例2")

  11.     def test_case2(self):

  12.         print("用例2")

  13.     @allure.story("子功能2")

  14.     @allure.title("用例3")

  15.     def test_case3(self):

  16.         print("用例3")

  17.     @allure.story("子功能1")

  18.     @allure.title("用例4")

  19.     def test_case4(self):

  20.         print("用例4")

 
  1. # allure相关的命令查看

  2. pytest --help|grep allure


 
  1. #通过指定命令行参数,运行 epic/feature/story 相关的用例:

  2. pytest 文件名

  3. --allure-epics=EPICS_SET --allure-features=FEATURES_SET --allure-stories=STORIES_SET

  4. # 只运行 epic 名为 "需求1" 的测试用例

  5. pytest --alluredir ./results --clean-alluredir --allure-epics=需求1

  6. # 只运行 feature 名为 "功能模块2" 的测试用例

  7. pytest --alluredir ./results --clean-alluredir --allure-features=功能模块2

  8. # 只运行 story 名为 "子功能1" 的测试用例

  9. pytest --alluredir ./results --clean-alluredir --allure-stories=子功能1

  10. # 运行 story 名为 "子功能1和子功能2" 的测试用例

  11. pytest --alluredir ./results --clean-alluredir --allure-stories=子功能1,子功能2

  12. # 运行 feature + story 的用例(取并集)

  13. pytest --alluredir ./results --clean-alluredir --allure-features=功能模块1 --allure-stories=子功能1,子功能2

  14. Allure epic/feature/story 的关系

5.总结

  • epic:敏捷里面的概念,用来定义史诗,相当于定义一个项目。

  • feature:相当于一个功能模块,相当于 testsuite,可以管理很多个子分支 story

  • story:相当于对应这个功能或者模块下的不同场景,分支功能。

  • epic 与 featurefeature 与 story 类似于父子关系。

八.Allure2 报告中添加用例描述

1.应用场景:Allure 支持往测试报告中对测试用例添加非常详细的描述语,用来描述测试用例详情。

2.Allure添加描述的四种方式:

方式一:使用装饰器 @allure.description() 传递一个字符串参数来描述测试用例。

 
  1. @allure.description("""

  2. 多行描述语:<br/>

  3. 这是通过传递字符串参数的方式添加的一段描述语,<br/>

  4. 使用的是装饰器 @allure.description

  5. """)

  6. def test_description_provide_string():

  7.     assert True

方式二:使用装饰器 @allure.description_html 传递一段 HTML 文本来描述测试用例。

 
  1. @allure.description_html("""html代码块""")

  2. def test_description_privide_html():

  3.     assert True

方式三:直接在测试用例方法中通过编写文档注释的方法来添加描述。

 
  1. def test_description_docstring():

  2.     """

  3.     直接在测试用例方法中

  4.     通过编写文档注释的方法

  5.     来添加描述。

  6.     :return:

  7.     """

  8.     assert True

方式四:用例代码内部动态添加描述信息。

 
  1. import allure

  2. @allure.description("""这个描述将被替换""")

  3. def test_dynamic_description():

  4.     assert 42 == int(6 * 7)

  5.     allure.dynamic.description('这是最终的描述信息')

  6.     # allure.dynamic.description_html(''' html 代码块 ''')

九.Allure2报告中添加用例优先级

1.应用场景:用例执行时,希望按照严重级别执行测试用例。

2.解决:可以为每个用例添加一个等级的装饰器,用法:@allure.severity

3.Allure 对严重级别的定义分为 5 个级别:

  • Blocker级别:中断缺陷(客户端程序无响应,无法执行下一步操作)。

  • Critical级别:临界缺陷( 功能点缺失)。

  • Normal级别:普通缺陷(数值计算错误)。

  • Minor级别:次要缺陷(界面错误与UI需求不符)。

  • Trivial级别:轻微缺陷(必输项无提示,或者提示不规范)。

4.使用装饰器添加用例方法/类的级别。类上添加的级别,对类中没有添加级别的方法生效。

 
  1. #运行时添加命令行参数 --allure-severities:

  2. pytest --alluredir ./results --clean-alluredir --allure-severities normal,blocker


 
  1. import allure

  2. def test_with_no_severity_label():

  3.     pass

  4. @allure.severity(allure.severity_level.TRIVIAL)

  5. def test_with_trivial_severity():

  6.     pass

  7. @allure.severity(allure.severity_level.NORMAL)

  8. def test_with_normal_severity():

  9.     pass

  10. @allure.severity(allure.severity_level.NORMAL)

  11. class TestClassWithNormalSeverity(object):

  12.     def test_inside_the_normal(self):

  13.         pass

  14.     @allure.severity(allure.severity_level.CRITICAL)

  15.     def test_critical_severity(self):

  16.         pass

  17.     @allure.severity(allure.severity_level.BLOCKER)

  18.     def test_blocker_severity(self):

  19.         pass

十.Allure2报告中添加用例支持tags标签

1.Allure2 添加用例标签-xfailskipif

 
  1. import pytest

  2. # 用法:使用装饰器 @pytest.xfail()、@pytest.skipif()

  3. # 当用例通过时标注为 xfail

  4. @pytest.mark.xfail(condition=lambda: True, reason='这是一个预期失败的用例')

  5. def test_xfail_expected_failure():

  6.     """this test is a xfail that will be marked as expected failure"""

  7.     assert False

  8. # 当用例通过时标注为 xpass

  9. @pytest.mark.xfail

  10. def test_xfail_unexpected_pass():

  11.     """this test is a xfail that will be marked as unexpected success"""

  12.     assert True

  13. # 跳过用例

  14. @pytest.mark.skipif('2 + 2 != 5', reason='当条件触发时这个用例被跳过 @pytest.mark.skipif')

  15. def test_skip_by_triggered_condition():

  16.     pass

2.Allure2 添加用例标签-fixture

应用场景:fixture 和 finalizer 是分别在测试开始之前和测试结束之后由 Pytest 调用的实用程序函数。Allure 跟踪每个 fixture 的调用,并详细显示调用了哪些方法以及哪些参数,从而保持了调用的正确顺序。

 
  1. import pytest

  2. @pytest.fixture()

  3. def func(request):

  4.     print("这是一个fixture方法")

  5.     # 定义一个终结器,teardown动作放在终结器中

  6.     def over():

  7.         print("session级别终结器")

  8.     request.addfinalizer(over)

  9. class TestClass(object):

  10.     def test_with_scoped_finalizers(self,func):

  11.         print("测试用例")

十一.Allure2报告中支持记录失败重试功能

1.Allure 可以收集用例运行期间,重试的用例的结果,以及这段时间重试的历史记录。

2.重试功能可以使用 pytest 相关的插件,例如 pytest-rerunfailures。重试的结果信息,会展示在详情页面的Retries 选项卡中。

 
  1. import pytest

  2. @pytest.mark.flaky(reruns=2, reruns_delay=2)   # reruns重试次数,reruns_delay每次重试间隔时间(秒)

  3. def test_rerun2():

  4.     assert False

十二.Allure2 报告中添加附件-图片

1.应用场景:在做 UI 自动化测试时,可以将页面截图,或者出错的页面进行截图,将截图添加到测试报告中展示,辅助定位问题。

2.解决方案

  • Python:使用 allure.attach 或者 allure.attach.file() 添加图片。

  • Java:直接通过注解或调用方法添加。

3.python方法一

 
  1. 语法:allure.attach.file(source, name, attachment_type, extension),

  2. 参数解释:

  3.     ①source:文件路径,相当于传一个文件。

  4.     ②name:附件名字。

  5.     ③attachment_type:附件类型,是 allure.attachment_type 其中的一种(支持 PNG、JPG、BMP、GIF 等)。

  6.     ④extension:附件的扩展名。


 
  1. import allure

  2. class TestWithAttach:

  3.     def test_pic(self):

  4.         allure.attach.file("pic.png", name="图片", attachment_type=allure.attachment_type.PNG, extension="png")

4.python方法二

 
  1. 语法:allure.attach(body, name=None, attachment_type=None, extension=None)

  2. 参数解释:

  3.     ①body:要写入附件的内容

  4.     ②name:附件名字。

  5.     ③attachment_type:附件类型,是 allure.attachment_type 其中的一种(支持 PNG、JPG、BMP、GIF 等)。

  6.     ④extension:附件的扩展名。

5.裂图的原因以及解决办法

  • 图片上传过程中出现了网络中断或者传输过程中出现了错误。解决方案:重新上传图片。

  • Allure 报告中的图片大小超过了 Allure 的限制。解决方案:调整图片大小。

  • 图片本身存在问题。解决方案:检查图片格式和文件本身。

十三.Allure2报告中添加附件-日志

1.应用场景:报告中添加详细的日志信息,有助于分析定位问题。2.解决方案:使用 python 自带的 logging 模块生成日志,日志会自动添加到测试报告中。日志配置,在测试报告中使用 logger 对象生成对应级别的日志。

 
  1. # 创建一个日志模块:log_util.py

  2. import logging

  3. import os

  4. from logging.handlers import RotatingFileHandler

  5. # 绑定绑定句柄到logger对象

  6. logger = logging.getLogger(__name__)

  7. # 获取当前工具文件所在的路径

  8. root_path = os.path.dirname(os.path.abspath(__file__))

  9. # 拼接当前要输出日志的路径

  10. log_dir_path = os.sep.join([root_path, f'/logs'])

  11. if not os.path.isdir(log_dir_path):

  12. os.mkdir(log_dir_path)

  13. # 创建日志记录器,指明日志保存路径,每个日志的大小,保存日志的上限

  14. file_log_handler = RotatingFileHandler(os.sep.join([log_dir_path, 'log.log']), maxBytes=1024 * 1024, backupCount=10 , encoding="utf-8")

  15. # 设置日志的格式

  16. date_string = '%Y-%m-%d %H:%M:%S'

  17. formatter = logging.Formatter(

  18. '[%(asctime)s] [%(levelname)s] [%(filename)s]/[line: %(lineno)d]/[%(funcName)s] %(message)s ', date_string)

  19. # 日志输出到控制台的句柄

  20. stream_handler = logging.StreamHandler()

  21. # 将日志记录器指定日志的格式

  22. file_log_handler.setFormatter(formatter)

  23. stream_handler.setFormatter(formatter)

  24. # 为全局的日志工具对象添加日志记录器

  25. # 绑定绑定句柄到logger对象

  26. logger.addHandler(stream_handler)

  27. logger.addHandler(file_log_handler)

  28. # 设置日志输出级别

  29. logger.setLevel(level=logging.INFO)

代码输出到用例详情页面。运行用例命令:pytest --alluredir ./results --clean-alluredir(注意不要加-vs)。

 
  1. import allure

  2. from pytest_test.log_util import logger

  3. @allure.feature("功能模块2")

  4. class TestWithLogger:

  5.     @allure.story("子功能1")

  6.     @allure.title("用例1")

  7.     def test_case1(self):

  8.         logger.info("用例1的 info 级别的日志")

  9.         logger.debug("用例1的 debug 级别的日志")

  10.         logger.warning("用例1的 warning 级别的日志")

  11.         logger.error("用例1的 error 级别的日志")

  12.         logger.fatal("用例1的  fatal 级别的日志")

日志展示在 Test body 标签下,标签下可展示多个子标签代表不同的日志输出渠道:

  • log 子标签:展示日志信息。

  • stdout 子标签:展示 print 信息。

  • stderr 子标签:展示终端输出的信息。

禁用日志,可以使用命令行参数控制 --allure-no-capture

pytest --alluredir ./results --clean-alluredir --allure-no-capture

 
  1. public void exampleTest() {

  2.       byte[] contents = Files.readAllBytes(Paths.get("a.txt"));

  3.       attachTextFile(byte[]的文件, "描述信息");

  4.   }

  5. @Attachment(value = "{attachmentName}", type = "text/plain")

  6. public byte[] attachTextFile(byte[] contents, String attachmentName) {

  7.       return contents;

  8. }

调用方法添加。

 
  1. --String类型添加。 日志文件为String类型

  2. Allure.addAttachment("描述信息", "text/plain", 文件读取为String,"txt");

  3. --InputStream类型添加。日志文件为InputStream流

  4. Allure.addAttachment("描述信息", "text/plain", Files.newInputStream(文件Path), "txt");

十四.Allure2报告中添加附件-html

1.应用场景:可以定制测试报告页面效果,可以将 HTML 类型的附件显示在报告页面上。

2.解决方案:使用 allure.attach() 添加 html 代码。

 
  1. 语法:allure.attach(body, name, attachment_type, extension),

  2. 参数解释:

  3.     body:要写入附件的内容(HTML 代码块)。

  4.     name:附件名字。

  5.     attachment_type:附件类型,是 allure.attachment_type 其中的一种。

  6.     extension:附件的扩展名。


 
  1. import allure

  2. class TestWithAttach:

  3.     def test_html(self):

  4.         allure.attach('<head></head><body> a page </body>',

  5.                       '附件是HTML类型',

  6.                       allure.attachment_type.HTML)

  7.                       

  8.     def test_html_part(self):

  9.         allure.attach('''html代码块''',

  10.                       '附件是HTML类型',

  11.                       allure.attachment_type.HTML)

十五.Allure2 报告中添加附件-视频

使用 allure.attach.file() 添加视频。

 
  1. 语法:allure.attach.file(source, name, attachment_type, extension)

  2. 参数解释:

  3.     source:文件路径,相当于传一个文件。

  4.     name:附件名字。

  5.     attachment_type:附件类型,是 allure.attachment_type 其中的一种。

  6.     extension:附件的扩展名。


 
  1. import allure

  2. class TestWithAttach:

  3.     def test_video(self):

  4.         allure.attach.file("xxx.mp4", name="视频", attachment_type=allure.attachment_type.MP4, extension="mp4")

十六.Allure2 报告定制

应用场景:针对不同的项目可能需要对测试报告展示的效果进行定制,比如修改页面的 logo、修改项目的标题或者添加一些定制的功能等等。

1.修改页面 Logo

(1)修改allure.yml文件,在后面添加 logo 插件:custom-logo-plugin(在 allure 安装路径下:/allure-2.21.0/config/allure.yml,可以通过 where allure 或者which allure查看 allure 安装路径)

(2)编辑 styles.css 文件,配置 logo 图片(logo图片可以提前准备好放在/custom-logo-plugin/static中)

 
  1. /* 打开 styles.css 文件,

  2. 目录在安装allure时,解压的路径:/xxx/allure-2.21.0/plugins/custom-logo-plugin/static/styles.css,

  3. 将内容修改图片logo和相应的大小:*/

  4. .side-nav__brand {

  5.   background: url("logo.jpeg") no-repeat left center !important;

  6.   margin-left: 10px;

  7.   height: 40px;

  8.   background-size: contain !important;

  9. }

2.修改页面标题,编辑 styles.css 文件,添加修改标题对应的代码。

 
  1. /* 去掉图片后边 allure 文本 */

  2. .side-nav__brand-text {

  3.   display: none;

  4. }

  5. /* 设置logo 后面的字体样式与字体大小 */

  6. .side-nav__brand:after {

  7.   content: "测试报告";

  8.   margin-left: 18px;

  9.   height: 20px;

  10.   font-family: Arial;

  11.   font-size: 13px;

  12. }

感谢每一个认真阅读我文章的人,礼尚往来总是要有的,虽然不是什么很值钱的东西,如果你用得到的话可以直接拿走:

这些资料,对于【软件测试】的朋友来说应该是最全面最完整的备战仓库,这个仓库也陪伴上万个测试工程师们走过最艰难的路程,希望也能帮助到你!有需要的小伙伴可以点击下方小卡片领取   

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.xdnf.cn/news/148048.html

如若内容造成侵权/违法违规/事实不符,请联系一条长河网进行投诉反馈,一经查实,立即删除!

相关文章

计算机前沿技术-人工智能算法-大语言模型-最新论文阅读-2024-09-15

计算机前沿技术-人工智能算法-大语言模型-最新论文阅读-2024-09-15 1. Towards the holistic design of alloys with large language models Z Pei, J Yin, J Neugebauer, A Jain - Nature Reviews Materials, 2024 利用大型语言模型实现合金的全面设计 摘要 文章讨论了大型…

基于单片机的自行车智能辅助系统设计

文章目录 前言资料获取设计介绍功能介绍设计程序具体实现截图目 录设计获取 前言 &#x1f497;博主介绍&#xff1a;✌全网粉丝10W,CSDN特邀作者、博客专家、CSDN新星计划导师&#xff0c;一名热衷于单片机技术探索与分享的博主、专注于 精通51/STM32/MSP430/AVR等单片机设计 …

构建数据分析模型,及时回传各系统监控监测数据进行分析反馈响应的智慧油站开源了。

AI视频监控平台简介 AI视频监控平台是一款功能强大且简单易用的实时算法视频监控系统。它的愿景是最底层打通各大芯片厂商相互间的壁垒&#xff0c;省去繁琐重复的适配流程&#xff0c;实现芯片、算法、应用的全流程组合&#xff0c;从而大大减少企业级应用约95%的开发成本。增…

[论文精读]Towards Deeper Graph Neural Networks

论文网址&#xff1a;Towards Deeper Graph Neural Networks | Proceedings of the 26th ACM SIGKDD International Conference on Knowledge Discovery & Data Mining 英文是纯手打的&#xff01;论文原文的summarizing and paraphrasing。可能会出现难以避免的拼写错误和…

在云渲染中3D工程文件安全性怎么样?

在云渲染中&#xff0c;3D工程文件的安全性是用户最关心的问题之一。随着企业对数据保护意识的增强&#xff0c;云渲染平台采取了严格的安全措施和加密技术&#xff0c;以确保用户数据的安全性和隐私性。 云渲染平台为了保障用户数据的安全&#xff0c;采取了多层次的安全措施。…

ROS机器人书的一些思考

思考 写一本书不难&#xff0c;写一本有价值的书很难&#xff0c;在语言大模型如此发展的今天写一本有价值的书&#xff0c;难上加难。 如何能让学生或读者发自内心的渴望打开一本书&#xff0c;尤其是在这个数字媒体技术如此发达的时代。 这个问题从一开始从事相关工作到如…

解决shop-vite项目打包被限制问题

本人网上找了一个好看的项目 shio-vite 项目源码 &#xff0c;并通过其他方式获取到源码&#xff0c;但是打包出现了以下问题。 问题图片一&#xff1a; 问题图片二&#xff1a; 问题图片三&#xff1a; 需要code和解决方式私可以留言哈

如何使用gewechat开发微信机器人

随着人工智能和自动化技术的快速发展&#xff0c;微信机器人已经成为越来越多人的选择。它们可以帮助我们自动回复消息、管理群组、发送定时消息等&#xff0c;极大地提高了我们的工作效率。而GeWe框架&#xff0c;作为一款开源的微信机器人框架&#xff0c;为开发者提供了便捷…

基于SpringBoot+Vue的垃圾分类回收管理系统

作者&#xff1a;计算机学姐 开发技术&#xff1a;SpringBoot、SSM、Vue、MySQL、JSP、ElementUI、Python、小程序等&#xff0c;“文末源码”。 专栏推荐&#xff1a;前后端分离项目源码、SpringBoot项目源码、Vue项目源码、SSM项目源码 精品专栏&#xff1a;Java精选实战项目…

ChatGPT 推出“Auto”自动模式:智能匹配你的需求

OpenAI 最近为 ChatGPT 带来了一项新功能——“Auto”自动模式&#xff0c;这一更新让所有用户无论使用哪种设备都能享受到更加个性化的体验。简单来说&#xff0c;当你选择 Auto 模式后&#xff0c;ChatGPT 会根据你输入的提示词复杂程度&#xff0c;自动为你挑选最适合的AI模…

【WRF运行第三期】服务器上运行WRF模型(官网案例-Hurricane Matthew)

【WRF运行第三期】运行WRF模型&#xff08;官网案例-Hurricane Matthew&#xff09; 官网案例-Hurricane Matthew介绍0 创建DATA文件夹1 WPS预处理1.1 解压GRIB数据&#xff08;ungrib.exe&#xff09;1.1.1 解压GRIB数据---GFS&#xff08;Matthew案例研究数据&#xff09;1.1…

Gartner:中国企业利用GenAI提高生产力的三大策略

作者&#xff1a;Gartner高级首席分析师 雷丝、Gartner 研究总监 闫斌、Gartner高级研究总监 张桐 随着生成式人工智能&#xff08;GenAI&#xff09;风靡全球&#xff0c;大多数企业都希望利用人工智能&#xff08;AI&#xff09;技术进行创新&#xff0c;以收获更多的业务成果…

“AI+Security”系列第3期(二):AI赋能自动化渗透测试

近日&#xff0c;“AI Security” 系列第 3 期&#xff1a;AI 安全智能体&#xff0c;重塑安全团队工作范式技术沙龙活动正式举行。该活动由安全极客、Wisemodel 社区、InForSec 网络安全研究国际学术论坛和海升集团联合主办&#xff0c;吸引了线上与线下千余名观众参与。 在…

LLM大语言模型算法特训,带你转型AI大语言模型算法工程师

LLM&#xff08;大语言模型&#xff09;是指大型的语言模型&#xff0c;如GPT&#xff08;Generative Pre-trained Transformer&#xff09;系列模型。以下是《LLM大语言模型算法特训&#xff0c;带你转型AI大语言模型算法工程师》课程可能包含的内容&#xff1a; 1.深入理解大…

【算法思想·二叉树】最近公共祖先问题

本文参考labuladong算法笔记[拓展&#xff1a;最近公共祖先系列解题框架 | labuladong 的算法笔记] 0、引言 如果说笔试的时候经常遇到各种动归回溯这类稍有难度的题目&#xff0c;那么面试会倾向于一些比较经典的问题&#xff0c;难度不算大&#xff0c;而且也比较实用。 本…

分享一个vue+spring的前后端项目

管理员页面 用户界面 后面的一部分 后端代码

守护企业资产安全:企业微信群禁止互加好友操作指南!

为了防止其他公司的人员混入发起私聊&#xff0c;导致客户资源流失&#xff0c;禁止互加好友十分重要。而软件自带群防骚扰功能&#xff0c;设置好相关规则后&#xff0c;群内成员触发规则会被踢出群聊。 进入工作台-点击更多-选择客户群-选择防骚扰-选择配制企业成员防骚扰规…

spring 代码执行(CVE-2018-1273)

&#xff08;1&#xff09;填写注册信息&#xff0c;burp抓包 &#xff08;2&#xff09;添加poc username[#this.getClass().forName("java.lang.Runtime").getRuntime().exec("touch /tmp/zcc")]&password&repeatedPassword &#xff08;3&…

2024 Python3.10 系统入门+进阶(十五):文件及目录操作

目录 一、文件IO操作1.1 创建或打开文件1.2 读取文件1.2.1 按行读取1.2.2 多行读取1.2.3 完整读取 1.3 写入文件1.3.1 写入字符串1.3.2 写入序列 1.4 上下文管理1.4.1 with语句的使用1.4.2 上下文管理器(拓展----可以学了面向对象之后再回来看) 1.5 文件的遍历 二、os.path模块…

力扣题解1014

大家好&#xff0c;欢迎来到无限大的频道。 今日继续给大家带来力扣题解。 题目描述&#xff08;中等&#xff09;&#xff1a; 最佳观光组合 给你一个正整数数组 values&#xff0c;其中 values[i] 表示第 i 个观光景点的评分&#xff0c;并且两个景点 i 和 j 之间的 距离…