Exemplo n.º 1
0
def send(conn: Conn, data: bytes) -> int:
    if conn.close:
        raise ConnException('Connection closed')

    sent = send_data(conn, data)
    print('Sent', sent, 'bytes')

    return sent
Exemplo n.º 2
0
    ('Truong, Lilianna', 'The Veiled Identity', 'Being faced with decades of continuous stereotypes and misconceptions, the Native American identity has been warped and lost. Influences of media, social activism and other forms of American perception have all lead to the false representation of people with rich history, knowledge, and complexity.', '8 in x 13 in x 1in', 'Acetate, foamcore, oil based marker'),
    ('Nguyen, Emily', 'Capitalism, Environmentalism, and Racism', 'A broad depiction of the dynamic between racism against African Americans, environmentalism, and capitalism.', '17 x 10 x 1.5', 'Resin, embroidery thread, wood'),
    ('D’Ambrogia, Kelly', 'The Urban Tree', 'This tree is a depiction of the effects of urbanization on the natural environment. Urbanization often leads to a loss of natural habitats, deforestation, and pollution. I made ropes out of plastic bags, which are wrapped around the tree to symbolize the effects of pollution and loss of natural areas. The butterflies are made out of soda cans, and the flowers are made out of plastic bottles, to represent how nature and urban areas are sometimes able to coexist, despite negative impacts. The base is made of recycled paper which I painted over with watercolors to create the grass. ', '7 x 3 x 2', 'Branches, plastic bags, soda cans, plastic bottles, recycled paper, watercolors, sharpies'),
    ('Lew, Dylan; Adachi, Mei', 'Water Crisis Incarnate', 'Our art project is on the topic of Flint Water Crisis. The project will portray three different perspectives surrounding the crisis by highlighting key figures that were involved in this public health crisis, namely the guilty parties, affected parties and activists. We created three portraits with various photoshop technique applied, and the artistic objective of this artwork is to show the correlation between social and environmental aspect of the Flint water crisis and the magnitude to which the crisis impacted people of Flint. Through this we are addressing for environmental justice. ', '11 in. x 27.5 in ', 'Matte paper print'),
    ('Sosa, Diana', 'Gentrification in Oakland ', 'In my art, I decided to illustrate and use the symbol of yin and yang to demonstrate how gentrification is affecting Oakland. I wanted to create a visual representation of the "good" and the "bad" side side of gentrification and who is getting affected and benefiting from this. I wanted to illustrate this through a series of drawing and illustrations without many words being involved. I decided to illustrate this be creating like each side in the case of how people of color are being affected on the left side and how white people are benefiting on the right side. ', 'It\'s a poster so the height is 24in and the width is 17.625. Ideally the final product should not change drastically. ', 'Used programs of Adobe Photoshop and Illustrator to create and put these images together. '),
    ('Reyes, Teodora; Bermundez, Christal', 'Pieces of Oakland', '', '', ''),
    ('Chan, Crystal ', 'Behind', 'This dance piece is inspired by the story of immigration to the United States in the 19th century. Specifically, this piece shows three segments of immigration: leaving your home country and loved ones, journeying to a foreign country without knowing what is in store for you, and finally being used as cheap labor in America to build the transcontinental railroad and many other things. ', 'Dance video', 'Dance video'),
    ('Ortiz, William', 'More than Just a Dumb Fish', 'Growing up in the Central Valley, I constantly heard about the Delta Smelt. With these four images, I hope to display some of the arguments in this controversy and point the ridiculous nature of some.', '8.5in x 11in (4 pieces of same dimensions)', 'Bristol board, pencil, ink.'),
    ('Westin, Emma', 'Hopi Coiled Basket Plague ', 'This is a coiled basket plague in the style of the Native American tribe Hopi. Basket weaving has been an important part of the Hopi culture for many centuries, and the coiling technique applied to make this basket was one of three main methods they used while weaving. ', '3" x 10" x 10" ', 'Yarn. Rope.'),
    ('Lee, Natlie', 'Out of Sight, Out of Mind', 'I know who I am—a proud Asian American. But why was I so blind to the suffering of my own people who poured their blood, sweat, and tears into this land so I can proudly stand where I am today? \n\nWhy is our past forgotten? Why is our presence erased by the media  in the present? Why is our future so uncertain?', '14x17', 'watercolor, soft pastels, graphite pencil set'),
    ('Anselmo, Dylan', 'Where is our water?', 'I chose to illustrate the reality of where our water comes from. Learning about where California water actually comes from it inspired me to illustrate water in geometric lines and shapes. Because how we gather water now is more mechanical and separated from nature illustrated by the dam encompassing the circle and with the mountain. The circle containing the mountain represents the the picturesque ideal we have about where we think we get our water from and how it is separated from the reality of how we actually gather water. The bottom represents where a majority of our water goes which is municipal and agricultural but how the plants are wilted and the buildings are incomplete because at the level of water we are using in California could be dwindling unless we make changes to responsibly use our finite resources. ', '11x17 in', 'printed poster'),
    ('Zia, Yumna', 'A Flower Among Weeds', 'San Jose\'s horizon shows an amalgam of urban, suburban, and rural landscapes, which is representative of the various stages of San Jose\'s history. Described upon first sight as "The Valley of Heart\'s Desire," San Jose has started out as open mountains and fields. Over time the city was dominated by fruit orchards as canneries became a lucrative business rooted in San Jose. Soon, the majority of San Jose population settled in the center of the valley, what is known as downtown. At the center of San Jose rising tall buildings that make up its urban environment. However, the Mt Diablo mountain range still surrounds the center of this million-member city, while suburbs grow by the borders. San Jose stretches as far as the eye can see from some of its beautiful vista points. I painted this to display San Jose\'s dynamic landscape, which preserved its roots in nature even as the city grew and changed over time. Though its population grows at an increasing rate at the center of Silicon Valley, San Jose still possesses growing woods, clear mountains, hiking trails, and an abundance of wildlife.', '14"X17"', 'watercolor on paper'),
    ('Cartier, Abby', 'For All, For No One', 'A portrayal of the Klamath River ecosystem, with attention to important plants and animals to the Yurok tribe. The title addresses the different views of nature that have imparted on the same land in the form of property rights.Meaning, in the Yurok property rights system: all the richness of the ecosystem is for all to enjoy, but it is no one person\'s alone. ', '11 in. x 15 in. flat', 'marker and watercolor on paper'),
    # ADDED
    ('Randmaa, Jack', '[untitled sketches of San Francisco]', None, 'ink and watercolor'),
    ('Yang, Jonathan; Chen, Luming; Ma, Lynn; Chen, Percival', 'Dialectical Face', '22 in x 34 in', 'digital and collage'),
    ('Yuan, Yidan', 'Past and Present', None, 'digial'),
]

