旅游集市数仓建设

news2024/9/24 3:29:19

旅游集市数仓建设

小白如何从0到1成为大数据工程师

目录

旅游集市数仓建设

1.上传数据

2.可能用到的UDF函数

3.创建所需数据库及表

1)ODS层

①ods_oidd

②ods_wcdr

③ods_ddr

④ods_dpi

2)DWD层

①dwd_res_regn_mergelocation_msk_d

②dwm_staypoint_msk_d

③dws_province_tourist_msk_d

④dws_city_tourist_msk_d

⑤dws_county_tourist_msk_d

3)DIM层

①dim_usertag_msk_m

4)ADS层

1)需求矩阵

2)根据区县游客表计算如下指标


1.上传数据

cd /usr/local/soft/

mkdir ctyun/

cd ctyun/

pwd

2.可能用到的UDF函数

cd /usr/local/soft/

mkdir jars/

cd jars/

pwd

添加资源并注册函数

add jars /usr/local/soft/jars/jtxy_hdfs-1.0-SNAPSHOT.jar;


create temporary function get_points as 'ctyun.udf.getPointsUDF';


create temporary function dateBetweenUDF as 'ctyun.udf.dateBetweenUDF';


create temporary function calLength as 'ctyun.udf.calLength';


create temporary function get_city_or_prov_id as 'ctyun.udf.getCityIdOrProvID';

3.创建所需数据库及表

create database ods;

use ods;

1)ODS层
①ods_oidd

OIDD是采集A接口的信令数据,包括手机在发生业务时的位置信息。OIDD信令类型数据分为三大 类,呼叫记录、短信记录和用户位置更新记录。

CREATE EXTERNAL TABLE IF NOT EXISTS ods.ods_oidd(
 mdn string comment '手机号码'  
,start_time string comment '业务开始时间'  
,county_id string comment '区县编码'  
,longi string comment '经度'  
,lati string comment '纬度'  
,bsid string comment '基站标识'  
,grid_id string comment '网格号'  
,biz_type string comment '业务类型'  
,event_type string comment '事件类型'  
,data_source string comment '数据源'  
) 
comment  'oidd位置数据表'
 PARTITIONED BY (
 day_id string comment '天分区'  
) 
ROW FORMAT DELIMITED 
FIELDS TERMINATED BY '\t' 
STORED AS INPUTFORMAT 'org.apache.hadoop.mapred.TextInputFormat' 
OUTPUTFORMAT 'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat'  
location '/data/tour/ods/ods_oidd'; 


// 添加分区
alter table ods.ods_oidd add partition(day_id=20180503);


 // 加载数据
load data local inpath '/usr/local/soft/ctyun/ods_oidd/day_id=20180503/*' into table ods_oidd partition(day_id=20180503);

//查看数据

select * from  ods.ods_oidd limit 10;

dfs -mkdir -p /data/tour/ods/ods_oidd;


dfs -ls /data/tour/ods/ods_oidd;

dfs -ls /data/tour/ods/;


dfs -rmr /data/tour/ods/ods_oidd;

②ods_wcdr

WCDR采集网络中ABIS接口的数据,基于业务发生过程中三个扇区的测量信息,通过三角定位法 确定用户的位置信息。

CREATE EXTERNAL TABLE IF NOT EXISTS ods.ods_wcdr (
 mdn string comment '手机号码'  
,start_time string comment '业务开始时间'  
,county_id string comment '区县编码'  
,longi string comment '经度'  
,lati string comment '纬度'  
,bsid string comment '基站标识'  
,grid_id string comment '网格号'  
,biz_type string comment '业务类型'  
,event_type string comment '事件类型'  
,data_source string comment '数据源'  
) 
comment  'wcdr位置数据表'
 PARTITIONED BY (
 day_id string comment '天分区'  
) 
ROW FORMAT DELIMITED 
FIELDS TERMINATED BY '\t' 
STORED AS INPUTFORMAT 'org.apache.hadoop.mapred.TextInputFormat' 
OUTPUTFORMAT 'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat'  
location '/data/tour/ods/ods_wcdr'; 

// 添加分区
alter table ods.ods_wcdr add partition(day_id=20180503);

 // 加载数据
