`

Another Google question - drop glassballs from a building 4

阅读更多
The test cases are divided into 3 classes.

The first one is just a pinpoint test class that contains some corner cases:

java 代码
 
  1. package glassball;  
  2.   
  3. import junit.framework.TestCase;  
  4. import java.util.List;  
  5.   
  6. /** 
  7.  * Testcases for path. 
  8.  */  
  9. public class PathFinderTest extends TestCase  
  10. {  
  11.     public void test1BallSingleCase()  
  12.     {  
  13.         int broken = 10;  
  14.         Building building = new Building(10, broken);  
  15.         PathFinder finder = new PathFinder(building, 1);  
  16.         List path = finder.findPuzzlePath();  
  17.         TestUtil.printPath(path);  
  18.         assertTrue(broken == TestUtil.getBrokenFloor(path));  
  19.         assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  20.     }  
  21.   
  22.     public void test2BallSingleCase1()  
  23.     {  
  24.         // 70 is the beginning of the 2nd level search  
  25.         int broken = 70;  
  26.         Building building = new Building(100, broken);  
  27.         PathFinder finder = new PathFinder(building, 2);  
  28.         List path = finder.findPuzzlePath();  
  29.         TestUtil.printPath(path);  
  30.         assertTrue(broken == TestUtil.getBrokenFloor(path));  
  31.         assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  32.     }  
  33.   
  34.     public void test2BallSingleCase2()  
  35.     {  
  36.         // 77 is the end of the 2nd level search.  
  37.         // 77 jumps out of the loop without going to return line.  
  38.         int broken = 77;  
  39.         Building building = new Building(100, broken);  
  40.         PathFinder finder = new PathFinder(building, 2);  
  41.         List path = finder.findPuzzlePath();  
  42.         TestUtil.printPath(path);  
  43.         assertTrue(broken == TestUtil.getBrokenFloor(path));  
  44.         assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  45.     }  
  46.   
  47.     public void test3BallSingleCase()  
  48.     {  
  49.         int broken = 53;  
  50.         Building building = new Building(100, broken);  
  51.         PathFinder finder = new PathFinder(building, 3);  
  52.         List path = finder.findPuzzlePath();  
  53.         TestUtil.printPath(path);  
  54.         assertTrue(broken == TestUtil.getBrokenFloor(path));  
  55.         assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  56.     }  
  57.   
  58.     public void test4BallSingleCase()  
  59.     {  
  60.         // 89 is a special number to test whether  
  61.         // totalFloors == baseFloor + totalFloors, it caused  
  62.         // 91 has been hit 3 times. Without this check, it kills 3 balls.  
  63.         int broken = 89;  
  64.         Building building = new Building(100, broken);  
  65.         PathFinder finder = new PathFinder(building, 4);  
  66.         List path = finder.findPuzzlePath();  
  67.         TestUtil.printPath(path);  
  68.         assertTrue(broken == TestUtil.getBrokenFloor(path));  
  69.         assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  70.     }  
  71.   
  72.     public void test4BallForLowerBound1()  
  73.     {  
  74.         int broken = 1;  
  75.         Building building = new Building(10, broken);  
  76.         PathFinder finder = new PathFinder(building, 4);  
  77.         List path = finder.findPuzzlePath();  
  78.         TestUtil.printPath(path);  
  79.         assertTrue(broken == TestUtil.getBrokenFloor(path));  
  80.         assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  81.     }  
  82.   
  83.     public void test4BallForLowerBound2()  
  84.     {  
  85.         int broken = 2;  
  86.         Building building = new Building(10, broken);  
  87.         PathFinder finder = new PathFinder(building, 4);  
  88.         List path = finder.findPuzzlePath();  
  89.         TestUtil.printPath(path);  
  90.         assertTrue(broken == TestUtil.getBrokenFloor(path));  
  91.         assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  92.     }  
  93.   
  94.     public void test4BallForLowerBound3()  
  95.     {  
  96.         int broken = 6;  
  97.         Building building = new Building(10, broken);  
  98.         PathFinder finder = new PathFinder(building, 4);  
  99.         List path = finder.findPuzzlePath();  
  100.         TestUtil.printPath(path);  
  101.         assertTrue(broken == TestUtil.getBrokenFloor(path));  
  102.         assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  103.     }  
  104.   
  105.     public void test2Ball4Floors()  
  106.     {  
  107.         int broken = 1;  
  108.         Building building = new Building(4, broken);  
  109.         PathFinder finder = new PathFinder(building, 2);  
  110.         List path = finder.findPuzzlePath();  
  111.         TestUtil.printPath(path);  
  112.         assertTrue(broken == TestUtil.getBrokenFloor(path));  
  113.         assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  114.     }  
  115.   
  116.     public void test3Ball17Floors()  
  117.     {  
  118.         int broken = 13;  
  119.         Building building = new Building(17, broken);  
  120.         PathFinder finder = new PathFinder(building, 3);  
  121.         List path = finder.findPuzzlePath();  
  122.         TestUtil.printPath(path);  
  123.         assertTrue(broken == TestUtil.getBrokenFloor(path));  
  124.         assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  125.     }  
  126.   
  127.     public void test4Ball100Floors()  
  128.     {  
  129.         int broken = 70;  
  130.         Building building = new Building(100, broken);  
  131.         PathFinder finder = new PathFinder(building, 4);  
  132.         List path = finder.findPuzzlePath();  
  133.         TestUtil.printPath(path);  
  134.         assertTrue(broken == TestUtil.getBrokenFloor(path));  
  135.         assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  136.     }  
  137.   
  138.     public void test5Ball100Floors()  
  139.     {  
  140.         int broken = 70;  
  141.         Building building = new Building(100, broken);  
  142.         PathFinder finder = new PathFinder(building, 5);  
  143.         List path = finder.findPuzzlePath();  
  144.         TestUtil.printPath(path);  
  145.         assertTrue(broken == TestUtil.getBrokenFloor(path));  
  146.         assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  147.     }  
  148.   
  149.     public void test6Ball100Floors()  
  150.     {  
  151.         int broken = 70;  
  152.         Building building = new Building(100, broken);  
  153.         PathFinder finder = new PathFinder(building, 6);  
  154.         List path = finder.findPuzzlePath();  
  155.         TestUtil.printPath(path);  
  156.         assertTrue(broken == TestUtil.getBrokenFloor(path));  
  157.         assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  158.     }  
  159.   
  160.     public void test3Ball9Floors()  
  161.     {  
  162.         int broken = 9;  
  163.         Building building = new Building(100, broken);  
  164.         PathFinder finder = new PathFinder(building, 3);  
  165.         List path = finder.findPuzzlePath();  
  166.         TestUtil.printPath(path);  
  167.         assertTrue(broken == TestUtil.getBrokenFloor(path));  
  168.         assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  169.     }  
  170. }  

The util class is like this:

java 代码
 
  1. package glassball;  
  2.   
  3. import java.util.List;  
  4.   
  5. /** 
  6.  * 
  7.  */  
  8. public class TestUtil  
  9. {  
  10.     public static void printPath(List path)  
  11.     {  
  12.         System.out.print("path=");  
  13.         for (int i=0; i<path.size(); i++)  
  14.         {  
  15.             System.out.print(path.get(i).toString() + "-->");  
  16.         }  
  17.         System.out.println("END");  
  18.         System.out.println("number of trials=" + path.size());  
  19.     }  
  20.   
  21.     public static int getPathSize(List path)  
  22.     {  
  23.         int size = 0;  
  24.         for (int i=0; i<path.size(); i++)  
  25.         {  
  26.             Trial trial = (Trial)path.get(i);  
  27.             if (!trial.isDeducted()) size++;  
  28.         }  
  29.   
  30.         return size;  
  31.     }  
  32.       
  33.     public static int getBrokenFloor(List path)  
  34.     {  
  35.         // several cases:  
  36.         // 1. the last one is broken,  
  37.         // 2. the last broken is before several wholes.  
  38.         // 3. all are broken, the one we are looking for is not in the list because:  
  39.         //     it's the last one.  
  40.         for (int i=path.size()-1; i>=0; i--)  
  41.         {  
  42.             Trial trial = (Trial)path.get(i);  
  43.             // The last broken piece is the one we are looking for.  
  44.             if (trial.isBroken()) return trial.getFloor();  
  45.         }  
  46.         return -1;  
  47.     }  
  48.   
  49.     public static boolean compareTwoIntegerArrays(List path1, List path2)  
  50.     {  
  51.         if (path1.size() != path2.size()) return false;  
  52.   
  53.         for (int i=0; i<path1.size(); i++)  
  54.         {  
  55.             if (path1.get(i).equals(path2.get(i))) return false;  
  56.         }  
  57.   
  58.         return true;  
  59.     }  
  60. }  


The second one is to vary the broken level to see whether it's good enough:

java 代码
 
  1. package glassball;  
  2.   
  3. import junit.framework.TestCase;  
  4.   
  5. import java.util.List;  
  6.   
  7. /** 
  8.  * This is to test the minimal trial numbers. 
  9.  */  
  10. public class PathFinderMinimalFullTest extends TestCase  
  11. {  
  12.     public void test3Ball100Floors()  
  13.     {  
  14.         int numOfTrials = 0;  
  15.   
  16.         for (int broken=1; broken < 100; broken++)  
  17.         {  
  18.             Building building = new Building(100, broken);  
  19.             PathFinder finder = new PathFinder(building, 3);  
  20.             List path = finder.findPuzzlePath();  
  21.   
  22.             if (TestUtil.getPathSize(path) > numOfTrials)  
  23.                 numOfTrials = TestUtil.getPathSize(path);  
  24.   
  25.             TestUtil.printPath(path);  
  26.             assertTrue(broken == TestUtil.getBrokenFloor(path));  
  27.             assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  28.         }  
  29.   
  30.         System.out.println("numOfTrials=" + numOfTrials);  
  31.     }  
  32.   
  33.     public void test4Ball100Floors()  
  34.     {  
  35.         int numOfTrials = 0;  
  36.   
  37.         for (int broken=1; broken < 100; broken++)  
  38.         {  
  39.             Building building = new Building(100, broken);  
  40.             PathFinder finder = new PathFinder(building, 4);  
  41.             List path = finder.findPuzzlePath();  
  42.   
  43.             if (TestUtil.getPathSize(path) > numOfTrials)  
  44.                 numOfTrials = TestUtil.getPathSize(path);  
  45.   
  46.             TestUtil.printPath(path);  
  47.             assertTrue(broken == TestUtil.getBrokenFloor(path));  
  48.             assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  49.         }  
  50.   
  51.         System.out.println("numOfTrials=" + numOfTrials);  
  52.     }  
  53.   
  54.     public void test5Ball100Floors()  
  55.     {  
  56.         int numOfTrials = 0;  
  57.   
  58.         for (int broken=1; broken < 100; broken++)  
  59.         {  
  60.             Building building = new Building(100, broken);  
  61.             PathFinder finder = new PathFinder(building, 5);  
  62.             List path = finder.findPuzzlePath();  
  63.   
  64.             if (TestUtil.getPathSize(path) > numOfTrials)  
  65.                 numOfTrials = TestUtil.getPathSize(path);  
  66.   
  67.             TestUtil.printPath(path);  
  68.             assertTrue(broken == TestUtil.getBrokenFloor(path));  
  69.             assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  70.         }  
  71.   
  72.         System.out.println("numOfTrials=" + numOfTrials);  
  73.     }  
  74.   
  75.     public void test5Ball1000Floors()  
  76.     {  
  77.         int numOfTrials = 0;  
  78.   
  79.         for (int broken=1; broken < 200; broken++)  
  80.         {  
  81.             Building building = new Building(200, broken);  
  82.             PathFinder finder = new PathFinder(building, 5);  
  83.             List path = finder.findPuzzlePath();  
  84.   
  85.             if (TestUtil.getPathSize(path) > numOfTrials)  
  86.                 numOfTrials = TestUtil.getPathSize(path);  
  87.   
  88.             TestUtil.printPath(path);  
  89.             assertTrue(broken == TestUtil.getBrokenFloor(path));  
  90.             assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  91.         }  
  92.   
  93.         System.out.println("numOfTrials=" + numOfTrials);  
  94.     }  
  95.   
  96.     public void test6Ball1000Floors()  
  97.     {  
  98.         int numOfTrials = 0;  
  99.   
  100.         for (int broken=1; broken < 200; broken++)  
  101.         {  
  102.             Building building = new Building(200, broken);  
  103.             PathFinder finder = new PathFinder(building, 6);  
  104.             List path = finder.findPuzzlePath();  
  105.   
  106.             if (TestUtil.getPathSize(path) > numOfTrials)  
  107.                 numOfTrials = TestUtil.getPathSize(path);  
  108.   
  109.             TestUtil.printPath(path);  
  110.             assertTrue(broken == TestUtil.getBrokenFloor(path));  
  111.             assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  112.         }  
  113.   
  114.         System.out.println("numOfTrials=" + numOfTrials);  
  115.     }  
  116.   
  117.     public void test10Ball1000Floors()  
  118.     {  
  119.         int numOfTrials = 0;  
  120.   
  121.         for (int broken=1; broken < 200; broken++)  
  122.         {  
  123.             Building building = new Building(200, broken);  
  124.             PathFinder finder = new PathFinder(building, 50);  
  125.             List path = finder.findPuzzlePath();  
  126.   
  127.             if (TestUtil.getPathSize(path) > numOfTrials)  
  128.                 numOfTrials = TestUtil.getPathSize(path);  
  129.   
  130.             TestUtil.printPath(path);  
  131.             assertTrue(broken == TestUtil.getBrokenFloor(path));  
  132.             assertTrue(TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  133.         }  
  134.   
  135.         System.out.println("numOfTrials=" + numOfTrials);  
  136.     }  
  137. }  

The third one is a brutal force testing to test all cases in a certain range:

java 代码
 
  1. package glassball;  
  2.   
  3. import junit.framework.TestCase;  
  4.   
  5. import java.util.List;  
  6.   
  7. /** 
  8.  * The brutal force loops. 
  9.  */  
  10. public class PathFinderFullTest extends TestCase  
  11. {  
  12.     public void test1BallSingleCase()  
  13.     {  
  14.         for (int floors=3; floors<=300; floors++)  
  15.         {  
  16.             for (int broken=1; broken<floors; broken++)  
  17.             {  
  18.                 for (int balls=1; balls<6; balls++)  
  19.                 {  
  20.                     Building building = new Building(floors, broken);  
  21.                     PathFinder finder = new PathFinder(building, balls);  
  22.                     List path = finder.findPuzzlePath();  
  23.   
  24.                     //TestUtil.printPath(path);  
  25.                     String errorMsg = "floors=" + floors + " broken=" + broken + " balls=" + balls;  
  26.                     errorMsg += " path size=" + TestUtil.getPathSize(path) + " minimal trials=" +  
  27.                                 finder.getPuzzle().getMinimalTrials();  
  28.                     errorMsg += " result floor=" + TestUtil.getBrokenFloor(path);  
  29.                     assertTrue(errorMsg, TestUtil.getPathSize(path) <= finder.getPuzzle().getMinimalTrials());  
  30.                     assertTrue(errorMsg, broken == TestUtil.getBrokenFloor(path));  
  31.                 }  
  32.             }  
  33.         }  
  34.     }  
  35. }  

Now we should have enough confidence.
分享到:
评论

相关推荐

    计算机网络第六版答案

    An Internet Exchange Points (IXP) (typically in a standalone building with its own switches) is a meeting point where multiple ISPs can connect and/or peer together. An ISP earns its money by ...

    ICS delphixe10源码版

    4. You must register this software by sending a picture postcard to the author. Use a nice stamp and mention your name, street address, EMail address and any comment you like to say. 5. As this ...

    微软内部资料-SQL性能优化5

    An index consists of a tree with a root from which the navigation begins, possible intermediate index levels, and bottom-level leaf pages. You use the index to find the correct leaf page. The number ...

    级联H桥SVG无功补偿系统在不平衡电网中的三层控制策略:电压电流双闭环PI控制、相间与相内电压均衡管理,级联H桥SVG无功补偿系统在不平衡电网中的三层控制策略:电压电流双闭环PI控制、相间与相内电压均

    级联H桥SVG无功补偿系统在不平衡电网中的三层控制策略:电压电流双闭环PI控制、相间与相内电压均衡管理,级联H桥SVG无功补偿系统在不平衡电网中的三层控制策略:电压电流双闭环PI控制、相间与相内电压均衡管理,不平衡电网下的svg无功补偿,级联H桥svg无功补偿statcom,采用三层控制策略。 (1)第一层采用电压电流双闭环pi控制,电压电流正负序分离,电压外环通过产生基波正序有功电流三相所有H桥模块直流侧平均电压恒定,电流内环采用前馈解耦控制; (2)第二层相间电压均衡控制,注入零序电压,控制通过注入零序电压维持相间电压平衡; (3)第三层相内电压均衡控制,使其所有子模块吸收的有功功率与其损耗补,从而保证所有H桥子模块直流侧电压值等于给定值。 有参考资料。 639,核心关键词: 1. 不平衡电网下的SVG无功补偿 2. 级联H桥SVG无功补偿STATCOM 3. 三层控制策略 4. 电压电流双闭环PI控制 5. 电压电流正负序分离 6. 直流侧平均电压恒定 7. 前馈解耦控制 8. 相间电压均衡控制 9. 零序电压注入 10. 相内电压均衡控制 以上十个关键词用分号分隔的格式为:不

    GTX 1080 PCB图纸

    GTX 1080 PCB图纸,内含图纸查看软件

    深度优化与应用:提升DeepSeek润色指令的有效性和灵活性指南

    内容概要:本文档详细介绍了利用 DeepSeek 进行文本润色和问答交互时提高效果的方法和技巧,涵盖了从明确需求、提供适当上下文到尝试开放式问题以及多轮对话的十个要点。每一部分内容都提供了具体的示范案例,如指定回答格式、分步骤提问等具体实例,旨在指导用户更好地理解和运用 DeepSeek 提升工作效率和交流质量。同时文中还强调了根据不同应用场景调整提示词语气和风格的重要性和方法。 适用人群:适用于希望通过优化提问技巧以获得高质量反馈的企业员工、科研人员以及一般公众。 使用场景及目标:本文针对所有期望提高 DeepSeek 使用效率的人群,帮助他们在日常工作中快速获取精准的答案或信息,特别是在撰写报告、研究材料准备和技术咨询等方面。此外还鼓励用户通过不断尝试不同形式的问题表述来进行有效沟通。 其他说明:该文档不仅关注实际操作指引,同样重视用户思维模式转变——由简单索取答案向引导 AI 辅助创造性解决问题的方向发展。

    基于FPGA与W5500实现的TCP网络通信测试平台开发-Zynq扩展口Verilog编程实践,基于FPGA与W5500芯片的TCP网络通信测试及多路Socket实现基于zynq开发平台和Vivad

    基于FPGA与W5500实现的TCP网络通信测试平台开发——Zynq扩展口Verilog编程实践,基于FPGA与W5500芯片的TCP网络通信测试及多路Socket实现基于zynq开发平台和Vivado 2019软件的扩展开发,基于FPGA和W5500的TCP网络通信 测试平台 zynq扩展口开发 软件平台 vivado2019.2,纯Verilog可移植 测试环境 压力测试 cmd命令下ping电脑ip,同时采用上位机进行10ms发包回环测试,不丢包(内部数据回环,需要时间处理) 目前实现单socket功能,多路可支持 ,基于FPGA; W5500; TCP网络通信; Zynq扩展口开发; 纯Verilog可移植; 测试平台; 压力测试; 10ms发包回环测试; 单socket功能; 多路支持。,基于FPGA与W5500的Zynq扩展口TCP通信测试:可移植Verilog实现的高效网络通信

    Labview液压比例阀伺服阀试验台多功能程序:PLC通讯、液压动画模拟、手动控制与调试、传感器标定、报警及记录、自动实验、数据处理与查询存储,报表生成与打印一体化解决方案 ,Labview液压比例阀

    Labview液压比例阀伺服阀试验台多功能程序:PLC通讯、液压动画模拟、手动控制与调试、传感器标定、报警及记录、自动实验、数据处理与查询存储,报表生成与打印一体化解决方案。,Labview液压比例阀伺服阀试验台多功能程序:PLC通讯、液压动画模拟、手动控制与调试、传感器标定、报警管理及实验自动化,labview液压比例阀伺服阀试验台程序:功能包括,同PLC通讯程序,液压动画,手动控制及调试,传感器标定,报警设置及报警记录,自动实验,数据处理曲线处理,数据库存储及查询,报表自动生成及打印,扫码枪扫码及信号录入等~ ,核心关键词:PLC通讯; 液压动画; 手动控制及调试; 传感器标定; 报警设置及记录; 自动实验; 数据处理及曲线处理; 数据库存储及查询; 报表生成及打印; 扫码枪扫码。,Labview驱动的智能液压阀测试系统:多功能控制与数据处理

    华为、腾讯、万科员工职业发展体系建设与实践.pptx

    华为、腾讯、万科员工职业发展体系建设与实践.pptx

    基于遗传算法的柔性车间调度优化 附Matlab代码.rar

    1.版本:matlab2014/2019a/2024a 2.附赠案例数据可直接运行matlab程序。 3.代码特点:参数化编程、参数可方便更改、代码编程思路清晰、注释明细。 4.适用对象:计算机,电子信息工程、数学等专业的大学生课程设计、期末大作业和毕业设计。

    电网不对称故障下VSG峰值电流限制的柔性控制策略:实现电流平衡与功率容量的优化利用,电网不对称故障下VSG峰值电流限制的柔性控制策略:兼顾平衡电流与功率控制切换的动态管理,电网不对称故障下VSG峰值电

    电网不对称故障下VSG峰值电流限制的柔性控制策略:实现电流平衡与功率容量的优化利用,电网不对称故障下VSG峰值电流限制的柔性控制策略:兼顾平衡电流与功率控制切换的动态管理,电网不对称故障下VSG峰值电流限制的柔性不平衡控制(文章完全复现)。 提出一种在不平衡运行条件下具有峰值电流限制的可变不平衡电流控制方法,可灵活地满足不同操作需求,包括电流平衡、有功或无功恒定运行(即电流控制、有功控制或无功控制之间的相互切),注入电流保持在安全值内,以更好的利用VSG功率容量。 关键词:VSG、平衡电流控制、有功功率控制、无功功率控制。 ,VSG; 峰值电流限制; 柔性不平衡控制; 电流平衡控制; 有功功率控制; 无功功率控制。,VSG柔性控制:在电网不对称故障下的峰值电流限制与平衡管理

    libpinyin-tools-0.9.93-4.el7.x64-86.rpm.tar.gz

    1、文件内容:libpinyin-tools-0.9.93-4.el7.rpm以及相关依赖 2、文件形式:tar.gz压缩包 3、安装指令: #Step1、解压 tar -zxvf /mnt/data/output/libpinyin-tools-0.9.93-4.el7.tar.gz #Step2、进入解压后的目录,执行安装 sudo rpm -ivh *.rpm 4、更多资源/技术支持:公众号禅静编程坊

    机器学习(预测模型):动漫《龙珠》相关的数据集

    数据集是一个以经典动漫《龙珠》为主题的多维度数据集,广泛应用于数据分析、机器学习和图像识别等领域。该数据集由多个来源整合而成,涵盖了角色信息、战斗力、剧情片段、台词以及角色图像等多个方面。数据集的核心内容包括: 角色信息:包含《龙珠》系列中的主要角色及其属性,如名称、种族、所属系列(如《龙珠》《龙珠Z》《龙珠超》等)、战斗力等级等。 图像数据:提供角色的图像资源,可用于图像分类和角色识别任务。这些图像来自动画剧集、漫画和相关衍生作品。 剧情与台词:部分数据集还包含角色在不同故事中的台词和剧情片段,可用于文本分析和自然语言处理任务。 战斗数据:记录角色在不同剧情中的战斗力变化和战斗历史,为研究角色成长和剧情发展提供支持。 数据集特点 多样性:数据集整合了角色、图像、文本等多种类型的数据,适用于多种研究场景。 深度:不仅包含角色的基本信息,还涵盖了角色的成长历程、技能描述和与其他角色的互动关系。 实用性:支持多种编程语言(如Python、R)的数据处理和分析,提供了详细的文档和示例代码。

    基于protues仿真的多功公交站播报系统设计(仿真图、源代码)

    基于protues仿真的多功公交站播报系统设计(仿真图、源代码) 该设计为基于protues仿真的多功公交站播报系统,实现温度显示、时间显示、和系统公交站播报功能; 具体功能如下: 1、系统使用51单片机为核心设计; 2、时钟芯片进行时间和日期显示; 3、温度传感器进行温度读取; 4、LCD12864液晶屏进行相关显示; 5、按键设置调节时间; 6、按键设置报站; 7、仿真图、源代码; 操作说明: 1、下行控制报站:首先按下(下行设置按键),(下行指示灯)亮,然后按下(手动播报)按键控制播报下一站; 2、上行控制报站:首先按上(上行设置按键),(上行指示灯)亮,然后按下(手动播报)按键控制播报下一站; 3、按下关闭播报按键,则关闭播报功能和清除显示

    基于微信小程序的琴房管理系统的设计与实现.zip

    采用Java后台技术和MySQL数据库,在前台界面为提升用户体验,使用Jquery、Ajax、CSS等技术进行布局。 系统包括两类用户:学生、管理员。 学生用户 学生用户只要实现了前台信息的查看,打开首页,查看网站介绍、琴房信息、在线留言、轮播图信息公告等,通过点击首页的菜单跳转到对应的功能页面菜单,包括网站首页、琴房信息、注册登录、个人中心、后台登录。 学生用户通过账户账号登录,登录后具有所有的操作权限,如果没有登录,不能在线预约。学生用户退出系统将注销个人的登录信息。 管理员通过后台的登录页面,选择管理员权限后进行登录,管理员的权限包括轮播公告管理、老师学生信息管理和信息审核管理,管理员管理后点击退出,注销登录信息。 管理员用户具有在线交流的管理,琴房信息管理、琴房预约管理。 在线交流是对前台用户留言内容进行管理,删除留言信息,查看留言信息。

    界面GUI设计MATLAB教室人数统计.zip

    MATLAB可以用于开发人脸识别考勤系统。下面是一个简单的示例流程: 1. 数据采集:首先收集员工的人脸图像作为训练数据集。可以要求员工提供多张照片以获得更好的训练效果。 2. 图像预处理:使用MATLAB的图像处理工具对采集到的人脸图像进行预处理,例如灰度化、裁剪、缩放等操作。 3. 特征提取:利用MATLAB的人脸识别工具包,如Face Recognition Toolbox,对处理后的图像提取人脸特征,常用的方法包括主成分分析(PCA)和线性判别分析(LDA)等。 4. 训练模型:使用已提取的人脸特征数据集训练人脸识别模型,可以选择支持向量机(SVM)、卷积神经网络(CNN)等算法。 5. 考勤系统:在员工打卡时,将摄像头捕获的人脸图像输入到训练好的模型中进行识别,匹配员工信息并记录考勤数据。 6. 结果反馈:根据识别结果,可以自动生成考勤报表或者实时显示员工打卡情况。 以上只是一个简单的步骤,实际开发过程中需根据具体需求和系统规模进行定制和优化。MATLAB提供了丰富的图像处理和机器学习工具,是开发人脸识别考勤系统的一个很好选择。

    hjbvbnvhjhjg

    hjbvbnvhjhjg

    HCIP、软考相关学习PPT

    HCIP、软考相关学习PPT提供下载

    绿豆BOX UI8版:反编译版六个全新UI+最新后台直播管理源码

    绿豆BOX UI8版:反编译版六个全新UI+最新后台直播管理源码 最新绿豆BOX反编译版六个UI全新绿豆盒子UI8版本 最新后台支持直播管理 作为UI6的升级版,UI8不仅修复了前一版本中存在的一些BUG,还提供了6套不同的UI界面供用户选择,该版本有以下特色功能: 在线管理TVBOX解析 在线自定义TVBOX 首页布局批量添加会员信息 并支持导出批量生成卡密 并支持导出直播列表管理功能

    vue3的一些语法以及知识点

    vue3的一些语法以及知识点

Global site tag (gtag.js) - Google Analytics