pieces = [
    dict(zip([ 'authors', 'title', 'desc', 'size', 'medium' ], row))
    for row in data
]

if __name__ == '__main__':
    sender.send_data(
        pieces=pieces,
        box_input_folder_id='57395093689',
        collection_name='sp18_0',
        semester_tag='sp18')
Exemplo n.º 3
0
def run(ip, port):
    try:
        data = os.popen("./getinfo.sh").read()
        sender.send_data(ip, port, data)
    except Exception as e:
        print e
Exemplo n.º 4
0
from socket import *
import sender
from time import sleep

sock = socket(AF_INET, SOCK_DGRAM)

calc = raw_input('Digite o calculo: ')
sender.send_data(sock, calc.encode('utf-8'), ('localhost', 3001))
response, client = sock.recvfrom(1024)
print(response.decode('utf-8'))
sleep(2)
sock.sendto('ACK', ('localhost', 3001))

Exemplo n.º 5
0
    ('Panning for resources: The successful development of California', 'Guo, Michelle;Kim, Nathan; Qi, Richard', ' We wanted to trace the extraction of resources that led to California’s continued success today. We depicted a series of miners panning in the Gold Rush environment, but instead of panning for just gold, the miners come up with a variety of items such as timber, fish, immigrants, railroads, etc. to modern day symbols such as the tech company logos which have contributed to the continued success of California’s Bay Area economy. This is accompanied with the issues and repercussions that each mined resource raised. Our artistic objectives include tracing California’s resources in a metaphoric and whimsical way, as well as providing social commentary when showing the subsequent environmental damage alongside aforementioned extraction. ', '11x14', 'colored pencil and pen'),
    ('The Tears of Generations ', 'Sullivan, Brendan ;Mcinerny, Brendan', 'In service of highlighting the injustice inflicted upon those who call the United States home. Separated by generations, the Cherokee Nation and modern day immigrants share a common foe--the United States Government. ', '16x20x1', 'Canvas and Paint '),
    ('The View from Above', 'Schellscheidt, June', 'HDR Photography. I am studying how vineyard owners create ecosystem security in the vineyards to ensure decent grape yields. Satellite imagery is used as a tool in order to adapt growth strategies.  ', '4 4x6 photos, maybe one 8x10', 'HDR Photography '),
    ('82 Midnight Suns', 'Conway, Anna', 'Jean, a young pilot starting her career, finds herself based in America\'s northernmost city, Barrow, Alaska. A Florida native, Jean expects the worst from the isolated state, but in turn develops a deep connection with the land and its people. Just as she becomes settled in her routine, a tragic event reveals the irony of Jean\'s work, bringing the raw relationship between imperial America and Iñupiaq people to the surface. Jean\'s time in Alaska exposes a world hardly known to the majority of Americans as well as the environmental and social consequences of capitalist venture and the "Manifest Destiny" complex. ', 'text', 'text'),
    ('Uprooted', 'Stephens, Cheyenne', 'This piece is meant to convey the relationship between the environment and humanity. The red represents human arteries. The tattered ends symbolize the attempted detachment of humans from nature. By denying the inseparability of the two, we are destroying ourselves along with our surroundings.', '37cm x 37cm x 1cm', 'Embroidery floss, linen'),
    ('Legacy', 'Ding, Xueting', 'Our generation leaves the scene on the left, looking forward to bright futures. But, we leave destruction in our wake; from fires to drought to pollutions, the Earth is left ravaged and dying.\nThe future generations walk in, entering the mess we\'ve left behind. Will they be able to live in this dying world?', '1 ft tall, 6 ft wide', 'Ipad app Procreate'),
    ('Mosaic Landscape', 'Hoage, Ariel', 'This piece integrates different gathered and found materials to explore the following questions. How do we see ourselves in relation to the natural world? How does this perspective change over time, and how does this change impact the physical landscapes we inhabit? How can we use different types of mapping and artistic representation to explore these concepts? ', '23" x 35" x 5"', 'Mixed media- Acrylic, Glass, Shell, Paper (papier mache and collage), plastic, dried house paint. adhesive '),
    ('Save Nature', 'Gaffney, Conall', 'My art shows the beauty of the natural world. It also explains the importance of the natural world to individuals and depicts how we are in grave danger.', '4 feet by 5 feet', 'Photography, printing'),
    ('The Gold Rush', 'Kim, Ashley', 'The Gold Rush attracted many immigrants to come to America to mine gold. However, the immigrants were disregarded. This artwork is to portray to story of immigrants through their skin. The reason why the immigrant’s skin color is not defined is because I want to represent the diverse racial groups of laborers from all over the world. ', '14" x 17"', 'Pencil, water color, color pencil, marker, sharpie'),
    ('Water Management in California ', 'Sepheri, Nika', 'I am a MCB and Math double major who appreciates art in all forms. Since I have started college I have not had a chance to practice art so I took advantage of this opportunity and made this piece for my final project.\nThis piece is a timeline for all of the important events, policies, and infrastructures that are related to water management in California. The timeline starts from 1848 and it goes until 2010. My goal is that people can picture and understand these events better, after having a visual representation.', '', 'Water color, colored pencils, and pen '),
    ('Tales from the Gold Mountain ', 'Mucho, Rachel', '"Tales from the Gold Mountain" depicts Chinese transcontinental railroad workers travelling through the Sierra Nevada mountains. The piece is done in a traditional Chinese watercolor style to depict the idealization of California in the late 1800s. The upper left corner depicts an old Chinese poem describing the sojourner experience. It reads: \n\nDispirited by life in my village home,\nI make a journey specially to the United States \n   of America.\nSeparated by mountains and passes, I feel an \n   extreme anxiety and grief;\nRushing about east and west does me no good.\nTurning in all directions—\nAn ideal opportunity has yet to come.\nIf fate is indeed Heaven\'s will, what more can \n   I say?\n\'Tis a disgrace to a man\'s pride and dignity.\n', '1920x1080 pixels', 'Photo manipulation and digital illustration'),
    ('Wild Fire', 'Meza Montoya, Gustavo', 'This song was inspired by the annecdotes from survivors in the recent wildfires that took place in Santa Rosa, California. The song reflects pain at the beginning and evolves to a reflective state by the end, in an effort to bridge an understanding with the environment to prevent any other disasters. ', 'n/a', 'The software used to mix all instrumentation was Garage band. Several instruments were used, along with a microphone and as well as some electronic music technology. '),
    ('Is vegetarianism cruelty free?', 'Garcia, Lizari', 'This purpose of this painting is to inform people about the effects that pesticides are having on people who live near were they are being sprayed. A study called CHAMACOS, done by UC Berkeley School of Public Health and Clinica de Salud del Valle de Salinas, started  about 16 years ago to show the negative effects that pesticides have on the people living in Salinas and the surrounding towns. Many things have been discovered but a lot of the people who live in Salinas are  illiterate so they can\'t read or understand the results, this is the reason that I decided to do an art project instead of a paper. The sky in this painting represents the negative impact that pesticides have on people, the mountains represents the environment, and the kids with different color clothes represent the kids who are part of the CHAMACOS study. The kids\' clothes are different colors because in the 1940\'s and 1950\'s when Cesar Chaves was advocating for field workers\'  rights the people would put a song while marching called "De colores," which literally means of colors. ', '16 by 20', 'oil paints, pictures of fields workers, and a canvas '),
    ('The Human and Crock', 'Xiao, Nan', 'From the Gold Rush Era to now, Environment is like a vessel of humanity. Sometimes, environment, as if a crock, contains our shapeless humanity; and sometimes, environment, as if a meduim, takes us from one place to another. ', 'unknown', 'Oil on Canvas '),
    ('Eutrophication in the Gulf of Mexico', 'Mehta, Monika', 'My art piece is supposed to represent eutrophication in the Gulf of Mexico. The dark part on the side is showing that run off fertilizer from farms and other areas that flow into the ocean is actually killing our reefs and native fish. This can affect the economy and natural ecosystems including birds that feed off of these fish.', '11x14', 'I used a canvas and watercolor paints.'),
    ('Worster\'s Theoretical Framework coming to life', 'Adler, Lila', 'Here is the depiction of Worster\'s theoretical framework coming to life. First the venn diagram to your left is an illustration of New Orlean\'s "instrumentalist" view on the use of nature. Next the center diagram is Hurricane Katrina followed by the shift towards "inter subjective" views on nature.', '10x22', 'Charcoal pencils, White canvas'),
    ('Field worker holding son\'s hand', 'Sanchez, David', 'This piece portrays a field worker holding their son\'s hand which represents the sacrifices they make for their families by working in such harsh conditions. The grapes represent the activism of field workers during the 1960s. I wanted to relate my work to the policies concerning immigration, DACA, and citizenship which is easy to think of in a solely political way, but I want to remind people that this is a much more personal matter.', '8x10 in', 'I used graphite pencils on sketch paper.'),
]

