Tootfinder

Opt-in global Mastodon full text search. Join the index!

@hynek@mastodon.social
2024-04-07 23:14:32

As the person who has been called being “famous for advocating for the src layout” I endorse this message.
Occasionally I get that suggested by Copilot and I weep for who taught it that.
The whole point of the src directory is to NOT be importable.
hachyderm.io/@nedbat/112232430

@mgorny@pol.social
2024-04-03 06:12:33

Naprawdę, kiedy Pythonowcy wreszcie zrozumieją, że "przestrzenie nazw" w paczkach były jedną, wielką pomyłką? Zwłaszcza, kiedy używane są tylko po to, by pompować ludziom ego.
github.com/pytest-dev/pytest/i

@scottmiller42@mstdn.social
2024-03-01 15:53:21

Due to my assumption that my code will (eventually) be used to train AI, I've been obfuscating my #LeetCode submissions.
Today, I figured out how to use the #Python walrus operator inside a list to mash variable assignment into a return statement. It's delightfully horrible. Check out this o…

This is a screenshot of some Python code that was deliberately written in a way to be confusing (aka, obfuscated):

from collections import Counter
def DoSomething (s:str) -> str:
    return [CharCount := Counter(s), 
            f"The string has {CharCount['0']} zeros."
            ][1]

#  This prints "The string has 4 zeros."
print (DoSomething ('00011110'))
@nobodyinperson@fosstodon.org
2024-02-13 16:32:53

Grr I let my data analysis run for 2h, just for it to blow up at the *last* crucial saving step with a stupid ImportError because I forgot to 'import pickle' 🤦 I should run #mypy more often... 😅
#Python #dataAnalysis

@arXiv_physicsbioph_bot@mastoxiv.page
2024-05-01 07:04:57

Advanced analysis of single-molecule spectroscopic data
Joshua L. Botha, Bertus van Heerden, Tjaart P. J. Kr\"uger
arxiv.org/abs/2404.18945 arxiv.org/pdf/2404.18945
arXiv:2404.18945v1 Announce Type: new
Abstract: We present Full SMS, a multipurpose graphical user interface (GUI)-based software package for analysing single-molecule spectroscopy (SMS) data. SMS typically delivers multiparameter data -- such as fluorescence brightness, lifetime, and spectra -- of molecular- or nanometre-scale particles such as single dye molecules, quantum dots, or fluorescently labelled biological macromolecules. Full SMS allows an unbiased statistical analysis of fluorescence brightness through level resolution and clustering, analysis of fluorescence lifetimes through decay fitting, as well as the calculation of second-order correlation functions and the display of fluorescence spectra and raster-scan images. Additional features include extensive data filtering options, a custom HDF5-based file format, and flexible data export options. The software is open source and written in Python but GUI-based so it may be used without any programming knowledge. A multi-process architecture was employed for computational efficiency. The software is also designed to be easily extendable to include additional import data types and analysis capabilities.

@risottobias@tech.lgbt
2024-05-04 04:11:14

# !/usr/bin/env python3
# small_universe_test.py
import pandas as pd
const lightyear = 9461000000000000
const size = 930000000000 * lightyear # 8798730000000000000000000000
# largest number on some registers is 9223372036854775807 or 18446744073709551615
universe = sphere(radius=size,x=0,y=0,z=0,t=0)
pd.Series(universe, filling_function)
pd.Plot()
#cosmology #astrophysics #python

@arXiv_eessIV_bot@mastoxiv.page
2024-04-10 06:54:00

Raster Forge: Interactive Raster Manipulation Library and GUI for Python
Afonso Oliveira, Nuno Fachada, Jo\~ao P. Matos-Carvalho
arxiv.org/abs/2404.06389