Saravanan666/pypi-org huggingface dataset:
Package: photo-sorter
photo-sorter.pymasterdevelopThis is a python script to automatically sort photos from a Canon camera.
In principle, this should also work with other directories containing
images, but it is primarily done for theCanon Powershot G7 X's
image structure.The script assumes a directory structure like this;- DCIM
-- images&videos_1
-- images&videos_2
-- ...
-- images&videos_n
-- CANONMSC (optional, will be deleted)What does the script do?1. Set up new folder structureFirst, it will create a new directory structure like so:- DCIM
-- Images
--- Raw
--- High Quality
--- Low Quality
-- Videosand move all relevant image and video files in the directories.Raw files (.CR2) will be put into theImages/RawdirectoryJPG files will be put into theImages/High QualitydirectoryMP4 files will be put into theVideosdirectory2. Look for missing JPG filesIf Raw files exist without a corresponding JPG file, the .CR2 file's
preview image will be extracted and equiped with the same exif data as
the .CR2 file and stored in theImages/High Qualityfolder.3. Rename according to exif dataAll image files will be renamed according to their exif timestamp. The
file names will follow the formatYY-MM-DD---hh-mm--ss4. Create lower quality JPG filesAll High Quality JPG files are converted down to ~1080p (1920x1080 / 1080x1920)
and put into theImages/Low QualityfolderOptional: MergeIf more than one directory is passed as an argument, These directories are first
processed with Steps 1-4 indivdually and then merged. The resulting folder will
be calledMergedHow do I use this script?Just call the script usingphoto-sorter <directory 1> <directory 2> ... <directory n>.This will process each directory individually and then merge them together.Dependencies:The following commands need to be installed and in the system's PATH:exiftooljpegoptimconvert(Part ofimagemagick)To install these on Arch Linux, run the following command:sudo pacman -S imagemagick jpegoptim perl-image-exiftoolInstallation on other distributions may differ.Further InformationChangelogLicense (GPLv3)GitlabGithubProgstatsPyPi
Package: photos-picker
Photos PickerThis libary allows to pick photos in a folder according to a given strategy (last photos, random photos...) and copy them to a destination (another system folder, Dropbox or Google drive folder...)CompatibilityThis library currently works with Python 2.7, Python 3.4, Python 3.5, Python 3.6 and Python 3.7.Install$pipinstallphotos-pickerUsageThe main classPhotosPickeraccepts a "picker", a tuple of "filters" and an "uploader" as arguments. The picker allows to select photos while the filters modify them. At the end of the process, the uploader copy transformed (or not) photos to a given destination. Below the simplest example which copy the 50 lastest photos to another directory:# Python 2.7 examplefromphotospicker.exception.abstract_exceptionimportAbstractExceptionfromphotospicker.picker.pickers.last_photos_pickerimportLastPhotosPickerfromphotospicker.uploader.uploaders.filesystem_uploaderimportFilesystemUploaderfromphotospicker.photos_pickerimportPhotosPickerif__name__=='__main__':try:picker=LastPhotosPicker('/pictures',50)uploader=FilesystemUploader('/destination')photos_picker=PhotosPicker(picker,(),uploader)photos_picker.run()exceptAbstractExceptionaserr:printerr.messageSince picking and uloading may take a while, progress events are dispatched.
You can see a more complex example which displays work progresshere.Pickers:LastPhotosPicker: pick thenlastest photos.RandomPicker: pick randomlynphotos.SmartPicker: pick randomynphotos. Recent photos have more chance to be picked than old ones. It results by a picking of a majority of recent photos and a few old ones.More detailshereNote you can also create your own picker extending the base classAbstractPicker.Filters:ResizeFilter: resize the photos with the given width and height. The final photos size are computed for avoiding distortion.RotateFilter: Rotate the photos according to EXIF data.More detailshereNote you can also create your own filter extending the base classAbstractFilter.Uploaders:Note that uploaders don't append new photos. Either the directory must be empty or the uploader clear it before copying files.FilesystemUploader: copy the photos to a given directory. This directory must exist and be empty.DropBoxUploader: upload the photos to Dropbox. Note that you should limit your token access to application. Creating a full access token is not needed and may induce security issues.GDriveUploaderupload  the photos to Google Drive.More detailshereNote you can also create your own uploader extending the base classAbstractUploader.ContributingThe project is currenlty currently shipped with many pickers, filters or uploaders. But others can be developed, you may post an issue for that. Or better, readhow to post a pull request:)
Package: photostation
A Python API to communicate withPhoto Stationrunning on Synology NAS. Photos and videos are uploaded directly to PhotoStation through its Web API with various metadata including ratings, title, description, and GPS coordinates.This module uploads original files and lets Synology to process the required thumbnail versions. This works fine with Synology DS916+ but might be too slow with models having slower processors.Supported features:Login to your shared or personal Photo StationList album contentsCreate missing albums automaticallyAdd new photosUpdate metadata of existing photosUpdate photo binaries based if either timestamp or filesize differsDelete photosTested with Synology DS916+ running DSM 6.1 and Photo Station 6.7.1. Should work with older versions too but you mileage may vary.Installationpip install photostationUsagefrom photostation import PhotoStationService, SynologyException
import requests