pieces = [
    dict(zip([ 'title', 'authors', 'desc', 'size', 'medium' ], row))
    for row in data
]

if __name__ == '__main__':
    sender.send_data(
        pieces=pieces,
        box_input_folder_id='57392956412',
        collection_name='fa17_0',
        semester_tag='fa17')
Exemplo n.º 6
0
def send_data(spo2, hr, red_buffer, ir_buffer, temperature):
    sender.send_data(WS, USERNAME, spo2, hr, red_buffer, ir_buffer,
                     temperature)
Exemplo n.º 7
0
handler = logging.StreamHandler()
handler.setLevel(logging.DEBUG)

logger.addHandler(handler)

SCAN_TIME = 3

if __name__ == "__main__":
    logger.info("******** Source started!")

    while True:
        # получаем список устройств с уровнями сигналов для каждого якоря
        devices_list_anchor1 = scan_anchor('anchor1', SCAN_TIME)
        devices_list_anchor2 = scan_anchor('anchor2',
                                           SCAN_TIME)  # list of MyScanEntry

        # конвертируем децибелы в метры
        devices_list_meters_anchor1 = convert_from_dB_to_meters(
            devices_list_anchor1)
        devices_list_meters_anchor2 = convert_from_dB_to_meters(
            devices_list_anchor2)

        # переводим в формат для отправки
        data_for_send = make_body_request(devices_list_meters_anchor1,
                                          devices_list_meters_anchor2)

        logger.info(f"Data for send: {data_for_send}")

        # отправляем данные на backend
        send_data(data_for_send)
