摘要:1. automagic IPython中提供了一些以%开头的特殊命令,我们称这些命令为Magic Command。它可以认为是IPython系统中的命令行程序,使用?可以查看其选项。if automagic is on, Magic Command也可以不带百分号直接使用,只要没有定义与其同名的变
阅读全文
摘要:1. chr is to get the character, ord can get the order(unicode)chr(11035)=chr(0x2B1B)='\u2B1B' black square; 2B1A white squareint('2B1B',16)=11035 2. s
阅读全文
摘要:1. from timeit import timeit计算程序运行时间 比如: timeit(list(range(1000))) 2. if we using jupyter it will keep ranning for many times and giving the average t
阅读全文
摘要:Topology1. toplology is to describe connectivity between spatial features, which is a collection of rules that coupled with a set of editing tools and
阅读全文
摘要:surface models 1. The two main methods of creating surface models are interpolation and triangulation interpolation: we use it to help developing 3D s
阅读全文
摘要:break将退出整个循环 l=[3,4,5,6,7,8] for i in l: if i ==5: break print(i) 3 4 continue将退出当前循环 l=[3,4,5,6,7,8] for i in l: if i ==5: continue print(i) 3 4 6 7
阅读全文
摘要:1. ''' '''the comment in the middle will be shown in your code while ranning 2. a=bc=a%bor we can simplify them into:a, c=b, a%b 3. while we wanna tes
阅读全文
摘要:1. break语句和continue语句都可以在循环中使用,且常与选择结构结合使用,以达到在特定条件满足时跳出循环的作用。break语句被执行,可以使整个循环提前结束。而continue语句的作用是结束本次循环,回到循环的最开始然后进入下一次循环 2. ValueError try...excep
阅读全文
摘要:1. Coordinate(坐标) data for GIS real coordinate system:Cartesian coordinate systems(笛卡尔坐标系)
阅读全文
摘要:1. 在print结尾处添加end='' print默认在字符串结尾处添加换行符,添加end=''后表示这个语句并没有结束,结尾不换行 2. 为了减少重复代码以及便于修改,我们可以编写函数 1) 函数编写中出现的问题只有在调用并执行该函数时才能被发现 2) def 函数名(形参列表, 可以不写,多个
阅读全文
摘要:最近三天的时间都花在重新更新系统等事情上,纯属人祸,故总结如下供今后参考。 1. 安装程序不应该与安装之后的软件安装在同一个文件夹内,便于管理,且两个文件夹都不能用中文命名。 2. 一定不要傻到直接修改文件夹的名字。 3. 删除软件时先将软件卸载,再删除安装软件。 4.安装过程中一直出现问题,可以尝
阅读全文
摘要:Principles of GIS( UNSW Metternicht ) outline:data input data management data manipulation+data analysis spatial modelling Definition 1. GIS is a tool
阅读全文
摘要:有关yield的用法简介以及图灵机 第一节课大体没有太大变化,前半节课为了给图灵机的讲解做铺垫引入了yield。数组、字符串和文件等都是一个可迭代的对象,但由于它们的所有数据都存储与内存中,对内存的消耗过大,借此引用generator生成器,其工作原理是重复调用next()方法,直到捕获一个异常。
阅读全文