try:
    # login to Photo Station and set up root album
    service = PhotoStationService('https://USERNAME:PASSWORD@xyz.synology.me/photo/webapi/', 'root-album')

    # get reference to album and create it if missing
    album = service.album('2017/05/13', create=True)

    # list album content (subalbums, photos, videos)
    print(album.items)

    # add photo reference inside album
    photo = album.create_item(
        filename = 'testimage.jpg', # original filename
        filetype = 'photo',         # photo or video
        created = 1494603121336,    # timestamp of photo capture
        modified = 1494603121336    # optional timestamp to compare if existing binary has changed
        filesize = 1000,            # optional filesize to compare if existing binary has changed
        title = '',                 # optional title
        description = '',           # optional description
        rating = 0,                 # optional starts from 0 to 5
        latitude = 60,              # optional coordinates for videos
        longitude = 20)             # optional coordinates for videos

    # update metadata of existing photos
    merged = photo.merge()

    if merged:
        print('metadata was updated or already up to date, deleting photo')

        photo.delete()
    else:
        # upload new file
        stream = requests.get('https://dummyimage.com/600x400/000/fff', stream=True)
        photo.save_content(stream)

except SynologyException as se:
    print se.value
Package: photostats
This is a Python package that will eventually have a bunch of utilities for running a variety of stats on
your photos based on EXIF data. By using exiv-based library, it can also read data
from RAW files.Currently will print output to the commandline and produce a bar graph for eachcategory.usage: __main__.py [-h] [-p PATH] [-g GRAPHPATH]optional arguments:-h,--helpshow this help message and exit-pPATH,--pathPATHPath to recursively search for photos-gGRAPHPATH,--graphpathGRAPHPATHPath to save graphs generated by this programIt will produce output like:Lens Model Count:EF17-40mm f/4L USM : 18EF28-105mm f/3.5-4.5 USM : 8055-200mm : 6035mm : 23Focal Length Count:17 mm : 1420 mm : 428 mm : 335 mm : 2355 mm : 1260 mm : 1063 mm : 564 mm : 365 mm : 470 mm : 4175 mm : 282 mm : 190 mm : 198 mm : 7105 mm : 17200 mm : 34Make-Model Count:Canon Canon EOS Rebel T6s : 181Google Pixel : 143Motorola XT1096 : 96
Package: photo-steganography
project-templateA module for hiding images inside other images, as well as videos.first of allspecifics:writen and owned by: Shahaf Frank-Shapirall the rights are saved for: Shahaf Frank-Shapirprogramming languages: python 3.9.12 (100%)before we startdescription:visit the docs to learn more about this project and how to develop with it.dependencies:opening:
For this is a complex program, which uses a lot of modules, there are required dependencies needed
in order to run the program. keep in mined the program was writen in python 3.9, so any python version lower
than 3.9 might not work properly.install app dependencies by writing the "-r" option to install the requirements
writen in a file, and write the following line in the project directory:pip install -r requirements.txtrun a testrun from windows command line (inside the project directory)run with python by writing to the command line in the project directory:python test.py
Package: photos-where
Where - day by day location from your photosThis scripts reads EXIF data from your photos and generates CSV file or Pandas dataframe with day by day location in terms of country.It relies on my packageexif2pandas. It usesreverse-geocoderto convert GPS data to country codes. That module uses a csv file with 150k cities and then uses nearest neighbour algorithm to find the position of each gps data point. This sometimes does not work in border regions so if you are seeing bad data the easiest fix is to copycities.csvand add your village etc.In case some of your photos contain bad gps data that show that you have been to countries where you have never been you can useignore_countriesargument.world mapGenerated world map with colored regions according to how many days you have spent in the country.Pie graph with number of days you spent in a countryCSV file with your travel list:id,from,to,days,country,country_code
4,2015-11-07,2015-11-09,1,Scotland,GB
5,2015-11-09,2015-12-12,32,Praha,CZ
6,2015-12-12,2015-12-12,0,Budapest,HU
7,2015-12-12,2015-12-12,0,Praha,CZ
8,2015-12-12,2015-12-15,2,Budapest,HUnote that the country column is usually wrong - this is because the cities.csv is not consisent with administrative boundaries beyond country_code.Year by year histogramsRaw dataframes:Finally there is a raw dataframe with exif data per image file:Jupyter examples:Seeexample.ipynbfor example graphs and data frames exported.Install:See PYPIPython package.$ pip install photos-whereUse:$ photos_where Dropbox/Photos/2020/
$ ls where
cities-pie.jpg      
countries-pie.jpg
intervals.csv
location-by-day.csv 
photos.feather     
years.jpg
Package: photosync
Synchronize your phone photos easilyEach time you take new photos with your phone and you want to transfer them to your computer you have the same problem:
when did you last transfer them? What should you transfer? How to know if you have already back them up? This program is
here to help solving that problem. It is not really a synchronisation program. Actually it will keep track of already
transferred files, so you copy each file from the source once. When copied, you can sort, move, reorganize them or whatever.
You don’t need to keep them as there were transferred to avoid them being transferred again next time. That’s why it is not
really a synchronization program.The “database” is a clear text JSON file optimized for quick finding.As of my Android phone, photo and video file names have to contain the following pattern :(IMG|VID)_YYYYMMDD.installationpip install .This will install aphotosyncscript.usageusage: photosync [-h] [-d DB] [-v] src dest