Exemplo n.º 8
0
    ('Modeling the Path to Disaster', 'Kim, Yoona;Suresh, Sahana;Tang, Sarah', 'racially differentiated risk,hurricane katrina,landscape in new orleans,la'),
    ('Natural skin care ', 'Ajayi, Iyioluwa;Nguyen, Vy ', 'skin care products,healthcare,environment,beauty'),
    ('Nature and Civilization Collide ', 'Anderson , Julia ', 'california topography,erosion,manmade structures'),
    ('Net-Zero Application', 'Acuna, Michelle', 'affordable housing,environmental justice,green architecture'),
    ('Oxford Tract Resistance', 'Hernandez, Lauren;White, Angela ', 'student activism,community engagement,environmental education'),
    ('Personal history of Chinese American women ', 'zhan, shuya', 'chinese immigration,resistance,women\'s role'),
    ('Pesticides', 'Li, Jeffrey;Le, Sabrina;Zhong, Justin', 'naled,ddt,methyl bromine,methyl bromide'),
    ('Project Short Story', 'Fann, Amy;Chu, Brenton', 'bp oil spill,identity,preservation of natural resources,environmental preservation'),
    ('Ceiling to the Sand', 'Campos, Josh', 'systemic poverty,resource management,power'),
    ('Sketch series on the Ohlone People\'s natural resource use and interaction', 'Wagner, Emily', 'ohlone,natural resources,interaction with nature'),
    ('The Chinese Immigrant Story', 'Lin, Helen;Thai, Thanh Thanh. ', 'chinese immigrant experience,california gold rush,transcontinental railroad'),
    ('The conflict of man and nature', 'Turnbull, Chase', 'man and nature,nature as sacred,nature as a resource'),
    ('the ecological Indian and his land ', 'Babikian, Karnie', 'woodland indians pre contact,cultural appreciation,niche in nature/land'),
    ('The Faces of Hurricane Katrina', 'Mateo, Crystal', 'hurricane katrina,individual impact,environmental racism'),
    ('The Gold Rush', 'Kim, Ashley', 'gold rush,mining,immigrants'),
    ('Hey, CAreful with that WATER', 'Wu, Lisa', 'change in landscape and land use in california'),
    ('Transition of American Views on Natural Resources', 'Kim, Heidi;Li, Amy', 'views of nature,native americans,europeans'),
]

