brightway


find a product that causes a non-square technosphere matrix with Brightway2


As a prophecy, I have a question related to a previous question of "cleaning" the database. How can I identify why my technosphere is not longer square?
I have done something to my database that if I try to do an LCIA of a random activity
def testactivity(activity):
method_key=methods.random()
fu={activity:1}
lca = LCA(fu,method_key)
lca.lci()
lca.lcia()
print(lca.score)
return()
testactivity(Database('ei_33consequential').random())
I get this warning message: NonsquareTechnosphere: Technosphere matrix is not square: 12384 activities (columns) and 12385 products (rows). Use LeastSquaresLCA to solve this system, or fix the input data.
I tried to find if I have a dataset with two reference products, to check that I looped through the database to check if the "production amount" was not a float. but I didn't find anything "wrong"
for ds in Database('ei_33consequential'):
if (isinstance(act['production amount'],float))==False:
print(ds['name'])
Is this approach correct to find an activity with more than one reference flow?. Otherwise, how can I find the product which is making my matrix non inversable?
You can check to see which activities have more than one production exchange with something like this:
for a in Database("ecoinvent 3.3 cutoff"):
assert len(a.production()) == 1

Related Links

Brightway2: Modifying/deleting exchanges from activity without using activity as dict
Backups in Brightway: how to use them
Saving multiple activities to database in a loop in Brightway
Obtaining distribution of results from LCIA
Simapro dataset to ecoinvent migration fails in brightway2
What is the best practice when importing 2 simapro datasets in brightway2 to merge them together
How to manually link in Brightway2 an imported exchange, given I have found the correct one in ecoinvent
Can't write copy of activity in newly created databases
Are eco-indicator endpoints reported in points or millipoints
Multi and Parallel Monte Carlo fail with key error (on database name)
sparse matrix solver runs out of memory in parallaleized dynamic LCA
Accessing exchange data in Brightway2 database object
Ecospold Identifiers for ecoinvent 3.2
Importing LCI database - dealing with unlinked exchanges
Installing activity-browser - progressbar error
De-aggregating ecoinvent processes in Brightway2

Categories

HOME
internet-explorer
casting
blob
atlassian-fisheye
ephesoft
velocity
websharper
opengrok
bookmarklet
multibinding
k-means
pylint
indri
javaagents
policy
ckeditor4.x
smart-device
stack-trace
angular2-changedetection
ds-5
delphi-2010
paper-trail-gem
vtd-xml
textview
akamai
luhn
android-scrollview
sdl-2
stochastic-process
client-server
armadillo
ngrok
usernotifications
compiled-query
jvisualvm
autodesk-data-management
test-kitchen
paperclip
apiman
cakephp-3.2
api-key
jenkins-2
evaluation
dynamic-linking
fluent-nhibernate-mapping
selection-sort
programming-pearls
opticalflow
dmalloc
chain
ios-keyboard-extension
pyautogui
blackberry-webworks
disconnect
scriptengine
objectify
audiorecord
jquery-draggable
encode
app-data
persian
exchange-server-2007
pdcurses
firewire
mergecursor
minko
screen-lock
perfect-scrollbar
google-experiments
nsq
grunt-contrib-connect
qf-test
behance-api
code-smell
rssi
starling-framework
kuka-krl
carrier
codio
xcode6.1-gm-seed
google-mirror-api
google-oauth-java-client
ia-32
friendly-url
pyxplot
dd4t
rbm
setcookie
zepto
report-viewer2010
big-endian
jquery-1.8
certificate-revocation
filedialog
jqzoom
designated-initializer
browser-state
system-analysis
mdd
jettison
urlscan

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App