Grow Together
Generate meaningful discussions with your audience and build a strong, loyal community. Think of the insightful conversations you miss out on with a feedback form.
Huddle re-imagines the way we build communities. You have a voice, but so does your audience. Create connections with your users as you engage in genuine discussion.
Generate meaningful discussions with your audience and build a strong, loyal community. Think of the insightful conversations you miss out on with a feedback form.
You wouldn't paginate a conversation in real life, so why do it online? Our threads have just-in-time loading for a more natural flow.
It takes no time at all to integrate Huddle with your app's authentication solution. This means, once signed in to your app, your users can start chatting immediately.


Collector
After page reload all changes will be lost. To save them edit list in
'empl.js'
file
Sum ($):
7
10
20


Name Surname
Status: Not verified
Token amount: 876 LSD
ICO
Verification
Buy tokens
Referral Program
Settings
toggle menu
Unfortunately your profile is not verified yet.
WHITE PAPER CONDITIONS
please read the white paper and agree to the proposed conditions
Read the white paper
I agree with the terms of use
Drag and drop the image of your ID accepted formats: jpg, jpeg, png, svg, pdf, zip, rar
Full name
Phone
Date of birth
Day
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
Month
Year
ZIP Code


Edit Profile
Delete User
{{#if email}}{{email}}{{/if}}
Age: {{age}} Shirt size: {{shirtSize}}
Home phone: {{homePhone}} Mobile phone: {{mobilePhone}}
Notes: {{notes}}
Are you sure you wish to delete this user? This operation will remove their user account, any associated volunteer details, and any tournament registrations. This can not be undone.


Grid based design is a design of webpage with layout using pre-made grid classes. '.row' class is just one row of 100% of width of the page, and there are 12 '.column' classes with width of 1/12 to 12/12. 12 columns can useful to divide the page into 2, 3, or 4 which is very handy when making layout with different sized boxes.
When a webpage is responsive, the contents in the page changes size depend on the screen size. Hence, the website can be opened with different kinds of devices like tablet PC or smart phone without any problem.
HTML has many semantic tags such as header, paragraph, division, etc. and they provide information about the each content on the page. For example, h1, h2, h3 are all heading tags but h1 is larger heading than h2 and h2 is larger heading than h3. The web browser understands it and shows different font size automatically. Semantic tags are communication between the code and the website.
I didn't know there would be a website like for place holder. It's sad that dog one is not working but kitten is cute too :) Google font and Bootstrap will be useful too.


SONSHINE
MINISTRIES
SPECIALIZED
CAMPING
WE ARE SONSHINE
We work with your leadership to custom tailor the most incredible week on your ministry calendar. The combination of your leadership, our equipment and staff, along with the incredible power of God’s Spirit makes it happen year after year.
2018 REGISTRATION
Reservations for the 2018 season has begun. Be sure to contact our office and reserve a trip today! Once again we are fully committed to making your 2018 houseboat trip another incredible experience.
Learn more about the registration process.
CONTACT US
SONSHINE MINISTRIES
Sonshine Specialized Camping Ministries
P.O. Box 1527 Woodbridge, CA 95258
209-367-0212 (phone)
209-368-1662 (fax)
Report Bug


| Invoice # | 6859 |
| Date of Invoice | 01-24-2012 |
| Due Date | 02-10-2012 |
| Item & Description | Quantity | Price |
|---|---|---|
| Single License 12 Months @ Sanityos.com | 1 | |
| Amounts in words |
| Subtotal: | ||
|---|---|---|
| Discount/Voucher | % | |
| Total: |
This invoice contains details of your purchase for using SanityOS.com. Your license expiration date can be found under "your profile" in your account.
For support and guidance on using Sanityos.com please refer to the Help Topics section.
Should you wish to bla bla bla.


Russia gives back three seized Ukraine ships, says foreign ministry
MOSCOW, Nov 18 — Russia said today it had handed back three Ukrainian naval ships seized off the Crimean coast a year ago, but Kiev did not immediately confirm the move.
“On November 18 the handover took place to the Ukrainian side of three Ukraine naval ships that illegally crossed the Russian border in November 2018,” the foreign ministry said in a statement.
However, Ukrainian Navy spokesman Oleg Chalyk told AFP: “We are not commenting at this stage.”
In November 2018, Russian forces boarded and took control of the ships as they headed through the Kerch Strait, a narrow waterway leading to the Sea of Azov that is used by Ukraine and Russia.
The seizure of the two gunboats and a tugboat was the most serious confrontation between the two countries since the start of the Ukraine conflict in 2014.
Russia captured 24 Ukrainian sailors, who were returned to Ukraine as part of a prisoner swap in September.
Border officials had said yesterday that the ships would be returned and local television showed footage of them being towed by the Russian coast guard through the Kerch Strait.
The ships had been seized as “evidence,” Moscow said Monday, but added that the handover was possible because investigators no longer needed them.
The Russian ministry maintained that Ukraine had committed a “crime” by ordering its sailors to carry out “provocative actions”.
It added that it would continue to “harshly crack down on any provocations on its borders.” — AFP


|
IM Profile | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.lang.Throwable java.lang.Exception java.io.IOException javax.microedition.pki.CertificateException
The CertificateException
encapsulates an error that
occurred while a Certificate
is being used. If multiple errors
are found within a Certificate
the more significant error
should be reported in the exception.
| Field Summary | |
static byte |
BAD_EXTENSIONS
Indicates a certificate has unrecognized critical extensions. |
static byte |
BROKEN_CHAIN
Indicates a certificate in a chain was not issued by the next authority in the chain. |
static byte |
CERTIFICATE_CHAIN_TOO_LONG
Indicates the server certificate chain exceeds the length allowed by an issuer's policy. |
static byte |
EXPIRED
Indicates a certificate is expired. |
static byte |
INAPPROPRIATE_KEY_USAGE
Indicates a certificate public key has been used in way deemed inappropriate by the issuer. |
static byte |
MISSING_SIGNATURE
Indicates a certificate object does not contain a signature. |
static byte |
NOT_YET_VALID
Indicates a certificate is not yet valid. |
static byte |
ROOT_CA_EXPIRED
Indicates the root CA's public key is expired. |
static byte |
SITENAME_MISMATCH
Indicates a certificate does not contain the correct site name. |
static byte |
UNAUTHORIZED_INTERMEDIATE_CA
Indicates an intermediate certificate in the chain does not have the authority to be a intermediate CA. |
static byte |
UNRECOGNIZED_ISSUER
Indicates a certificate was issued by an unrecognized entity. |
static byte |
UNSUPPORTED_PUBLIC_KEY_TYPE
Indicates that type of the public key in a certificate is not supported by the device. |
static byte |
UNSUPPORTED_SIGALG
Indicates a certificate was signed using an unsupported algorithm. |
static byte |
VERIFICATION_FAILED
Indicates a certificate failed verification. |
| Constructor Summary | |
CertificateException(Certificate certificate,
byte status)
Create a new exception with a Certificate
and specific error reason. |
|
CertificateException(String message,
Certificate certificate,
byte status)
Create a new exception with a message, Certificate ,
and specific error reason. |
| Method Summary | |
Certificate |
getCertificate()
Get the Certificate that caused the exception. |
byte |
getReason()
Get the reason code. |
| Methods inherited from class java.lang.Throwable |
getMessage, printStackTrace, toString |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static final byte BAD_EXTENSIONS
public static final byte CERTIFICATE_CHAIN_TOO_LONG
public static final byte EXPIRED
public static final byte UNAUTHORIZED_INTERMEDIATE_CA
public static final byte MISSING_SIGNATURE
public static final byte NOT_YET_VALID
public static final byte SITENAME_MISMATCH
public static final byte UNRECOGNIZED_ISSUER
public static final byte UNSUPPORTED_SIGALG
public static final byte INAPPROPRIATE_KEY_USAGE
public static final byte BROKEN_CHAIN
public static final byte ROOT_CA_EXPIRED
public static final byte UNSUPPORTED_PUBLIC_KEY_TYPE
public static final byte VERIFICATION_FAILED
| Constructor Detail |
public CertificateException(Certificate certificate, byte status)
Certificate
and specific error reason. The descriptive message for the new exception
will be automatically provided, based on the reason.
certificate
- the certificate that caused the exceptionstatus
- the reason for the exception;
the status MUST be between BAD_EXTENSIONS and VERIFICATION_FAILED
inclusive.public CertificateException(String message, Certificate certificate, byte status)
Certificate
,
and specific error reason.
message
- a descriptive messagecertificate
- the certificate that caused the exceptionstatus
- the reason for the exception;
the status MUST be between BAD_EXTENSIONS and VERIFICATION_FAILED
inclusive.| Method Detail |
public Certificate getCertificate()
Certificate
that caused the exception.
Certificate
that included the failure.public byte getReason()
|
IM Profile | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |


#include <OISInputManager.h>
Base Manager class. No longer a Singleton; so feel free to create as many InputManager's as you have windows.
◆ AddOnFactories
All generic devices OIS supports internally (if they are compiled in)
| Enumerator |
|---|
| AddOn_All | |
| AddOn_LIRC | |
| AddOn_WiiMote | |
◆ InputManager()
| InputManager::InputManager |
( |
const std::string & |
name | ) |
|
|
explicitprotected |
◆ ~InputManager()
| InputManager::~InputManager |
( |
| ) |
|
|
protectedvirtual |
◆ _initialize()
| virtual void OIS::InputManager::_initialize |
( |
ParamList & |
paramList | ) |
|
|
protectedpure virtual |
◆ addFactoryCreator()
- Parameters
-
| factory | Factory instance to add Make sure you do not delete the factory before devices created from the factory are destroyed (either by calling RemoveFactoryCreator, or shutting down the input system). Order should be something like the following: Create Input System Create Factory Instance AddFactoryCreator(factory) Create a device from the InputManager (device created by factory) One of the follwoing: removeFactoryCreator(factory) inputManager->destroyInputObject(obj) destroyInputSystem(inputManager) destroy Factory Instance You can safely delete the factory instance once you have removed it or shut down the input manager. |
◆ createInputObject()
| Object * InputManager::createInputObject |
( |
Type |
iType, |
|
|
bool |
bufferMode, |
|
|
const std::string & |
vendor = "" |
|
) |
| |
◆ createInputSystem() [1/2]
| InputManager * InputManager::createInputSystem |
( |
std::size_t |
winHandle | ) |
|
|
static |
- Parameters
-
| winHandle | Contains OS specific window handle (such as HWND or X11 Window) |
- Returns
- A pointer to the created manager, or raises Exception
◆ createInputSystem() [2/2]
- Parameters
-
| paramList | ParamList contains OS specific info (such as HWND and HINSTANCE for window apps), and access mode. |
- Returns
- A pointer to the created manager, or raises Exception
◆ destroyInputObject()
| void InputManager::destroyInputObject |
( |
Object * |
obj | ) |
|
◆ destroyInputSystem()
| void InputManager::destroyInputSystem |
( |
InputManager * |
manager | ) |
|
|
static |
- Parameters
-
| manager | Manager to destroy |
◆ enableAddOnFactory()
◆ getNumberOfDevices()
| int InputManager::getNumberOfDevices |
( |
Type |
iType | ) |
|
- Parameters
-
| iType | Type that you are interested in |
◆ getVersionName()
| const std::string & InputManager::getVersionName |
( |
| ) |
|
◆ getVersionNumber()
| unsigned int InputManager::getVersionNumber |
( |
| ) |
|
|
static |
- Returns
- Bits: 1-8 Patch number, 9-16 Minor version, 17-32 Major version
◆ inputSystemName()
| const std::string & InputManager::inputSystemName |
( |
| ) |
|
◆ listFreeDevices()
- Returns
- DeviceList which contains Type and vendor of device
◆ removeFactoryCreator()
- Parameters
-
| factory | Factory object to remove. Removing a factory will automatically destroy any Objects created from the factory |
◆ m_lircSupport
| LIRCFactoryCreator* OIS::InputManager::m_lircSupport |
|
protected |
Extra factory (not enabled by default)
◆ m_VersionName
| const std::string OIS::InputManager::m_VersionName |
|
protected |
◆ m_wiiMoteSupport
| WiiMoteFactoryCreator* OIS::InputManager::m_wiiMoteSupport |
|
protected |
◆ mFactories
◆ mFactoryObjects
Factory created objects - useful so we can find creator to send destruction request to.
◆ mInputSystemName
| const std::string OIS::InputManager::mInputSystemName |
|
protected |
Name of the input system.
The documentation for this class was generated from the following files:


| load_schedules {nflreadr} | R Documentation |
This returns game/schedule information as maintained by Lee Sharpe.
load_schedules(seasons = TRUE)
seasons |
a numeric vector of seasons to return, default |
A tibble of game information for past and/or future games.
https://github.com/nflverse/nfldata/blob/master/DATASETS.md#games
dictionary_schedules
for the data dictionary as a dataframe
vignette("Data Dictionary - Schedules")
for the data dictionary as a vignette
load_schedules(2020)


This is where i will be talking about programming in this chapter
Computer programming is the process of designing and building an executable computer program to accomplish a specific computing result or to perform a specific task.Programming involves tasks such as: analysis, generating algorithms, profiling algorithms' accuracy and resource consumption, and the implementation
of algorithms in a chosen programming language (commonly referred to as coding).[1][2] The source code of a program is written in one or more languages that are intelligible
to programmers, rather than machine code, which is directly executed by the central processing unit. The purpose of programming is to find a sequence
of instructions that will automate the performance of a task (which can be as complex as an operating system) on a computer, often for solving a given problem.
Proficient programming thus often requires expertise in several different subjects, including knowledge of the application domain, specialized algorithms, and formal logic.


ADDRESS: 701 15th Ave, New York, NY 10001
EMAIL<EMAIL_ADDRESS>PHONE: +1<PHONE_NUMBER>
ADDRESS: 701 15th Ave, New York, NY 10001
EMAIL<EMAIL_ADDRESS>PHONE: +1<PHONE_NUMBER>
We'd love to hear from you.
Send us a message and we'll respond as soon as possible.


Vienna
Vienna is best city for living on the Earth!
Cuprija
Cuprija is city in middle Serbia where author come from!
Barcelona
Barcelona is the most beautiful city on the Earth!


Welcome to GridSphere!
Thank you for downloading and installing the
GridSphere portal.
Below you will find links to documents relating to GridSphere installation, administration and portlet
development.
-
GridSphere User's Guide
(HTML)
-
GridSphere Portal Administrator's Guide
(HTML)
-
GridSphere Portlet Reference Guide
(HTML)
-
GridSphere Tag Library User's Guide
(HTML)
-
GridSphere Frequently Asked Questions
(HTML)
-
GridSphere JavaDoc API
(HTML)
Please join the forums and/or mailing lists for more involvement:
- GridSphere Forums Online forums for discussions
related to GridSphere and portlet development.
- Developers List
Discussions relating to overall GridSphere and portlet development.
- Users List
Discussions on installing and configuring GridSphere.
- SVN List SVN
commit information. Very useful if you're a developer.
and please submit bug reports to GridSphere (Jira) bugtracker


About us →
Are you a TECH ENTHUSIAST?... a passionate coder💻, developer, or a ML enthusiast.Perhaps a Robo-geek🤖, or an IoT enthusiast .... then yes yes yes.... you are visiting the right site.
WELCOME WELCOME WELCOME!!!!
This is the official website for tech-blogs of ELEKTRONICA, the official Technical wing of NSEC ECE department.A website made solely for the progress of the students of the department, you will find blogs and project ideas and what not! And lets not forget the various events in which you can be a part of , so get ready, put on your coding pants and lets start debugging together!!!


Composite.Image Class
Image Class
Constructor
Item Index
Methods
Attributes
Methods
_getGetAtFunction
()
private
Call this function with the length of each dimension followed by the number of channels. Returns a function which accepts a pixel index and returns an at array.
Returns:
_getGetPixelIndexFunction
()
private
Call this function with the length of each dimension. Returns a function which accepts dimension indices and returns a pixel index.
Returns:
clear
()
chainable
Clears the image. This method is chainable.
conformChannelValue
-
value
-
channel
Conforms the given value to the channel's specifications.
Returns:
eachPixel
-
pixelParameters
-
callbackFunction
-
contextObject
Invokes a function for each pixel in the image. This method is chainable.
Parameters:
-
pixelParameters
ObjectThis object contains the following members
- ctx - Object - Optional scope with which to call fn.
-
fn - Function - This function is invoked once per pixel.
This function will receive an object with the following
parameters
- at - Array of image pixel coordinates.
- chs - Array of image channel definitions.
- dims - Array of image dimension lengths.
- img - Reference to this image.
- pch - Array of pixel channel indices.
- pcnt - Number of pixels in this image.
- pix - Integer index of this pixel.
- pxl - Array of pixel channel values.
- pch - Array - Optional array of channel indexes. If undefined, pixels will contain all channels in order.
-
callbackFunction
FunctionThis function is invoked after the function has been invoked for each pixel in the image. This function will receive an object with the following members
- chs - Array of image channel definitions.
- dims - Array of image dimension lengths.
- img - Reference to this image.
- pcnt - Number of pixels in this image.
- pix - The last integer pixel index processed. If eachPixel was not stopped early, this value should be equal to pcnt and not a valid pixel index.
-
contextObject
ObjectOptional scope with which to call the callback function.
getAt
-
pixelIndex
Converts a pixel index to an at array.
Parameters:
-
pixelIndex
Number
Returns:
getPixel
-
at
-
pixelChannels
Accessor method to get a pixel from the image.
Parameters:
Returns:
setPixel
-
at
-
pixel
-
pixelChannels
Accessor method to set a pixel in the image. This method is chainable.
Parameters:
-
at
ArrayArray containing pixel coordinates. The length of this array should match the number of dimensions of the image.
-
pixel
ArrayArray containing the pixel's channel values.
-
pixelChannels
ArrayOptional array of channel indexes. If undefined, the given pixel is assumed to contain all channels in order.
Attributes
channels
Array
Defines the color space for the image.
An image can have as many channels as needed. 3 or 4 channels is most common. Usually the first channel is the red color component, the second is green, the third is blue, and the fourth is alpha.
There are various ways to represent the value of a channel. Values can either be stored as integers or floating-point numbers. Values may be constrained within a minimum and maximum value.
Most commonly red, green, and blue channels are represented by integers between 0 and 255. In this case the values 0, 0, 0 represent black and the values 255, 255, 255 represent white.
The alpha channel is commonly stored as a floating-point value from 0 to 1. 1 represents a completely visible pixel while 0 is completely transparent.
Values are not required to be constrained. For example, sometimes it is interesting or useful to store colors which have brightness beyond white.
This attribute should be set to an array of objects. This array represents the channels in order. This array should have at least one element. This should not be a sparse array. Each object must have a mode property. The mode property must be set to either 'f' for floating-point values or 'i' for integer values. Each object may include the optional maximum and/or minimum properties. Each object may include the optional blackValue and/or whiteValue properties. If undefined, blackValue will default to 0 and whiteValue will default to 255 when mode is set to 'i' or 1 otherwise.
Default: [ {maximum: 255, minimum: 0, mode:'i'}, {maximum: 255, minimum: 0, mode:'i'}, {maximum: 255, minimum: 0, mode:'i'}, {maximum: 1, minimum: 0, mode:'f'} ]
Fires event channelsChange
Fires when the value for the configuration attribute channels
is
changed. You can listen for the event using the on
method if you
wish to be notified before the attribute's value has changed, or
using the after
method if you wish to be notified after the
attribute's value has changed.
Parameters:
-
e
EventFacadeAn Event Facade object with the following attribute-specific properties added:
dimensions
Array
Defines the pixel dimensions of the image.
An image can have as many dimensions as needed. 2 dimensions is most common. Usually the first dimension is width and the second is height.
Default: [512, 512]
Fires event dimensionsChange
Fires when the value for the configuration attribute dimensions
is
changed. You can listen for the event using the on
method if you
wish to be notified before the attribute's value has changed, or
using the after
method if you wish to be notified after the
attribute's value has changed.
Parameters:
-
e
EventFacadeAn Event Facade object with the following attribute-specific properties added:
pixelCount
Number
Contains the number of pixels in the image.
Fires event pixelCountChange
Fires when the value for the configuration attribute pixelCount
is
changed. You can listen for the event using the on
method if you
wish to be notified before the attribute's value has changed, or
using the after
method if you wish to be notified after the
attribute's value has changed.
Parameters:
-
e
EventFacadeAn Event Facade object with the following attribute-specific properties added:


Strategy & Performance
Supply Chain Intelligence
Processes & Digitalisation
Procurement Contracts
Risk Mgmt, Regulations & Sustainability
QMS, surveillance & Requirement
Supplier Development
QUEST
Supply Quality Fr Uk Spain & Germany & Quality BP for BLs
A400M
CIS
ENS & Orbital
MRITT & M&L
Telecoms
Combat AC & UAVs
Commodities/SubCommodities |
||
|---|---|---|
Systems & EquipmentFlight Systems Platform Systems Propulsion Mission Systems |
Structures & MaterialsA/C Sattelites Assemblies Detail Parts Raw Materials |
Services & ITEquipment Support Services Operational & Ground Services MRO & FAL Support Services Training Services & Simulators IT & Software |
Spain
Germany
France
UK


{% extends "global/Page.html" %} {% load otree static %} {% block title %} Welcome to LEEPS Online Laboratory! {% endblock %} {% block content %}
Welcome, and thank you for participating!
From now until the end of the experiment, please stay focused on the task at hand, as your payment highly depends on your performance in the experiment. If you have any questions, please send the host a private message; the experimenter will answer your question. Please pay careful attention to the instructions as real money is at stake. Please also remember to open the session link with Chrome because other browsers may cause problems.
During the experiment, you will earn points in each round. At the end of the experiment, one round will be randomly chosen, from which your points will be converted to US dollars at the rate specified in the instructions Zoom call. You are guaranteed a show-up fee of $4.00 but can earn considerably more.
When you finish reading, please press next and start to read the instruction.
{% next_button %} {% endblock %}


--- layout: post title: 'Google Voice Blog: Google Voice for everyone' categories: [] tags: - google - google_voice - voice status: publish type: post published: true meta: _original_post_id: '' _original_import_author: John Duprey author: ---
Yay! Google voice is now open to the public! It provides all the feature you expect in your other communication mediums e-mail/IM/etc. for your phone! Its free. Give it a try.


CrimPapers
Articles published on 5 November 2018
On 5 November 2018, 6 new articles were published in 6 journals.
From Child Maltreatment to Adolescent Substance Use: Different Pathways For Males and Females? by Kristen M. Benedini, Abigail A. Fagan
Self-Legitimacy and Use of Force: A Quantitative Study of Prison Officers in Slovenia by Gorazd Meško, Rok Hacin
Challenging Assumptions: A Genetically Sensitive Assessment of the Criminogenic Effect of Contact With the Criminal Justice System by Joseph L. Nedelec, Ian A. Silver
Frameworks For Credible Causal Inference in Observational Studies of Family Violence
Embedding Learning and Assessment Within Police Practice: the Opportunities and Challenges Arising From the Introduction of the Peqf in England and Wales
Brazilian Criminal Organizations As Transnational Violent Non-State Actors: A Case Study of the Primeiro Comando da Capital (pcc)


What do people tweet?
Draw their feelings on a map
to find the answer.
In this project, you will develop a geographic visualization of twitter data across the USA. You will need to use dictionaries, lists, and data abstraction techniques to create a modular program. This project uses ideas from Sections 2.1-2.4 of the lecture notes.
The map displayed above depicts how the people in different states feel about Texas. This image is generated by:
The details of how to conduct each of these steps is contained within the project description. By the end of this project, you will be able to map the sentiment of any word or phrase. There are two alternative zip archives related to this project:
The project uses several files, but all of your changes will be made to the first one.
|
A starter implementation of the main project file. |
|
|
Geographic positions, 2-D projection equations, and geographic distance functions. |
|
|
Functions for drawing maps. |
|
|
Functions for loading Twitter data from files. |
|
|
A simple Python graphics library. |
|
|
Utility functions for 61A. |
This is a one-week project. You'll work in a team of two people, and you can complete all problems together with your partner.
Start early! Feel free to ask for help early and often. The course staff is here to assist you, but we can't help everyone an hour before the deadline. Piazza awaits. You are not alone!
In the end, you and your partner will submit one project. There are 19 possible
points (16 for correctness and 3 for composition). You only need to submit the
file trends.py
. You do not need to modify any other files for this
project. To submit the project, change to the directory where the
trends.py
file is located and run submit proj2
.
In this phase, you will create an abstract data type for tweets, split the text of a tweet into words, and calculate the amount of positive or negative feeling in a tweet.
First, you will implement an abstract data type for Tweets. The constructor
make_tweet
is defined at the top of trends.py
.
make_tweet
returns a python dictionary with
the following entries:
text: a string, the text of the tweet, all in lowercase time: a datetime object, when the tweet was posted latitude: a floating-point number, the latitude of the tweet's location longitude: a floating-point number, the longitude of the tweet's location
Problem 1 (1 pt). Implement the tweet_words
and
tweet_time
selectors. Call extract_words
to list the
words in the text of a tweet.
Problem 2 (1 pt). Implement the tweet_location
selector,
which returns a position
. Positions are another abstract data
type, defined at the top of geo.py
. Make sure that you understand
how to manipulate positions; they play an important role in this project.
When you complete problems 1 and 2, the doctest for make_tweet
should pass.
python3 trends.py -t make_tweet
Problem 3 (1 pt). Improve the extract_words
function as follows: Assume that a word is any consecutive substring of
text
that consists only of ASCII letters. The string
ascii_letters
in the string
module contains all
letters in the ASCII character set. The extract_words
function
should list all such words in order and nothing else.
When you complete this problem, the doctest for extract_words
should pass.
python3 trends.py -t extract_words
Problem 4 (1 pt). Implement the sentiment abstract data type, which
represents a sentiment value that may or may not exist. The constructor
make_sentiment
takes either a numeric value within the interval -1
to 1, or None
to indicate that the value does not exist. Implement
the selectors has_sentiment
and sentiment_value
as
well. You may use any representation you choose, but the rest of your
program should not depend on this representation.
When you complete this problem, the doctests for make_sentiment
and get_word_sentiment
should pass. You can also call the
print_sentiment
function to print the sentiment values of all
sentiment-carrying words in a line of text.
python3 trends.py -t make_sentiment python3 trends.py -t get_word_sentiment python3 trends.py -p computer science is my favorite! python3 trends.py -p life without lambda: awful or awesome?
Problem 5 (1 pt). Implement analyze_tweet_sentiment
,
which takes a tweet (of the abstract data type) and returns a
sentiment
. Read the docstrings for
get_word_sentiment
and analyze_tweet_sentiment
to
understand how the two functions interact. Your implementation should not
depend on the representation of a sentiment!.
When you complete this problem, the doctests for
analyze_tweet_sentiment
should pass.
python3 trends.py -t analyze_tweet_sentiment
We will use the position abstract data type to represent geographic
latitude-longitude positions on the Earth. The data abstraction, defined at the
top of geo.py
, has the constructor make_position
and
the selectors latitude
and longitude
.
In this phase, you will write two functions that together determine the centers of U.S. states. The shape of a state is represented as a list of polygons. Some states (e.g. Hawaii) consist of multiple polygons, but most states (e.g. Colorado) consist of only one polygon (still represented as a length-one list).
Problem 6 (2 pt). Implement find_centroid
, which takes a
polygon and returns three values: the coordinates of its centroid and its area.
The input polygon is represented as a list of position
abstract
data types, which are the consecutive vertices of its perimeter. The first
vertex is always identical to the last.
The centroid of a two-dimensional shape is its center of balance, defined as
the intersection of all straight lines that evenly divide the shape into
equal-area halves. find_centroid
returns the centroid and area of
an individual polygon.
The formula for computing the centroid of a polygon appears on Wikipedia. The formula relies on vertices being consecutive (either clockwise or counterclockwise; both give the same answer), a property that you may assume always holds for the input.
When you complete this problem, the doctest for find_centroid
should pass.
python3 trends.py -t find_centroid
Problem 7 (2 pt). Implement find_center
, which takes a
shape represented by a list of polygons and returns a position, its centroid.
The centroid of a collection of polygons can be computed by geometric decomposition. The centroid of a shape is the weighted average of the centroids of its component polygons, weighted by their area.
When you complete this problem, the doctest for find_center
should pass.
python3 trends.py -t find_center
Once you are finished, draw_centered_map
will draw the
10
states closest to a given state (including that state).
python3 trends.py -d CA
The name us_states
is bound to a dictionary containing the
shape of each U.S. state, keyed by its two-letter postal code. You can use
the keys of this dictionary to iterate over all the U.S. states.
In this phase, you will write functions to determine the state that a tweet is coming from, group tweets by state, and calculate the average positive or negative feeling in all the tweets associated with a state.
Problem 8 (1 pt). Implement find_closest_state
, which
returns the two-letter postal code of the state that is closest to the location
of a tweet. Use the geo_distance
function (provided in
geo.py
) to calculate the shortest distance in miles between two
positions.
When you complete this problem, the doctests for
find_closest_state
should pass.
python3 trends.py -t find_closest_state
Problem 9 (1 pt). Implement group_tweets_by_state
, which
takes a sequence of tweets and returns a dictionary. The keys of the returned
dictionary are state names (two-letter postal codes), and the values are lists
of tweets that appear closer to that state's center than any other.
When you complete this problem, the doctests for
group_tweets_by_state
should pass.
python3 trends.py -t group_tweets_by_state
Problem 10 (1 pt). As an exercise, implement
most_talkative_state
, which returns the state containing the
most tweets containing a given term.
When you complete this problem, the doctests for
most_talkative_state
should pass.
python3 trends.py -t most_talkative_state
Problem 11 (2 pt). Implement average_sentiments
. This
function takes the dictionary returned by group_tweets_by_state
and also returns a dictionary. The keys of the returned dictionary are the
state names (two-letter postal codes), and the values are average sentiment
values for all the tweets in that state.
If a state has no tweets with sentiment values, leave it out of the returned dictionary entirely. Do not include a state with no sentiment using a zero sentiment value. Zero represents neutral sentiment, not unknown sentiment. States with unknown sentiment will appear gray, while states with neutral sentiment will appear white.
You should now be able to draw maps that are colored by sentiment corresponding to tweets that contain a given term.
python3 trends.py -m sandwich python3 trends.py -m obama python3 trends.py -m texas python3 trends.py -m my lifeIf you downloaded the small version of the project, you will only be able to map these four terms. If you would like to map any term, you will need to download this Twitter data file and place it in the
data
directory of your project.
In this last section, you will take into account the fourth dimension:
time. Each tweet has a datetime
object, which represents the time
that the tweet was posted.
The provided draw_map_by_hour
function visualizes the tweets
that were posted during each hour of the day. For example, "sandwich" tweets
appear most positive at 10:00pm: late night snack!
Problem 12 (2 pt). Implement group_tweets_by_hour
. which
takes a sequence of tweets and returns a dictionary. The keys of the returned
dictionary are the integers 0 through 23, representing the 24 hours of the day.
The value for each key is a list of the tweets that were posted during that
hour.
To get started, read the online documentation
on datetime
objects. When you are finished, you can visualize the
changing sandwich sentiments over time.
python3 trends.py -b sandwich
Congratulations! One more 61A project completed.
These extensions are optional and ungraded. In this class, you are welcome to program just for fun. If you build something interesting, come to office hours and give us a demo. However, please do not change the behavior or signature of the functions you have already implemented.
:-)
and negative sentiment to sad ones.
find_containing_state
that finds the state that
actually contains a tweet position.
graphics.py
package supports animation. Use the
slide_shape
method to have states and dots slide into place.
Acknowledgements: Aditi Muralidharan developed this project with John DeNero. Hamilton Nguyen extended it.


