Author(s): Rebecca Vandewalle
This notebook gently introduces Python coding and interactive web map development with the Folium package. This lesson is intended for young learners (middle school to high school). Materials in this notebook were developed by Rebecca Vandewalle for the NSF funded I-STEM Nobel Project (see https://www.istem.illinois.edu/news/nobel.project.2021.html).
Keywords: Mapping, introduction, Nobel Project
University of Illinois at Urbana-Champaign
(for viewing purpose only)
The purpose of this website, https://cybergisxhub.cigi.illinois.edu/ is to provide information to You related to “CyberGISX Project” (“Project”). This Project aims to enable open access and sharing of computation- and data-intensive geospatial analytics, under Apache 2.0 license agreement. The initial version of the Project (“Original Project”), was developed by the CyberGIS Center for Advanced Digital and Spatial Studies (CyberGIS Center) and is solely owned by The Board of Trustees of the Illinois of Illinois. The Site and its content is made available by the Board of Trustees of the Illinois of Illinois (“Illinois”, “we”, “our”, “us”), on behalf of the CyberGIS Center. The Site is owned by the Illinois.
The Terms are governed by Illinois’s web privacy notices and policy links presented here:
You hereby accept that all intellectual property, including copyrights, and other proprietary rights in or related to Original Project and Site are, and will remain, the exclusive property of Illinois, whether or not specifically recognized or perfected under applicable law. As End User, You will not take any action that jeopardizes Illinois’s proprietary rights.
You agree to credit and attribute the authors and creators of Project that You use with the copyright notice or statement of credit/attribution as customarily acceptable in industry.
In no event shall Illinois or its employees be liable for any damages (including, without limitation, damages for loss of data or profit, or due to business interruption) arising out of the use or inability to use the content on Site, even if Illinois or a Illinois authorized representative has been notified orally or in writing of the possibility of such damage. Because some jurisdictions do not allow limitations on implied warranties, or limitations of liability for consequential or incidental damages, these limitations may not apply to you.
Illinois reserves the right to modify the Site and may discontinue, temporarily or permanently, the Site for any reason, at its sole discretion, with or without notice to You. Illinois may likewise change the Terms from time to time with or without notice to you. You agree to review the Terms periodically to ensure that you are aware of any modifications. Your continued access to the Site after the modifications have become effective shall be deemed your conclusive acceptance of the modified Terms.
If you violate or fail to comply with any of these Terms or in Illinois’ sole discretion restrict or inhibit any other user from using or enjoying the Site, Illinois may terminate your access to the Site account without notice to You.
Version 1.0 February 9, 2021
Thank you for your interest in contributing to the CyberGISX Project. In order to contribute, you will need to provide your name and contact information and sign this CyberGISX Project Contributor License Agreement, which sets the terms and conditions of the intellectual property license granted with your contributions.
This CyberGISX Project Contributor License Agreement (“Agreement”) is by and between you, any person or entity (“You” or “Your”) and the Board of Trustees of the University of Illinois, a body corporate and politic of the State of Illinois (“Illinois”). Please read this document carefully before signing and keep a copy for your records. By signing this Agreement or making a “Contribution” to the “CyberGISX Project” as defined below (even if You do not sign), You agree to the following:
1. “CyberGISX Project” is an open-source software project that aims to enable open access and sharing of computation- and data-intensive geospatial analytics with computational reproducibility and transparency support available under Apache 2.0 license agreement: https://www.apache.org/licenses/LICENSE-2.0
2. “Contribution” means all of Your contributions of object code, source code, content, and documentation, and any modifications thereof, to the CyberGISX Project.
3. “Licensed Patents” mean patent claims licensable by You which are necessarily infringed by the making, using, selling, offering for sale, having made, import, or transfer of either Your Contribution alone or when combined with the CyberGISX Project.
4. “Representation.” You represent the following to the best of your knowledge:
a. You are at least 18 years of age and have full power and authority to enter into this Agreement and to grant the rights in and to the Contribution as set forth herein (individuals who are under 18 years of age and who wish to contribute to the CyberGISX project may not enter into this Agreement, but may contact CyberGISX at firstname.lastname@example.org to explore alternatives);
b. If your employer has rights to intellectual property that You create as part of the Contribution, You represent that You have obtained permission from Your employer to make the Contribution on behalf of that employer, or Your employer waived any rights in and to Your Contribution, or Your employer authorizes the Contribution and agrees to be bound by the terms herein by signing as an entity below;
c. That either:
1. all documentation and code in the Contribution is Your original work and includes complete details of any third-party license and any other restriction (including, but not limited to related patents and trademarks) of which You are personally aware and which are associated with any part of Your Contributions; or
2. any part of the Contribution that is not Your original creation is submitted to CyberGISX separately from any original Contribution, includes the complete details of its source and any corresponding license and any other restriction (including, but not limited to related patents, trademarks, and license agreements) of which You are personally aware, and is conspicuously marked as "Submitted on behalf of a third party: [named here]".
d. That Your Contribution does not include any viruses, worms, Trojan horses, malicious code or other harmful or destructive content;
e. The CyberGISX Project delivered under this Agreement may be subject to U.S. export control laws and may be subject to export or import regulations in other countries. You agree to comply strictly with all such laws and regulations and acknowledge that You have the responsibility, at Your own expense, to obtain such licenses to export, re-export, or import as may be required; and
f. Your Contribution does not include any encryption technology and no government license or permission is required for the export, import, transfer or use of the Contribution.
5. Notification. Your representations are accurate, and You agree to notify Illinois of any facts or circumstances of which You become aware that would make any of Your representations inaccurate in any respect.
6. License grant to Contributions. You grant to Illinois and to recipients of the CyberGISX software (collectively, “Recipients”), a perpetual, irrevocable, non-exclusive, worldwide, royalty-free unrestricted license to use, reproduce, prepare derivative works of, publicly display, publicly perform, distribute, and sublicense the Contribution, and such derivative works, in source code and object code forms.
7. License grant to Patents.
8. No support. Except for the rights granted to Recipients above, You reserve all right, title, and interest in and to Your Contribution. You are not expected to provide support for your Contributions.
9. No Warranties. Subject to Your representations above, Your Contributions are provided on an “AS-IS” basis WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND (express or implied), including, without limitation, any implied warranty of merchantability and fitness for a particular purpose, and any warranty of non-infringement.
10. No Liability. Illinois, its trustees, directors, officers, employees, students, and agents have no liability for any infringement of any copyright, patent, or other right of third parties in connection with any Contributions, the CyberGISX Project, or CyberGISX software, and are not liable for any direct, indirect, punitive, special, incidental, consequential, or exemplary damages arising in connection with any Contribution, the CyberGISX Project, or CyberGISX software.
11. Indemnity. You agree to indemnify, defend, and hold Illinois and its subsidiaries, affiliates, officers, agents, employees, partners, licensees, and licensors harmless from any claim or demand, including but not limited to reasonable attorneys’ fees, made by any third party due to or arising out of Contributions You submit, post, transmit or otherwise make available through the CyberGISX Project, as well as Your use of the CyberGISX software; connection to the CyberGISX Project; or violation of any rights of another.
12. You agree that Illinois may assign this Agreement and CyberGISX Project to any third party without notice or consent.
13. Illinois is under no obligation to accept or include Your Contribution to the CyberGISX Project.
14. This Agreement is governed by the laws of the State of Illinois, excluding its conflict of laws provisions.
Declaix commented on November 22, 2020 at 11:19 am
thanks for this page. I spent a lot of time before finding a clear and helpful explanation of how to add a text via folium.
The problem I have now : I want to add a python string by name, a variable, not a ‘constant’ string. Like for example ” a = ‘sss'” : I want to put “a”, not “sss” in the HTML text.
Is it possible ?
beckvalle commented on November 23, 2020 at 10:54 am
You could use something like the following to store your variable name as a text string to be able to use in the HTML. However, this is clunky and it is often better to simply type “a” directly into the HTML, or figure out a way to store the information you need as the variable data not the variable name.
a = “sss”
variable_name = [k for k, v in locals().items() if v == “sss”]
Code from: https://www.codespeedy.com/get-a-variable-name-as-a-string-in-python/
BRADLEY commented on January 27, 2021 at 10:38 pm
This article is very helpful and grateful. Thank you for sharing awesome article.