load data local inpath '/usr/local/soft/ctyun/ods_wcdr/day_id=20180503/*' into 
table ods_wcdr partition(day_id=20180503);

//查看数据

select * from ods.ods_wcdr limit 10;

③ods_ddr

当前DDR中只有移动数据详单可以提取基站标识,其他语音,短信,增值等业务没有位置信息, 不做为数据融合的基础数据。

CREATE EXTERNAL TABLE IF NOT EXISTS ods.ods_ddr(
 mdn string comment '手机号码'  
,start_time string comment '业务开始时间'  
,county_id string comment '区县编码'  
,longi string comment '经度'  
,lati string comment '纬度'  
,bsid string comment '基站标识'  
,grid_id string comment '网格号'  
,biz_type string comment '业务类型'  
,event_type string comment '事件类型'  
,data_source string comment '数据源'  
) 
comment  'ddr位置数据表'
 PARTITIONED BY (
 day_id string comment '天分区'  
) 
ROW FORMAT DELIMITED 
FIELDS TERMINATED BY '\t' 
STORED AS INPUTFORMAT 'org.apache.hadoop.mapred.TextInputFormat' 
OUTPUTFORMAT 'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat'  
location '/data/tour/ods/ods_ddr'; 

// 添加分区
alter table ods.ods_ddr add partition(day_id=20180503);

 // 加载数据
load data local inpath '/usr/local/soft/ctyun/ods_ddr/day_id=20180503/*' into 
table ods_ddr partition(day_id=20180503);

// 查询数据

select * from ods.ods_ddr limit 10;

④ods_dpi

移动DPI数据采集用户移动用户数据上网时移动核心网和PDSN之间接口的数据。

CREATE EXTERNAL TABLE IF NOT EXISTS ods.ods_dpi(
 mdn string comment '手机号码'  
,start_time string comment '业务开始时间'  
,county_id string comment '区县编码'  
,longi string comment '经度'  
,lati string comment '纬度'  
,bsid string comment '基站标识'  
,grid_id string comment '网格号'  
,biz_type string comment '业务类型'  
,event_type string comment '事件类型'  
,data_source string comment '数据源'  
) 
comment  'dpi位置数据表'
 PARTITIONED BY (
 day_id string comment '天分区'  
) 
ROW FORMAT DELIMITED 
FIELDS TERMINATED BY '\t' 
STORED AS INPUTFORMAT 'org.apache.hadoop.mapred.TextInputFormat' 
OUTPUTFORMAT 'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat'  
location '/data/tour/ods/ods_dpi'; 

// 添加分区
alter table ods.ods_dpi add partition(day_id=20180503);

 // 加载数据
load data local inpath '/usr/local/soft/ctyun/ods_dpi/day_id=20180503/*' into 
table ods_dpi partition(day_id=20180503);

// 查询数据

select * from ods.ods_dpi limit 10;

2)DWD层
create database dwd;

use dwd;

①dwd_res_regn_mergelocation_msk_d

在ODS层中,由于数据来源不同,原始位置数据被分成了好几张表加载到了我们的ODS层。 为了方便大家的使用,我们在DWD层做了一张位置数据融合表,在这里,我们将oidd、wcdr、 ddr、dpi位置数据汇聚到一张表里面,统一字段名,提升数据质量,这样就有了一张可供大家方 便使用的明细表了。

CREATE EXTERNAL TABLE IF NOT EXISTS dwd.dwd_res_regn_mergelocation_msk_d (
 mdn string comment '手机号码'  
,start_time string comment '业务开始时间'  
,county_id string comment '区县编码'  
,longi string comment '经度'  
,lati string comment '纬度'  
,bsid string comment '基站标识'  
,grid_id string comment '网格号'  
,biz_type string comment '业务类型'  
,event_type string comment '事件类型'  
,data_source string comment '数据源'  
) 
comment  '位置数据融合表'
 PARTITIONED BY (
 day_id string comment '天分区'  
) 
ROW FORMAT DELIMITED 
FIELDS TERMINATED BY '\t' 
STORED AS ORCFile
 location '/data/tour/dwd/dwd_res_regn_mergelocation_msk_d'; 