COMMUNE-IC8
Welcome to COMMUNE-IC8
Please sign in
Invalid username and password.
You have been logged out.
Username
Password
Sign in


?
Use the carousel to define your occasion and click the button to move on
What's the Occasion?
Next Page


Urban heat islands are a phenomenon where surface and air temperature in an urban area is hotter than their rural surroundings.
As an ecosystem we need to adapt. Urban data is important if we want to understand what is going on whith our urban ecosystem. From diagnosis to solutions, urban data is our way to observe our urban ecosystem and understand it.
 Extra sensors to measure levels of CO2, light and others could be added easily.
The aim is that a large amount of these urban boxes send data to Urban Data periodically. In rural areas a mesh net will be deployed using many units. Other devices will be supported. Phones and tablets with a sensor tag, microcontrollers with sensors and connectivity and others.
Urban Data is open source software and hardware. It will follow the standards to make it easy to integrate with other systems.
You can participate by getting an Urban Box to send data either to Urban Data or any other Urban Data based server(s). If you are a developer see our developer's guide. There are other ways you can help us. You can spread the word, cite us, use Urban Data for your research or donate so that we can dedicate more effort and time to this project.
Send an email to contact@urbandata.org


Arrays & Hashes
Salt n Pepper
28 June 2015
As we found with Class and ID, Arrays and Hashes are more similar than different. They hold the same data in the same way. Where they differ is in how you refer to members in the Array or Hash.
Array members are called out by the number of their slot in the array, with [0] calling out the first and [n] or [-1] calling out the last. Since array members are called and ordered by the natural number set, moving through arrays is easily iterative. Pinpointing specific members is clearcut.
What is not so clear is that my_array[3] contains my age. Or is that my IQ? When the array makes sense as a data structure -- perhaps akin to a data table row -- a hash lets you define the callout as any legal object. So you can use a string like "age" and then your code references for this element's value become self-documenting: bar_age = mydata[age]-10. The hash is "ordered" in the same order as the hash objects are added.
An array of Hashes should be effectively the same as a database table, where the array index is the table row number and the the hash is the data values for that row, addressed by their "column" names. Whereas Class and ID are in opposition to one another, Arrays and Hashes work hand in hand.


