SSM(Spring SpringMVC MyBatis)配置文件信息,完成学生管理页面(前后端全部代码)

效果图(elementUI)

项目结构

web.xml

<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_4_0.xsd"
         version="4.0">

    <servlet>
        <servlet-name>DispatcherServlet</servlet-name>
        <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
        <init-param>
            <param-name>contextConfigLocation</param-name>
            <param-value>classpath:springmvc.xml</param-value>
        </init-param>
        <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>DispatcherServlet</servlet-name>
        <url-pattern>/</url-pattern>
    </servlet-mapping>

    <filter>
        <filter-name>CharacterEncodingFilter</filter-name>
        <filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>
        <init-param>
            <param-name>encoding</param-name>
            <param-value>utf-8</param-value>
        </init-param>
    </filter>
    <filter-mapping>
        <filter-name>CharacterEncodingFilter</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>

    <context-param>
        <param-name>contextConfigLocation</param-name>
        <param-value>classpath:spring.xml</param-value>
    </context-param>
    <listener>
        <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
    </listener>
    <filter>
        <filter-name>httpPutFormContentFilter</filter-name>
        <filter-class>org.springframework.web.filter.HttpPutFormContentFilter</filter-class>
    </filter>
    <filter-mapping>
        <filter-name>httpPutFormContentFilter</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>
</web-app>

springMVC

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xmlns:context="http://www.springframework.org/schema/context"
       xmlns:mvc="http://www.springframework.org/schema/mvc"
       xsi:schemaLocation="http://www.springframework.org/schema/beans
       http://www.springframework.org/schema/beans/spring-beans.xsd
       http://www.springframework.org/schema/context
       http://www.springframework.org/schema/context/spring-context.xsd
       http://www.springframework.org/schema/mvc
       http://www.springframework.org/schema/mvc/spring-mvc-3.2.xsd">
    <!--扫描包-->
    <context:component-scan base-package="com.etime.controller"></context:component-scan>
    <mvc:annotation-driven></mvc:annotation-driven>
    <bean class="org.springframework.web.servlet.view.InternalResourceViewResolver">
        <property name="prefix" value="/"></property>
        <property name="suffix" value=".html"></property>
    </bean>
</beans>

spring

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xmlns:context="http://www.springframework.org/schema/context"
       xmlns:aop="http://www.springframework.org/schema/aop"
       xmlns:tx="http://www.springframework.org/schema/tx"
       xsi:schemaLocation="http://www.springframework.org/schema/beans
       http://www.springframework.org/schema/beans/spring-beans.xsd
       http://www.springframework.org/schema/context
       http://www.springframework.org/schema/context/spring-context.xsd
       http://www.springframework.org/schema/aop
       http://www.springframework.org/schema/aop/spring-aop.xsd
       http://www.springframework.org/schema/tx
       http://www.springframework.org/schema/tx/spring-tx.xsd">
    <!--扫描包-->
    <context:component-scan base-package="com.etime.service"></context:component-scan>
    <bean class="org.mybatis.spring.mapper.MapperScannerConfigurer">
        <property name="basePackage" value="com.etime.dao"></property>
    </bean>

    <!--数据源-->
    <context:property-placeholder location="classpath:db.properties"/>
    <bean id="pool" class="com.mchange.v2.c3p0.ComboPooledDataSource">
        <property name="driverClass" value="${jdbc.driver}"/>
        <property name="jdbcUrl" value="${jdbc.url}"/>
        <property name="user" value="${jdbc.username}"/>
        <property name="password" value="${jdbc.password}"/>
    </bean>
    <!--mybatis的核心工厂对象-->
    <bean id="sessionFactory" class="org.mybatis.spring.SqlSessionFactoryBean">
        <!--注入数据源-->
        <property name="dataSource" ref="pool"/>
        <!--配置别名-->
        <property name="typeAliasesPackage" value="com.etime.pojo"/>
        <!--dao文件配置-->
        <property name="mapperLocations" value="classpath:com/etime/dao/*.xml"/>
        <!--分页插件-->
        <property name="plugins">
            <array>
                <bean class="com.github.pagehelper.PageInterceptor"></bean>
            </array>
        </property>
        <property name="configLocation" value="classpath:mybatis.xml"></property>
    </bean>

    <!--事务-->
    <bean id="transactionManager" class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
        <property name="dataSource" ref="pool"/>
    </bean>
    <!--开启注解事务-->
    <tx:annotation-driven transaction-manager="transactionManager"/>