positional arguments:
  src             where are the photos you want to copy
  dest            where you want to copy your photos

optional arguments:
  -h, --help      show this help message and exit
  -d DB, --db DB  the location of the file that contains information about
                  already transferred photos
  -v, --verbose
Package: photosynthetic
PhotosyntheticPhotosynthetic is a python library that uses a unique clustering and distance algorithm to
determine the perceptual color palette of an image. It offers a high degree of flexibility
and configuration, allowing you to dial it in for post-processed images, illustrations,
low-saturation, or product images!A few examples of what you could do with this library:Create a fun, albeit useless, image host centered around color palettes like :https://photosynther.netDetermine the primary color of product images for your eCommerce merchandising pipelineHave fun!Combine reference images into a brand guide or design systemAutomatically change themes based on profile imagesAnd probably at least a little but moreUsage:This library can be used one of two ways, you can import the package into your own project
and use it as a library, or you can use it via the command line by passing in an image
filepath as the first argumentCommand Line Usagepythonmain.pypath/to/file.pngLibrary UsageQuickstart (Will extract a palette using sane and generic analysis defaults)fromphotosynthetic.PaletteimportPalettep=Palette('images/test.png')palette=p.extract()print(palette)# Returns :#
Package: phototodices
photoToDicesconvert photo to DicesUsing1-create a virtualenvpython3 -m venv .venv2-activate the virtualenv. ./.venv/bin/activate3-install packagepip install phototodices4- run it :)python app.pycontain more than 3M dicesLicenseThis project is licensed under theMIT LicenseHAVE FUN :DThanks forJadi
Package: phototrie
phototrie (and other helper scripts)Phototrie is a minimalistic application for quickly sorting through your
photographs.This repository also includesbatchrenameanddatename, two commands useful
for organising photographs.UsagephototrieRunphototrie JPGin a directory where you have unsortedJPGphotos.CR2photos in the same directory, or in aCR2/subdirectory,
with the same name will also be processed.Wait a short while for thumbnails to be generated. Once this has completed,
a window will pop up, showing your photos.PressBto mark a photo asbad,GforgoodandPforpristine(future versions may allow custom names).Phototrie will move them into directories with those labels as you go along.datenamedatename photo1.jpg photo2.jpg(etc)e.g.datename *.JPGto process all JPG files in a directory.This will rename photos to have their date (as stored in EXIF) as their name.CR2photos in the same directory, or in aCR2/subdirectory,
with the same name will also be processed.Once you are ready to apply the changes for real, pass--apply(or-y).batchrenamebatchrename <regex> <replacement> photo1.jpg photo2.jpg(etc)e.g.batchrename .JPG$ .jpg *.JPGOnce you are ready to apply the changes for real, pass--apply(or-y).InstallationYou will probably need to install (on Debian/Ubuntu):apt install python3-dev python3-pip python3-tk python3-pil python3-pil.imagetkThen you can use:pip3 install --user phototrie(or, install from this repository:pip3 install --user git+https://bics.ga/reivilibre/phototrie)
Package: photoweb
Photoweb creates HTML galleries based on in-photo metadata, from flexible
templates. What’s different about it?It’s easy to add new photos; just drop them in the folder and re-runYou don’t have to track metadata; it comes from the photos themselves, using
standard embedded metadataIt’s easy to modify the templates to make your photos look great.See <http://www.mnot.net/photo/> for an example.Installing PhotowebPhotoweb needs:Python 2.6 or greater; see <http://python.org/>The PIL and pystache libraries.It’s easiest with PIP:$ pip install photowebUsing PhotowebTo generate the HTML for a gallery, call photoweb from the command line:$ photoweb .You can generate multiple galleries at once:$ photoweb beach hawaii snowWhen you first generate a gallery, you can specify the page title and
description, which will be used in the template:$ photoweb -p “At the Beach” -d “We went to the beach for a weekend. Fun!” .The page metadata will be saved in a file (md.json) for use next time you
run photoweb.Creating and Using TemplatesBy default, the default template will be used (from ~/.photoweb/tpl/default;
if it isn’t there, it’ll be automagically created). You can edit this, or
create new templates, using them with the -t option:$ photoweb -t “my template” .Templates are directories with the following files in them:md.json - a configuration filegallery.html - the overview pagedetail.html - a single photo pageTake a look at the default template to get an idea of how to create your own.LicenseCopyright (c) 2011-2012 Mark NottinghamPermission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the “Software”), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
Package: photowrench
photowrenchJust a small tool to perform photography related tasks that are
kind of annoying. So far following commands are implemented:remove-orphan-raws: removes raw files that do not match any picture file (e.g. .jpeg)rename-to-timestamp:  Renames files to their timestampType anytimephotowrench-hto see commands and options.InstalationThis is in PyPI, so just run:pip install photowrench
Package: photpy
PyPhotA Python library for the simulation of optical fiber transmission, characterized by the ability of running on both CPU and GPU to gain powerful acceleration.User guideFirst, you need to install necessary dependencies, open the CLI and enter this command:pip3install-rrequirements.txtThere is anexample.pyunder the root directory showing how to use our API (for PyPhotEngine). Please read it carefully.Generate requirements.txtrequirements.txtis useful for installation of related dependencies, you can generate it by command line toolpipreqs, enter the root directory and execute this command:pipreqs.--modegt--force--ignore./testDeprecated phot moduleThe deprecated phot module is indeprecatedfolder. It is just reserved for developers. If you are user, just ignore it.
Package: phot-py-tyz
PyPhot一个用于光纤仿真运算的 Python 库。目前已经实现的组件包括：随机二进制生成器QAM调制器RRC脉冲整形DAC的量化噪声激光器产生的相位噪声高斯白噪声双偏振的光纤传输信道收发端激光器造成的频偏接收机造成的I/Q失衡ADC的量化噪声IQ正交化补偿频偏估计和补偿帧同步自适应均衡BPS相位恢复分析器画星座图和眼图计算误码率和 Q 影响因子此外，我们还实现了多种方式的加速效果：光纤传输部分采用了 GPU 加速发射端和接收端组件采用了 JIT 加速运行代码# 安装相关依赖pipinstall-rrequirements.txt# 运行代码示例pythonexample.py主目录下的 Python 文件example.py展示了 PyPhot  所有组件 API 的使用方式。TOML 配置文件TOML 配置文件是用于前端定义组件和计算引擎实现自动调度的，都位于toml目录下。开发者文档开发者文档提供了对于开发者的指导。组件清单组件分为两种：函数和类。
Package: photutils
Photutils is anAstropypackage for detection and photometry of
astronomical sources.Please see theonline documentationforinstallation instructionsand usage
information.Citing PhotutilsIf you use Photutils for a project that leads to a publication,
whether directly or as a dependency of another package, please include
the following acknowledgment:This research made use of Photutils, an Astropy package for
detection and photometry of astronomical sources (Bradley et al.
<YEAR>).where (Bradley et al. <YEAR>) is a citation to theZenodo recordof the Photutils
version that was used. We also encourage citations in the
main text wherever appropriate. Please see theCITATIONfile for details and an example BibTeX entry.LicensePhotutils is licensed under a 3-clause BSD license.  Please see theLICENSEfile
for details.
Package: phouse
Phouse easy work with clickhousehttps://github.com/bedretdinov/phousefor installpip3installgit+https://github.com/bedretdinov/phouseExamplesfromphouse.phouseimportPhouse# The connection will be repeat if get failed. It is need for stability your ETL scripts.# The script will try until get connection. try with interval 60 secpd=Phouse.getConnection({'host':'0.0.0.0','user':'default','password':'','database':'owox'})# return pandas dataframedf=pd.clickhouse_query(''' SELECT database, name FROM system.tables ''')# !!!! And very important things this data frame must have date column else you get errordf['date']=pd.to_datetime('today')# insert to the tabledf.clickhouse.append(table='new_table')# The table is created automatically# truncate table and insertdf.clickhouse.write(table='new_table')# The table is created automatically# write by packagefromsklearnimportdatasetsiris=datasets.load_iris()df=pd.DataFrame(iris.data,columns=iris.feature_names)df['date']=pd.to_datetime('today')first=Truebuffer_size=10foriinrange(0,df.shape[0],buffer_size):item=df[i:i+buffer_size]if(first):item.clickhouse.write(table='iris_test')first=notfirstelse:item.clickhouse.append(table='iris_test')# How to create engine and partition# VersionedCollapsingMergeTreedf=pd.DataFrame([['Y',0.4,1,56],['N',0.6,-1,34]],columns=['status','probability','category','party'])df.clickhouse.drop(table='test333')df.clickhouse.VersionedCollapsingMergeTree(SIGN='category',VERSION='party',PARTITION='status',ORDER_BY='status',INDEX_GRANULARITY=8192)df.clickhouse.append(table='test333')# __________________________________________________________________# CollapsingMergeTreedf=pd.DataFrame([['Y',0.4,1],['N',0.6,-1]],columns=['status','probability','category'])df.clickhouse.drop(table='test333')df.clickhouse.CollapsingMergeTree(SIGN='category',PARTITION='status',ORDER_BY='status',INDEX_GRANULARITY=8192)df.clickhouse.append(table='test333')# __________________________________________________________________# CollapsingMergeTreedf=pd.DataFrame([['Y',0.4,1],['N',0.6,-1]],columns=['status','probability','category'])df.clickhouse.drop(table='test333')df.clickhouse.CollapsingMergeTree(SIGN='category',PARTITION='status',ORDER_BY='status',INDEX_GRANULARITY=8192)df.clickhouse.append(table='test333')# __________________________________________________________________# AggregatingMergeTreedf=pd.DataFrame([['Y',0.4,56],['N',0.6,23]],columns=['status','probability','category'])df.clickhouse.drop(table='test333')df.clickhouse.AggregatingMergeTree(PARTITION='status',ORDER_BY='status',INDEX_GRANULARITY=8192)df.clickhouse.append(table='test333')# __________________________________________________________________# Clean tabledf.clickhouse.truncate(table='test333')
Package: phovea-clue
DEPRECATED: phovea_clueCLUE (forCapture,Label,Understand,Explain) is a model that tightly integrates data exploration and presentation of discoveries. Based on provenance data captured during the exploration process, users can extract key steps, add annotations, and author 'Vistories', visual stories based on the history of the exploration.Further resources:Vistories.orgProject HomepageExamples using CLUE:StratomeXandGapminderDEPRECATION InformationPlease note that this project has been archived and is no longer being maintained. There is an active development underhttps://github.com/datavisyn/tdp_coreand we will also contribute our future changes to it.Installationgit clone https://github.com/phovea/phovea_clue.git
cd phovea_clue
npm installTestingnpm testBuildingnpm run buildUsageThe most important module istemplate.tsproviding a wrapper for an application to include CLUE. See Caleydo/clue_dummy
for an simple example how to use it.This repository is part ofPhovea, a platform for developing web-based visualization applications. For tutorials, API docs, and more information about the build and deployment process, see thedocumentation page.