Perceptron Statistical Learning Method Chapter 2, numpy primitive form and dual form, torch implementation

Perceptron Perceporn Theory "Statistical Learning Methods" Chapter 2 Perceptron Code numpy version && torch version Python3.7 %matplotlib inline Model The linear classification model of binary classification aims to find a hyperplane to linearly divide all instances into positive examples and negative examples, a ...

Posted by dbrown on Fri, 27 Jan 2023 14:27:42 +0300

Implementation of the Fruit Fly Optimization Algorithm (FOA) (Python with source code)

1. Implementation idea of ​​fruit fly optimization algorithm Fruit Fly Optimization Algorithm (FOA) is a swarm intelligence optimization algorithm proposed by Pan Wenchao in 2011. It simulates the way fruit flies in nature forage, and compares the position information of food to the optimal solution of optimization problems. The optimal soluti ...

Posted by krysco on Fri, 20 Jan 2023 04:38:33 +0300

Python Basics - Numpy Numerical Calculation

NumPy provides a multidimensional array object called ndarray whose elements have a fixed size. That is, NumPy array elements are homogeneous and can only store objects of the same data type. It can use vectorized operation to process the entire array, which has high operation efficiency. array creation Create an ndarray array through the arr ...

Posted by Elle0000 on Wed, 04 Jan 2023 20:32:18 +0300

Mathematical Modeling - Interpolation and Fitting

1. Interpolation and fitting 1. What is interpolation and fitting?  Interpolation and fitting is to construct a function through sample data. If the constructed function image is required to pass through all sample points, it is interpolation, otherwise it is fitting. 2. Commonly used one-dimensional interpolation methods (1) piece ...

Posted by russy on Fri, 30 Dec 2022 07:58:35 +0300

Dictionary name [key name] = new value Modify the value of the dictionary

37. Dictionary name [key name] = new value Modify the value of the dictionary 1. Mutability of dictionaries Strings and tuples are immutable data types. Lists and dictionaries are mutable. Variable means that it can be changed, that is, elements can be added to lists and dictionaries, and existing elements can be deleted and modified. ...

Posted by buzzby on Mon, 24 Oct 2022 07:07:08 +0300

Teen python Series 10. Strings

Teenager python Series Directory - Old Programmer's Blog - CSDN Blog Teenager python teaching video ppt source code Introduction In Python, the text enclosed in quotation marks is a string, and the string can also be saved in a variable for use. If the text in the string contains double quotes, you can enclose the string in single quote ...

Posted by squallm1 on Sun, 09 Oct 2022 22:43:30 +0300

Python Basics | Numpy Detailed Tutorial

⭐This column aims to explain the basic grammar of Python in detail, summarize the key points in the grammar, and explain the difficulties in detail. It is aimed at zero-based and entry-level learners. Through the study of the column, you can master python programming proficiently, and at the same time, it will be used for subsequent data analy ...

Posted by yacaph on Thu, 06 Oct 2022 09:53:22 +0300

python loop keywords and lists

1, Nested loop comparison (code runtime management) In python, if we want to pursue the simplicity of the code, we need to understand that more code will take more time to run, which will reduce the work efficiency. Next, we observe the effect through python's time library import time start=time.time() for x in range(0, 35): # y stan ...

Posted by paulsiew2 on Fri, 26 Aug 2022 00:29:49 +0300

python based integrated student information management system for teachers and students -- python final design!!!

System introduction The system uses python language for program design. The main contents of the design can be summarized as follows: the teacher-student integrated student information management system, first of all, the administrator (teacher) adds, deletes, modifies, finds and exports student information (in the form of excel form), and the ...

Posted by narch31 on Fri, 01 Jul 2022 21:35:10 +0300

[learning notes] analysis report on user consumption behavior

This is an analysis report of users' consumption behavior The data comes from the Internet (teacher Qin Lu). It is the consumption records of users on a CD website. It is only used for learning. If there is infringement, you can contact to delete it~ 0 Introduction User consumption record is the concrete embodiment of user behavior. Analyzin ...

Posted by isedeasy on Fri, 06 May 2022 06:46:07 +0300