## Pytorch draws train loss and val acc curves

import os importsys import json import torch import torch.nn as nn import torch.optim as optim from torchvision import transforms, datasets from tqdm import tqdm from model import resnet34,resnet101 import matplotlib.pyplot as plt # from csv import readerxon import numpy as np from osgeo import gdal from torchvision.transforms import functional as F # from torch.utils.tensorboard import […]

## 5. QtCharts curve beautification

Article directory Effect ui settings dialog.h dialog.cpp Effect ui settings dialog.h #ifndef DIALOG_H #define DIALOG_H #include <QDialog> #include <QtCharts> #include <QLineSeries> #include <QGraphicsScene> #include <QTimer> #include <QSplineSeries> QT_BEGIN_NAMESPACE namespace Ui {<!– –> class Dialog; } QT_END_NAMESPACE class Dialog : public QDialog {<!– –> Q_OBJECT public: Dialog(QWidget *parent = nullptr); ~Dialog(); private: Ui::Dialog *ui; private: /** […]

## C# | Chaikin algorithm – Calculate the coordinate points of the smooth curve corresponding to the polyline

Chaikin algorithm – Calculate the coordinate points of the smooth curve corresponding to the polyline This article will introduce an algorithm for calculating the coordinate points of a smooth curve corresponding to a polyline. This algorithm uses the Chaikin curve smoothing method to adjust the smoothness and accuracy of the curve by controlling the tension […]

## Python secondary development of Solidworks: reading spline curve data

Table of Contents 1. Sketch segment object 2. VBA code analysis 3. python code implementation Spline curve is a mathematical term. It is a special parametric curve that is generated by curve fitting from a set of control points. The word spline originated from a temporary auxiliary bracket in ship construction. It was later introduced […]

## Drawing of ROC curve and PR curve

Evaluating the performance of classification models is an important topic in machine learning research. In this article, we will focus on two commonly used evaluation indicators, ROC curve and PR curve, introduce their principles and application methods, and explain how to use these indicators to evaluate performance. Analyze and compare. 1. Select the data set […]

## ROC curve and PR curve

Table of Contents 1. ROC curve 1. Concept 2. Drawing of ROC curve 2. PR curve 1. Concept 2.AP (area under the PR curve) 3. Drawing of PR curve 3. Advantages and disadvantages of ROC curve and PR curve 1.ROC curve 2.PR curve 4. Experiment summary 1. ROC curve 1. Concept The ROC (Receiver Operating […]

## ROC curve and PR curve

Table of Contents Article overview: Introduction: ROC curve: PR curve: Features: Draw ROC curve and PR curve Environment setup and data preparation and model training Functions for calculating Precision and Recall and functions for calculating TPR and FPR Draw ROC curve and PR curve The results obtained: Article Overview: In this blog, we will introduce […]

## ROC curve and PR curve

Table of Contents 1.PR, ROC curve concept 2. Confusion matrix 3.The difference between ROC curve and PR curve 4. Draw PR curve and ROC curve 5. Summary 1.PR, ROC curve concept PR curves and ROC curves are commonly used tools when evaluating binary classification models (classifiers) to show the performance and effectiveness of the model. […]

## PR curve and ROC curve

1. PR Curve 1. What is the P-R curve: P is precision, which is precision rate (precision rate), and R is recall, which is recall rate, so the P-R curve reflects the relationship between precision rate and recall rate. Generally, the abscissa is recall and the ordinate is precision. 2. Function of P-R curve: PR […]

## Javascript uses canvas to draw curves, arrows, etc. between two points

Javascript uses canvas to draw curves and rectangles between two points, and draw text in the rectangle to achieve center alignment and arrow drawing. The effect is as shown below: 1. HTML, the code is as follows <canvas id=”canvas” width=”1000″ height=”600″></canvas> 2. The css code is as follows: canvas {<!– –> display: block; width: 1000px; […]