I agree to the terms and conditions.
Your payment is successful! Please wait while we unlock your code...
{{errorMsg}}


Stories
Opening the way
Growing up in a troubled home in East San Jose, Brandon Vi would often find reasons to stay at school.
He would spend hours in the library combing through books on science, technology, and transportation. He also volunteered in an after-hours program, sometimes staying so late he'd miss the last bus and have to walk 45 minutes home.
Today, Vi, 20 (Crown '17, physics and computer science), is working with a team to implement a mobile app for the Santa Cruz Metropolitan Transit District that may eventually help riders like himself track their bus's arrival in real time.
His work is part of an internship he hopes will open the way for a career as a transportation planner or highway engineer. Without an Alumni Association scholarship, however, the transit district internship might not have been possible.
Instead of finding a minimum-wage job to make ends met, Vi—who also is employed at a computer lab on campus—was able to pursue work that "not only helps me develop personally, but also allows me to give back to the community," he said.
According to Vi, all signs pointed to him not graduating from high school—let alone going on to college. His parents were divorced, their income was low, he lived in a gang-infected neighborhood, and his home life was complicated, he said.
"I had to take care of myself a lot, and I didn't go to a really good high school," he said. But thanks to inspiring teachers and friends who encouraged him to pursue his passion for science and technology, Vi was accepted to several UCs. He chose Santa Cruz for its coastal beauty and the opportunities it offered.
The praise he received from others for his volunteering also gave him confidence to believe in himself, to never give up, and to beat the odds, he said.
"I also believe that persistence, giving 100 percent all the time, and taking risks is very important," he said. "What's the worst that can happen to me?"


| ||
| detail: element | attribute | value |
Data Structure { "typeId": "com.tintri.api.rest.vcommon.dto.rbac.AuthInfo", "authCode": <String>, "test": <Boolean>, "accessToken": <String>, } |
| Name | Type | Description |
|---|---|---|
| accessToken | xsd:string | The access token. This value is not set by the user but is gotten from the token endpoint for use in creating a user session. |
| Name | Type | Description |
|---|---|---|
| authCode | xsd:string | The authorization code response sent to the redirect uri as part of the Authorization Code Grant workflow. |
| test | xsd:boolean | True user authentication without creating a session, used to test the login endpoint Default: False |
| ||
| detail: element | attribute | value |


Arbitrary data (e.g. JSON object) can be saved into the atom and bond data structures. Methods are g(s)etAtomAdditionalData, g(s)etBondAdditionalData. This page shows also the use of the pseudoMark option, custom marker color circle (markerIconColor), custom bond and atom background colors (setAtomBackgroundColors, setBondBackgroundColors), custom size for atom and bond background coloring.
| Import predefined chemical structure to applet: | ||||


Disclaimer: Windows Support is an Independent Service provider for software related issues in desktops, laptops, and peripherals.The brand names, trademarks, logos, company names used in the site belongs to their respective owners and are for representation purposes only. Windows Support recommends support from the respective OEM as similar tech help may be provided by the brand owner site as well.
Support For Windows
By Windows Support
Get Windows support and Windows help by certified Windows Windows professionals. If you have installed latest Windows version or any other Windows product then you need a Windows support professional to help you troubleshoot and fix problems. You can call us anytime and one of our Windows support professional will help you find a solution and get you up and running within no time. We offer Windows premium tech support to users using any of the Windows products. We are always open which ensures you are never left out and one of us will always be with you to help you on all Windows products.
Error installing Windows Windows Update
Office 365 install error
Windows Windows not downloading updates
Windows Windows security pop-ups
Windows Internet Explorer crashes
Windows Windows backup fails
Windows Windows DLL missing error
Windows Unexpected error occurred
These are just some of the remote tech support available through us. If you need detailed information about the same, you can call our Call Center experts, available to serve you round the clock.
- Great service you expect from us
- Qualified and skilled team of technicians
Support from Windows Support Includes:
- Printer & Printing Problems
- Drivers & Software Problems
- Scanning Problems
- Internet Problems
- Antivirus Problems
- Router & Wifi Problems
- Infections Problems
- Sound / Videos / Flash Problems
- Slow Performance Problems
- Unwanted Software & Tools Removal
- Gaming Problems
- Other Software Issues
How We Work
CALL
Dial USA Toll Free 24X7
CONNECT
Allow our tech support experts to securely access your PC over the internet.
RELAX
Our experts will fix your problem right before your eyes and be right there on the phone.


|
Basic Search Engine
For the purpose of learning we are creating a basic search engine using inverted index
|
The primary purpose of this assignment is to get familiar with the basic term generation, indexing, and query processing algorithms and use them to implement a simple search engine.
You will build your search engine with the given skeleton code in Python and test on the Cranfield Dataset http://web1.cs.wright.edu/~tkprasad/courses/cs7800/asg-S16/CranfieldDataset.zip. You can work individually or in a two-person team.
Project is running Python 3.7
The preprocessing steps include
Easiest way to do this is using Extent Index.
These steps are shared by both indexing and query processing. Thus, it's better to put these common functions in one place. Check the util.py file. The Cranfield document file has a special format. cran.py has been provided to simplify your work in reading the documents.
Once you get a list of terms, use the steps to put the terms in the inverted index and sort the lists correspondingly. Check the files: doc.py and index.py to understand how the classes are organized, and then implement the necessary methods - you are free to add more methods if necessary.
Finally, the index should be saved to a file. You can use any serialization method you like (e.g., JSON or any Python built-in libraries). Make sure the index can be saved/loaded correctly.
You should provide the executable indexing program that can be run as follows
It builds the index for the cran.all file and saves the index into the index_file.
The query processing component contains the following steps.
If the data set contains any queries that require us to use author or other significant fields we have to use the extended indexing.
Your standard query processing program should be run as follows
where mode_selection has: 0 - Boolean, 1 - vector, 2 - batch evaluation, query.text contains the sample queries (included in the Cranfield dataset), and in mode 0 or 1 qid_or_n is the specific query_id you choose and in mode 2 qid_or_n represent randomly selecting n queries for batch evaluation. cranqry.py has been provided for reading the special format used by query.text. In mode=0 or 1 The output will be a list of document IDs for the Boolean model, and the top 3 ranked results for the vector model. For vector model, choose one of the TFIDF scoring methods, e.g., lnc.ltc, mentioned in Figure 6.15 at the page 118 of the textbook (or the same Figure in slides "scoring_idf.ppt").
For mode=2, it will randomly select n queries, e.g., n=20, process them, and evaluate the total time spent on processing the queries for each model (Boolean and vector) - do not print out query results in processing queries, which will pollute the evaluation of processing time. You should repeat this experiment (mode=2) for 5 times and report the result in a table (or figure).
Check qrels.text in the Cranfield dataset for evaluating the quality of search results. You can use the ndcg_score function in metrics.py to evaluate the quality. Please finish the program "batch_eval.py" to compute the average NDCGs for the boolean-model and vector-model based query processing results, respectively, and use t-test https://docs.scipy.org/doc/scipy-0.15.1/reference/generated/scipy.stats.ttest_ind.html or wilcoxon-test https://docs.scipy.org/doc/scipy-0.14.0/reference/generated/scipy.stats.wilcoxon.html to get the p-value for comparison (i.e., whether one ranking result is /statistically-significantly/ better than the other).
where n is the number of randomly selected queries from query.text. The output should be the average NDCGs (for n queries) for the boolean model and the vector model respectively, and the p-value for the comparison. Repeat your evaluation for 5 times with n=50. Report the result in a table.
(Extra credit (5%)) You can extend this query evaluation program to compare different settings of vector models (i.e., TFIDF scoring methods mentioned in Part 2): implement some different query processing methods. Then compare and report the quality of ranking result
Since the final exam is kind of written it is hard to determine the exact grade that will be given. Therefore 5% padding seems worth it.
Please test/debug all your programs thoroughly. By designing tests, ask yourself questions like
Turn in three files (DO NOT zip them into one zip file) to Pilot: (1) a brief documentation about your design, implementation, and tests you have done, (2) paste your well-commented source code in one PDF file, and (3) the zipped whole source code directory. You should put your team members names in the beginning of each PDF file.
Plagiarism will get 0 directly. No deadline extension will be given.


Library FFTPACK 5.1 contains 1D, 2D, and multiple fast Fourier subroutines, written in Fortran 77, for transforming real and complex data, real even and odd wave data, and real even and odd quarter-wave data. All of the FFTPACK 5.1 routines listed above are grouped in triplets e.g. {CFFT1I, CFFT1F, CFFT1B}. The suffix I denotes initialize, F denotes forward (as in forward transform) and B denotes backward. In an application program, before calling B or F routines for the first time, or before calling them with a different length, users must initialize an array by calling the I routine of the appropriate pair or triplet. Note that I routines need not be called each time before a B or F routine is called.
All of the transform routines in FFTPACK 5.1 are normalized.
Error messages are written to unit 6 by routine XERFFT. The standard version of XERFFT issues an error message and halts execution, so that no FFTPACK 5.1 routine will return to the calling program with error return IER different than zero. Users may consider modifying the STOP statement in order to call system-specific exception-handling facilities.
FFTPACK 5.1 is not fully compliant with the Fortran 77 standard. There are several instances where arrays of type REAL or COMPLEX are passed to a subroutine and used as a different type. We have not passed the code through a rigorous standards-checker, so we do not have a list of the infractions. Prospective users whose projects require strict adherence to the Fortran standard should not use this library.
(1) Vectorizing the Fast Fourier Transforms, by Paul Swarztrauber, Parallel Computations, G. Rodrigue, ed., Academic Press, New York 1982.
(2) Fast Fourier Transforms Algorithms for Vector Computers, by Paul Swarztrauber, Parallel Computing, (1984) pp.45-63.


First Post less than 1 minute read Hey guys. I am trying to construct a personal homepage, and this is my very first post. GitHub provids a really convenient place to host my homepage, and Jek...
Building a 3-Phase Servo Motor Driver 7 minutes read In the past few months I was intensively exposed to servo motors: their constructions, working principles, and driving circuits, thanks to my internship. The...
Learning Logic Circuits with Minecraft 1 minute read I’m not a game person, and I rarely play games. However, there’s one game to which I’m particularly addicted: Minecraft!!!


Money Play. How should Red play 62?
pips Red=99 White=121
(CorrectAnswer= 0/0, ErrorScore= 0)
This is another type of position often misplayed.
Over the board Red played 11/3 but that leaves three stripped outfield points and the alarm bells should be ringing.11/3 is a blunder.
Correct is 10/8, 10/4, clearing a point and providing some much needed spares. The old adage ‘a point cleared is a point not be to be feared’ does the trick here.
Over the board Red played 11/3 but that leaves three stripped outfield points and the alarm bells should be ringing.11/3 is a blunder.
Correct is 10/8, 10/4, clearing a point and providing some much needed spares. The old adage ‘a point cleared is a point not be to be feared’ does the trick here.
1. Cubeful 2-ply 10/8 10/4 Eq.: +0.401 0.741 0.018 0.000 - 0.259 0.012 0.000 2. Cubeful 2-ply 11/3 Eq.: +0.314 (-0.087) 0.707 0.022 0.000 - 0.293 0.022 0.000 3. Cubeful 0-ply 8/6 8/2 Eq.: +0.262 (-0.139) 0.683 0.021 0.000 - 0.317 0.018 0.000 4. Cubeful 0-ply 10/2 Eq.: -0.101 (-0.502) 0.543 0.041 0.000 - 0.457 0.073 0.000 5. Cubeful 0-ply 8/2 6/4 Eq.: -0.159 (-0.560) 0.523 0.042 0.000 - 0.477 0.085 0.000


#29: Robin Richardson, Remzi Celebi, Sven van der Burg, Djura Smits, Lars Ridder, Michel Dumontier and Tobias Kuhn. User-friendly composition of FAIR workflows in a notebook environment
#43: Alba Catalina Morales Tirado, Enrico Daga and Enrico Motta. Reasoning on health condition evolution for enhanced detection of vulnerable people in emergency settings
#47: Ryan Brate, Andrei Nesterov, Valentin Vogelmann, Jacco van Ossenbruggen, Laura Hollink and Marieke van Erp. Capturing Contentiousness: Constructing the Contentious terms in Context Corpus
#49: Kaviya Dhanabalachandran, Vanessa Hassouna, Maria M. Hedblom, Michaela Kuempel, Nils Leusmann and Michael Beetz. Cutting Events: Towards Autonomous Plan Adaption by Robotic Agents through Image-Schematic Event Segmentation
#25: Albert Meroño-Peñuela, Romana Pernisch, Christophe Guéret and Stefan Schlobach. Multi-domain and Explainable Prediction of Changes in Web Vocabularies
#31: Lucie Cadorel, Alicia Blanchi and Andrea Tettamanzi. Geospatial Knowledge in housing advertisements : Capturing and Extracting Spatial Information from Text
#37: Petar Ristoski, Zhizhong Lin and Qunzhi Zhou. KG-ZESHEL: Knowledge Graph-Enhanced Zero-Shot Entity Linking
#51: Nicholas Halliwell, Fabien Gandon and Freddy Lecue. User Scored Evaluation of Non-Unique Explanations for Relational Graph Convolutional Network Link Prediction on Knowledge Graphs
#102: Olivia Sanchez-Graillet, Arne Kramer-Sunderbrink and Philipp Cimiano. CTrO-Editor: A Web-based tool to capture clinical trial data for aggregation and pooling
#60: Doerthe Arndt, Sven Lieber, Raf Buyle, Sander Goossens, David De Block, Ben De Meester and Erik Mannens. Dynamic workflow composition with OSLO-steps: Data re-use and simplification of automated administration
#116: Rui Zhu, Ling Cai, Gengchen Mai, Cogan Shimizu, Colby K. Fisher, Krzysztof Janowicz, Anna Lopez-Carr, Andrew Schroeder, Mark Schildhauer, Yuanyuan Tian, Shirly Stephen and Zilong Liu. Providing Humanitarian Relief Support through
Knowledge Graphs
#32: Stijn Schouten, Victor de Boer, Lodewijk Petram and Marieke van Erp. The Wind in Our Sails: Developing a Reusable and Maintainable Dutch Maritime History Knowledge Graph
#104: Adnan Akhter, Muhammad Saleem, Axel-Cyrille Ngonga Ngomo and Alexander Bigerl. Efficient RDF Knowledge Graph Partitioning Using Querying Workload


pymatgen.analysis.local_env module¶
-
class
BrunnerNN_real
(tol=0.0001, cutoff=8.0)[source]¶ Bases:
pymatgen.analysis.local_env.NearNeighbors
Determine coordination number using Brunner’s algorithm which counts the atoms that are within the largest gap in differences in real space interatomic distances. This algorithm uses Brunner’s method of largest gap in interatomic distances.
Parameters: - tol (float) – tolerance parameter for bond determination (default: 1E-4).
- cutoff (float) – cutoff radius in Angstrom to look for near-neighbor atoms. Defaults to 8.0.
-
get_nn_info
(structure, n)[source]¶ Get all near-neighbor sites as well as the associated image locations and weights of the site with index n.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine near-neighbor information.
Returns: - each dictionary provides information
about a single near neighbor, where key ‘site’ gives access to the corresponding Site object, ‘image’ gives the image location, and ‘weight’ provides the weight that a given near-neighbor site contributes to the coordination number (1 or smaller), ‘site_index’ gives index of the corresponding site in the original structure.
Return type: siw (list of dicts)
-
class
BrunnerNN_reciprocal
(tol=0.0001, cutoff=8.0)[source]¶ Bases:
pymatgen.analysis.local_env.NearNeighbors
Determine coordination number using Brunner’s algorithm which counts the atoms that are within the largest gap in differences in real space interatomic distances. This algorithm uses Brunner’s method of largest reciprocal gap in interatomic distances.
Parameters: - tol (float) – tolerance parameter for bond determination (default: 1E-4).
- cutoff (float) – cutoff radius in Angstrom to look for near-neighbor atoms. Defaults to 8.0.
-
get_nn_info
(structure, n)[source]¶ Get all near-neighbor sites as well as the associated image locations and weights of the site with index n.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine near-neighbor information.
Returns: - each dictionary provides information
about a single near neighbor, where key ‘site’ gives access to the corresponding Site object, ‘image’ gives the image location, and ‘weight’ provides the weight that a given near-neighbor site contributes to the coordination number (1 or smaller), ‘site_index’ gives index of the corresponding site in the original structure.
Return type: siw (list of dicts)
-
class
BrunnerNN_relative
(tol=0.0001, cutoff=8.0)[source]¶ Bases:
pymatgen.analysis.local_env.NearNeighbors
Determine coordination number using Brunner’s algorithm which counts the atoms that are within the largest gap in differences in real space interatomic distances. This algorithm uses Brunner’s method of of largest relative gap in interatomic distances.
Parameters: - tol (float) – tolerance parameter for bond determination (default: 1E-4).
- cutoff (float) – cutoff radius in Angstrom to look for near-neighbor atoms. Defaults to 8.0.
-
get_nn_info
(structure, n)[source]¶ Get all near-neighbor sites as well as the associated image locations and weights of the site with index n.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine near-neighbor information.
Returns: - each dictionary provides information
about a single near neighbor, where key ‘site’ gives access to the corresponding Site object, ‘image’ gives the image location, and ‘weight’ provides the weight that a given near-neighbor site contributes to the coordination number (1 or smaller), ‘site_index’ gives index of the corresponding site in the original structure.
Return type: siw (list of dicts)
-
class
CovalentBondNN
(tol=0.2, order=True)[source]¶ Bases:
pymatgen.analysis.local_env.NearNeighbors
Determine near-neighbor sites and bond orders using built-in pymatgen.Molecule CovalentBond functionality.
NOTE: This strategy is only appropriate for molecules, and not for structures.
Parameters: - tol (float) – Tolerance for covalent bond checking.
- order (bool) – If True (default), this class will compute bond orders. If
- bond lengths will be computed (False,) –
-
get_bonded_structure
(structure, decorate=False)[source]¶ Obtain a MoleculeGraph object using this NearNeighbor class.
Parameters: - structure – Molecule object.
- decorate (bool) – whether to annotate site properties
- order parameters using neighbors determined by (with) –
- NearNeighbor class (this) –
Returns: a pymatgen.analysis.graphs.MoleculeGraph object
-
get_nn_info
(structure, n)[source]¶ Get all near-neighbor sites and weights (orders) of bonds for a given atom.
Parameters: - structure – input Molecule.
- n – index of site for which to determine near neighbors.
Returns: [dict] representing a neighboring site and the type of
bond present between site n and the neighboring site.
-
get_nn_shell_info
(structure, site_idx, shell)[source]¶ Get a certain nearest neighbor shell for a certain site.
Determines all non-backtracking paths through the neighbor network computed by get_nn_info. The weight is determined by multiplying the weight of the neighbor at each hop through the network. For example, a 2nd-nearest-neighbor that has a weight of 1 from its 1st-nearest-neighbor and weight 0.5 from the original site will be assigned a weight of 0.5.
As this calculation may involve computing the nearest neighbors of atoms multiple times, the calculation starts by computing all of the neighbor info and then calling _get_nn_shell_info. If you are likely to call this method for more than one site, consider calling get_all_nn first and then calling this protected method yourself.
Parameters: - structure (Molecule) – Input structure
- site_idx (int) – index of site for which to determine neighbor information.
- shell (int) – Which neighbor shell to retrieve (1 == 1st NN shell)
Returns: - list of dictionaries. Each entry in the list is information about
a certain neighbor in the structure, in the same format as get_nn_info.
-
class
Critic2NN
[source]¶ Bases:
pymatgen.analysis.local_env.NearNeighbors
Performs a topological analysis using critic2 to obtain neighbor information, using a sum of atomic charge densities. If an actual charge density is available (e.g. from a VASP CHGCAR), see Critic2Caller directly instead.
-
get_bonded_structure
(structure, decorate=False)[source]¶ Obtain a StructureGraph object using this NearNeighbor class. Requires the optional dependency networkx (pip install networkx).
Parameters: - structure – Structure object.
- decorate (bool) – whether to annotate site properties
- order parameters using neighbors determined by (with) –
- NearNeighbor class (this) –
Returns: a pymatgen.analysis.graphs.BondedStructure object
-
get_nn_info
(structure, n)[source]¶ Get all near-neighbor sites as well as the associated image locations and weights of the site with index n.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine near-neighbor information.
Returns: - each dictionary provides information
about a single near neighbor, where key ‘site’ gives access to the corresponding Site object, ‘image’ gives the image location, and ‘weight’ provides the weight that a given near-neighbor site contributes to the coordination number (1 or smaller), ‘site_index’ gives index of the corresponding site in the original structure.
Return type: siw (list of dicts)
-
-
class
CrystalNN
(weighted_cn=False, cation_anion=False, distance_cutoffs=(0.5, 1), x_diff_weight=3.0, porous_adjustment=True, search_cutoff=7, fingerprint_length=None)[source]¶ Bases:
pymatgen.analysis.local_env.NearNeighbors
This is custom near neighbor method intended for use in all kinds of periodic structures (metals, minerals, porous structures, etc). It is based on a Voronoi algorithm and uses the solid angle weights to determine the probability of various coordination environments. The algorithm can also modify probability using smooth distance cutoffs as well as Pauling electronegativity differences. The output can either be the most probable coordination environment or a weighted list of coordination environments.
Initialize CrystalNN with desired parameters. Default parameters assume “chemical bond” type behavior is desired. For geometric neighbor finding (e.g., structural framework), set (i) distance_cutoffs=None, (ii) x_diff_weight=0.0 and (optionally) (iii) porous_adjustment=False which will disregard the atomic identities and perform best for a purely geometric match.
Parameters: - weighted_cn – (bool) if set to True, will return fractional weights for each potential near neighbor.
- cation_anion – (bool) if set True, will restrict bonding targets to sites with opposite or zero charge. Requires an oxidation states on all sites in the structure.
- distance_cutoffs – ([float, float]) - if not None, penalizes neighbor distances greater than sum of covalent radii plus distance_cutoffs[0]. Distances greater than covalent radii sum plus distance_cutoffs[1] are enforced to have zero weight.
- x_diff_weight – (float) - if multiple types of neighbor elements are possible, this sets preferences for targets with higher electronegativity difference.
- porous_adjustment – (bool) - if True, readjusts Voronoi weights to better describe layered / porous structures
- search_cutoff – (float) cutoff in Angstroms for initial neighbor search; this will be adjusted if needed internally
- fingerprint_length – (int) if a fixed_length CN “fingerprint” is desired from get_nn_data(), set this parameter
-
NNData
¶ alias of
nn_data
-
get_cn
(structure, n, use_weights=False)[source]¶ Get coordination number, CN, of site with index n in structure.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine CN.
- use_weights (boolean) – flag indicating whether (True) to use weights for computing the coordination number or not (False, default: each coordinated site has equal weight).
Returns: coordination number.
Return type: cn (integer or float)
-
get_cn_dict
(structure, n, use_weights=False)[source]¶ Get coordination number, CN, of each element bonded to site with index n in structure
Parameters: - structure (Structure) – input structure
- n (integer) – index of site for which to determine CN.
- use_weights (boolean) – flag indicating whether (True) to use weights for computing the coordination number or not (False, default: each coordinated site has equal weight).
Returns: dictionary of CN of each element bonded to site
Return type: cn (dict)
-
get_nn_data
(structure, n, length=None)[source]¶ The main logic of the method to compute near neighbor.
Parameters: - structure – (Structure) enclosing structure object
- n – (int) index of target site to get NN info for
- length – (int) if set, will return a fixed range of CN numbers
Returns: - all near neighbor sites with weights
- a dict of CN -> weight
- a dict of CN -> associated near neighbor sites
Return type: a namedtuple (NNData) object that contains
-
get_nn_info
(structure, n)[source]¶ Get all near-neighbor information. :param structure: (Structure) pymatgen Structure :param n: (int) index of target site
Returns: - each dictionary provides information
- about a single near neighbor, where key ‘site’ gives access to the corresponding Site object, ‘image’ gives the image location, and ‘weight’ provides the weight that a given near-neighbor site contributes to the coordination number (1 or smaller), ‘site_index’ gives index of the corresponding site in the original structure.
Return type: siw (list of dicts)
-
class
CutOffDictNN
(cut_off_dict=None)[source]¶ Bases:
pymatgen.analysis.local_env.NearNeighbors
A very basic NN class using a dictionary of fixed cut-off distances. Can also be used with no dictionary defined for a Null/Empty NN class.
Parameters: - cut_off_dict (Dict[str, float]) – a dictionary
- cut-off distances, e.g. { (of) – 2.0} for
- maximum Fe-O bond length of 2.0 Angstroms. (a) –
- that if your structure is oxidation state (Note) –
- the cut-off distances will have to (decorated,) –
- include the oxidation state, e.g. (explicitly) –
- { ('Fe2+', 'O2-') – 2.0}
-
static
from_preset
(preset)[source]¶ Initialise a CutOffDictNN according to a preset set of cut-offs.
Parameters: preset (str) – A preset name. The list of supported presets are:
- ”vesta_2019”: The distance cut-offs used by the VESTA visualisation program.
Returns: A CutOffDictNN using the preset cut-off dictionary.
-
get_nn_info
(structure, n)[source]¶ Get all near-neighbor sites as well as the associated image locations and weights of the site with index n.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine near-neighbor information.
Returns: - each dictionary provides information
about a single near neighbor, where key ‘site’ gives access to the corresponding Site object, ‘image’ gives the image location, and ‘weight’ provides the weight that a given near-neighbor site contributes to the coordination number (1 or smaller), ‘site_index’ gives index of the corresponding site in the original structure.
Return type: siw (list of dicts)
-
class
EconNN
(tol=0.0001, cutoff=10.0)[source]¶ Bases:
pymatgen.analysis.local_env.NearNeighbors
Determines the average effective coordination number for each cation in a given structure using Hoppe’s algorithm.
This method finds all cation-centered polyhedrals in the structure, calculates the bond weight for each peripheral ion in the polyhedral, and sums up the bond weights to obtain the effective coordination number for each polyhedral. It then averages the effective coordination of all polyhedrals with the same cation at the central site.
Parameters: - tol (float) – tolerance parameter for bond determination (default: 1e-4).
- cutoff (float) – cutoff radius in Angstrom to look for near-neighbor atoms. Defaults to 10.0.
-
get_nn_info
(structure, n)[source]¶ Get all near-neighbor sites as well as the associated image locations and weights of the site with index n.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine near-neighbor information.
Returns: - each dictionary provides information
about a single near neighbor, where key ‘site’ gives access to the corresponding Site object, ‘image’ gives the image location, and ‘weight’ provides the weight that a given near-neighbor site contributes to the coordination number (1 or smaller), ‘site_index’ gives index of the corresponding site in the original structure.
Return type: siw (list of dicts)
-
class
JmolNN
(tol=0.56, min_bond_distance=0.4, el_radius_updates=None)[source]¶ Bases:
pymatgen.analysis.local_env.NearNeighbors
Determine near-neighbor sites and coordination number using an emulation of Jmol’s default autoBond() algorithm. This version of the algorithm does not take into account any information regarding known charge states.
Parameters: - tol (float) – tolerance parameter for bond determination (default: 0.56).
- el_radius_updates – (dict) symbol->float to override default atomic radii table values
-
get_max_bond_distance
(el1_sym, el2_sym)[source]¶ Use Jmol algorithm to determine bond length from atomic parameters :param el1_sym: (str) symbol of atom 1 :param el2_sym: (str) symbol of atom 2
Returns: (float) max bond length
-
get_nn_info
(structure, n)[source]¶ Get all near-neighbor sites as well as the associated image locations and weights of the site with index n using the bond identification algorithm underlying Jmol.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine near neighbors.
Returns: - tuples, each one
of which represents a neighbor site, its image location, and its weight.
Return type: siw (list of tuples (Site, array, float))
-
class
LocalStructOrderParams
(types, parameters=None, cutoff=-10.0)[source]¶ Bases:
object
This class permits the calculation of various types of local structure order parameters.
Parameters: - types ([string]) –
list of strings representing the types of order parameters to be calculated. Note that multiple mentions of the same type may occur. Currently available types recognize following environments:
- ”cn”: simple coordination number—normalized
- if desired;
”sgl_bd”: single bonds; “bent”: bent (angular) coordinations
(Zimmermann & Jain, in progress, 2017);”T”: T-shape coordinations; “see_saw_rect”: see saw-like coordinations; “tet”: tetrahedra
(Zimmermann et al., submitted, 2017);- ”oct”: octahedra
- (Zimmermann et al., submitted, 2017);
- ”bcc”: body-centered cubic environments (Peters,
- Chem. Phys., 131, 244103, 2009);
”tri_plan”: trigonal planar environments; “sq_plan”: square planar environments; “pent_plan”: pentagonal planar environments; “tri_pyr”: trigonal pyramids (coordinated atom is in
the center of the basal plane);”sq_pyr”: square pyramids; “pent_pyr”: pentagonal pyramids; “hex_pyr”: hexagonal pyramids; “tri_bipyr”: trigonal bipyramids; “sq_bipyr”: square bipyramids; “pent_bipyr”: pentagonal bipyramids; “hex_bipyr”: hexagonal bipyramids; “cuboct”: cuboctahedra; “q2”: motif-unspecific bond orientational order
parameter (BOOP) of weight l=2 (Steinhardt et al., Phys. Rev. B, 28, 784-805, 1983);”q4”: BOOP of weight l=4; “q6”: BOOP of weight l=6. “reg_tri”: regular triangle with varying height
to basal plane;”sq”: square coordination (cf., “reg_tri”); “oct_legacy”: original Peters-style OP recognizing
octahedral coordination environments (Zimmermann et al., J. Am. Chem. Soc., 137, 13352-13361, 2015) that can, however, produce small negative values sometimes.”sq_pyr_legacy”: square pyramids (legacy);
- parameters ([dict]) –
list of dictionaries that store float-type parameters associated with the definitions of the different order parameters (length of list = number of OPs). If an entry is None, default values are used that are read from the op_params.yaml file. With few exceptions, 9 different parameters are used across all OPs:
- ”norm”: normalizing constant (used in “cn”
- (default value: 1)).
- ”TA”: target angle (TA) in fraction of 180 degrees
- (“bent” (1), “tet” (0.6081734479693927), “tri_plan” (0.66666666667), “pent_plan” (0.6), “sq_pyr_legacy” (0.5)).
- ”IGW_TA”: inverse Gaussian width (IGW) for penalizing
- angles away from the target angle in inverse fractions of 180 degrees to (“bent” and “tet” (15), “tri_plan” (13.5), “pent_plan” (18), “sq_pyr_legacy” (30)).
- ”IGW_EP”: IGW for penalizing angles away from the
- equatorial plane (EP) at 90 degrees (“T”, “see_saw_rect”, “oct”, “sq_plan”, “tri_pyr”, “sq_pyr”, “pent_pyr”, “hex_pyr”, “tri_bipyr”, “sq_bipyr”, “pent_bipyr”, “hex_bipyr”, and “oct_legacy” (18)).
- ”fac_AA”: factor applied to azimuth angle (AA) in cosine
- term (“T”, “tri_plan”, and “sq_plan” (1), “tet”, “tri_pyr”, and “tri_bipyr” (1.5), “oct”, “sq_pyr”, “sq_bipyr”, and “oct_legacy” (2), “pent_pyr” and “pent_bipyr” (2.5), “hex_pyr” and “hex_bipyr” (3)).
- ”exp_cos_AA”: exponent applied to cosine term of AA
- (“T”, “tet”, “oct”, “tri_plan”, “sq_plan”, “tri_pyr”, “sq_pyr”, “pent_pyr”, “hex_pyr”, “tri_bipyr”, “sq_bipyr”, “pent_bipyr”, “hex_bipyr”, and “oct_legacy” (2)).
- ”min_SPP”: smallest angle (in radians) to consider
- a neighbor to be at South pole position (“see_saw_rect”, “oct”, “bcc”, “sq_plan”, “tri_bipyr”, “sq_bipyr”, “pent_bipyr”, “hex_bipyr”, “cuboct”, and “oct_legacy” (2.792526803190927)).
- ”IGW_SPP”: IGW for penalizing angles away from South
- pole position (“see_saw_rect”, “oct”, “bcc”, “sq_plan”, “tri_bipyr”, “sq_bipyr”, “pent_bipyr”, “hex_bipyr”, “cuboct”, and “oct_legacy” (15)).
- ”w_SPP”: weight for South pole position relative to
- equatorial positions (“see_saw_rect” and “sq_plan” (1), “cuboct” (1.8), “tri_bipyr” (2), “oct”, “sq_bipyr”, and “oct_legacy” (3), “pent_bipyr” (4), “hex_bipyr” (5), “bcc” (6)).
- cutoff (float) – Cutoff radius to determine which nearest neighbors are supposed to contribute to the order parameters. If the value is negative the neighboring sites found by distance and cutoff radius are further pruned using the get_nn method from the VoronoiNN class.
-
compute_trigonometric_terms
(thetas, phis)[source]¶ ” Computes trigonometric terms that are required to calculate bond orientational order parameters using internal variables.
Parameters: - thetas ([float]) – polar angles of all neighbors in radians.
- phis ([float]) – azimuth angles of all neighbors in radians. The list of azimuth angles of all neighbors in radians. The list of azimuth angles is expected to have the same size as the list of polar angles; otherwise, a ValueError is raised. Also, the two lists of angles have to be coherent in order. That is, it is expected that the order in the list of azimuth angles corresponds to a distinct sequence of neighbors. And, this sequence has to equal the sequence of neighbors in the list of polar angles.
-
get_order_parameters
(structure, n, indices_neighs=None, tol=0.0, target_spec=None)[source]¶ Compute all order parameters of site n.
Parameters: - structure (Structure) – input structure.
- n (int) – index of site in input structure, for which OPs are to be calculated. Note that we do not use the sites iterator here, but directly access sites via struct[index].
- indices_neighs ([int]) – list of indices of those neighbors in Structure object structure that are to be considered for OP computation. This optional argument overwrites the way neighbors are to be determined as defined in the constructor (i.e., Voronoi coordination finder via negative cutoff radius vs constant cutoff radius if cutoff was positive). We do not use information about the underlying structure lattice if the neighbor indices are explicitly provided. This has two important consequences. First, the input Structure object can, in fact, be a simple list of Site objects. Second, no nearest images of neighbors are determined when providing an index list. Note furthermore that this neighbor determination type ignores the optional target_spec argument.
- tol (float) – threshold of weight (= solid angle / maximal solid angle) to determine if a particular pair is considered neighbors; this is relevant only in the case when Voronoi polyhedra are used to determine coordination
- target_spec (Specie) – target species to be considered when calculating the order parameters of site n; None includes all species of input structure.
Returns: representing order parameters. Should it not be possible to compute a given OP for a conceptual reason, the corresponding entry is None instead of a float. For Steinhardt et al.’s bond orientational OPs and the other geometric OPs (“tet”, “oct”, “bcc”, etc.), this can happen if there is a single neighbor around site n in the structure because that does not permit calculation of angles between multiple neighbors.
Return type: [floats]
-
get_parameters
(index)[source]¶ Returns list of floats that represents the parameters associated with calculation of the order parameter that was defined at the index provided. Attention: the parameters do not need to equal those originally inputted because of processing out of efficiency reasons.
Parameters: index (int) – index of order parameter for which associated parameters are to be returned. Returns: parameters of a given OP. Return type: [float]
-
get_q2
(thetas=None, phis=None)[source]¶ Calculates the value of the bond orientational order parameter of weight l=2. If the function is called with non-empty lists of polar and azimuthal angles the corresponding trigonometric terms are computed afresh. Otherwise, it is expected that the compute_trigonometric_terms function has been just called.
Parameters: - thetas ([float]) – polar angles of all neighbors in radians.
- phis ([float]) – azimuth angles of all neighbors in radians.
Returns: - bond orientational order parameter of weight l=2
corresponding to the input angles thetas and phis.
Return type: float
-
get_q4
(thetas=None, phis=None)[source]¶ Calculates the value of the bond orientational order parameter of weight l=4. If the function is called with non-empty lists of polar and azimuthal angles the corresponding trigonometric terms are computed afresh. Otherwise, it is expected that the compute_trigonometric_terms function has been just called.
Parameters: - thetas ([float]) – polar angles of all neighbors in radians.
- phis ([float]) – azimuth angles of all neighbors in radians.
Returns: - bond orientational order parameter of weight l=4
corresponding to the input angles thetas and phis.
Return type: float
-
get_q6
(thetas=None, phis=None)[source]¶ Calculates the value of the bond orientational order parameter of weight l=6. If the function is called with non-empty lists of polar and azimuthal angles the corresponding trigonometric terms are computed afresh. Otherwise, it is expected that the compute_trigonometric_terms function has been just called.
Parameters: - thetas ([float]) – polar angles of all neighbors in radians.
- phis ([float]) – azimuth angles of all neighbors in radians.
Returns: - bond orientational order parameter of weight l=6
corresponding to the input angles thetas and phis.
Return type: float
-
get_type
(index)[source]¶ Return type of order parameter at the index provided and represented by a short string.
Parameters: index (int) – index of order parameter for which type is to be returned. Returns: OP type. Return type: str
-
last_nneigh
¶ ” :returns:
- the number of neighbors encountered during the most
- recent order parameter calculation. A value of -1 indicates that no such calculation has yet been performed for this instance.
Return type: int
-
num_ops
¶ ” :returns:
- the number of different order parameters that are targeted
- to be calculated.
Return type: int
- types ([string]) –
-
class
MinimumDistanceNN
(tol=0.1, cutoff=10.0)[source]¶ Bases:
pymatgen.analysis.local_env.NearNeighbors
Determine near-neighbor sites and coordination number using the nearest neighbor(s) at distance, d_min, plus all neighbors within a distance (1 + delta) * d_min, where delta is a (relative) distance tolerance parameter.
Parameters: - tol (float) – tolerance parameter for neighbor identification (default: 0.1).
- cutoff (float) – cutoff radius in Angstrom to look for trial near-neighbor sites (default: 10.0).
-
get_nn_info
(structure, n)[source]¶ Get all near-neighbor sites as well as the associated image locations and weights of the site with index n using the closest neighbor distance-based method.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine near neighbors.
Returns: - tuples, each one
of which represents a neighbor site, its image location, and its weight.
Return type: siw (list of tuples (Site, array, float))
-
class
MinimumOKeeffeNN
(tol=0.1, cutoff=10.0)[source]¶ Bases:
pymatgen.analysis.local_env.NearNeighbors
Determine near-neighbor sites and coordination number using the neighbor(s) at closest relative distance, d_min_OKeffee, plus some relative tolerance, where bond valence parameters from O’Keeffe’s bond valence method (J. Am. Chem. Soc. 1991, 3226-3229) are used to calculate relative distances.
Parameters: - tol (float) – tolerance parameter for neighbor identification (default: 0.1).
- cutoff (float) – cutoff radius in Angstrom to look for trial near-neighbor sites (default: 10.0).
-
get_nn_info
(structure, n)[source]¶ Get all near-neighbor sites as well as the associated image locations and weights of the site with index n using the closest relative neighbor distance-based method with O’Keeffe parameters.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine near neighbors.
Returns: - tuples, each one
of which represents a neighbor site, its image location, and its weight.
Return type: siw (list of tuples (Site, array, float))
-
class
MinimumVIRENN
(tol=0.1, cutoff=10.0)[source]¶ Bases:
pymatgen.analysis.local_env.NearNeighbors
Determine near-neighbor sites and coordination number using the neighbor(s) at closest relative distance, d_min_VIRE, plus some relative tolerance, where atom radii from the ValenceIonicRadiusEvaluator (VIRE) are used to calculate relative distances.
Parameters: - tol (float) – tolerance parameter for neighbor identification (default: 0.1).
- cutoff (float) – cutoff radius in Angstrom to look for trial near-neighbor sites (default: 10.0).
-
get_nn_info
(structure, n)[source]¶ Get all near-neighbor sites as well as the associated image locations and weights of the site with index n using the closest relative neighbor distance-based method with VIRE atomic/ionic radii.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine near neighbors.
Returns: - tuples, each one
of which represents a neighbor site, its image location, and its weight.
Return type: siw (list of tuples (Site, array, float))
-
class
NearNeighbors
[source]¶ Bases:
object
Base class to determine near neighbors that typically include nearest neighbors and others that are within some tolerable distance.
-
get_all_nn_info
(structure)[source]¶ Get a listing of all neighbors for all sites in a structure
Parameters: structure (Structure) – Input structure Returns: - List of NN site information for each site in the structure. Each
- entry has the same format as get_nn_info
-
get_bonded_structure
(structure, decorate=False)[source]¶ Obtain a StructureGraph object using this NearNeighbor class. Requires the optional dependency networkx (pip install networkx).
Parameters: - structure – Structure object.
- decorate (bool) – whether to annotate site properties
- order parameters using neighbors determined by (with) –
- NearNeighbor class (this) –
Returns: a pymatgen.analysis.graphs.BondedStructure object
-
get_cn
(structure, n, use_weights=False)[source]¶ Get coordination number, CN, of site with index n in structure.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine CN.
- use_weights (boolean) – flag indicating whether (True) to use weights for computing the coordination number or not (False, default: each coordinated site has equal weight).
Returns: coordination number.
Return type: cn (integer or float)
-
get_cn_dict
(structure, n, use_weights=False)[source]¶ Get coordination number, CN, of each element bonded to site with index n in structure
Parameters: - structure (Structure) – input structure
- n (integer) – index of site for which to determine CN.
- use_weights (boolean) – flag indicating whether (True) to use weights for computing the coordination number or not (False, default: each coordinated site has equal weight).
Returns: dictionary of CN of each element bonded to site
Return type: cn (dict)
-
get_local_order_parameters
(structure, n)[source]¶ Calculate those local structure order parameters for the given site whose ideal CN corresponds to the underlying motif (e.g., CN=4, then calculate the square planar, tetrahedral, see-saw-like, rectangular see-saw-like order paramters).
Parameters: - structure – Structure object
- n (int) – site index.
- Returns (Dict[str, float]):
- A dict of order parameters (values) and the underlying motif type (keys; for example, tetrahedral).
-
get_nn
(structure, n)[source]¶ Get near neighbors of site with index n in structure.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site in structure for which to determine neighbors.
Returns: near neighbors.
Return type: sites (list of Site objects)
-
get_nn_images
(structure, n)[source]¶ Get image location of all near neighbors of site with index n in structure.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine the image location of near neighbors.
Returns: - image locations of
near neighbors.
Return type: images (list of 3D integer array)
-
get_nn_info
(structure, n)[source]¶ Get all near-neighbor sites as well as the associated image locations and weights of the site with index n.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine near-neighbor information.
Returns: - each dictionary provides information
about a single near neighbor, where key ‘site’ gives access to the corresponding Site object, ‘image’ gives the image location, and ‘weight’ provides the weight that a given near-neighbor site contributes to the coordination number (1 or smaller), ‘site_index’ gives index of the corresponding site in the original structure.
Return type: siw (list of dicts)
-
get_nn_shell_info
(structure, site_idx, shell)[source]¶ Get a certain nearest neighbor shell for a certain site.
Determines all non-backtracking paths through the neighbor network computed by get_nn_info. The weight is determined by multiplying the weight of the neighbor at each hop through the network. For example, a 2nd-nearest-neighbor that has a weight of 1 from its 1st-nearest-neighbor and weight 0.5 from the original site will be assigned a weight of 0.5.
As this calculation may involve computing the nearest neighbors of atoms multiple times, the calculation starts by computing all of the neighbor info and then calling _get_nn_shell_info. If you are likely to call this method for more than one site, consider calling get_all_nn first and then calling this protected method yourself.
Parameters: - structure (Structure) – Input structure
- site_idx (int) – index of site for which to determine neighbor information.
- shell (int) – Which neighbor shell to retrieve (1 == 1st NN shell)
Returns: - list of dictionaries. Each entry in the list is information about
a certain neighbor in the structure, in the same format as get_nn_info.
-
get_weights_of_nn_sites
(structure, n)[source]¶ Get weight associated with each near neighbor of site with index n in structure.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine the weights.
Returns: near-neighbor weights.
Return type: weights (list of floats)
-
-
class
OpenBabelNN
(order=True)[source]¶ Bases:
pymatgen.analysis.local_env.NearNeighbors
Determine near-neighbor sites and bond orders using OpenBabel API.
NOTE: This strategy is only appropriate for molecules, and not for structures.
Parameters: - order (bool) – True if bond order should be returned as a weight, False
- bond length should be used as a weight. (if) –
-
get_bonded_structure
(structure, decorate=False)[source]¶ Obtain a MoleculeGraph object using this NearNeighbor class. Requires the optional dependency networkx (pip install networkx).
Parameters: - structure – Molecule object.
- decorate (bool) – whether to annotate site properties
- order parameters using neighbors determined by (with) –
- NearNeighbor class (this) –
Returns: a pymatgen.analysis.graphs.MoleculeGraph object
-
get_nn_info
(structure, n)[source]¶ Get all near-neighbor sites and weights (orders) of bonds for a given atom.
Parameters: - molecule – input Molecule.
- n – index of site for which to determine near neighbors.
Returns: [dict] representing a neighboring site and the type of
bond present between site n and the neighboring site.
-
get_nn_shell_info
(structure, site_idx, shell)[source]¶ Get a certain nearest neighbor shell for a certain site.
Determines all non-backtracking paths through the neighbor network computed by get_nn_info. The weight is determined by multiplying the weight of the neighbor at each hop through the network. For example, a 2nd-nearest-neighbor that has a weight of 1 from its 1st-nearest-neighbor and weight 0.5 from the original site will be assigned a weight of 0.5.
As this calculation may involve computing the nearest neighbors of atoms multiple times, the calculation starts by computing all of the neighbor info and then calling _get_nn_shell_info. If you are likely to call this method for more than one site, consider calling get_all_nn first and then calling this protected method yourself.
Parameters: - structure (Molecule) – Input structure
- site_idx (int) – index of site for which to determine neighbor information.
- shell (int) – Which neighbor shell to retrieve (1 == 1st NN shell)
Returns: - list of dictionaries. Each entry in the list is information about
a certain neighbor in the structure, in the same format as get_nn_info.
-
class
ValenceIonicRadiusEvaluator
(structure)[source]¶ Bases:
object
Computes site valences and ionic radii for a structure using bond valence analyzer
Parameters: structure – pymatgen.core.structure.Structure -
radii
¶ List of ionic radii of elements in the order of sites.
-
structure
¶ Returns oxidation state decorated structure.
-
valences
¶ List of oxidation states of elements in the order of sites.
-
-
class
VoronoiNN
(tol=0, targets=None, cutoff=13.0, allow_pathological=False, weight='solid_angle', extra_nn_info=True, compute_adj_neighbors=True)[source]¶ Bases:
pymatgen.analysis.local_env.NearNeighbors
Uses a Voronoi algorithm to determine near neighbors for each site in a structure.
Parameters: - tol (float) – tolerance parameter for near-neighbor finding. Faces that are smaller than tol fraction of the largest face are not included in the tessellation. (default: 0).
- targets (Element or list of Elements) – target element(s).
- cutoff (float) – cutoff radius in Angstrom to look for near-neighbor atoms. Defaults to 13.0.
- allow_pathological (bool) – whether to allow infinite vertices in determination of Voronoi coordination.
- weight (string) – available in get_voronoi_polyhedra)
- extra_nn_info (bool) –
- compute_adj_neighbors (bool) – for faster performance
-
get_all_nn_info
(structure)[source]¶ Get a listing of all neighbors for all sites in a structure
Parameters: structure (Structure) – Input structure Returns: - List of NN site information for each site in the structure. Each
- entry has the same format as get_nn_info
-
get_all_voronoi_polyhedra
(structure)[source]¶ Get the Voronoi polyhedra for all site in a simulation cell
Parameters: structure (Structure) – Structure to be evaluated Returns: A dict of sites sharing a common Voronoi facet with the site n mapped to a directory containing statistics about the facet: - solid_angle - Solid angle subtended by face
- angle_normalized - Solid angle normalized such that the
- faces with the largest
- area - Area of the facet
- face_dist - Distance between site n and the facet
- volume - Volume of Voronoi cell for this face
- n_verts - Number of vertices on the facet
-
get_nn_info
(structure, n)[source]¶ ” Get all near-neighbor sites as well as the associated image locations and weights of the site with index n in structure using Voronoi decomposition.
Parameters: - structure (Structure) – input structure.
- n (integer) – index of site for which to determine near-neighbor sites.
Returns: - tuples, each one
of which represents a coordinated site, its image location, and its weight.
Return type: siw (list of tuples (Site, array, float))
-
get_voronoi_polyhedra
(structure, n)[source]¶ Gives a weighted polyhedra around a site.
See ref: A Proposed Rigorous Definition of Coordination Number, M. O’Keeffe, Acta Cryst. (1979). A35, 772-775
Parameters: - structure (Structure) – structure for which to evaluate the coordination environment.
- n (integer) – site index.
Returns: A dict of sites sharing a common Voronoi facet with the site n mapped to a directory containing statistics about the facet:
- solid_angle - Solid angle subtended by face
- angle_normalized - Solid angle normalized such that the
- faces with the largest
- area - Area of the facet
- face_dist - Distance between site n and the facet
- volume - Volume of Voronoi cell for this face
- n_verts - Number of vertices on the facet
-
calculate_weighted_avg
(bonds)[source]¶ Returns the weighted average bond length given by Hoppe’s effective coordination number formula.
Parameters: - bonds (list) – list of floats that are the
- distances between a cation and its (bond) –
- ions (peripheral) –
-
get_neighbors_of_site_with_index
(struct, n, approach='min_dist', delta=0.1, cutoff=10.0)[source]¶ Returns the neighbors of a given site using a specific neighbor-finding method.
Parameters: - struct (Structure) – input structure.
- n (int) – index of site in Structure object for which motif type is to be determined.
- approach (str) – type of neighbor-finding approach, where “min_dist” will use the MinimumDistanceNN class, “voronoi” the VoronoiNN class, “min_OKeeffe” the MinimumOKeeffe class, and “min_VIRE” the MinimumVIRENN class.
- delta (float) – tolerance involved in neighbor finding.
- cutoff (float) – (large) radius to find tentative neighbors.
Returns: neighbor sites.
-
get_okeeffe_distance_prediction
(el1, el2)[source]¶ Returns an estimate of the bond valence parameter (bond length) using the derived parameters from ‘Atoms Sizes and Bond Lengths in Molecules and Crystals’ (O’Keeffe & Brese, 1991). The estimate is based on two experimental parameters: r and c. The value for r is based off radius, while c is (usually) the Allred-Rochow electronegativity. Values used are not generated from pymatgen, and are found in ‘okeeffe_params.json’.
Parameters: el2 (el1,) – two Element objects Returns: a float value of the predicted bond length
-
get_okeeffe_params
(el_symbol)[source]¶ Returns the elemental parameters related to atom size and electronegativity which are used for estimating bond-valence parameters (bond length) of pairs of atoms on the basis of data provided in ‘Atoms Sizes and Bond Lengths in Molecules and Crystals’ (O’Keeffe & Brese, 1991).
Parameters: el_symbol (str) – element symbol. Returns: - atom-size (‘r’) and electronegativity-related (‘c’)
- parameter.
Return type: (dict)
-
gramschmidt
(vin, uin)[source]¶ Returns that part of the first input vector that is orthogonal to the second input vector. The output vector is not normalized.
Parameters: - vin (numpy array) – first input vector
- uin (numpy array) – second input vector
-
site_is_of_motif_type
(struct, n, approach='min_dist', delta=0.1, cutoff=10.0, thresh=None)[source]¶ Returns the motif type of the site with index n in structure struct; currently featuring “tetrahedral”, “octahedral”, “bcc”, and “cp” (close-packed: fcc and hcp) as well as “square pyramidal” and “trigonal bipyramidal”. If the site is not recognized, “unrecognized” is returned. If a site should be assigned to two different motifs, “multiple assignments” is returned.
Parameters: - struct (Structure) – input structure.
- n (int) – index of site in Structure object for which motif type is to be determined.
- approach (str) – type of neighbor-finding approach, where “min_dist” will use the MinimumDistanceNN class, “voronoi” the VoronoiNN class, “min_OKeeffe” the MinimumOKeeffe class, and “min_VIRE” the MinimumVIRENN class.
- delta (float) – tolerance involved in neighbor finding.
- cutoff (float) – (large) radius to find tentative neighbors.
- thresh (dict) – thresholds for motif criteria (currently, required keys and their default values are “qtet”: 0.5, “qoct”: 0.5, “qbcc”: 0.5, “q6”: 0.4).
Returns: motif type (str).
-
solid_angle
(center, coords)[source]¶ Helper method to calculate the solid angle of a set of coords from the center.
Parameters: - center (3x1 array) – Center to measure solid angle from.
- coords (Nx3 array) – List of coords to determine solid angle.
Returns: The solid angle.
-
vol_tetra
(vt1, vt2, vt3, vt4)[source]¶ Calculate the volume of a tetrahedron, given the four vertices of vt1, vt2, vt3 and vt4. :param vt1: coordinates of vertex 1. :type vt1: array-like :param vt2: coordinates of vertex 2. :type vt2: array-like :param vt3: coordinates of vertex 3. :type vt3: array-like :param vt4: coordinates of vertex 4. :type vt4: array-like
Returns: volume of the tetrahedron. Return type: (float)


ABOUT US
SAMPLES OF OUR WORK
WORK WITH US
For over 50 years the University of Wisconsin Cartography Lab has worked closely with faculty and members of the public to create maps of the highest quality and simultaneously provide learning and apprenticeship opportunities for students.