This is a Python script and library to encode, decode and format numbers
including fractions and exponential notation in radixes/bases other than
decimal, such as octal, dozenal/duodecimal, hexadecimal, base57 and base62. The
radix can also be determined by any number of digits specified: 0123456789ab…
Requirements
Python 3
Installation
From the Python Package Index:
pip install num-radix
Or download and run:
python3 setup.py install
Command-Line
Use the --help argument for help.
num-radix --help
By default, the script encodes and decodes in dozenal.
This outputs ‘6X,534;3000’ encoded in dozenal.
num-radix --encode 142456.25 --format ',.4f'
The format string causes the output to have a scale of 4 and every 3 integer
digits to be separated by a comma.
The format is given in Python format string syntax.
Format with e-notation. This outputs ‘4;133X82e-0E’.
vim-bootstrap is also available on openSUSE on both Leap 42.2/42.3 and Tumbleweed. Leap versions must add devel:tools repository before, while Tumbleweed users should have vim-bootstrap in the default repository without the need to add any extra repository.
Leap 42.2
$ sudo zypper ar -f http://download.opensuse.org/repositories/devel:/tools/openSUSE_Leap_42.2/ devel:tools
$ sudo zypper ref
$ sudo zypper in vim-bootstrap
Leap 42.3
$ sudo zypper ar -f http://download.opensuse.org/repositories/devel:/tools/openSUSE_Leap_42.3/ devel:tools
$ sudo zypper ref
$ sudo zypper in vim-bootstrap
Tumbleweed
$ sudo zypper ref
$ sudo zypper in vim-bootstrap
Adding a new Theme
Create a folder inside generate/vim_template/themes/ with the name of your theme.
mkdir generate/vim_template/themes/my_theme
Inside this folder, add a file called mytheme.vim with colorscheme instruction (optionally other configs).
Submit a PR and when approved new theme was added.
Customization
It’s highly recommended to add customizations in a separate file. This way, you can maintain the original vim-bootstrap generated vimrc file and subsequent updates.
For Vim users, the files available for customization are ~/.vimrc.local and ~/.vimrc.local.bundles. The former handles general configuration while the latter handles external Vim plugins through vim-plug.
NeoVim users can also customize their configuration by using $XDG_CONFIG_HOME/nvim/local_init.vim and $XDG_CONFIG_HOME/nvim/local_bundles.vim.
Commands
▪️ Basic Commands
Commands
Descriptions
:cd <path>
Open path /path
Ctrlw+hjkl
Navigate via split panels
Ctrlww
Alternative navigate vim split panels
,.
Set path working directory
,w or ,x
Next buffer navigate
,q or ,z
previous buffer navigate
shiftt
Create a tab
tab
next tab navigate
shifttab
previous tab navigate
,e
Find and open files
,b
Find file on buffer (open file)
,c
Close active buffer (close file)
F2
Open tree navigate in actual opened file
F3
Open/Close tree navigate files
F4
List all class and method, support for python, go, lua, ruby and php
,v
Split vertical
,h
Split horizontal
,f
Search in the project
,o
Open github file/line (website), if used git in github
,sh
Open shell.vim terminal inside Vim or NeoVim built-in terminal
,ga
Execute git add on current file
,gc
git commit (splits window to write commit message)
,gsh
git push
,gll
git pull
,gs
git status
,gb
git blame
,gd
git diff
,gr
git remove
,so
Open Session
,ss
Save Session
,sd
Delete Session
,sc
Close Session
>
indent to right
<
indent to left
gc
Comment or uncomment lines that {motion} moves over
YY
Copy to clipboard
,p
Paste
Ctrly + ,
Activate Emmet plugin
Ctrlh
Does a fuzzy search in your command mode history
▪️ Python hotkeys
Commands
Descriptions
SHIFT+k
Open documentation
Control+Space
Autocomplete
,d
Go to the Class/Method definition
,r
Rename object definition
,n
Show where command is usage
▪️ Ruby hotkeys
Commands
Descriptions
,a
Run all specs
,l
Run last spec
,t
Run current spec
,rap
Add Parameter
,rcpc
Inline Temp
,rel
Convert Post Conditional
,rec
Extract Constant (visual selection)
,rec
Extract to Let (Rspec)
,relv
Extract Local Variable (visual selection)
,rrlv
Rename Local Variable (visual selection/variable under the cursor)
,rriv
Rename Instance Variable (visual selection)
,rem
Extract Method (visual selection)
▪️ Php hotkeys
Commands
Descriptions
,u
Include use statement
,mm
Invoke the context menu
,nn
Invoke the navigation menu
,oo
Goto definition
,oh
Goto definition on horizontal split
,ov
Goto definition on vertical split
,ot
Goto definition on tab
,K
Show brief information about the symbol under the cursor
,tt
Transform the classes in the current file
,cc
Generate a new class (replacing the current file)
,ee
Extract expression (normal mode)
,ee
Extract expression (visual selection)
,em
Extract method (visual selection)
,pcd
cs-fixer fix directory
,pcf
cs-fixer fix file
Learn Vim
Visit the following sites to learn more about Vim:
This course is designed to equip software engineers, data scientists, and machine learning professionals with the skills and knowledge needed to deploy AI models effectively in production environments. As AI continues to revolutionize industries, the ability to deploy, manage, and optimize AI applications at scale is becoming increasingly crucial. This course covers the full spectrum of deployment considerations, from leveraging cutting-edge tools like Kubernetes, llama.cpp, and GGUF, to mastering cost management, compute optimization, and model quantization.
Sinan Ozdemir is the Founder and CTO of LoopGenius where he uses State of the art AI to help people create and run their businesses. Sinan is a former lecturer of Data Science at Johns Hopkins University and the author of multiple textbooks on data science and machine learning. Additionally, he is the founder of the recently acquired Kylie.ai, an enterprise-grade conversational AI platform with RPA capabilities. He holds a master’s degree in Pure Mathematics from Johns Hopkins University and is based in San Francisco, CA.
Counting number of triangles that each node contributes to in large sparse matrices.
For this algorithm we use large sparse matrices with in CSC or CSR format only!
~ Function V3 ~
The logic followed in function V3 is as follows. First we access the
nodes-rows (row_ptr table) and their corresponding column elements (col_index).
For each possible col_index data pair of a given node, a search is started in the
line, the pointer of which is defined by the first element of the pair. Searhing the data
col_index contained in the respective row-node, if we locate its second component
pair, we have proven the existence of a triangle, and the appropriate pointers increase.
For example, lets say node zero is adjacent to the elements {1, 2, 3, 4}. For
pair (1,2), a pointer will be referenced in line 1 and will
access its col_index data. In case the second
element of the pair is also located on the new line (line 1), there is a connection
of nodes (0-1), (0-2), (1-2) therefore they participate in a triangle.
~ Function V4 ~
The algorithm that implements V4 follows a similar logic to V3 with respect to
accessing nodes, indirectly using array multiplication for
finding the node contribution to existing triangles. This time we receive every
pair of neighboring nodes, and look for the number of their common col_index elements.
Considering the above example, node zero is adjacent to node 1, so
our pointer will access the col_index table data corresponding to the row
1, counting the common neighbors of the nodes (0,1). This result expresses
substantially the number of non-zero existing multiplications (Hadamard
product), therefore the final value of the index will be indicated in c3 [0,1].
The algorithm uses merge function to compare lists of neighboring nodes
in order to significantly reduce complexity. The process continues for
all neighbors of node zero, ending in the calculation of c3 [0, {1,2,3,4}]
by summing the individual c3 [0, x] and repeating the same for all of them
remaining nodes.
Then replace your holding SENTRY DSNs after you’ve generated your projects in sentry for api, auth, feed and ui – leave the sentry:9000 – change everything around it!
make down-up
Now every time you bring it up it will all work and you can create amazing micro services for DP!
make stop
make start
If you commit and push any changes to the other repos always run:
make git-up
This will bring your containers down pull all the repos from git hub rebuild everything and bring it all back up.
If it all comes back up and appears in your browser (automatically opens on macs) awesome. If not, please fix asap!!!
Trouble Shooting
If you run into any problems:
make git-clean
This will clean docker, clean your composer installs and rebuild all images. Then bring it all up for you.
Once the temporal table is uploaded, you can play with the data, execute Eloquent & SQL queries, import the content into the final table, etc., and of course once you finish working with the data you can remove the temporal table.
Using node instead of PHP for reading and import spreadsheets is considerably faster, also, because you will work with a temporal database table, the data is much easier to work with and the operations are faster.
Compatible with PostgreSQL as MySQL
Uses pg-copy-streams for faster inserts in PostgreSql datatabases.
Uses xlsx to parse xlsx files.
$ xlsx-laravel-spreadsheet-importer --help
Options:
--help Show help [boolean]
--version Show version number [boolean]
--input, -i Input xlsx file [string] [required]
--sheets, -s Only import specified sheets [array]
--sheetsIndex, --si Only import specified sheets index [array]
--prefix, -p Prefix is prepended to the table name
[string] [default: ""]
--tableNames, -n Table names to use when storing the data (instead of the
sheet name) [array] [default: []]
--batchSize, -b Amount of rows per single insert query
[number] [default: 1000]
--drop Drops and recreates matched tables
[boolean] [default: false]
--create, -c Creates tables [boolean] [default: false]
--id If set generates and ID column with the value
[string] [default: null]
--relatedId Name of the related ID where the data comes from (to send
to the artisan command) [string] [default: null]
--relatedClass Name of the related Model Class where the data comes from
(to send to the artisan command) [string] [default: null]
--columns Extra column:value to add into the database
[array] [default: []]
--formatted, -f Read as formatted text by default
[boolean] [default: false]
--artisan Laravel php artisan path [string] [default: ""]
--php php executable path [string] [default: "php"]
--env enviroment to sent to the artisan command
[string] [default: ""]
Artisan command
If the --artisan option is set it will create a Laravel artisan command with the progress of the import that can be read in a Laravel app.
Option
Possible values
Description
–relatedClass
Any value used a relatedClass param
Optional id that was sent as a param when running the script (useful to associate the data to a model for example)
–relatedId
Any value used a relatedId param
Optional id that was sent as a param when running the script (useful to associate the data to a model for example)
Depends of the type of the progress, for total_rows the number of rows, for table_created the name of the table, for error the error message, for processing the total rows processed
Data related with the progress type
–env
Laravel app enviroment
Optional env that was sent as a param when running the script (to run the artisan command in different enviroments)
–pid
The current process id
The process id of the running script, useful for kill the process if neccesary
This repository contains the source code for COVID-19 EnsembleVis, a visual analytics system that allows the assessment of ensembles and individual models at the county level, by enabling users to effortlessly navigate through and compare ensemble members considering their space and time dimensions. This visual interface provides an overview summary of ensemble data to assess uncertainty, identifies spatiotemporal trends, i.e., how a group of members change over space and time, and visually identifies differences between two or more ensemble members.
You will need to install Node.js and Angular to build the interface and Jupyter to preprocess the data. You can install all prerequisites by first installing Anaconda (or miniconda) and running the following command:
conda install nodejs jupyter
Pre-processing the data
COVID-19 EnsembleVis makes use of forecasts collected by the COVID-19 Forecast Hub, a site that maintains up-to-data records for forecasts of COVID-19 cases, deaths and hospitalizations in the US. The data is hosted on their GitHub repository, so in order to pre-process the data, first clone the repository:
Next, run our parser notebook inside the preprocessing folder. The notebook considers that the COVID-19 Forecast Hub repository was cloned at the same level of the COVID-19 EnsembleVis repository. In other words:
The jupyter notebook parser.ipynb will save a json file (models.json) inside the folder vis/src/assets/ containing the pre-processed data required by the interface.
Building the project
The project was generated with Angular CLI version 12.2.0. First install Angular CLI using npm (the default package manager for Node.js):
npm install –g @angular/cli
Next, run ng build inside the vis folder to build the project, and ng serve to create a server and serve the COVID-19 EnsembleVis application. The interface will be available at http://localhost:4200/.
This Matlab tool calculates the radiator return temperature as based on the performance/rating measures making use of various mean temperature difference approaches.
The main idea here is to develop simple and reliable emprical models for residential radiator units so to be used in system level modelling (i.e. at district heating simulations). Hence, this Matlab models estimate the radiator behaviour in terms of return temperature at different operational conditions (e.g. changing heat demand rate at different degrees of supply temperature).
Four different Matlab functions are given, each basing on different approaches for the radiator excess temperature such as either Logarithmic Mean Temperature Difference (LMTD) – implicit, Geometric Mean Temperature Difference (GTMD) – explicit, or Arithmetic Mean Temperature Difference (AMTD) – explicit.
Error evaluation are involved for GMTD and AMTD approaches, as error criteria formulated with the approach factor.
In order to avoid deviations at low flow conditions, Schlapmann factors are included in the AMTD method.
You are free to use, modify and distribute the code as long as authorship is properly acknowledged. The same applies for the original works ‘XSteam.m’ by Holmgren M.
Acknowledgement
We would like to acknowledge all of the open-source minds in general for their willing of share (as apps or comments/answers in forums), which has encouraged our department to publish our Matlab tools developed during the PhD study here in GitHub.
This Matlab tool makes use of other original open-source project:
XSteam by Holmgren M. | Author Description: XSteam provides accurate steam and water properties from 0 – 1000 bar and from 0 – 2000 deg C according to the standard IAPWS IF-97. For accuracy of the functions in different regions see IF-97 (www.iapws.org).
Tol, Hİ. District heating in areas with low energy houses – Detailed analysis of district heating systems based on low temperature operation and use of renewable energy. PhD Supervisors: Svendsen S. & Nielsen SB. Technical University of Denmark 2015; 204 p. ISBN: 9788778773685.
References
Phetteplace GE. Optimal design of piping systems for district heating. Hanover, N.H.: U.S. Army Cold Regions Research and Engineering Laboratory; 1995.
Bøhm B. Energy-economy of Danish district heating systems: A technical and economic analysis. Lyngby, Denmark: Laboratory of Heating and Air Conditioning, Technical University of Denmark; 1988.
Benonysson A. Dynamic modelling and operational optimization of district heating systems. Lyngby, Denmark: Laboratory of Heating and Air Conditioning, Technical University of Denmark; 1991.
British Standards Institution. BS EN 442-2:2014: Radiators and convectors – Part 2: Test methods and rating 2014:82.
Soumerai H. Practical thermodynamic tools for heat exchanger design engineers. New York: Wiley-Interscience; 1987.
Radson. Kv-calculator_-_03-2012(1).xls 2012:2.
Schlapmann D. Heat output and surface temperature of room heat emitters [Warmeleitung und oberflachentemperatureen von raumheizkorpern] (German). Heiz Luft Haustechnik 1976;27:317–21.