上一页 1 ··· 20 21 22 23 24 25 26 27 28 ··· 32 下一页
摘要: 给定一个经过编码的字符串,返回它解码后的字符串 输入:s = "3[a2[c]]" 输出:"accaccacc" ####字符串栈和数字栈 对于这种具有优先级的操作,使用栈来进行匹配 class Solution { public: string decodeString(string s) { s 阅读全文
posted @ 2022-07-07 15:36 失控D大白兔 阅读(79) 评论(0) 推荐(0) 编辑
摘要: 给你一个只包含正整数的非空数组 nums 。请你判断是否可以将这个数组分割成两个子集,使得两个子集的元素和相等 ###1. 回溯法(超时) class Solution { public: bool canPartition(vector<int>& nums) { //其实就是找一个集合值为特定值 阅读全文
posted @ 2022-07-06 23:49 失控D大白兔 阅读(21) 评论(0) 推荐(0) 编辑
摘要: 给你一个整数数组 nums ,你需要找出一个 连续子数组 ,如果对这个子数组进行升序排序,那么整个数组都会变为升序排序。 请你找出符合题意的最短 子数组,并输出它的长度 ###1. 排序后比较 先排序,再分别找第一个不在位的的元素,做差 class Solution { public: int fi 阅读全文
posted @ 2022-07-06 22:08 失控D大白兔 阅读(12) 评论(0) 推荐(0) 编辑
摘要: ###一. 特征选择 #####1. Permutation Importance # shuffle a single column of the validation data and get the loss(which reflects the importance) import eli5 阅读全文
posted @ 2022-07-06 22:03 失控D大白兔 阅读(47) 评论(0) 推荐(0) 编辑
摘要: ###一. 特征评价 #####1. 互信息 from sklearn.feature_selection import mutual_info_regression import matplotlib.pyplot as plt def make_mi_scores(X, y): X = X.co 阅读全文
posted @ 2022-07-06 17:13 失控D大白兔 阅读(38) 评论(0) 推荐(0) 编辑
摘要: ###一. 数据探索分析&数据清洗&缺失值填充 1 Which features are categorical? 什么特征是离散的? 2 Which features are numerical? 什么特征是连续的? 3 Which features are mixed data types? 什 阅读全文
posted @ 2022-07-06 15:39 失控D大白兔 阅读(67) 评论(0) 推荐(0) 编辑
摘要: Pipelines are a simple way to keep your data preprocessing and modeling code organized. Specifically, a pipeline bundles preprocessing and modeling st 阅读全文
posted @ 2022-07-04 15:20 失控D大白兔 阅读(89) 评论(0) 推荐(0) 编辑
摘要: 批量给指定文件夹内图片添加水印,并且能提取图片本身信息或指定信息进行添加,字体大小适配图片 减少简单的ps操作,同时使文字显现出蓝白的立体效果 from PIL import Image, ImageDraw, ImageFont import glob import re files = glob 阅读全文
posted @ 2022-07-03 14:56 失控D大白兔 阅读(293) 评论(0) 推荐(0) 编辑
摘要: nums1 中数字 x 的 下一个更大元素 是指 x 在 nums2 中对应位置 右侧 的 第一个 比 x 大的元素。 给你两个 没有重复元素 的数组 nums1 和 nums2 ,下标从 0 开始计数,其中nums1 是 nums2 的子集。 对于每个 0 <= i < nums1.length 阅读全文
posted @ 2022-07-03 03:46 失控D大白兔 阅读(28) 评论(0) 推荐(0) 编辑
摘要: 汽车从起点出发驶向目的地,该目的地位于出发位置东面 target 英里处。 沿途有加油站,每个 station[i] 代表一个加油站,它位于出发位置东面 station[i][0] 英里处,并且有 station[i][1] 升汽油。 假设汽车油箱的容量是无限的,其中最初有 startFuel 升燃 阅读全文
posted @ 2022-07-03 02:50 失控D大白兔 阅读(68) 评论(0) 推荐(0) 编辑
上一页 1 ··· 20 21 22 23 24 25 26 27 28 ··· 32 下一页