pieces = [
    dict(zip([ 'title', 'authors', 'tags' ], row))
    for row in data
]

if __name__ == '__main__':
    sender.send_data(
        pieces=pieces,
        box_input_folder_id='57860927765',
        collection_name='sp17_0',
        semester_tag='sp17')
Exemplo n.º 9
0
port = 3001
# Create a UDP socket
sock = socket(AF_INET, SOCK_DGRAM)
sock.bind(('localhost', port))

print('Server rodando')

while True:
    data, addr = sender.receive_and_send_ack(sock)
    op, x, y = data.decode('utf-8').split()

    x = int(x)
    y = int(y)

    if (op == 'ADD'):
        res = x + y
    elif (op == 'SUB'):
        res = x - y
    elif (op == 'MULT'):
        res = x * y
    elif (op == 'DIV'):
        if (y == 0):
            res = 'Invalido'
        else:
            res = x / y
    elif (op == 'EXP'):
        res = x**y

    sender.send_data(sock, str(res).encode('utf-8'), addr)
Exemplo n.º 10
0
import sender
import receiver

time_for_receiving_data = 10

for _try_ in range(3):
    print("try", _try_ + 1)
    if sender.send_data() == True:
        print('now u can transmit data ')
        (is_data_received_correct,
         data) = receiver.data_received(time_for_receiving_data)

    else:
        print("data is not sent there is some problem in sender.py")
        is_data_received_correct = False

    if is_data_received_correct == True:

        address = data[7:0:-1] + data[0]
        print(" ADDRESS :", hex(int(address, 2)))

        control = data[15:7:-1]
        print("CONTROLL :", hex(int(control, 2)))

        information = data[16:-1] + data[-1]

        n = (len(information)) / 8
        for idx in range(n):
            temp = information[0:8]
            temp = temp[::-1]
            print("INFORMATIONA   " + str(n), hex(int(temp, 2)))