// 添加分区
alter table dwd.dwd_res_regn_mergelocation_msk_d add partition(day_id=20180503);

手动下载数据

// hive 直接运行速度太慢,可用手动load/put文件方式
// 手动load
// 注意 上面的建表语句文件存储格式修改为了ORCFile 所以不能直接使用下面的load方法
 load data local inpath '/usr/local/soft/ctyun/dwd_merge/part-00000*' into 
table dwd.dwd_res_regn_mergelocation_msk_d partition(day_id=20180503);



 // union all
 insert into table dwd.dwd_res_regn_mergelocation_msk_d 
partition(day_id="20180503")
 select  mdn  
        ,start_time  
        ,county_id  
        ,longi  
        ,lati  
        ,bsid  
        ,grid_id  
        ,biz_type  
        ,event_type  
        ,data_source 
from ods.ods_oidd


 where day_id = "20180503"
 union all
 select  mdn  
        ,start_time  
        ,county_id  
        ,longi  
        ,lati  
        ,bsid  
        ,grid_id  
        ,biz_type  
        ,event_type  
        ,data_source 
from ods.ods_wcdr
 where day_id = "20180503"
 union all
 select  mdn  
        ,start_time  
        ,county_id  
        ,longi  
        ,lati  
        ,bsid  
        ,grid_id  
        ,biz_type  
        ,event_type  
        ,data_source 
from ods.ods_dpi
 where day_id = "20180503"
 union all
 select  mdn  
        ,start_time  
        ,county_id  
        ,longi  
        ,lati  
        ,bsid  
        ,grid_id  
,biz_type  
,event_type  
,data_source 
from ods.ods_ddr
 where day_id = "20180503";

②dwm_staypoint_msk_d

计算一个人在一个网格内的停留时间,按手机号,网格id,区县id分组

1、对所有时间进行排序

2、取第一个点的开始时间和最后一个点的结束时间

create database dwm;

use dwm;

CREATE EXTERNAL TABLE IF NOT EXISTS dwm.dwm_staypoint_msk_d (
 mdn string comment '用户手机号码'  
,longi string comment '网格中心点经度'  
,lati string comment '网格中心点纬度'  
,grid_id string comment '停留点所在电信内部网格号'  
,county_id string comment '停留点区县'  
,duration string comment '机主在停留点停留的时间长度(分钟),lTime-eTime'  
,grid_first_time string comment '网格第一个记录位置点时间(秒级)'  
,grid_last_time string comment '网格最后一个记录位置点时间(秒级)'  
) 
comment  '停留点表'
 PARTITIONED BY (
 day_id string comment '天分区'  
) 
ROW FORMAT DELIMITED 
FIELDS TERMINATED BY '\t' 
STORED AS TEXTFILE
 location '/data/tour/dwm/dwm_staypoint_msk_d'; 

通过grid_id 网格id 获取 网格中心点经纬度 longi、lati

该SQL执行会出现问题: 执行流程一直处于 0% Map  0% reduce
/**
insert into table dwm.dwm_staypoint_msk_d partition(day_id=20180503)
select  t1.mdn
        ,get_points(grid_id)[0] as longi
        ,get_points(grid_id)[1] as lati
        ,t1.grid_id
        ,t1.county_id
        ,dateBetweenUDF(t1.grid_first_time,t1.grid_last_time) as duration
        ,t1.grid_first_time
        ,t1.grid_last_time
from (
    select  mdn
            ,grid_id
            ,county_id
            ,min(split(start_time,',')[0]) as grid_first_time
            ,max(split(start_time,',')[1]) as grid_last_time
    from dwd.dwd_res_regn_mergelocation_msk_d
    where day_id="20180503"
    group by mdn, grid_id, county_id
)t1;
*/

优化后的SQL:

WITH split_table as (
SELECT
mdn
,grid_id
,county_id
,split(start_time,',')[1] as grid_first_time
,split(start_time,',')[0] as grid_last_time
FROM dwd.dwd_res_regn_mergelocation_msk_d
where day_id="20180503"
)
, max_min_table as (
SELECT
mdn
,grid_id
,county_id
,Max(grid_first_time) OVER(PARTITION BY mdn,grid_id,county_id) as grid_first_time
,MIN(grid_last_time) OVER(PARTITION BY mdn,grid_id,county_id) as grid_last_time
FROM split_table 
)

