• How to use Bert to deal with long text


    1 Preface The maximum sequence length that the pre training model Bert can process is 512. When facing long text (document level), text truncation or sliding window is usually used to make the sequence length of the input model meet the preset value, but this processing method will lead to the loss of global information […]

  • 20 + CSS high frequency practical clips, small skills to improve happiness, you can have Oh


    preface Modify input placeholder style、Multiline text overflow、Hide scroll bar、Modify cursor color、Horizontal vertical center… what a familiar function! Front end children’s shoes will deal with them almost every day. Let’s summarize our CSS happiness clips! Next time you don’t need Baidu or Google, this is your harbor. Click “view source address” to continuously update“ 1. Solve […]

  • The request load balancing of golang HTTP1.1 is forwarded according to http2.0


    Key parameters:TLSNextProto Solution:Setting tlsnextproto to an empty map will not automatically upgrade, which is equivalent to turning off http2.0 client := &http.Client { Transport:&http.Transport{ TLSNextProto: map[string]func(authority string, c *tls.Conn) http.RoundTripper{}, }, } reason:come from https://stackoverflow.com/que…Starting with Go 1.6, the http package has transparent support for the HTTP/2 protocol when using HTTPS. Programs that must disable […]

  • Ruffian Heng embedded: three methods to redirect key functions to ram for execution in IAR development environment


    Hello, I’m ruffian Heng, a serious technical ruffian. What ruffian Heng shared with you today isThree methods of redirecting key functions to ram for execution in IAR development environment。 In embedded projects, the application code is normally executed in flash, but sometimes some functions in the code need to be redirected to ram for execution, […]

  • The in-depth learning framework developed by Chinese and American universities may be used for epidemic prevention and control


    Technical editor: mango fruit from Sifu editorial departmentSegmentFault has he reported the official account number: SegmentFault Network science is an academic field that aims to reveal the structure and dynamics behind the network, such as telecommunications, computers, biological and social networks. In recent years, a basic problem that network scientists have been trying to solve […]

  • Spring for Kafka auto configuration and configuration properties


    order This article mainly lists some auto config and attribute configuration of spring for Apache Kafka maven <dependency> <groupId>org.springframework.kafka</groupId> <artifactId>spring-kafka</artifactId> <version>1.2.3.RELEASE</version> </dependency> This version uses Kafka client version spring retry used is version 1.1.3.release Several key configuration classes KafkaAutoConfigurationspring-boot-autoconfigure-1.5.7.RELEASE-sources.jar!/org/springframework/boot/autoconfigure/kafka/KafkaAutoConfiguration.java @Configuration @ConditionalOnClass(KafkaTemplate.class) @EnableConfigurationProperties(KafkaProperties.class) @Import(KafkaAnnotationDrivenConfiguration.class) public class KafkaAutoConfiguration { private final KafkaProperties properties; public KafkaAutoConfiguration(KafkaProperties properties) […]

  • The react child component modifies the state of the parent component and transfers the value of the child component to the parent component


    The parent component can pass an event (method) to the child component. When the child component receives the event (method) and calls the event (method), the method defined in the parent component will be triggered, so as to change the state of the parent component and pass parameters Here is the key code of the […]

  • Discussion on the effect of tree shading


    Webpack and other construction toolstree-shakingMechanism, utilizationes6inModuleGrammaticalexportandimportSyntax static analysis, eliminate useless code, reduce the amount of code after packagingHow to start webpacktree-shaking, need: Webpack above v2.0 Turn on code compression Webpack just marks statement dependencies and whether to use them,tree-shakingThe specific implementation of is generally provided by the compressor, such as the default compression tool of […]

  • Authority Subsystem (2) — menu module


    Menu management design description Business design description Menu management, also known as resource management, is the external manifestation of system resources. This module is mainly to add, modify, query and delete the menu. The table design statement is as follows: CREATE TABLE `sys_menus` ( `id` int(11) NOT NULL AUTO_INCREMENT, `Name ` varchar (50) default null […]

  • Authority Subsystem (3) — role module


    Role management design description Business design description This module mainly realizes the management of internal roles (positions) in the enterprise. When adding roles, you can assign resource access rights to roles, and finally assign roles to usersBased on the design of the table, the logical relationship of the data is shown as follows:The script of […]

  • Authority Subsystem (4) — user module


    User management design description Business design description This module mainly realizes the management of user information, including user query, save, update, disable, enable and other operationsBased on the design of the table, the logical relationship of the data is displayed, as shown in the figureThe script of user table design is as follows: CREATE TABLE […]

  • Picture (exercise class 2)


    Which of the following four digraphs is not strongly connected. ( B) First, we define what is a strongly connected graph: a directed graph is said to be strongly connected if every node has a path to any other node.Judgment method: take any node s of the digraph g, start the depth first search from s, […]