Skip to main content

숭실대학교 물리학과 실험에 사용되는 데이터 처리 및 시각화 도구

Project description

SSUphysics experiment supporting tools

숭실대학교 물리학과 물리계측실험 수업에서 유용하게 사용할 수 있는 python 페키지입니다.

향후 다른 실험 수업에서도 사용할 수 있도록 확장할 예정입니다.

How to install

pip install SSUphysicsTools

Example

다음의 repository를 참고하여 사용할 수 있습니다. SSUphysicsTools-example

How to use

Setting up

실험 데이터는 data 폴더에 저장되어 있어야 합니다. 이 때 data 폴더는 다음과 같은 구조를 가지고 있어야 합니다.

data
├── experiment 1
│   ├── 1.csv
│   ├── 2.csv
├── experiment 2
│   ├── 1.csv
│   ├── 2.csv
└── ...

만약 data 폴더가 준비되지 않았더면, 자동으로 data 폴더를 생성하고 DataDirectoryEmptyError를 발생시켜 data 폴더에 실험 데이터를 넣도록 알려줍니다.

getting data

data 폴더에 저장된 실험 데이터를 가져오는 방법은 다음과 같습니다.

from SSUphysicsTools import getting_data as gd
from padas import pd
data_paths=gd.get_all_csv_paths_in_data(custom_dir_name=True, flatten=False)()
data_set:list[pd.Dataframe]=[gd.read_csv_Tektronix(path) for path in data_paths]

위 코드는 다음과 같은 순서로 작동합니다. 0. SSUphysicsTools 패키지 중 getting_data module을 import 합니다.

  1. get_all_csv_paths_in_data를 이용하여 실험 데이터의 경로를 가져올 수 있습니다.
  2. read_csv_Tektronix를 이용하여 실험 데이터를 가져올 수 있습니다. 이 때 list comprehension을 이용하여 가독성 높임과 동시에 여러 실험 데이터를 가져올 수 있습니다.

[!warning] data_setnumpy.ndarray로 두지 마십시오. numpy.ndarraypandas.DataFrame의 내용을 전부 풀어서 저장하기 때문에 데이터를 다루기 어려워집니다.

|column1|column2|column3|
|-------|-------|-------|
|data1  |data2  |data3  |
|data4  |data5  |data6  |
...

-> numpy.ndarray를 사용하면 다음과 같이 저장됩니다.
array([data1, data2, data3, data4, data5, data6, ...])

processing data

  • Regression
    • cosine_regression
  • Delate_offset

analyzing data

  • Phase_shift
    • find_min_x_vector
    • find_ym_y0
    • call : get_phase_shift
  • get_error_rate

plot

  • DataPlots
    • data_plots
    • Lissajous_plots
  • plot_table

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ssuphysicstools-2.1.3.tar.gz (10.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

SSUphysicsTools-2.1.3-py3-none-any.whl (11.5 kB view details)

Uploaded Python 3

File details

Details for the file ssuphysicstools-2.1.3.tar.gz.

File metadata

  • Download URL: ssuphysicstools-2.1.3.tar.gz
  • Upload date:
  • Size: 10.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.13.0

File hashes

Hashes for ssuphysicstools-2.1.3.tar.gz
Algorithm Hash digest
SHA256 48d757679ca100972a29e5bc9c3ef2ef81300013e6e9ff942e2e44f6a7e1d090
MD5 76f0bc8c182f3220386fc0f9fce0e769
BLAKE2b-256 6ca4c4d28ca29572c78a70a29893e49cbf86ba865628640baa3d43f4c262e88d

See more details on using hashes here.

File details

Details for the file SSUphysicsTools-2.1.3-py3-none-any.whl.

File metadata

File hashes

Hashes for SSUphysicsTools-2.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 b9a2075eb0f73cec98bc21e7f1453ac06a75ef7fba7511b80a3d8474f05136c4
MD5 1b8bad52fcfd0e142b7ce03c8b604fe8
BLAKE2b-256 4e0cbaba6400a0d83743b4700e8510aa0b57733ee0df28f511596cbd945d4cb1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page