当前位置:网站首页>Jenkspy package installation
Jenkspy package installation
2022-04-23 18:00:00 【Be happy to study today】
jenkspy Bag installation pit *
use jenkspy Realization arcgis Natural breakpoint method in , There are many problems in the installation process :
A pit : My computer is equipped with Python2.7,Python3.9 Two environments , If direct pip install jenkpy , Then the system displays unable to create…, That means the system can't distinguish pip yes python2 still python3 The path of
How to set up multiple python Environmental Science
Pit two : After solving a problem , I am here python3 Installation in environment python3 -m pip install jenkspy, The error displayed is that the... Cannot be installed tar.gz file , Later it was found that python The version doesn't match ,jenkspy The latest version only supports up to 3.8, It happens that there is no 3.9 Version of ... There is less than 3.9 The version should be able to be installed directly , If it shows runtimeerror, According to python Version to download the corresponding compressed package , Link to :
jenkspy
Pit three : I don't want to reload 3.8 Of python edition , So try to use python2 download , The result shows a new error :Microsoft Visual C++ 9.0 is required.. Then the whole network looks for resources , eureka VCForPython27.msi8 Download , Then the problem is solved successfully .
Pit four : Even though it's loaded with , But the operation will report an error , So I modified core.py After the source code , It's running successfully :
from collections.abc import Iterable
Change it to from collections import Iterable
from math import isfinite
Change it to import math
values = [i for i in values if isfinite(i)]
Change it to values = [i for i in values if np.isfinite(i)]
Code practice
import jenkspy
import random
''' jenks_breaks( [1.3, 7.1, 7.3, 2.3, 3.9, 4.1, 7.8, 1.2, 4.3, 7.3, 5.0, 4.3], nb_class = 3) # Should output (1.2, 2.3, 5.0, 7.8) '''
list_of_values = [1.3, 7.1, 7.3, 2.3, 3.9, 4.1, 7.8, 1.2, 4.3, 7.3, 5.0, 4.3]
breaks = jenkspy.jenks_breaks(list_of_values, nb_class=3)
print(breaks)
The running result is correct :
版权声明
本文为[Be happy to study today]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204230545528196.html
边栏推荐
- C1小笔记【任务训练篇二】
- Process management command
- Re expression régulière
- Anchor location - how to set the distance between the anchor and the top of the page. The anchor is located and offset from the top
- Chrome浏览器的跨域设置----包含新老版本两种设置
- Nat commun | current progress and open challenges of applied deep learning in Bioscience
- Cross domain settings of Chrome browser -- including new and old versions
- ES6
- positioner
- C byte array (byte []) and string are converted to each other
猜你喜欢
.105Location
cv_ Solution of mismatch between bridge and opencv
Applet learning notes (I)
.104History
JS forms the items with the same name in the array object into the same array according to the name
On the problem of V-IF display and hiding
开源按键组件Multi_Button的使用,含测试工程
Go的Gin框架学习
JS parsing and execution process
Clion installation tutorial
随机推荐
Timestamp to formatted date
Excel opens large CSV format data
Classes and objects
C# 网络相关操作
纳米技术+AI赋能蛋白质组学|珞米生命科技完成近千万美元融资
Listen for click events other than an element
C byte array (byte []) and string are converted to each other
[UDS unified diagnostic service] (Supplement) v. detailed explanation of ECU bootloader development points (1)
Encapsulate a timestamp to date method on string prototype
2022制冷与空调设备运行操作判断题及答案
Flask项目的部署详解
_ FindText error
In JS, t, = > Analysis of
Clion installation tutorial
re正则表达式
[UDS unified diagnostic service] v. diagnostic application example: Flash bootloader
Gets the time range of the current week
Re expression régulière
Go's gin framework learning
Add animation to the picture under V-for timing