原创 用csv格式的文件代替poi導出xls文件
當導出的Excel文件對格式沒有要求,並且是單一表頭的時候,可以導出csv格式的文件,來代替xls文件 好處: 1、快 2、快 3、快 因爲poi操作不僅涉及到單元格數據的處理,還涉及到單元格格式,單元格合併等等操作
原创 任務五-模型參數優化
模型參數優化 使用網格搜索法對模型進行調優(調參時採用五折交叉驗證的方式),並進行模型評估 網格搜索 網格搜索,其實可以叫窮舉搜索,就是在所有候選的參數中,將不同參數組合起來,找出表現最好的一組參數。 eg:以有兩個參數的模型爲例
原创 Maven傳遞依賴的原則
maven引入的傳遞性依賴機制,一方面大大簡化和方便了依賴聲明,大部分情況下我們只需要關心項目的直接依賴是什麼,而不永哥你考慮這些直接依賴會引入什麼傳遞性依賴。但有時候,當歘地形依賴造成問題時,我們就需要清除知道該傳遞性依賴是從哪條依賴路
原创 HashMap的到底是有序還是無序
HashMap的到底是有序還是無序前提問題背景HashMap的一些特性問題分析結論再結論 前提 首先說明:HashMap不保證插入順序,但是循環遍歷時,輸出順序是不會改變的。 代碼說明: public class HashMapT
原创 Excel生成之java heap space異常
Excel生成之java heap space異常 問題場景 在使用poi操作,生成一個6w行,45列的excel的時候,老是報內存不夠用(java heap space異常)。 一開始以爲是默認啓動時,內存太小,就把堆內存調至2
原创 求二叉樹的所有末級左節點的值的和
題目:Sum of Leaves 描述: Find the sum of all left leaves in a given binary tree. Example: 3 / \ 9 20
原创 二叉樹的深度
題目:Maximum Depth of Binary Tree 題目詳情: Given a binary tree, find its maximum depth. The maximum depth is the number
原创 尋找數組中唯一的數
題目:Single Number 題目詳情: Given an array of integers, every element appears twice except for one. Find that single one
原创 輸入整數,返回數組,並代替某些位置的數
題目:Fizz Buzz 題目詳情: Write a program that outputs the string representation of numbers from 1 to n. But for multiple
原创 判斷“資源字符串”是否可以構成“目標字符串”
題目:Ransom Note 描述: Given an arbitrary ransom note string and another string containing letters from all the magazin
原创 將數組中的0全部移動到末尾
題目:Move Zeroes 描述: Given an array nums, write a function to move all 0’s to the end of it while maintaining the rel
原创 將Excel表頭轉換成列數
題目:Excel Sheet Column Number 描述: Given a column title as appear in an Excel sheet, return its corresponding column
原创 找尋字符串中的第一個唯一字符串
題目:First Unique Character in a String 描述: Given a string, find the first non-repeating character in it and return i
原创 刪除單向鏈表中的某個節點
題目:Delete Node in a linked List 描述: Write a function to delete a node (except the tail) in a singly linked list, gi
原创 linux定時任務運行jar包
linux定時任務運行jar包目標方法cron表達式配置 目標 使用linux上的定時設置,定時運行jar包。我的需求是每天需要在機器上定時跑一個程序,自動去預訂會議室,2333333… 方法 任意目錄輸入如下命令: cronta