insert into table dwm.dwm_staypoint_msk_d partition(day_id=20180503)
SELECT 
t1.mdn
,get_points(t1.grid_id)[0] as longi
,get_points(t1.grid_id)[1] as lati
,t1.grid_id
,t1.county_id
,dateBetweenUDF(t1.grid_first_time,t1.grid_last_time) as duration
,t1.grid_first_time
,t1.grid_last_time
FROM (
SELECT
mdn
,grid_id
,county_id
,grid_first_time
,grid_last_time
FROM max_min_table
group by 
mdn
,grid_id
,county_id
,grid_first_time
,grid_last_time
) t1

③dws_province_tourist_msk_d

游客定义 出行距离大于300km 常住地在用户画像表中 在省内停留时间大于3个小时

create database dws;

use dws;

CREATE EXTERNAL TABLE IF NOT EXISTS dws.dws_province_tourist_msk_d (
 mdn string comment '手机号大写MD5加密'  
,source_county_id string comment '游客来源区县'  
,d_province_id string comment '旅游目的地省代码'  
,d_stay_time double comment '游客在该省停留的时间长度(小时)'  
,d_max_distance double comment '游客本次出游距离'  
) 
comment  '旅游应用专题数据省级别-天'
 PARTITIONED BY (
 day_id string comment '日分区'  
) 
ROW FORMAT DELIMITED 
FIELDS TERMINATED BY '\t' 
STORED AS PARQUET
 location '/data/tour/dws/dws_province_tourist_msk_d';

停留点表dwm_staypoint_msk_d与用户画像维表dim_usertag_msk_m 通过mdn关联,使用 get_city_or_prov_id(county_id,"province")方法,传入county_id,返回province_id,然后按 mdn、province_id、resi_county_id分组,使用calLength(grid_id, resi_grid_id) 传入网格id、居 住地网格id,算出出行距离,并计算每个用户到每个省的累计出行时间,然后取出 累计时间最大 值超过3小时(180分钟),出行距离大于300km的用户

④dws_city_tourist_msk_d

出行距离大于100km 在市内停留时间大于3个小时

CREATE EXTERNAL TABLE IF NOT EXISTS dws.dws_city_tourist_msk_d (
 mdn string comment '手机号大写MD5加密'  
,source_county_id string comment '游客来源区县'  
,d_city_id string comment '旅游目的地市代码'  
,d_stay_time double comment '游客在该省市停留的时间长度(小时)'  
,d_max_distance double comment '游客本次出游距离'  
) 
comment  '旅游应用专题数据城市级别-天'
 PARTITIONED BY (
 day_id string comment '日分区'  
) 
ROW FORMAT DELIMITED 
FIELDS TERMINATED BY '\t' 
STORED AS PARQUET
 location '/data/tour/dws/dws_city_tourist_msk_d';

停留点表dwm_staypoint_msk_d与用户画像维表dim_usertag_msk_m 通过mdn关联,使用 get_city_or_prov_id(county_id,"city")方法,传入county_id,返回city_id,然后按mdn、city_id、 resi_county_id分组,使用calLength(grid_id, resi_grid_id) 传入网格id、居住地网格id,算出出行 距离,并计算每个用户到每个市的累计出行时间,然后取出 累计时间最大值超过3小时(180分 钟),出行距离大于100km的用户

⑤dws_county_tourist_msk_d

出行距离大于10km 在县内停留时间大于3个小时

CREATE EXTERNAL TABLE IF NOT EXISTS dws.dws_county_tourist_msk_d (
    mdn string comment '手机号大写MD5加密'  
    ,source_county_id string comment '游客来源区县'  
    ,d_county_id string comment '旅游目的地县代码'  
    ,d_stay_time double comment '游客在该县停留的时间长度(小时)'  
    ,d_max_distance double comment '游客本次出游距离'  
) 
comment  '旅游应用专题数据县级别-天'
 PARTITIONED BY (
    day_id string comment '日分区'  
) 
ROW FORMAT DELIMITED 
    FIELDS TERMINATED BY '\t' 