</beans>

myBatis

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE configuration
        PUBLIC "-//mybatis.org//DTD Config 3.0//EN"
        "http://mybatis.org/dtd/mybatis-3-config.dtd">
<configuration>
    <settings>
        <!-- 打印查询语句 -->
        <setting name="logImpl" value="STDOUT_LOGGING" />
    </settings>
</configuration>

studentDao.xml

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper
        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.etime.dao.StudentDao">
    <!--分页展示-->
    <select id="getAllStudent" parameterType="Student" resultMap="getAllStudentMap">
        SELECT * FROM student s,class c where s.class_id = c.cid
        <if test="sname != ''">
            and sname like concat('%',#{sname},'%')
        </if>
        <if test="gender != ''">
            and gender = #{gender}
        </if>
        <if test="class_id != 0">
            and class_id = #{class_id}
        </if>
    </select>
    <resultMap id="getAllStudentMap" type="Student">
        <id property="sid" column="sid"></id>
        <result property="gender" column="gender"></result>
        <result property="sname" column="sname"></result>
        <association property="clazz" javaType="Clazz">
            <id property="cid" column="cid"></id>
            <result property="caption" column="caption"></result>
        </association>
    </resultMap>
    <!--查询学生所有课程信息-->
    <select id="getAllCourseBySid" parameterType="int" resultMap="getAllCourseBySidMap">
        select *
        from score s,
             course c,
             teacher t
        where c.cid = s.course_id
          and c.teacher_id = t.tid
          and s.student_id = #{sid}
    </select>
    <resultMap id="getAllCourseBySidMap" type="Score">
        <id property="sid" column="sid"></id>
        <result property="student_id" column="student_id"></result>
        <result property="course_id" column="course_id"></result>
        <result property="num" column="num"></result>
        <collection property="courses" ofType="Course">
            <id property="cid" column="cid"></id>
            <result property="cname" column="cname"></result>
            <result property="teacher_id" column="teacher_id"></result>
            <association property="teacher" javaType="Teacher">
                <id property="tid" column="tid"></id>
                <result property="tname" column="tname"></result>
            </association>
        </collection>
    </resultMap>
    <!--批量删除-->
    <delete id="deleteStudents">
        delete from student where sid in
        <foreach collection="array" item="sid" separator="," open="(" close=")">
            #{sid}
        </foreach>
    </delete>
</mapper>

studentDao

@Repository
public interface StudentDao {
    List<Student> getAllStudent(Student student);

    @Select("select * from class")
    List<Clazz> getAllClass();

    List<Score> getAllCourseBySid(int sid);

    int deleteStudents(int[] sids);

    @Insert("insert into student(gender,class_id,sname) values(#{gender},#{class_id},#{sname})")
    int addStudent(Student student);

    @Update("update student set sname = #{sname},class_id=#{class_id},gender=#{gender} where sid = #{sid}")
    int editStudent(Student student);
}

studentService

@Service
public class StudentServiceImpl implements StudentService {

    @Autowired
    private StudentDao studentDao;

    @Override
    public PageInfo<Student> getAllStudent(int page,int rows,Student student) {
        PageHelper.startPage(page,rows);
        List<Student> list = studentDao.getAllStudent(student);
        PageInfo<Student> info = new PageInfo<>(list);
        System.out.println(info);
        return info;
    }

    @Override
    public List<Score> getAllCourseBySid(int sid) {
        return studentDao.getAllCourseBySid(sid);
    }

    @Override
    public List<Clazz> getAllClass() {
        return studentDao.getAllClass();
    }

    @Override
    public boolean deleteStudents(int[] sids) {
        return studentDao.deleteStudents(sids)==0?false:true;
    }

    @Override
    public boolean addStudent(Student student) {
        return studentDao.addStudent(student) == 0?false:true;
    }

    @Override
    public boolean editStudent(Student student) {
        return studentDao.editStudent(student)==0?false:true;
    }

}

controller


@Controller
@RequestMapping("student")
@ResponseBody
@CrossOrigin
public class StudentController {

    @Autowired
    private StudentService studentService;

    /*分页展示加搜索*/
    @GetMapping("getAllStudent")
    public PageInfo<Student> getAllStudent(int page, int rows, String sname, String gender, String cid) {
        int cids;
        if (cid == null || cid == "") {
            cids = 0;
        } else {
            cids = Integer.parseInt(cid);
        }
        System.out.println(sname + "," + gender);
        return studentService.getAllStudent(page, rows, new Student(gender, cids, sname));
    }

    /*查所有班级*/
    @GetMapping("getAllClass")
    public List<Clazz> getAllClass(){
        return studentService.getAllClass();
    }

    /*查询学生所有课程信息*/
    @GetMapping("getAllCourseBySid/{sid}")
    public List<Score> getAllCourseBySid(@PathVariable("sid")int sid) {
        return studentService.getAllCourseBySid(sid);
    }

    /*删除*/
    @DeleteMapping("deleteStudents")
    public boolean deleteStudents(@RequestBody int[] sids){
        return studentService.deleteStudents(sids);
    }

    /*添加*/
    @PostMapping("addStudent")
    public boolean addStudent(@RequestBody Student student){
        return studentService.addStudent(student);
    }

    /*修改*/
    @PutMapping("editStudent")
    public boolean editStudent(@RequestBody Student student){
        return studentService.editStudent(student);
    }

index.html

<head>
    <title></title>
    <meta charset="UTF-8">
    <link rel="stylesheet" href="element-ui-2.13.0/lib/theme-chalk/index.css" />
    <script type="text/javascript" src="vue/vue-v2.6.10.js"></script>
    <script type="text/javascript" src="element-ui-2.13.0/lib/index.js"></script>
    <script type="text/javascript" src="vue/axios-0.18.0.js"></script>
</head>

<body>
    <div id="app">
        <template>
            <el-table :data="tableData" @selection-change="handleSelectionChange" size="medium"
                highlight-current-row="true" style="width: 100%">
                <el-table-column type="selection" width="55" prop="sid">
                </el-table-column>
                <el-table-column width="100px" label="序号" type="index">
                </el-table-column>
                <el-table-column label="姓名" prop="sname">
                </el-table-column>
                <el-table-column label="性别" prop="gender">
                </el-table-column>
                <el-table-column label="班级" prop="clazz.caption">
                </el-table-column>
                <el-table-column>
                    <template slot="header" slot-scope="scope">
                        <el-input v-model="search" placeholder="请输入姓名" />
                    </template>
                </el-table-column>
                <el-table-column>
                    <template slot="header" slot-scope="scope">
                        <el-select v-model="cid" placeholder="请选择班级">
                            <el-option v-for="item in classes" :key="item.cid" :label="item.caption" :value="item.cid">
                            </el-option>
                        </el-select>
                    </template>
                </el-table-column>
                <el-table-column>
                    <template slot="header" slot-scope="scope">
                        <el-radio v-model="sex" label="男">男</el-radio>
                        <el-radio v-model="sex" label="女">女</el-radio>
                    </template>
                    <template slot-scope="scope">
                        <el-button size="mini" @click="handleLook(scope.$index, scope.row)">查看课程信息</el-button>
                    </template>
                </el-table-column>
                <el-table-column>
                    <template slot="header" slot-scope="scope">
                        <el-button type="success" @click="findAll()">搜索</el-button>
                    </template>
                    <template slot-scope="scope">
                        <el-button size="mini" @click="handleEdit(scope.$index, scope.row)">修改</el-button>
                    </template>
                </el-table-column>
            </el-table>
        </template>
        <br />
        <el-row>
            <el-button type="warning" @click="delAll()">删除选中</el-button>
            <el-button type="primary" @click="add()">添加用户</el-button>
        </el-row>
        <template>
            <div class="block" align="right">
                <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange"
                    :current-page="currentPage" :page-sizes="[3, 4, 5, 6, 7, 8]" :page-size="pageSize"
                    layout="total, sizes, prev, pager, next, jumper" :total="totalCount">
                </el-pagination>
            </div>
        </template>

        <!-- 查看课程信息 -->
        <el-dialog title="查看课程信息" :visible.sync="dialogFormVisible">
            <el-form ref="ruleForm" :model="ruleForm" label-width="80px">
                <el-form-item label="学生姓名">
                    <el-input v-model="ruleForm.sname" style="width: 210px;" readonly></el-input>
                </el-form-item>
            </el-form>
            <el-table :data="tableCourse" @selection-change="handleSelectionChange" size="medium"
                highlight-current-row="true" style="width: 100%">
                <el-table-column width="100px" label="序号" type="index">
                </el-table-column>
                <el-table-column label="课程" prop="courses[0].cname">
                </el-table-column>
                <el-table-column label="成绩" prop="num">
                </el-table-column>
                <el-table-column label="老师" prop="courses[0].teacher.tname">
                </el-table-column>
            </el-table>
        </el-dialog>
        <!--添加学生-->
        <el-dialog title="添加学生信息" :visible.sync="diaAdd">
            <el-form :model="ruleForm" ref="ruleForm" label-width="100px">
                <el-form-item label="姓名" prop="sname">
                    <el-input v-model="ruleForm.sname" style="width: 210px;"></el-input>
                </el-form-item>
                <el-form-item label="性別" prop="gender">
                    <el-radio-group v-model="ruleForm.gender">
                        <el-radio label="男">男</el-radio>
                        <el-radio label="女">女</el-radio>
                    </el-radio-group>
                </el-form-item>
                <el-form-item label="班级" prop="class_id">
                    <el-select v-model="ruleForm.class_id" placeholder="请选择班级">
                        <el-option v-for="item in classes" :key="item.cid" :label="item.caption" :value="item.cid">
                        </el-option>
                    </el-select>
                </el-form-item>
                <el-form-item>
                    <el-button type="primary" @click="submitForm()">立即添加</el-button>
                </el-form-item>
            </el-form>
        </el-dialog>
        <!--修改-->
        <el-dialog title="修改学生信息" :visible.sync="dialogVisible">
            <el-form :model="ruleForm" ref="ruleForm" label-width="100px">
                <el-form-item label="姓名" prop="sname">
                    <el-input v-model="ruleForm.sname" style="width: 210px;"></el-input>
                </el-form-item>
                <el-form-item label="性別" prop="gender">
                    <el-radio-group v-model="ruleForm.gender">
                        <el-radio label="男">男</el-radio>
                        <el-radio label="女">女</el-radio>
                    </el-radio-group>
                </el-form-item>
                <el-form-item label="班级" prop="class_id">
                    <el-select v-model="ruleForm.clazz.cid" placeholder="请选择班级">
                        <el-option v-for="item in classes" :key="item.cid" :label="item.caption" :value="item.cid">
                        </el-option>
                    </el-select>
                </el-form-item>
                <el-form-item>
                    <el-button type="primary" @click="submitFormEd()">立即修改</el-button>
                </el-form-item>
            </el-form>
        </el-dialog>
    </div>
</body>
<script>
    axios.defaults.withCredentials = false
    new Vue({
        el: "#app",
        data: {
            /*表格数据*/
            tableData: [],
            tableCourse: [],
            /*条件查询关键字*/
            search: '',
            sex: "",
            //批量删除存放选中的复选框
            multipleSelection: [],
            //存放删除的数据
            delarr: [],
            //当前页
            currentPage: 1,
            //每页显示条数
            pageSize: 5,
            //总条数
            totalCount: '',
            //总页数
            totalPage: '',
            // 是否展示课程信息对话框
            dialogFormVisible: false,
            diaAdd: false,
            dialogVisible: false,
            ruleForm: {
                sid: '',
                sname: '',
                gender: '',
                clazz: '',
                class_id: '',
                cid: '',
            },
            classes: '',
            cid: '',
        },
        methods: {

            findAll() {
                axios({
                    method: "get",
                    url: "http://localhost:8080/day11_war_exploded/student/getAllStudent",
                    params: {
                        page: this.currentPage,
                        rows: this.pageSize,
                        sname: this.search,
                        gender: this.sex,
                        cid: this.cid
                    }
                }).then(obj => {
                    console.log(obj)
                    this.tableData = obj.data.list;
                    this.totalCount = obj.data.total;
                });
            },

            getAllClass() {
                axios({
                    method: "get",
                    url: "http://localhost:8080/day11_war_exploded/student/getAllClass",
                }).then(obj => {
                    this.classes = obj.data
                });
            },

            handleSizeChange: function (size) {
                this.pageSize = size;
                this.findAll();
            },

            handleCurrentChange: function (currentPage) {
                this.currentPage = currentPage;
                this.findAll();
            },

            // 详情
            handleLook(index, row) {
                this.dialogFormVisible = true
                this.ruleForm = row
                axios({
                    method: "get",
                    url: "http://localhost:8080/day11_war_exploded/student/getAllCourseBySid/" + row.sid,
                }).then(obj => {
                    this.tableCourse = obj.data
                });
            },

            delAll() {
                //获取删除的ID
                this.delarr = [];
                for (let i = 0; i < this.multipleSelection.length; i++) {
                    this.delarr.push(this.multipleSelection[i].sid);
                }
                //判断要删除的文件是否为空
                if (this.delarr.length == 0) {
                    this.$message.warning("请选择要删除的数据!")
                } else {
                    this.$confirm("是否确认删除?", "提示", { type: 'warning' }).then(() => {
                        //点击确认删除
                        axios({
                            method: "delete",
                            url: "http://localhost:8080/day11_war_exploded/student/deleteStudents",
                            data: this.delarr
                        }).then(obj => {
                            if (obj.data) {
                                this.$message.success("删除成功");
                            } else {
                                this.$message.console.error("删除失败");
                            }
                            this.findAll();
                        });
                    });
                }
            },

            handleSelectionChange(val) {
                this.multipleSelection = val;
            },
            // 添加
            add() {
                this.diaAdd = true;
            },

            submitForm() {
                axios({
                    method: "post",
                    url: "http://localhost:8080/day11_war_exploded/student/addStudent",
                    data: {
                        sname: this.ruleForm.sname,
                        gender: this.ruleForm.gender,
                        class_id: this.ruleForm.class_id
                    }
                }).then(obj => {
                    if (obj.data) {
                        this.$message.success("添加成功");
                    } else {
                        this.$message.error("添加失败");
                    }
                    this.findAll();
                });
            },
            // 修改
            handleEdit(index, row) {
                this.dialogVisible = true;
                this.ruleForm = row;

            },
            submitFormEd() {
                axios({
                    method: "put",
                    url: "http://localhost:8080/day11_war_exploded/student/editStudent",
                    data: {
                        sname: this.ruleForm.sname,
                        gender: this.ruleForm.gender,
                        class_id: this.ruleForm.clazz.cid,
                        sid:this.ruleForm.sid
                    }
                }).then(obj => {
                    if (obj.data) {
                        this.$message.success("修改成功");
                    } else {
                        this.$message.error("修改失败");
                    }
                    this.findAll();
                });
            },
        },

        created() {
            this.findAll();
            this.getAllClass();
        }

    })
</script>

</html>

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

如若内容造成侵权/违法违规/事实不符,请联系我们进行投诉反馈qq邮箱809451989@qq.com,一经查实,立即删除!

相关文章

Python深度学习实战-基于tensorflow.keras六步法搭建神经网络(附源码和实现效果)

实现功能 第一步&#xff1a;import tensorflow as tf&#xff1a;导入模块 第二步&#xff1a;制定输入网络的训练集和测试集 第三步&#xff1a;tf.keras.models.Sequential()&#xff1a;搭建网络结构 第四步&#xff1a;model.compile()&#xff1a;配置训练方法 第五…

datahub 中血缘图的实现分析,在react中使用airbnb的visx可视化库来画有向无环图

背景 做大数据的项目&#xff0c;必不可少的是要接触到数据血缘图&#xff0c;它在大数据项目中有着很重要的作用。 之前在公司也做过一些案例&#xff0c;也看过很多友商的产品&#xff0c;阿里的DataWork&#xff0c;领英的Datahub&#xff0c; datawork的血缘图使用的是 G6…

常用Web安全扫描工具汇整

漏洞扫描是一种安全检测行为&#xff0c;更是一类重要的网络安全技术&#xff0c;它能够有效提高网络的安全性&#xff0c;而且漏洞扫描属于主动的防范措施&#xff0c;可以很好地避免黑客攻击行为&#xff0c;做到防患于未然。 1、AWVS Acunetix Web Vulnerability Scanner&a…

066:mapboxGL的marker的drag,dragstart,dragend三种触发事件示例

第066个 点击查看专栏目录 本示例是演示如何在vue+mapbox中处理marker的三种触发事件drag,dragstart,dragend。 marker通过on(‘XXX’, callback),的方式进行触发处理。 直接复制下面的 vue+mapbox源代码,操作2分钟即可运行实现效果 文章目录 示例效果配置方式示例源代码(…

树与二叉树(考研版)

文章目录 树与二叉树树的基本概念结点、树属性的描述树的性质 二叉树的概念二叉树的性质二叉树的构建二叉树的遍历先序遍历中序遍历后序遍历层次遍历 递归算法和非递归算法的转换源代码 线索二叉树二叉树的线索化线索二叉树 找前驱/后继 树和森林树的存储 树与二叉树的应用哈夫…

如何处理前端本地存储和缓存?

聚沙成塔每天进步一点点 ⭐ 专栏简介 前端入门之旅&#xff1a;探索Web开发的奇妙世界 欢迎来到前端入门之旅&#xff01;感兴趣的可以订阅本专栏哦&#xff01;这个专栏是为那些对Web开发感兴趣、刚刚踏入前端领域的朋友们量身打造的。无论你是完全的新手还是有一些基础的开发…

【MATLAB源码-第57期】基于matlab的IS95前向链路仿真,输出误码率曲线。

操作环境&#xff1a; MATLAB 2022a 1、算法描述 IS-95&#xff0c;也被称为cdmaOne&#xff0c;是第一代的CDMA&#xff08;Code Division Multiple Access&#xff0c;码分多址&#xff09;数字蜂窝通信标准。IS-95的全称是Interim Standard-95&#xff0c;最初由Qualcomm…

.obj模型文件(带材质和纹理)合并的基本思路

1、将v开头的顶点信息依次拷贝到合并新.obj中 2、将vt纹理坐标依次拷贝到合并新.obj中 3、f&#xff08;面&#xff09;的合并 步骤&#xff1a; &#xff08;1&#xff09;第一个obj文件的f&#xff08;面&#xff09;原封不动拷进新.obj中 &#xff08;2&#xff09;第二个…

Hadoop3.0大数据处理学习4(案例:数据清洗、数据指标统计、任务脚本封装、Sqoop导出Mysql)

案例需求分析 直播公司每日都会产生海量的直播数据&#xff0c;为了更好地服务主播与用户&#xff0c;提高直播质量与用户粘性&#xff0c;往往会对大量的数据进行分析与统计&#xff0c;从中挖掘商业价值&#xff0c;我们将通过一个实战案例&#xff0c;来使用Hadoop技术来实…

【机器学习合集】激活函数合集 ->(个人学习记录笔记)

文章目录 综述1. S激活函数(sigmoid&Tanh)2. ReLU激活函数3. ReLU激活函数的改进4. 近似ReLU激活函数5. Maxout激活函数6. 自动搜索的激活函数Swish 综述 这些都是神经网络中常用的激活函数&#xff0c;它们在非线性变换方面有不同的特点。以下是这些激活函数的主要区别&am…

Node编写获取用户信息接口

目录 前言 初始化路由模块 使用postman发送get获取用户信息请求 初始化路由处理函数模块 获取用户基本信息 前言 在前两篇文章中已经介绍了如何编写用户注册接口以及用户登录接口&#xff0c;这篇文章介绍如何获取用户信息&#xff0c;本篇文章建立在Node编写用户登录接口…

06 MIT线性代数-列空间和零空间 Column space Nullspace

1. Vector space Vector space requirements vw and c v are in the space, all combs c v d w are in the space 但是“子空间”和“子集”的概念有区别&#xff0c;所有元素都在原空间之内就可称之为子集&#xff0c;但是要满足对线性运算封闭的子集才能成为子空间 中 2 …

质数(素数)prime :只能被 1 和 它本身整除的自然数,不可再分,(三种方式求出质数)

从 2 开始&#xff0c;到这个数 减 1 结束为止&#xff0c; 都不能被这个数本身整除。例如&#xff1a;5 是否是质数 &#xff1f; 那么 2&#xff0c;3&#xff0c;4&#xff0c;都不能被 5 整除 所以 5 是 质数判断 n 是否是质数&#xff1f; 2&#xff0c;3&#xff0c;4&…

海外公司注册推广的9个实用技巧建议-华媒舍

在全球化的时代背景下&#xff0c;海外市场的开发对于企业来说是非常重要的战略决策。海外公司注册是进入海外市场的第一步&#xff0c;通过注册在海外的公司&#xff0c;企业可以获得更多的商业机会和巨大的价值。本篇文章将为您介绍海外公司注册推广的9个实用建议&#xff0c…

Elasticsearch:使用 Open AI 和 Langchain 的 RAG - Retrieval Augmented Generation (三)

这是继之前文章&#xff1a; Elasticsearch&#xff1a;使用 Open AI 和 Langchain 的 RAG - Retrieval Augmented Generation &#xff08;一&#xff09; Elasticsearch&#xff1a;使用 Open AI 和 Langchain 的 RAG - Retrieval Augmented Generation &#xff08;二&…

数字人解决方案——解决ER-NeRF/RAD-NeRF人像分割的问题

一、训练数据人像分割 训练ER-NeRF或者RAD-NeRF时&#xff0c;在数据处理时&#xff0c;其中有一步是要把人像分割出来&#xff0c;而且人像要分成三块&#xff0c;人的头部&#xff0c;人的有脖子&#xff0c;人的身体部分&#xff0c;效果如下&#xff1a; 从上面的分割的结…

通天之网:卫星互联网与跨境电商的数字化未来

在当今数字化时代&#xff0c;互联网已经成为商业的核心。跨境电商&#xff0c;作为在线商业的一部分&#xff0c;一直在寻求新的途径来拓宽其边界。近年来&#xff0c;卫星互联网技术的发展已经成为这一领域的重要驱动力&#xff0c;不仅将互联网带到了全球各个角落&#xff0…

zookeeper源码(02)源码编译启动及idea导入

本文介绍一下zookeeper-3.9.0源码下载、编译及本地启动。 下载源码 git clone https://gitee.com/apache/zookeeper.gitcd zookeeper git checkout release-3.9.0 git checkout -b release-3.9.0源码编译 README_packaging.md文件 该文件介绍了编译zookeeper需要的环境和命…

什么是React Router?它的作用是什么?

聚沙成塔每天进步一点点 ⭐ 专栏简介 前端入门之旅&#xff1a;探索Web开发的奇妙世界 欢迎来到前端入门之旅&#xff01;感兴趣的可以订阅本专栏哦&#xff01;这个专栏是为那些对Web开发感兴趣、刚刚踏入前端领域的朋友们量身打造的。无论你是完全的新手还是有一些基础的开发…

elasticsearch-5.6.15集群部署,如何部署x-pack并添加安全认证

目录 一、环境 1、JDK、映射、域名、三墙 2、三台服务器创建用户、并为用户授权 二、配置elasticsearch-5.6.15实例 1、官网获取elasticsearch-5.6.15.tar.gz&#xff0c;拉取到三台服务器 2、elas环境准备 3、修改elasticsearch.yml配置 4、修改软、硬件线程数 5、修改…