STORED AS PARQUET
 location '/data/tour/dws/dws_county_tourist_msk_d';

停留点表dwm_staypoint_msk_d与用户画像维表dim_usertag_msk_m 通过mdn关联,按mdn、 county_id、resi_county_id分组,使用calLength(grid_id, resi_grid_id) 传入网格id、居住地id, 算出出行距离,并计算每个用户到每个县的累计出行时间,然后取出 累计时间最大值超过3小时 (180分钟),出行距离大于10km的用户

运行SQL时报错 我们要创建一下UDF函数

add jars /usr/local/soft/jars/jtxy_hdfs-1.0-SNAPSHOT.jar;


create temporary function get_points as 'ctyun.udf.getPointsUDF';


create temporary function dateBetweenUDF as 'ctyun.udf.dateBetweenUDF';


create temporary function calLength as 'ctyun.udf.calLength';


create temporary function get_city_or_prov_id as 'ctyun.udf.getCityIdOrProvID';

insert into table dws.dws_county_tourist_msk_d partition(day_id="20180503")
 select  ttt1.mdn
        ,ttt1.source_county_id
        ,ttt1.d_county_id
        ,ttt1.d_stay_time
        ,ttt1.d_max_distance
 from(
        select  mdn
                ,resi_county_id as source_county_id
                ,county_id as d_county_id
                ,sum(duration) as d_stay_time
                ,max(calLength(tt1.grid_id,tt1.resi_grid_id)) as d_max_distance
        from(
                select  t1.mdn
                        ,t1.grid_id
                        ,t1.county_id
                        ,t1.duration
                        ,t2.resi_county_id
                        ,t2.resi_grid_id
                from (
                        select  *
                        from dwm.dwm_staypoint_msk_d
where day_id='20180503'
 ) t1 join(
 select *
 from dim.dim_usertag_msk_m
 where month_id='201805'
 ) t2 on t1.mdn = t2.mdn
 ) tt1 group by tt1.mdn,tt1.county_id,tt1.resi_county_id
 )ttt1 where d_stay_time > 180 and d_max_distance > 10000
 ;

3)DIM层
create database dim;

use dim;

①dim_usertag_msk_m
CREATE EXTERNAL TABLE IF NOT EXISTS dim.dim_usertag_msk_m (
 mdn string comment '手机号大写MD5加密'  
,name string comment '姓名'  
,gender string comment '性别,1男2女'  
,age string comment '年龄'  
,id_number string comment '证件号码'  
,number_attr string comment '号码归属地'  
,trmnl_brand string comment '终端品牌'    
,trmnl_price string comment '终端价格'
 ,packg string comment '套餐'  
,conpot string comment '消费潜力'  
,resi_grid_id string comment '常住地网格'  
,resi_county_id string comment '常住地区县'  
) 
comment  '用户画像表'
 PARTITIONED BY (
 month_id string comment '月分区'  
) 
ROW FORMAT DELIMITED 
FIELDS TERMINATED BY '\t' 
STORED AS PARQUET
 location '/data/tour/dim/dim_usertag_msk_m'; 


// 添加分区
alter table dim.dim_usertag_msk_m add partition(month_id=201805);


 // 加载数据
load data local inpath 
'/usr/local/soft/ctyun/dim_usertag_msk_m/month_id=201805/*' into table 
dim.dim_usertag_msk_m partition(month_id=201805);

// 查询数据

select * from dim_usertag_msk_m limit 10;

4)ADS层

根据需求建设

1)需求矩阵

2)根据区县游客表计算如下指标

客流量按天 [区县id,客流量]

select  t1.d_county_id
        ,count(*) as d_county_cnt
from (
    select  d_county_id
    from dws.dws_county_tourist_msk_d
    where t1.day_id="20180503"
) t1 group by t1.d_county_id;

性别按天 [区县id,性别,客流量]

select  t1.d_county_id
        ,t2.gender
        ,count(*) as d_county_gender_cnt
from(
    select  mdn
            ,d_county_id
    from dws.dws_county_tourist_msk_d
    where day_id="20180503"
) t1 left join (
    select  mdn
            ,gender
    from dim.dim_usertag_msk_m
    where month_id=20180503
) t2 on t1.mdn = t2.mdn
group by t1.d_county_id,t2.gender;

年龄按天 [区县id,年龄,客流量]
常住地按天 [区县id,常住地市,客流量]
归属地按天 [区县id,归属地市,客流量]

select  t1.d_county_id
        ,t2.number_attr
        ,count(*) as d_county_number_attr_cnt
from(
    select  mdn
            ,d_county_id
    from dws.dws_county_tourist_msk_d
    where day_id="20180503"
) t1 left join (
    select  mdn
            ,number_attr
    from dim.dim_usertag_msk_m
    where month_id=20180503
) t2 on t1.mdn = t2.mdn
group by t1.d_county_id,t2.number_attr;

终端型号按天 [区县id,终端型号,客流量]
消费等级按天 [区县id,消费等级,客流量]
停留时长按天 [区县id,停留时长,客流量]

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

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

相关文章

2024年5月面试知识点梳理

2024年5月面试知识点梳理 资料来源Java基础泛型注解异常反射SPI机制Java集合CollectionMap 并发基础线程并发关键字并发集合Lock核心类并发集合核心类原子类核心类线程池核心类ScheduledThreadPoolExecutorForkJoinPoolFokJoinTask JUC原子类: CAS, Unsafe和原子类详解JUC 工具…

【Linux】linux | 配置系统日志 | 安全日志 | 操作日志 | 登录日志

一、诉求 1、linux服务器开启日志功能,并记录10个月的登录 二、操作 1、进入目录 cd /etc 2、编辑配置 vi logrotate.conf 3、复制配置 /var/log/wtmp {monthlycreate 0664 root utmpminsize 1Mrotate 10 }/var/log/btmp {missingokmonthlycreate 0600 root …

多客陪玩系统,陪玩系统源码,线下搭子,爆改家政整理师等功能,陪玩预约系统 定制化陪玩系统,陪玩软件APP小程序H5游戏陪玩成品软件源码

简述 陪玩系统源码是指一款游戏陪玩平台的程序代码。陪玩系统通常是一个在线平台,可以让用户通过该平台找到愿意为他们提供游戏陪玩服务的人员,从而帮助他们在游戏中取得更好的成绩。这种系统通常包括客户端和服务器端两个部分,客户端用于用…

【强训笔记】day23

NO.1 思路:直接计算结果,先计算怪物可以抗几次攻击,再计算勇士受到的伤害,如果勇士的攻击力大于等于怪物的血量,那么就可以击杀无数只,如果勇士的血量正好是受到攻击的整数倍,那么击杀的怪物数…

服务攻防——应用协议软件,设备平台

向日葵利用 vnc利用5900端口 当为none就可以直接连接,而其他几种密码也能破解 可以使用hydna来尝试爆破 teamviewer(cve2020-13699) 让对方点击这个网站,就会 触发 zabbix 端口10051 cve2020 手工 点击这个 找到cookie 然后不需要密码就能进…

手心经常出汗、多汗是怎么回事?

点击文末领取揿针的视频教程跟直播讲解 手心爱出汗是一种怎样的体验? 手握着鼠标,一会儿就变得湿漉漉,小心翼翼拿着手机,防止它从满是汗的手掌滑出去……其实手心总出汗可能是一种病。 很多人都有手掌心出汗的症状。如果年轻健康…

【leetcode面试经典150题】-26. 删除有序数组中的重复项

26. 删除有序数组中的重复项 1 题目介绍1 个人解题思路1.1 解题代码1.2 思路解析 2、分析官方题解2.1 快慢双指针 1 题目介绍 给你一个 非严格递增排列 的数组 nums ,请你 原地 删除重复出现的元素,使每个元素 只出现一次 ,返回删除后数组的新…

佛山信息学真题 桂城-2021-五年级1.2

一、两位数(GC4091) GC4091 GC.2021.五年级.01.两位数http://43.139.152.26/d/DH_Trial/p/GC4091 题目描述 小明正在思考一个数学问题:有一个两位数,它的十位数大于等于个位数。现已知它的十位数和个位数之和为a,十位…

在pycharm添加pyqt5外部工具插件

一:查看环境所在位置以及安装pyqt5库 1、打开anaconda,输入以下命令,查看环境名,以及环境所在位置。 conda info --envs 从图中得知以下信息,下面根据自己实际情况,记住环境名和路径 ①环境名是&#xf…

Google IO 2024有哪些看点呢?

有了 24 小时前 OpenAI 用 GPT-4o 带来的炸场之后,今年的 Google I/O 还未开始,似乎就被架在了一个相当尴尬的地位,即使每个人都知道 Google 将发布足够多的新 AI 内容,但有了 GPT-4o 的珠玉在前,即使是 Google 也不得…

数据结构_链表基本操作的实现_代码_例题

一、基本操作实现 1.按位序插入(带头节点) 2.按位序插入(不带头节点) 3.指定结点的后插操作 4.指定结点的前插操作 5.按位序删除(带头节点) 6.指定结点的删除 7.按位查找,返回第i个元素&…

优雅谈论大模型8:神经网络与矩阵

向量与矩阵 上个章节的神经网络是为了解Transformer或者Mamba做好铺垫,在和后辈交流过程中发现有个障碍,那就是向量和矩阵。其实向量和矩阵的表达方式不是所有人都很习惯。在继续下面的章节之前小编认为有必要将向量、矩阵和神经网络做下补充解释。 向…

【完美恢复】修复计算机中丢失emp.dll的多个详细方法

最近,在尝试运行某款游戏时,我遭遇了一个令人头痛的问题——“emp.dll文件丢失”。这个错误通常意味着游戏的某个关键文件没有被正确加载或已损坏。以下是我解决问题的步骤和一些心得体会,希望对遇到类似问题的玩家们有所帮助。 emp.dll是一…

BI软件超实用功能揭秘

面对海量数据、复杂的指标计算和分析,BI软件都能轻而易举地达成,并且所用时间远远低于一般的分析软件。这背后自然是得益于一众强大的功能,接下来就来一起了解下BI软件那些超实用的功能。 1、标准化方案,更新数据源,立…

Anaconda下载安装

看到这篇文章的同学们,说明你们是要下载Anaconda,这篇文章讲的就是下载安装教程。 Anaconda下载网址: Download Now | Anaconda 根据我们需要的系统版本下载,我的电脑是window,所以选择第一个,如下图&am…

MIT 6.5840(6.824) Lab2:Key/Value Server 设计实现

1 实验要求 在本次 Lab 中,你将在单机上构建一个键/值服务器,以确保即使网络出现故障,每个操作也只能执行一次,并且操作是可线性化的。 客户端可以向键/值服务器发送三个不同的 RPC: Put(key, value) 、 Append(key,…

项目中使用Elasticsearch的API相关介绍

项目中使用Elasticsearch的API相关介绍 0、域映射类型 text:会分词,不支持聚合对当前搜索关键词,先自身分词,分成多个词,然后去一个一个的词去利用倒排索引去查询es索引库一般应用在搜索关键字匹配的字段的类型。 商…

如何解决 CentOS 双网卡配置的内外网通信问题?

🐯 如何解决 CentOS 双网卡配置的内外网通信问题?🐾 博主猫头虎的技术世界 🌟 欢迎来到猫头虎的博客 — 探索技术的无限可能! 专栏链接: 🔗 精选专栏: 《面试题大全》 — 面试准备的…

Spring学习①__Spring初识

Spring Spring初识一、框架二、Spring(春天)简介Spring官网Spring是什么?Spring介绍拓展 Spring初识 一、框架 ​框架就是一些类和接口的集合,通过这些类和接口协调来完成一系列的程序实现。 JAVA框架可以分为三层: 表示层业务…

【网络安全】【Frida实战案例】某图xx付费功能逆向分析(二)

文章目录 一、目标应用二、环境三、步骤1、重打包2、运行打包后apk3、找到签名信息(1)、查看apk签名信息(2)、hook Android方法获取apk签名信息(3)、转为md5验证 4、hook apk签名信息 四、总结五、相关源码…